[all-commits] [llvm/llvm-project] 811f95: [compiler-rt][hwasan] Factor out CanUseTaggingAbi(...

Alexander Potapenko via All-commits all-commits at lists.llvm.org
Thu Aug 25 01:45:41 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 811f958eef9a105a9ef7bafc36fae6ab17000e1a
      https://github.com/llvm/llvm-project/commit/811f958eef9a105a9ef7bafc36fae6ab17000e1a
  Author: Alexander Potapenko <glider at google.com>
  Date:   2022-08-25 (Thu, 25 Aug 2022)

  Changed paths:
    M compiler-rt/lib/hwasan/hwasan_linux.cpp

  Log Message:
  -----------
  [compiler-rt][hwasan] Factor out CanUseTaggingAbi() and EnableTaggingAbi()

Simplify InitializeOsSupport() by separating code for detecting and
enabling the tagged address ABI.

Also drop the unnecessary errno checks (regardless of errno value, we
cannot assume that tagging works if the system call failed) and ensure
prctl(PR_SET_TAGGED_ADDR_CTRL) is only called on Android, not on x86
(where arch_prctl(ARCH_ENABLE_TAGGED_ADDR, kTagBits) is used).

Depends on D132544

Differential Revision: https://reviews.llvm.org/D132545




More information about the All-commits mailing list