diff options
| -rw-r--r-- | lld/ELF/Writer.cpp | 6 | ||||
| -rw-r--r-- | lld/test/ELF/section-name.s | 2 |
2 files changed, 5 insertions, 3 deletions
diff --git a/lld/ELF/Writer.cpp b/lld/ELF/Writer.cpp index 8c5451ab058..8bb719a62ea 100644 --- a/lld/ELF/Writer.cpp +++ b/lld/ELF/Writer.cpp @@ -732,9 +732,9 @@ StringRef Writer<ELFT>::getOutputSectionName(InputSectionBase<ELFT> *S) const { return Dest; StringRef Name = S->getSectionName(); - for (StringRef V : - {".text.", ".rodata.", ".data.rel.ro.", ".data.", ".bss.", - ".init_array.", ".fini_array.", ".ctors.", ".dtors.", ".tbss."}) + for (StringRef V : {".text.", ".rodata.", ".data.rel.ro.", ".data.", ".bss.", + ".init_array.", ".fini_array.", ".ctors.", ".dtors.", + ".tbss.", ".gcc_except_table."}) if (Name.startswith(V)) return V.drop_back(); return Name; diff --git a/lld/test/ELF/section-name.s b/lld/test/ELF/section-name.s index 9e5deb1d4fc..3d82085c94b 100644 --- a/lld/test/ELF/section-name.s +++ b/lld/test/ELF/section-name.s @@ -22,9 +22,11 @@ _start: .section .data.rel.ro.local,"aw",%progbits .section .data.rel.ro.local.a,"aw",%progbits .section .tbss.foo,"aGwT",@nobits,foo,comdat +.section .gcc_except_table._Z1fIiEvv,"aG",@progbits,_Z1fIiEvv,comdat // CHECK-NOT: Name: .rodata.a // CHECK: Name: .rodata +// CHECK: Name: .gcc_except_table ({{.*}}) // CHECK-NOT: Name: .text.a // CHECK: Name: .text // CHECK: Name: .tbss ({{.*}}) |

