[PATCH] DataFlowSanitizer; LLVM changes.
Evgeniy Stepanov
eugenis at google.com
Mon Jul 1 06:19:48 PDT 2013
================
Comment at: lib/Transforms/Instrumentation/DataFlowSanitizer.cpp:656
@@ +655,3 @@
+ Ofs += 64 / DFS.ShadowWidth) {
+ BasicBlock *NextBB = BasicBlock::Create(*DFS.Ctx, "", F);
+ IRBuilder<> NextIRB(NextBB);
----------------
You creating are a lot of basic blocks here. Would it be better to make a loop here an leave it to the loop unroller to make the decision?
On the other hand, in practice Size must be very limited.
================
Comment at: lib/Transforms/Instrumentation/DataFlowSanitizer.cpp:723
@@ +722,3 @@
+ uint64_t Offset = 0;
+ if (Size >= ShadowVecSize) {
+ VectorType *ShadowVecTy = VectorType::get(DFS.ShadowTy, ShadowVecSize);
----------------
This looks like an optimization that belongs elsewhere. I wonder if there is a pass in LLVM that will do it for you?
Also, why 128 bit code here, and only 64 bit in LoadShadow?
http://llvm-reviews.chandlerc.com/D965
More information about the llvm-commits
mailing list