mirror of
https://github.com/shadps4-emu/ext-cryptopp.git
synced 2024-11-27 11:50:29 +00:00
Fix CPU_ProbeDARN test
The DARN probe used 64-bit version of the instruction. I think it would have been OK 32-bit binaries, but the 32-bit version is always safe.
This commit is contained in:
parent
3db34abf2f
commit
9ddd6dc93c
@ -107,13 +107,13 @@ bool CPU_ProbeDARN()
|
||||
result = false;
|
||||
else
|
||||
{
|
||||
// "darn r3, 1" in big- and little-endian
|
||||
// This is "darn r3, 0". It provides a conditioned 32-bit
|
||||
// word. It is available on both 32-bit and 64-bit.
|
||||
#if CRYPTOPP_BIG_ENDIAN
|
||||
__asm__ __volatile__ (".byte 0x7c, 0x61, 0x05, 0xe6 \n" : : : "r3");
|
||||
__asm__ __volatile__ (".byte 0x7c, 0x60, 0x05, 0xe6 \n" : : : "r3");
|
||||
#else
|
||||
__asm__ __volatile__ (".byte 0xe6, 0x05, 0x61, 0x7c \n" : : : "r3");
|
||||
__asm__ __volatile__ (".byte 0xe6, 0x05, 0x60, 0x7c \n" : : : "r3");
|
||||
#endif
|
||||
// If we got here without SIGILL then success
|
||||
result = true;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user