[PATCH] D49094: Reduce memory usage when creating .gdb_index. NFC.

Rui Ueyama via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 10 05:02:55 PDT 2018


ruiu added inline comments.


================
Comment at: lld/ELF/SyntheticSections.cpp:2499
+    memcpy(Buf + Sym.OutputOff, S.data(), S.size());
+    Buf[Sym.OutputOff + S.size()] = '\0';
   }
----------------
grimar wrote:
> You are assuming at line 2475 that buffer is filled with zeroes. I think you can omit this line then.
Ah, good point. I've never thought of it, but that's true.


https://reviews.llvm.org/D49094





More information about the llvm-commits mailing list