[PATCH] Invariant intrinsic canonicalization
Philip Reames
listmail at philipreames.com
Mon Jul 21 10:45:58 PDT 2014
LGTM.
================
Comment at: lib/Transforms/InstCombine/InstCombineCalls.cpp:1004
@@ +1003,3 @@
+ if (match(IIOperand, m_And(m_Value(A), m_Value(B)))) {
+ Builder->CreateCall(II->getCalledValue(), A, II->getName());
+ Builder->CreateCall(II->getCalledValue(), B, II->getName());
----------------
Extracting out II->getCalledValue with a name like "AssumeIntrinsic" would make this code easier to understand on first glance.
http://reviews.llvm.org/D4491
More information about the llvm-commits
mailing list