Change CodeGen to emit calls using (RValue,Type) list:
 - Add CodeGenFunction::EmitAnyExprToTemp
   o Like EmitAnyExpr, but emits aggregates to a temporary location if
     none is available. Seems like this should be simpler (even aside
     from using first class aggregates).

 - Killed CodeGenFunction::EmitCallArg (just append the pair)

 - Conversion of RValues to actual call arguments is now isolated in
   CodeGenFunction::EmitCall.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@55970 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/CodeGen/CodeGenFunction.h b/lib/CodeGen/CodeGenFunction.h
index c38171a..3d14aed 100644
--- a/lib/CodeGen/CodeGenFunction.h
+++ b/lib/CodeGen/CodeGenFunction.h
@@ -175,6 +175,12 @@
   RValue EmitAnyExpr(const Expr *E, llvm::Value *AggLoc = 0, 
                      bool isAggLocVolatile = false);
 
+  /// EmitAnyExprToTemp - Similary to EmitAnyExpr(), however, the result
+  /// will always be accessible even if no aggregate location is
+  /// provided.
+  RValue EmitAnyExprToTemp(const Expr *E, llvm::Value *AggLoc = 0, 
+                           bool isAggLocVolatile = false);
+
   /// isDummyBlock - Return true if BB is an empty basic block
   /// with no predecessors.
   static bool isDummyBlock(const llvm::BasicBlock *BB);
@@ -308,14 +314,6 @@
   //                         Scalar Expression Emission
   //===--------------------------------------------------------------------===//
 
-  /// EmitCallArg - Emit the given expression and append the result
-  /// onto the given Args list.
-  void EmitCallArg(const Expr *E, CallArgList &Args);
-
-  /// EmitCallArg - Append the appropriate call argument for the given
-  /// rvalue and type onto the Args list.
-  void EmitCallArg(RValue RV, QualType Ty, CallArgList &Args);
-
   /// EmitCall - Generate a call of the given function, expecting the
   /// given result type, and using the given argument list which
   /// specifies both the LLVM arguments and the types they were