Trim CGObjCRuntime::GenerateMessageSend[Super]
 - Returns an RValue.
 - Reduced to only taking the CodeGenFunction, Expr, and Receiver.
 - Becomes responsible for emitting the arguments.

Add CodeGenFunction::EmitCallExprExt
 - Takes optional extra arguments to insert at the head of the call.
 - This allows the Obj-C runtimes to call into this and isolates the
   argument and call instruction generation code to one place. Upshot
   is that we now pass structures (more) correctly.

Also, fix one aspect of generating methods which take structure
arguments (for NeXT). This probably needs to be merged with the
SetFunctionAttributes code in CodeGenModule.cpp

llvm-svn: 55223
diff --git a/clang/lib/CodeGen/CGExprAgg.cpp b/clang/lib/CodeGen/CGExprAgg.cpp
index 019d7be5..bc6af12 100644
--- a/clang/lib/CodeGen/CGExprAgg.cpp
+++ b/clang/lib/CodeGen/CGExprAgg.cpp
@@ -202,10 +202,12 @@
 }
 
 void AggExprEmitter::VisitObjCMessageExpr(ObjCMessageExpr *E) {
-  RValue RV = RValue::getAggregate(CGF.EmitObjCMessageExpr(E));
+  RValue RV = CGF.EmitObjCMessageExpr(E);
+  assert(RV.isAggregate() && "Return value must be aggregate value!");
 
   // If the result is ignored, don't copy from the value.
   if (DestPtr == 0)
+    // FIXME: If the source is volatile, we must read from it.
     return;
   
   EmitAggregateCopy(DestPtr, RV.getAggregateAddr(), E->getType());