[PATCH] D39548: [ELF] Set the section size on the section start symbols

Rui Ueyama via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 6 17:02:31 PST 2017


ruiu added a comment.

I think I understood your motivation to make this change, but it feels like this is still too specific to your target. Traditionally, these start/end symbols are NOTYPE symbols with size zero, and they are used as markers where their corresponding sections start/end. So, my understanding is that start symbols just point to where sections begin, and they do not "cover" sections, as the name implies. So, this change doesn't feel semantically correct to me.

In addition to that, because these symbols are being used in the wild since (I believe) the early Unix era, there's a chance that compatibility issues would arise if you change the symbol values. It seems a bit too risky. It's probably an unavoidable consequence that if you choose ELF as a file format, you'll have start/end symbols with size zero.

I wonder if you have thought about doing this in your loader. Your loader could identify start/end symbols and fix their values, couldn't it?


https://reviews.llvm.org/D39548





More information about the llvm-commits mailing list