[llvm] r196574 - [asan] fix ndebug build with strict warnings (-Wunused-variable)
Kostya Serebryany
kcc at google.com
Fri Dec 6 01:26:09 PST 2013
Author: kcc
Date: Fri Dec 6 03:26:09 2013
New Revision: 196574
URL: http://llvm.org/viewvc/llvm-project?rev=196574&view=rev
Log:
[asan] fix ndebug build with strict warnings (-Wunused-variable)
Modified:
llvm/trunk/lib/Transforms/Utils/ASanStackFrameLayout.cpp
Modified: llvm/trunk/lib/Transforms/Utils/ASanStackFrameLayout.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Utils/ASanStackFrameLayout.cpp?rev=196574&r1=196573&r2=196574&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Utils/ASanStackFrameLayout.cpp (original)
+++ llvm/trunk/lib/Transforms/Utils/ASanStackFrameLayout.cpp Fri Dec 6 03:26:09 2013
@@ -78,6 +78,7 @@ ComputeASanStackFrameLayout(SmallVectorI
for (size_t i = 0; i < NumVars; i++) {
bool IsLast = i == NumVars - 1;
size_t Alignment = std::max(Granularity, Vars[i].Alignment);
+ (void)Alignment; // Used only in asserts.
size_t Size = Vars[i].Size;
const char *Name = Vars[i].Name;
assert((Alignment & (Alignment - 1)) == 0);
More information about the llvm-commits
mailing list