[PATCH] CodeGen: Don't completely mess-up optimized atomic libcalls
robert lytton
robert at xmos.com
Tue Nov 25 10:23:47 PST 2014
REPOSITORY
rL LLVM
================
Comment at: cfe/trunk/lib/CodeGen/CGAtomic.cpp:747
@@ +746,3 @@
+ if (!RetTy->isVoidType()) {
+ if (UseOptimizedLibcall) {
+ if (HaveRetTy)
----------------
Hi David,
I've been chasing issues with libcxx for the xcore - hence finding this late in the day.
For non-optimized lib calls that return a value, don't we want to return the 'Res'?
viz:
if (!RetTy->isVoidType()) {
if (HaveRetTy)
return Res;
if (UseOptimizedLibcall) {
...
Have I understood the code correctly?
Robert
http://reviews.llvm.org/D5098
More information about the cfe-commits
mailing list