[PATCH] D69137: [profile] Do not cache __llvm_profile_get_filename result
Vedant Kumar via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Oct 17 16:49:19 PDT 2019
vsk added a comment.
In D69137#1713899 <https://reviews.llvm.org/D69137#1713899>, @davidxl wrote:
> maybe we should make lprofCurFilename hidden?
Oh, you mean to stop relying on the dynamic loader coalescing all copies of the symbol? I think that would be nice.
Currently the runtime only relies on a coalesced `lprofCurFilename` symbol to avoid truncating a raw profile twice (IIRC, if `FilenamePat` is set => do not truncate). But we could easily use `getenv`/`setenv` to accomplish the same thing. This might simplify the code, the only cost is parsing the filename repeatedly.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D69137/new/
https://reviews.llvm.org/D69137
More information about the llvm-commits
mailing list