[PATCH] D147740: [llvm-profdata] Refactoring Sample Profile Reader to increase FDO build speed using MD5 as key to Sample Profile map

Arthur Eubanks via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 10 13:10:14 PDT 2023


aeubanks added a comment.

In D147740#4486533 <https://reviews.llvm.org/D147740#4486533>, @huangjd wrote:

> In D147740#4485824 <https://reviews.llvm.org/D147740#4485824>, @aeubanks wrote:
>
>> In D147740#4482560 <https://reviews.llvm.org/D147740#4482560>, @huangjd wrote:
>>
>>> In D147740#4479339 <https://reviews.llvm.org/D147740#4479339>, @aeubanks wrote:
>>>
>>>> can you repro the previous failure with the alignment sanitizer? then if that goes away with your fix it should be good
>>>
>>> I built it with `-DLLVM_USE_SANITIZER=Memory` and didn't see any (new) issue on X86, but I don't have a SPARC machine available to test on it. Is there another flag I need to use?
>>
>> alignment checking is a ubsan thing, not a msan thing, so it should be `-DLLVM_USE_SANITIZER=Undefined`. I believe that should enable alignment checking: https://clang.llvm.org/docs/UndefinedBehaviorSanitizer.html#available-checks
>
> That option does not work for me. Note that `-DLLVM_USE_SANITIZER` is an option in CMake configuration, but the list you gave is compiler options. I got the error `cc: error: unrecognized argument to ‘-fno-sanitize=’ option: ‘function’` when `DLLVM_USE_SANITIZER` is set to anything other than `Memory`. Could you show the exact command to build and run all tests with said sanitizer enabled?

`cmake -S llvm -B build/cmake -GNinja -DLLVM_TARGETS_TO_BUILD=X86 -DCMAKE_BUILD_TYPE=Release -DLLVM_USE_SANITIZER=Undefined -DLLVM_ENABLE_LLD=ON -DCMAKE_C_COMPILER=$HOME/repos/chromium/src/third_party/llvm-build/Release+Asserts/bin/clang -DCMAKE_CXX_COMPILER=$HOME/repos/chromium/src/third_party/llvm-build/Release+Asserts/bin/clang++` works for me. I'm using Chrome's toolchain which is a very close to ToT clang package, that error message seems to imply that the host compiler you're using isn't a recent clang.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D147740/new/

https://reviews.llvm.org/D147740



More information about the llvm-commits mailing list