Inline single-use local variable

This commit is contained in:
Gary Gregory 2023-07-02 10:32:25 -04:00
parent 39fdca2da5
commit b773899854
1 changed files with 7 additions and 14 deletions

View File

@ -51,38 +51,31 @@ public class ArchUtils {
} }
private static void init_Aarch_64Bit() { private static void init_Aarch_64Bit() {
final Processor processor = new Processor(Processor.Arch.BIT_64, Processor.Type.AARCH_64); addProcessors(new Processor(Processor.Arch.BIT_64, Processor.Type.AARCH_64), "aarch64");
addProcessors(processor, "aarch64");
} }
private static void init_X86_32Bit() { private static void init_X86_32Bit() {
final Processor processor = new Processor(Processor.Arch.BIT_32, Processor.Type.X86); addProcessors(new Processor(Processor.Arch.BIT_32, Processor.Type.X86), "x86", "i386", "i486", "i586", "i686", "pentium");
addProcessors(processor, "x86", "i386", "i486", "i586", "i686", "pentium");
} }
private static void init_X86_64Bit() { private static void init_X86_64Bit() {
final Processor processor = new Processor(Processor.Arch.BIT_64, Processor.Type.X86); addProcessors(new Processor(Processor.Arch.BIT_64, Processor.Type.X86), "x86_64", "amd64", "em64t", "universal");
addProcessors(processor, "x86_64", "amd64", "em64t", "universal");
} }
private static void init_IA64_32Bit() { private static void init_IA64_32Bit() {
final Processor processor = new Processor(Processor.Arch.BIT_32, Processor.Type.IA_64); addProcessors(new Processor(Processor.Arch.BIT_32, Processor.Type.IA_64), "ia64_32", "ia64n");
addProcessors(processor, "ia64_32", "ia64n");
} }
private static void init_IA64_64Bit() { private static void init_IA64_64Bit() {
final Processor processor = new Processor(Processor.Arch.BIT_64, Processor.Type.IA_64); addProcessors(new Processor(Processor.Arch.BIT_64, Processor.Type.IA_64), "ia64", "ia64w");
addProcessors(processor, "ia64", "ia64w");
} }
private static void init_PPC_32Bit() { private static void init_PPC_32Bit() {
final Processor processor = new Processor(Processor.Arch.BIT_32, Processor.Type.PPC); addProcessors(new Processor(Processor.Arch.BIT_32, Processor.Type.PPC), "ppc", "power", "powerpc", "power_pc", "power_rs");
addProcessors(processor, "ppc", "power", "powerpc", "power_pc", "power_rs");
} }
private static void init_PPC_64Bit() { private static void init_PPC_64Bit() {
final Processor processor = new Processor(Processor.Arch.BIT_64, Processor.Type.PPC); addProcessors(new Processor(Processor.Arch.BIT_64, Processor.Type.PPC), "ppc64", "power64", "powerpc64", "power_pc64", "power_rs64");
addProcessors(processor, "ppc64", "power64", "powerpc64", "power_pc64", "power_rs64");
} }
/** /**