[llvm] r203558 - GVN: fix hashing of extractvalue.
Erik Verbruggen
erikjv at me.com
Tue Mar 11 03:21:30 PDT 2014
Author: erikjv
Date: Tue Mar 11 05:21:30 2014
New Revision: 203558
URL: http://llvm.org/viewvc/llvm-project?rev=203558&view=rev
Log:
GVN: fix hashing of extractvalue.
My last commit did not add the indexes to the hashed value for
extractvalue. Adding that back in.
Modified:
llvm/trunk/lib/Transforms/Scalar/GVN.cpp
Modified: llvm/trunk/lib/Transforms/Scalar/GVN.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/GVN.cpp?rev=203558&r1=203557&r2=203558&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/GVN.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/GVN.cpp Tue Mar 11 05:21:30 2014
@@ -189,6 +189,10 @@ Expression ValueTable::create_expression
for (InsertValueInst::idx_iterator II = E->idx_begin(), IE = E->idx_end();
II != IE; ++II)
e.varargs.push_back(*II);
+ } else if (ExtractValueInst *EVI = dyn_cast<ExtractValueInst>(I)) {
+ for (ExtractValueInst::idx_iterator II = EVI->idx_begin(),
+ IE = EVI->idx_end(); II != IE; ++II)
+ e.varargs.push_back(*II);
}
return e;
More information about the llvm-commits
mailing list