<div dir="ltr">reverted with r279277</div><br><div class="gmail_quote"><div dir="ltr">On Fri, Aug 19, 2016 at 1:42 AM Vitaly Buka <<a href="mailto:vitalybuka@google.com">vitalybuka@google.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">This revision was automatically updated to reflect the committed changes.<br>
Closed by commit rL279222: [asan] Fix size of shadow incorrectly calculated in r279178 (authored by vitalybuka).<br>
<br>
Changed prior to commit:<br>
  <a href="https://reviews.llvm.org/D23708?vs=68658&id=68659#toc" rel="noreferrer" target="_blank">https://reviews.llvm.org/D23708?vs=68658&id=68659#toc</a><br>
<br>
Repository:<br>
  rL LLVM<br>
<br>
<a href="https://reviews.llvm.org/D23708" rel="noreferrer" target="_blank">https://reviews.llvm.org/D23708</a><br>
<br>
Files:<br>
  llvm/trunk/lib/Transforms/Instrumentation/AddressSanitizer.cpp<br>
  llvm/trunk/test/Instrumentation/AddressSanitizer/stack-poisoning.ll<br>
<br>
Index: llvm/trunk/lib/Transforms/Instrumentation/AddressSanitizer.cpp<br>
===================================================================<br>
--- llvm/trunk/lib/Transforms/Instrumentation/AddressSanitizer.cpp<br>
+++ llvm/trunk/lib/Transforms/Instrumentation/AddressSanitizer.cpp<br>
@@ -2237,10 +2237,8 @@<br>
       IRBuilder<> IRBPoison(ThenTerm);<br>
       if (StackMallocIdx <= 4) {<br>
         int ClassSize = kMinStackMallocSize << StackMallocIdx;<br>
-        if ((int)ShadowBytesAfterReturn.size() != ClassSize) {<br>
-          ShadowBytesAfterReturn.resize(ClassSize,<br>
-                                        kAsanStackUseAfterReturnMagic);<br>
-        }<br>
+        ShadowBytesAfterReturn.resize(ClassSize >> Mapping.Scale,<br>
+                                      kAsanStackUseAfterReturnMagic);<br>
         poisonRedZones(ShadowBytesAfterReturn, IRBPoison, ShadowBase, true);<br>
         Value *SavedFlagPtrPtr = IRBPoison.CreateAdd(<br>
             FakeStack,<br>
Index: llvm/trunk/test/Instrumentation/AddressSanitizer/stack-poisoning.ll<br>
===================================================================<br>
--- llvm/trunk/test/Instrumentation/AddressSanitizer/stack-poisoning.ll<br>
+++ llvm/trunk/test/Instrumentation/AddressSanitizer/stack-poisoning.ll<br>
@@ -44,6 +44,7 @@<br>
   ; CHECK-UAR: store i64 -723401728380766731<br>
   ; CHECK-UAR: store i64 -723401728380766731<br>
   ; CHECK-UAR: store i64 -723401728380766731<br>
+  ; CHECK-UAR-NOT: store i64<br>
   ; CHECK-UAR: store i8 0<br>
   ; CHECK-UAR-NOT: store<br>
   ; CHECK-UAR: label<br>
<br>
<br>
</blockquote></div>