Re: [BUG] x86 kenel won't boot under Virtual PC
From: H. Peter Anvin
Date: Mon Sep 08 2008 - 13:09:21 EST
Linus Torvalds wrote:
Peter - does gcc actually use NOPL in _32-bit_ code too? It really seems
to be a stupid decision to make a binary not run on other CPU's over
something as trivial as that. That's something I'd expect out of an Intel
compiler just to mess with AMD, not out of gcc.
Yes, it does:
/* We need to decide which NOP sequence to use for 32bit and
64bit. When -mtune= is used:
1. For PROCESSOR_I386, PROCESSOR_I486, PROCESSOR_PENTIUM and
PROCESSOR_GENERIC32, f32_patt will be used.
2. For PROCESSOR_PENTIUMPRO, PROCESSOR_PENTIUM4, PROCESSOR_NOCONA,
PROCESSOR_CORE, PROCESSOR_CORE2, and PROCESSOR_GENERIC64,
alt_long_patt will be used.
3. For PROCESSOR_ATHLON, PROCESSOR_K6, PROCESSOR_K8 and
PROCESSOR_AMDFAM10, alt_short_patt will be used.
When -mtune= isn't used, alt_long_patt will be used if
cpu_arch_isa_flags has Cpu686. Otherwise, f32_patt will
be used.
"alt_long_patt" uses NOPL and its variants.
-hpa
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/