rjmccall added inline comments. ================ Comment at: lib/CodeGen/TargetInfo.cpp:241 @@ +240,3 @@ + return Address(PtrAsInt, Align); +} + ---------------- Thank you for extracting this.
First, this function deserves a doc comment now; I would suggest: /// Dynamically round a pointer up to a multiple of the given alignment. Also, this is now generically useful, so (1) please rename OverflowArgArea to something more generic, like Ptr, and (2) please use LLVM value names based on the name already in Ptr. That is, instead of "overflow_arg_area.align", please use Ptr->getName () + ".aligned" Finally, please look for the other places in this file that you could change to use this new function. There's one in emitVoidPtrDirectVAArg, and there are several other in other targets. ================ Comment at: lib/CodeGen/TargetInfo.cpp:3568 @@ +3567,3 @@ + OverflowArea = emitRoundPointerUpToAlignment(CGF, OverflowArgArea, + Align); + } ---------------- Please sink OverflowArgArea into the if block, since you don't need it outside. http://reviews.llvm.org/D14871 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits