rnk added inline comments.
================ Comment at: lib/CodeGen/CGExprComplex.cpp:204-206 + Scope.ensureDominatingValue(&Vals.first); + Scope.ensureDominatingValue(&Vals.second); + Scope.ForceCleanup(); ---------------- rsmith wrote: > I'm a little concerned about the loose connection between > `ensureDominatingValue` and `ForrceCleanup` here -- if you forget the > `ForceCleanup`, you get silent misbehavior. How about removing > `ensureDominatingValue` and instead passing a > `std::initializer_list<Value**>` to `ForceCleanup`? Done. ================ Comment at: lib/CodeGen/CodeGenFunction.h:539 private: + SmallVector<llvm::Value **, 1> ValuesToReload; ---------------- rsmith wrote: > If you keep a `SmallVector` here, set its inline size to 2 to avoid > allocations for the `_Complex` case. I removed it. Also, who wants to waste a whole pointer of stack space for _Complex expression evaluation. ;) https://reviews.llvm.org/D30590 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits