This is an archive of the discontinued LLVM Phabricator instance.

[lsan] [aarch64] Fix printing of pointers in make check tests
ClosedPublic

Authored by spetrovic on Oct 5 2016, 4:35 AM.

Details

Summary

This patch replaces fprintf with print_address function in LSAN tests. This is necessary because of different printing of pointers in fprintf and sanitizer's print function. After this patch is committed, we can enable make check-lsan option on aarch64 architecture.

Diff Detail

Event Timeline

spetrovic updated this revision to Diff 73620.Oct 5 2016, 4:35 AM
spetrovic retitled this revision from to [lsan] [aarch64] Fix printing of pointers in make check tests.
spetrovic updated this object.
spetrovic added subscribers: llvm-commits, petarj, ivanbaev.
peter.smith accepted this revision.Oct 6 2016, 4:45 AM
peter.smith edited edge metadata.

This looks good to me. I can't see any problems with changing from fprintf.

This revision is now accepted and ready to land.Oct 6 2016, 4:45 AM
kcc added a subscriber: kcc.Oct 20 2016, 1:08 PM

This does not look good to me
Why would lsan tests include ../../tsan/test.h ?

At the very least this header should be moved into a common dir

In tsan/test.h is function print_address, I didn't see any common folder with header files in santizer tests, so I take this function from tsan.h. Do you have proposal for the common place ?

kcc added a comment.Oct 24 2016, 1:13 PM

In tsan/test.h is function print_address, I didn't see any common folder with header files in santizer tests, so I take this function from tsan.h. Do you have proposal for the common place ?

I would create a separate header file with print_address in test/sanitizer_common

kcc added a comment.Oct 27 2016, 11:39 AM

Ping?
This is a minor problem but I don't like that the change was made and reviewed by non-owners and the problem is not being fixed.

spetrovic updated this revision to Diff 76193.Oct 28 2016, 8:45 AM
spetrovic edited edge metadata.

Comments addressed.

kcc added a comment.Oct 28 2016, 8:55 AM

This patch was already submitted, so no reason to update the review here.
Please create a separate patch.

spetrovic closed this revision.Nov 22 2016, 2:18 AM