Page 1 of 1

[Patch] CMPXCHG8B for the IDT WinChip

Posted: Fri 02 Mar, 2018 2:34 am
by nerd73
This was something I brought up a little bit back in 2014 before the Pentium emulation was added.
Well, it's been three and a half years since then, and with the people who would use CMPXCHG8B requiring applications on PCem just using the Pentium, the issue fell to the wayside.

So then, is there CMPXCHG8B on the IDT WinChip? As it turns out, yes.

Obviously I implemented the instructions, but then came the CPUID part. CX8, or the CPUID identifier for CMPXCHG8B, is disabled by default on the WinChip. The main way to remedy that is by setting a bit on the feature control register, which is allowed in the patch. But if you enable it by default on non-Intel/AMD/Cyrix CPUs, that breaks NT4 below SP4 due to conflicting installation tests. So then, this patch only enables CX8 if the proper WRMSR bit is set.

This patch also disables CX8 on soft reset.
winchip.patch
(35.41 KiB) Downloaded 46 times

Re: [Patch] CMPXCHG8B for the IDT WinChip

Posted: Sat 03 Mar, 2018 9:33 pm
by SarahWalker
Committed at rev 1090.