This option is used to enable certain functions to make coreboot
work correctly on symmetric multi processor (SMP) systems.
-# Set MMX and SSE in socket or model if the CPU has them.
-# If all CPUs for the socket have MMX or SSE, set them there.
-# These options are only needed for boards compiled with romcc.
config MMX
bool
+ help
+ Select MMX in your socket or model Kconfig if your CPU has MMX
+ streaming SIMD instructions. ROMCC can build more efficient
+ code if it can spill to MMX registers.
config SSE
bool
+ help
+ Select SSE in your socket or model Kconfig if your CPU has SSE
+ streaming SIMD instructions. ROMCC can build more efficient
+ code if it can spill to SSE (aka XMM) registers.
+
+config SSE2
+ bool
+ help
+ Select SSE2 in your socket or model Kconfig if your CPU has SSE2
+ streaming SIMD instructions. Some parts of coreboot can be built
+ with more efficient code if SSE2 instructions are available.
config VAR_MTRR_HOLE
bool
static void write_phys(unsigned long addr, unsigned long value)
{
-#if CONFIG_HAVE_MOVNTI
+ // Assembler in lib/ is very ugly. But we properly guarded
+ // it so let's obey this one for now
+#if CONFIG_SSE2
asm volatile(
"movnti %1, (%0)"
: /* outputs */
}
write_phys(addr, addr);
};
+#if CONFIG_SSE2
+ // Needed for movnti
+ asm volatile ("sfence" ::: "memory");
+#endif
/* Display final address */
#if CONFIG_USE_PRINTK_IN_CAR
printk_debug("%08lx\r\nDRAM filled\r\n", addr);