summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lld/test/ELF/gc-sections-eh.s13
1 files changed, 13 insertions, 0 deletions
diff --git a/lld/test/ELF/gc-sections-eh.s b/lld/test/ELF/gc-sections-eh.s
index 042b68ebdfe..88c3dd0d9ca 100644
--- a/lld/test/ELF/gc-sections-eh.s
+++ b/lld/test/ELF/gc-sections-eh.s
@@ -1,10 +1,23 @@
# REQUIRES: x86
# RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t
+
# RUN: ld.lld %t -o %t2 --gc-sections
# RUN: llvm-readobj -t %t2 | FileCheck %s
+# RUN: llvm-objdump --dwarf=frames %t2 | FileCheck --check-prefix=EH %s
+
+# RUN: ld.lld %t -o %t3
+# RUN: llvm-readobj -t %t3 | FileCheck --check-prefix=NOGC %s
+# RUN: llvm-objdump --dwarf=frames %t3 | FileCheck --check-prefix=EHNOGC %s
# CHECK-NOT: foo
+# NOGC: foo
+
+# EH: FDE cie={{.*}} pc=
+# EH-NOT: FDE
+
+# EHNOGC: FDE cie={{.*}} pc=
+# EHNOGC: FDE cie={{.*}} pc=
.section .text,"ax",@progbits,unique,0
.globl foo
OpenPOWER on IntegriCloud