[llvm-dev] [HWASAN] Is Buildbot missing hwasan tests?

Evgenii Stepanov via llvm-dev llvm-dev at lists.llvm.org
Wed Jan 2 13:53:15 PST 2019


This commit has added __hwasan_memset to compiler-rt:

commit 749bd83b08b7239f5d18c4e3095183919c68eb30
Author: Eugene Leviant <eleviant at accesssoftek.com>
Date:   Thu Dec 20 09:10:03 2018 +0000

    [HWASAN] Add support for memory intrinsics

    This is patch complements D55117 implementing __hwasan_mem*
    functions in runtime

    Differential revision: https://reviews.llvm.org/D55554

Notes:
    git-svn-rev: 349730

We run hwasan tests on
http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-android in
the "run lit tests" step on aarch64 android.

It looks like you are right about the x86_64-linux bot, we should add
check-hwasan there as well. I'll look into it.

On Wed, Jan 2, 2019 at 1:39 PM Chandler Carruth <chandlerc at gmail.com> wrote:
>
> +Evgenii Stepanov
>
> On Wed, Jan 2, 2019 at 10:42 AM David Greene via llvm-dev <llvm-dev at lists.llvm.org> wrote:
>>
>> After updating from trunk today, I am seeing this failure in hwasan:
>>
>> FAIL: HWAddressSanitizer-x86_64 :: TestCases/sizes.cpp (19011 of 49508)
>> ******************** TEST 'HWAddressSanitizer-x86_64 :: TestCases/sizes.cpp' FAILED ********************
>> <snip>
>> Command Output (stderr):
>> --
>> + : 'RUN: at line 1'
>> + /build/./bin/clang --driver-mode=g++ -fsanitize=hwaddress -mllvm -hwasan-generate-tags-with-calls -m64 -gline-tables-only /compiler-rt/test/hwasan/TestCases/sizes.cpp -lstdc++ -o /build/projects/compiler-rt/test/hwasan/X86_64/TestCases/Output/sizes.cpp.tmp
>> /install/binutils/x86_64/bin/ld.gold: warning: Cannot export local symbol '__hwasan_thread_enter'
>> /install/binutils/x86_64/bin/ld.gold: warning: Cannot export local symbol '__hwasan_thread_exit'
>> /install/binutils/x86_64/bin/ld.gold: warning: Cannot export local symbol '__hwasan_tls'
>> /tmp/lit_tmp_GtMlYc/sizes-acae44.o:sizes.cpp:function main: error: undefined reference to '__hwasan_memset'
>> /tmp/lit_tmp_GtMlYc/sizes-acae44.o:sizes.cpp:function main: error: undefined reference to '__hwasan_memset'
>> clang-8: error: linker command failed with exit code 1 (use -v to see invocation)
>>
>> I looked through the buildbots and I don't see anything that runs hwasan
>> tests.
>>
>> As far as I can tell, the hwasan tests are only run as part of check-all
>> when compiler-rt is included in a top-level LLVM build or as part of
>> check-hwasan.  No clang or llvm builder include compiler-rt AFAICT, so
>> check-all doesn't test it.  I don't see check-hwasan in this builder, or
>> any of the other sanitizer builders I checked:
>>
>> http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux/builds/18677
>>
>> Is there a hole in our testing?
>>
>> Anyone else seeing this failure?  Any idea of the cause?
>> "hwasan_memset" doesn't appear anywhere in compiler-rt's history, but it
>> shows up in LLVM:
>>
>> commit 631b5bc6125d979804e3e563935a93e2577e617c
>> Author: Eugene Leviant <eleviant at accesssoftek.com>
>> Date:   Thu Dec 20 09:04:33 2018 +0000
>>
>>     [HWASAN] Add support for memory intrinsics
>>
>>     Differential revision: https://reviews.llvm.org/D55117
>>
>>
>>     git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@349728 91177308-0d34-0410-b5e6-96231b3b80d8
>>
>> This commit turned on memory intrinsic instrumentation by default and is
>> the culprit, I'm guessing:
>>
>> commit 73121b2cc825d26b849e5c6fa04c690a6a35fb6e
>> Author: Eugene Leviant <eleviant at accesssoftek.com>
>> Date:   Mon Dec 24 16:02:48 2018 +0000
>>
>>     [HWASAN] Instrument memorty intrinsics by default
>>
>>     Differential revision: https://reviews.llvm.org/D55926
>>
>>
>>     git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@350055 91177308-0d34-0410-b5e6-96231b3b80d8
>>
>>                            -David
>> _______________________________________________
>> LLVM Developers mailing list
>> llvm-dev at lists.llvm.org
>> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev


More information about the llvm-dev mailing list