[llvm-commits] [llvm] r134641 - in /llvm/trunk: lib/Target/X86/MCTargetDesc/X86MCTargetDesc.cpp lib/Target/X86/MCTargetDesc/X86MCTargetDesc.h lib/Target/X86/X86.td lib/Target/X86/X86Subtarget.cpp lib/Target/X86/X86Subtarget.h lib/Target/X86/X86Ta

Eli Friedman eli.friedman at gmail.com
Fri Jul 8 14:55:11 PDT 2011


On Fri, Jul 8, 2011 at 2:54 PM, Evan Cheng <evan.cheng at apple.com> wrote:
>
> On Jul 8, 2011, at 2:35 PM, Eli Friedman wrote:
>
>> On Fri, Jul 8, 2011 at 2:15 PM, Evan Cheng <evan.cheng at apple.com> wrote:
>>> r134741 should handle the non-x86 hosts. For the other cases, we should either fix tests or add specific CPUs to X86.td.
>>
>> r134741 does't help at all.  Consider the case where we're compiling
>> for a triple like x86_64-apple-macosx10.7.0, no CPU is specified, and
>> we're on ARM.  We end up in 64-bit mode, but with cmov and SSE
>> disabled.  Stuff explodes.
>
> That's why this hack is in X86Subtarget.cpp:
>
>  // If requesting codegen for X86-64, make sure that 64-bit features
>  // are enabled.
>  // FIXME: Remove this feature since it's not actually being used.
>  if (In64BitMode) {
>    HasX86_64 = true;
>
>    // All 64-bit cpus have cmov support.
>    HasCMov = true;
>  }

In64BitMode is unconditionally false.

-Eli




More information about the llvm-commits mailing list