[PATCH] D133392: [MTE] Add AArch64GlobalsTagging Pass

Florian Mayer via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Sep 6 18:19:38 PDT 2022


fmayer added inline comments.


================
Comment at: llvm/lib/Target/AArch64/AArch64GlobalsTagging.cpp:60
+  // gadgets.
+  if (G.getName().startswith("llvm.") || G.isThreadLocal() || G.isConstant()) {
+    Meta.Memtag = false;
----------------
not necessarily in this CL: do we want some attribute to turn off instrumentation?


================
Comment at: llvm/lib/Target/AArch64/AArch64GlobalsTagging.cpp:98
+    // Pad the initializer out to the next multiple of 16 bytes.
+    std::vector<uint8_t> Init(NewSize - SizeInBytes, 0);
+    Constant *Padding = ConstantDataArray::get(M.getContext(), Init);
----------------
can we use the SmallVector here?


================
Comment at: llvm/lib/Target/AArch64/AArch64GlobalsTagging.cpp:108
+
+    Value *Indices2[2];
+    IRBuilder<> IRB(M.getContext());
----------------
what does this do?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D133392



More information about the cfe-commits mailing list