jlebar added inline comments.

================
Comment at: lib/Basic/Targets.cpp:1808
+    if (HostTriple.getArch() == llvm::Triple::x86)
+      HostTarget->setCPU("i586");
+
----------------
mgorny wrote:
> jlebar wrote:
> > Okay, is this still needed now?
> Yes. I've specifically tested with it commented out, and the CPU gets 
> initiated to generic (=no inline atomics) then.
Yes, but is that a bug?  Does that break the test?

I thought the problem we were trying to solve here was that CUDA host and 
device builds did not define the same macros.  And I thought that setCPU 
modified the values for MaxAtomicInlineWidth and MaxAtomicPromoteWidth.  
Moreover I thought that we called HostTarget->setCPU before calling this 
function.

If all of those things are true, I don't see what problem we're solving by 
calling HostTarget->setCPU("i586") here.


https://reviews.llvm.org/D29542



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to