Skip to content

Commit

Permalink
[MC] [Win64EH] Update the AArch64/seh.s test slightly. NFC.
Browse files Browse the repository at this point in the history
Update the comment stating the aim of the test - this is currently
only checking that these assembler directives doesn't cause the
assembler to fail, but the results of the testcase aren't particularly
correct yet.

Remove bits of the testcase that are even less likely to be found in
the wild (the .seh_startchained/.seh_endchained block), where the
testcase currently doesn't really generate anything interesting
anyway.

Differential Revision: https://reviews.llvm.org/D86524
  • Loading branch information
mstorsjo committed Aug 26, 2020
1 parent db259fe commit b07d78b
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions llvm/test/MC/AArch64/seh.s
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// This test checks that the SEH directives emit the correct unwind data.
// This test checks that the SEH directives don't cause the assembler to fail.

// RUN: llvm-mc -triple aarch64-pc-win32 -filetype=obj %s | llvm-readobj -S -r - | FileCheck %s

Expand All @@ -15,7 +15,7 @@
// CHECK-NEXT: }
// CHECK: Section {
// CHECK: Name: .xdata
// CHECK: RawDataSize: 24
// CHECK: RawDataSize: 20
// CHECK: RelocationCount: 1
// CHECK: Characteristics [
// CHECK-NEXT: ALIGN_4BYTES
Expand All @@ -25,7 +25,7 @@
// CHECK-NEXT: }
// CHECK: Section {
// CHECK: Name: .pdata
// CHECK: RelocationCount: 6
// CHECK: RelocationCount: 4
// CHECK: Characteristics [
// CHECK-NEXT: ALIGN_4BYTES
// CHECK-NEXT: CNT_INITIALIZED_DATA
Expand All @@ -41,10 +41,8 @@
// CHECK-NEXT: Section (5) .pdata {
// CHECK-NEXT: 0x0 IMAGE_REL_ARM64_ADDR32NB func
// CHECK-NEXT: 0x4 IMAGE_REL_ARM64_ADDR32NB .xdata
// CHECK-NEXT: 0x8 IMAGE_REL_ARM64_ADDR32NB func
// CHECK-NEXT: 0x8 IMAGE_REL_ARM64_ADDR32NB smallFunc
// CHECK-NEXT: 0xC IMAGE_REL_ARM64_ADDR32NB .xdata
// CHECK-NEXT: 0x10 IMAGE_REL_ARM64_ADDR32NB smallFunc
// CHECK-NEXT: 0x14 IMAGE_REL_ARM64_ADDR32NB .xdata
// CHECK-NEXT: }
// CHECK-NEXT: ]

Expand All @@ -65,9 +63,6 @@ func:
.seh_handlerdata
.long 0
.text
.seh_startchained
.seh_endprologue
.seh_endchained
add sp, sp, #24
ret
.seh_endproc
Expand Down

0 comments on commit b07d78b

Please sign in to comment.