[llvm-commits] [llvm] r40745 - /llvm/trunk/lib/Analysis/BasicAliasAnalysis.cpp
Christopher Lamb
christopher.lamb at gmail.com
Thu Aug 2 10:52:00 PDT 2007
Author: clamb
Date: Thu Aug 2 12:52:00 2007
New Revision: 40745
URL: http://llvm.org/viewvc/llvm-project?rev=40745&view=rev
Log:
Implement review feedback.
Modified:
llvm/trunk/lib/Analysis/BasicAliasAnalysis.cpp
Modified: llvm/trunk/lib/Analysis/BasicAliasAnalysis.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Analysis/BasicAliasAnalysis.cpp?rev=40745&r1=40744&r2=40745&view=diff
==============================================================================
--- llvm/trunk/lib/Analysis/BasicAliasAnalysis.cpp (original)
+++ llvm/trunk/lib/Analysis/BasicAliasAnalysis.cpp Thu Aug 2 12:52:00 2007
@@ -311,25 +311,25 @@
// Pointing at a discernible object?
if (O1) {
if (O2) {
- if (isa<Argument>(O1)) {
+ if (const Argument *O1Arg = dyn_cast<Argument>(O1)) {
// Incoming argument cannot alias locally allocated object!
if (isa<AllocationInst>(O2)) return NoAlias;
// If they are two different objects, and one is a noalias argument
// then they do not alias.
- if (O1 != O2 && isNoAliasArgument(cast<Argument>(O1)))
+ if (O1 != O2 && isNoAliasArgument(O1Arg))
return NoAlias;
// Otherwise, nothing is known...
}
- if (isa<Argument>(O2)) {
+ if (const Argument *O2Arg = dyn_cast<Argument>(O2)) {
// Incoming argument cannot alias locally allocated object!
if (isa<AllocationInst>(O1)) return NoAlias;
// If they are two different objects, and one is a noalias argument
// then they do not alias.
- if (O1 != O2 && isNoAliasArgument(cast<Argument>(O2)))
+ if (O1 != O2 && isNoAliasArgument(O2Arg))
return NoAlias;
// Otherwise, nothing is known...
More information about the llvm-commits
mailing list