Skip to content

Commit cd6f4cc

Browse files
authored
[LLD][COFF][NFC] Use CHPE version 2 in tests (#109872)
1 parent 22829f7 commit cd6f4cc

File tree

2 files changed

+18
-25
lines changed

2 files changed

+18
-25
lines changed

lld/test/COFF/Inputs/loadconfig-arm64ec.s

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -42,12 +42,6 @@ __os_arm64x_check_icall_cfg:
4242
.xword 0
4343
__os_arm64x_dispatch_fptr:
4444
.xword 0
45-
__os_arm64x_helper0:
46-
.xword 0
47-
__os_arm64x_helper1:
48-
.xword 0
49-
__os_arm64x_helper2:
50-
.xword 0
5145
__os_arm64x_helper3:
5246
.xword 0
5347
__os_arm64x_helper4:
@@ -65,7 +59,7 @@ __os_arm64x_helper8:
6559
.globl __chpe_metadata
6660
.p2align 3, 0
6761
__chpe_metadata:
68-
.word 1
62+
.word 2
6963
.rva __hybrid_code_map
7064
.word __hybrid_code_map_count
7165
.rva __x64_code_ranges_to_entry_points
@@ -85,9 +79,9 @@ __chpe_metadata:
8579
.word __arm64x_extra_rfe_table_size
8680
.rva __os_arm64x_dispatch_fptr
8781
.rva __hybrid_auxiliary_iat_copy
88-
.rva __os_arm64x_helper0
89-
.rva __os_arm64x_helper1
90-
.rva __os_arm64x_helper2
82+
.word 0 // __hybrid_auxiliary_delayload_iat
83+
.word 0 // __hybrid_auxiliary_delayload_iat_copy
84+
.word 0 // __hybrid_image_info_bitfield
9185
.rva __os_arm64x_helper3
9286
.rva __os_arm64x_helper4
9387
.rva __os_arm64x_helper5

lld/test/COFF/arm64ec-import.test

Lines changed: 14 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ RUN: llvm-readobj --coff-imports out2.dll | FileCheck --check-prefix=IMPORTS %s
2727
RUN: llvm-readobj --coff-imports out3.dll | FileCheck -check-prefix=IMPORTS %s
2828
IMPORTS: Import {
2929
IMPORTS-NEXT: Name: test.dll
30-
IMPORTS-NEXT: ImportLookupTableRVA: 0x4230
30+
IMPORTS-NEXT: ImportLookupTableRVA: 0x4218
3131
IMPORTS-NEXT: ImportAddressTableRVA: 0x3000
3232
IMPORTS-NEXT: Symbol: data (0)
3333
IMPORTS-NEXT: Symbol: func (0)
@@ -79,13 +79,13 @@ RUN: llvm-readobj --hex-dump=.test out2.dll | FileCheck --check-prefix=TESTSEC %
7979
TESTSEC: 0x180007000 08500000 00300000 10500000 20500000
8080
TESTSEC-NEXT: 0x180007010 08300000 00500000 10300000 20300000
8181
TESTSEC-NEXT: 0x180007020 14100000 28100000 00200000 08100000
82-
TESTSEC-NEXT: 0x180007030 3c100000 a0420000
82+
TESTSEC-NEXT: 0x180007030 3c100000 88420000
8383

8484
RUN: llvm-readobj --hex-dump=.test out3.dll | FileCheck -check-prefix=TESTSEC-X64 %s
8585
TESTSEC-X64: 0x180007000 08300000 00300000 10300000 20300000
8686
TESTSEC-X64-NEXT: 0x180007010 08300000 00500000 10300000 20300000
8787
TESTSEC-X64-NEXT: 0x180007020 14100000 28100000 00200000 08100000
88-
TESTSEC-X64-NEXT: 0x180007030 3c100000 a0420000
88+
TESTSEC-X64-NEXT: 0x180007030 3c100000 88420000
8989

9090
RUN: FileCheck --check-prefix=MAP %s < out.map
9191
RUN: FileCheck --check-prefix=MAP %s < out2.map
@@ -100,10 +100,10 @@ MAP-NEXT: 0002:00000000 __imp_data 0000000180003000 te
100100
MAP-NEXT: 0002:00000008 __imp_aux_func 0000000180003008 test{{.*}}:test.dll
101101
MAP-NEXT: 0002:00000010 __imp_aux_func2 0000000180003010 test{{.*}}:test.dll
102102
MAP-NEXT: 0002:00000020 __imp_aux_t2func 0000000180003020 test2{{.*}}:test2.dll
103-
MAP: 0002:00001298 __auximpcopy_data 0000000180004298 test{{.*}}:test.dll
104-
MAP-NEXT: 0002:000012a0 __auximpcopy_func 00000001800042a0 test{{.*}}:test.dll
105-
MAP-NEXT: 0002:000012a8 __auximpcopy_func2 00000001800042a8 test{{.*}}:test.dll
106-
MAP-NEXT: 0002:000012b8 __auximpcopy_t2func 00000001800042b8 test2{{.*}}:test2.dll
103+
MAP: 0002:00001280 __auximpcopy_data 0000000180004280 test{{.*}}:test.dll
104+
MAP-NEXT: 0002:00001288 __auximpcopy_func 0000000180004288 test{{.*}}:test.dll
105+
MAP-NEXT: 0002:00001290 __auximpcopy_func2 0000000180004290 test{{.*}}:test.dll
106+
MAP-NEXT: 0002:000012a0 __auximpcopy_t2func 00000001800042a0 test2{{.*}}:test2.dll
107107
MAP: 0002:00002000 __imp_aux_data 0000000180005000 test{{.*}}:test.dll
108108
MAP-NEXT: 0002:00002008 __imp_func 0000000180005008 test{{.*}}:test.dll
109109
MAP-NEXT: 0002:00002010 __imp_func2 0000000180005010 test{{.*}}:test.dll
@@ -120,15 +120,14 @@ RUN: llvm-readobj --coff-load-config out.dll | FileCheck -check-prefix=LOADCONFI
120120
RUN: llvm-readobj --coff-load-config out2.dll | FileCheck -check-prefix=LOADCONFIG %s
121121
RUN: llvm-readobj --coff-load-config out3.dll | FileCheck -check-prefix=LOADCONFIG %s
122122
LOADCONFIG: AuxiliaryIAT: 0x5000
123-
LOADCONFIG: AuxiliaryIATCopy: 0x4298
123+
LOADCONFIG: AuxiliaryIATCopy: 0x4280
124124

125125
RUN: llvm-readobj --hex-dump=.rdata out.dll | FileCheck -check-prefix=RDATA %s
126126
RUN: llvm-readobj --hex-dump=.rdata out2.dll | FileCheck -check-prefix=RDATA %s
127127
RUN: llvm-readobj --hex-dump=.rdata out3.dll | FileCheck -check-prefix=RDATA %s
128-
RDATA: 0x180004290 2e646c6c 00000000 00000000 00000000
129-
RDATA-NEXT: 0x1800042a0 14100080 01000000 28100080 01000000
130-
RDATA-NEXT: 0x1800042b0 00000000 00000000 48100080 01000000
131-
RDATA-NEXT: 0x1800042c0 00000000 00000000 00000000 00000000
128+
RDATA: 0x180004280 00000000 00000000 14100080 01000000
129+
RDATA-NEXT: 0x180004290 28100080 01000000 00000000 00000000
130+
RDATA-NEXT: 0x1800042a0 48100080 01000000 00000000 00000000
132131
RDATA: 0x180005000 00000000 00000000 14100080 01000000
133132
RDATA-NEXT: 0x180005010 28100080 01000000 00000000 00000000
134133
RDATA-NEXT: 0x180005020 48100080 01000000 00000000 00000000
@@ -138,15 +137,15 @@ RUN: llvm-readobj --coff-basereloc out2.dll | FileCheck -check-prefix=BASERELOC
138137
RUN: llvm-readobj --coff-basereloc out3.dll | FileCheck -check-prefix=BASERELOC %s
139138
BASERELOC: BaseReloc [
140139
Aux IAT copy:
141-
BASERELOC: Address: 0x42A0
140+
BASERELOC: Address: 0x4288
142141
BASERELOC-NEXT: }
143142
BASERELOC-NEXT: Entry {
144143
BASERELOC-NEXT: Type: DIR64
145-
BASERELOC-NEXT: Address: 0x42A8
144+
BASERELOC-NEXT: Address: 0x4290
146145
BASERELOC-NEXT: }
147146
BASERELOC-NEXT: Entry {
148147
BASERELOC-NEXT: Type: DIR64
149-
BASERELOC-NEXT: Address: 0x42B8
148+
BASERELOC-NEXT: Address: 0x42A0
150149
BASERELOC-NEXT: }
151150
Aux IAT:
152151
BASERELOC-NOT: Address: 0x5000

0 commit comments

Comments
 (0)