authorgravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2024-07-24 05:49:31+02:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2024-07-24 15:02:55-07:00
logbe56c67b1444632a719db2aac9a8476c2911b882
tree7f81dbe9952dec05ee9ee4a0325d3901a9179884
parent4de8bba648c6ab9e2f3a05f3f90ba6524520d3c0

std.coff: Add missing entries to MachineType.

Sources: * https://learn.microsoft.com/en-us/windows/win32/sysinfo/image-file-machine-constants * https://github.com/wine-mirror/wine/blob/88a28aa5757ae74d9997b470d70216f10974247f/include/winnt.h#L2720-L2758

1 files changed, 20 insertions(+), 0 deletions(-)

lib/std/coff.zig+20
...@@ -984,6 +984,10 @@ pub const DebugInfoDefinition = struct {...@@ -984,6 +984,10 @@ pub const DebugInfoDefinition = struct {
984984
985pub const MachineType = enum(u16) {985pub const MachineType = enum(u16) {
986 Unknown = 0x0,986 Unknown = 0x0,
987 /// Alpha AXP, 32-bit address space
988 ALPHA = 0x184,
989 /// Alpha 64, 64-bit address space
990 ALPHA64 = 0x284,
987 /// Matsushita AM33991 /// Matsushita AM33
988 AM33 = 0x1d3,992 AM33 = 0x1d3,
989 /// x64993 /// x64
...@@ -994,8 +998,16 @@ pub const MachineType = enum(u16) {...@@ -994,8 +998,16 @@ pub const MachineType = enum(u16) {
994 ARM64 = 0xaa64,998 ARM64 = 0xaa64,
995 /// ARM64EC999 /// ARM64EC
996 ARM64EC = 0xa641,1000 ARM64EC = 0xa641,
1001 /// ARM64X
1002 ARM64X = 0xa64e,
997 /// ARM Thumb-2 little endian1003 /// ARM Thumb-2 little endian
998 ARMNT = 0x1c4,1004 ARMNT = 0x1c4,
1005 /// CEE
1006 CEE = 0xc0ee,
1007 /// CEF
1008 CEF = 0xcef,
1009 /// Hybrid PE
1010 CHPE_X86 = 0x3a64,
999 /// EFI byte code1011 /// EFI byte code
1000 EBC = 0xebc,1012 EBC = 0xebc,
1001 /// Intel 386 or later processors and compatible processors1013 /// Intel 386 or later processors and compatible processors
...@@ -1019,7 +1031,11 @@ pub const MachineType = enum(u16) {...@@ -1019,7 +1031,11 @@ pub const MachineType = enum(u16) {
1019 /// Power PC with floating point support1031 /// Power PC with floating point support
1020 POWERPCFP = 0x1f1,1032 POWERPCFP = 0x1f1,
1021 /// MIPS little endian1033 /// MIPS little endian
1034 R3000 = 0x162,
1035 /// MIPS little endian
1022 R4000 = 0x166,1036 R4000 = 0x166,
1037 /// MIPS little endian
1038 R10000 = 0x168,
1023 /// RISC-V 32-bit address space1039 /// RISC-V 32-bit address space
1024 RISCV32 = 0x5032,1040 RISCV32 = 0x5032,
1025 /// RISC-V 64-bit address space1041 /// RISC-V 64-bit address space
...@@ -1030,12 +1046,16 @@ pub const MachineType = enum(u16) {...@@ -1030,12 +1046,16 @@ pub const MachineType = enum(u16) {
1030 SH3 = 0x1a2,1046 SH3 = 0x1a2,
1031 /// Hitachi SH3 DSP1047 /// Hitachi SH3 DSP
1032 SH3DSP = 0x1a3,1048 SH3DSP = 0x1a3,
1049 /// SH3E little-endian
1050 SH3E = 0x1a4,
1033 /// Hitachi SH41051 /// Hitachi SH4
1034 SH4 = 0x1a6,1052 SH4 = 0x1a6,
1035 /// Hitachi SH51053 /// Hitachi SH5
1036 SH5 = 0x1a8,1054 SH5 = 0x1a8,
1037 /// Thumb1055 /// Thumb
1038 Thumb = 0x1c2,1056 Thumb = 0x1c2,
1057 /// Infineon
1058 TRICORE = 0x520,
1039 /// MIPS little-endian WCE v21059 /// MIPS little-endian WCE v2
1040 WCEMIPSV2 = 0x169,1060 WCEMIPSV2 = 0x169,
10411061