[PATCH] D26230: [AddressSanitizer] Add support for (constant-)masked loads and stores.

Filipe Cabecinhas via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 15 13:47:46 PST 2016


filcab marked an inline comment as done.
filcab added inline comments.


================
Comment at: lib/Transforms/Instrumentation/AddressSanitizer.cpp:996
 /// If I is an interesting memory access, return the PointerOperand
 /// and set IsWrite/Alignment. Otherwise return nullptr.
 Value *AddressSanitizer::isInterestingMemoryAccess(Instruction *I,
----------------
RKSimon wrote:
> Add MaybeMask description to comment.
Deleted this one, since there's no reason to have those comments on both the prototype and impl.


================
Comment at: lib/Transforms/Instrumentation/AddressSanitizer.cpp:1064
+          *Alignment = 1; // No alignment guarantees. We probably got Undef
+        if (MaybeMask)
+          *MaybeMask = CI->getOperand(2 + OpOffset);
----------------
vitalybuka wrote:
> You don't call this with nullptr, so for consistency with other output arguments i'd remove "if (MaybeMask)" check
It's called in many places outside the function I changed, though.
In the future we will need to refactor this to support scatter/gathers, so I'd like to avoid doing too much now.


https://reviews.llvm.org/D26230





More information about the llvm-commits mailing list