[PATCH] D17502: [ELF] - Fix of 22906, referencing __start or __stop should keep the section from GC.
Rui Ueyama via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 24 10:49:43 PST 2016
ruiu added a comment.
LGTM with a nit.
================
Comment at: ELF/MarkLive.cpp:90
@@ -83,3 +89,3 @@
template <class ELFT> void elf2::markLive(SymbolTable<ELFT> *Symtab) {
SmallVector<InputSection<ELFT> *, 256> Q;
----------------
Yes, I wanted to avoid hash table lookup here, and also the code duplication (although it is just 8 lines of code) was my concern. This is a small corner case so I think we want to avoid overdesigning stuff but just make it work with a minimal amount of work.
================
Comment at: test/ELF/startstop-gccollect.s:1
@@ +1,2 @@
+# REQUIRES: x86
+# RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t
----------------
You want to remove __start and __stop symbols from the test and just verify that we do not reclaim sections if their section names are valid C identifiers.
http://reviews.llvm.org/D17502
More information about the llvm-commits
mailing list