summaryrefslogtreecommitdiff
path: root/lib/sanitizer_common/sanitizer_getauxval.h
AgeCommit message (Collapse)Author
2017-11-22[scudo] Overhaul hardware CRC32 feature detectionKostya Kortchinsky
Summary: This patch aims at condensing the hardware CRC32 feature detection and making it slightly more effective on Android. The following changes are included: - remove the `CPUFeature` enum, and get rid of one level of nesting of functions: we only used CRC32, so we just implement and use `hasHardwareCRC32`; - allow for a weak `getauxval`: the Android toolchain is compiled at API level 14 for Android ARM, meaning no `getauxval` at compile time, yet we will run on API level 27+ devices. The `/proc/self/auxv` fallback can work but is worthless for a process like `init` where the proc filesystem doesn't exist yet. If a weak `getauxval` doesn't exist, then fallback. - couple of extra corrections. Reviewers: alekseyshl Reviewed By: alekseyshl Subscribers: kubamracek, aemerson, srhines, kristof.beyls, llvm-commits Differential Revision: https://reviews.llvm.org/D40322 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@318859 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-21[sanitizer] Define SANITIZER_USE_GETAUXVAL for AndroidKostya Kortchinsky
Summary: Android for API level >= 21 has `getauxval`. Enable `SANITIZER_USE_GETAUXVAL` when those requirements are met. Correct a typo in the header. Reviewers: alekseyshl Reviewed By: alekseyshl Subscribers: srhines, llvm-commits, kubamracek Differential Revision: https://reviews.llvm.org/D40260 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@318775 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-06[LSan] Detect dynamic loader by its base address.Alex Shlyapnikov
Summary: Relanding D38600, which was reverted due to various PPC bot failures. If it breaks something again, please provide some pointers to broken bots, not just revert it, otherwise it's very hard to reason what's wrong with this commit. Whenever possible (Linux + glibc 2.16+), detect dynamic loader module by its base address, not by the module name matching. The current name matching approach fails on some configurations. Reviewers: eugenis Subscribers: kubamracek, llvm-commits Differential Revision: https://reviews.llvm.org/D39275 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317512 91177308-0d34-0410-b5e6-96231b3b80d8