[PATCH] D128950: Add 'sanitize_memtag' Global IR attribute

Evgenii Stepanov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 7 15:06:50 PDT 2022


eugenis added inline comments.


================
Comment at: llvm/include/llvm/IR/GlobalValue.h:321
+    // optimisations, whereas ASan/HWASan simply rewrites the global variable
+    // and accesses, and doesn't need to interact with other parts of LLVM.
+    //
----------------
This paragraph explains why we need the include bit, but not the exclude bit.
Why do we need both?
IR backward compatibility?


================
Comment at: llvm/test/Assembler/globalvariable-attributes.ll:13
+ at g10 = global i32 2, sanitize_memtag, align 4
+ at g11 = global i32 2, no_sanitize_memtag, sanitize_memtag, align 4
+ at g12 = global i32 2, no_sanitize_address, no_sanitize_hwaddress, sanitize_memtag, align 4
----------------
can we ban both attrs on the same global?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D128950



More information about the llvm-commits mailing list