[PATCH] D146208: [ASAN] Support memory checks on vp.load/store.

Philip Reames via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 16 07:51:34 PDT 2023


reames requested changes to this revision.
reames added inline comments.
This revision now requires changes to proceed.


================
Comment at: llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp:1475
+  // Skip if EVL has wider type then IntptrTy.
+  if (EVL && IntptrTy->getPrimitiveSizeInBits() < 32)
+    return;
----------------
This looks wrong?  What does the bitwidth have to do with the *value* of EVL?


================
Comment at: llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp:1487
+      if (EVL) {
+        Value *ExtEVL = IRB.CreateZExt(EVL, IntptrTy);
+        Value *InEVLRange = IRB.CreateICmpULT(Index, ExtEVL);
----------------
I may be missing something here, but isn't EVL just an upper bound on the loop?  If so, maybe we shouldn't use for the ForEachLane variant and should instead have a variant which takes End explicitly?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D146208



More information about the llvm-commits mailing list