[cfe-commits] r41444 - in /cfe/trunk/CodeGen: CGDecl.cpp CGExpr.cpp CGExprComplex.cpp CGStmt.cpp CodeGenFunction.h
Chris Lattner
sabre at nondot.org
Sun Aug 26 09:22:14 PDT 2007
Author: lattner
Date: Sun Aug 26 11:22:13 2007
New Revision: 41444
URL: http://llvm.org/viewvc/llvm-project?rev=41444&view=rev
Log:
be slightly more volatile correct
Modified:
cfe/trunk/CodeGen/CGDecl.cpp
cfe/trunk/CodeGen/CGExpr.cpp
cfe/trunk/CodeGen/CGExprComplex.cpp
cfe/trunk/CodeGen/CGStmt.cpp
cfe/trunk/CodeGen/CodeGenFunction.h
Modified: cfe/trunk/CodeGen/CGDecl.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/CodeGen/CGDecl.cpp?rev=41444&r1=41443&r2=41444&view=diff
==============================================================================
--- cfe/trunk/CodeGen/CGDecl.cpp (original)
+++ cfe/trunk/CodeGen/CGDecl.cpp Sun Aug 26 11:22:13 2007
@@ -89,7 +89,7 @@
llvm::Value *V = EmitScalarExpr(Init);
Builder.CreateStore(V, DeclPtr, D.getType().isVolatileQualified());
} else if (Init->getType()->isComplexType()) {
- EmitComplexExprIntoAddr(Init, DeclPtr);
+ EmitComplexExprIntoAddr(Init, DeclPtr, D.getType().isVolatileQualified());
} else {
EmitAggExpr(Init, DeclPtr, D.getType().isVolatileQualified());
}
Modified: cfe/trunk/CodeGen/CGExpr.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/CodeGen/CGExpr.cpp?rev=41444&r1=41443&r2=41444&view=diff
==============================================================================
--- cfe/trunk/CodeGen/CGExpr.cpp (original)
+++ cfe/trunk/CodeGen/CGExpr.cpp Sun Aug 26 11:22:13 2007
@@ -450,7 +450,7 @@
if (!E->getType()->isComplexType()) {
EmitAggExpr(E, DestMem, false);
} else if (NeedResult)
- EmitComplexExprIntoAddr(E, DestMem);
+ EmitComplexExprIntoAddr(E, DestMem, false);
else
EmitComplexExpr(E);
Modified: cfe/trunk/CodeGen/CGExprComplex.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/CodeGen/CGExprComplex.cpp?rev=41444&r1=41443&r2=41444&view=diff
==============================================================================
--- cfe/trunk/CodeGen/CGExprComplex.cpp (original)
+++ cfe/trunk/CodeGen/CGExprComplex.cpp Sun Aug 26 11:22:13 2007
@@ -383,10 +383,11 @@
/// EmitComplexExprIntoAddr - Emit the computation of the specified expression
/// of complex type, storing into the specified Value*.
void CodeGenFunction::EmitComplexExprIntoAddr(const Expr *E,
- llvm::Value *DestAddr) {
+ llvm::Value *DestAddr,
+ bool DestIsVolatile) {
assert(E && E->getType()->isComplexType() &&
"Invalid complex expression to emit");
ComplexExprEmitter Emitter(*this);
ComplexPairTy Val = Emitter.Visit(const_cast<Expr*>(E));
- Emitter.EmitStoreOfComplex(Val, DestAddr, false);
+ Emitter.EmitStoreOfComplex(Val, DestAddr, DestIsVolatile);
}
Modified: cfe/trunk/CodeGen/CGStmt.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/CodeGen/CGStmt.cpp?rev=41444&r1=41443&r2=41444&view=diff
==============================================================================
--- cfe/trunk/CodeGen/CGStmt.cpp (original)
+++ cfe/trunk/CodeGen/CGStmt.cpp Sun Aug 26 11:22:13 2007
@@ -290,7 +290,7 @@
Builder.CreateRet(EmitScalarExpr(RV));
} else if (RV->getType()->isComplexType()) {
llvm::Value *SRetPtr = CurFn->arg_begin();
- EmitComplexExprIntoAddr(RV, SRetPtr);
+ EmitComplexExprIntoAddr(RV, SRetPtr, false);
} else {
llvm::Value *SRetPtr = CurFn->arg_begin();
EmitAggExpr(RV, SRetPtr, false);
Modified: cfe/trunk/CodeGen/CodeGenFunction.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/CodeGen/CodeGenFunction.h?rev=41444&r1=41443&r2=41444&view=diff
==============================================================================
--- cfe/trunk/CodeGen/CodeGenFunction.h (original)
+++ cfe/trunk/CodeGen/CodeGenFunction.h Sun Aug 26 11:22:13 2007
@@ -374,7 +374,8 @@
/// EmitComplexExprIntoAddr - Emit the computation of the specified expression
/// of complex type, storing into the specified Value*.
- void EmitComplexExprIntoAddr(const Expr *E, llvm::Value *DestAddr);
+ void EmitComplexExprIntoAddr(const Expr *E, llvm::Value *DestAddr,
+ bool DestIsVolatile);
};
} // end namespace CodeGen
} // end namespace clang
More information about the cfe-commits
mailing list