[PATCH] D25627: [ELF] Convert linker generated sections to input sections
Eugene Leviant via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 31 06:05:25 PDT 2016
evgeny777 added inline comments.
================
Comment at: ELF/InputSection.cpp:863
+ memcpy(Buf.data() + 12, "GNU", 4); // Name string
+ this->Data = ArrayRef<uint8_t>(Buf);
+}
----------------
ruiu wrote:
> Here, you fill the internal buffer with data, which to be memcpy'ed to the final output buffer. I think we don't want to do that. Instead, we want to virtualize InputFile's `writeTo` so that each input section will directly write to the output buffer.
Besides writeTo one will also have to virtualize getSize(), in order for assignOffsets to work properly
https://reviews.llvm.org/D25627
More information about the llvm-commits
mailing list