mirror of
https://github.com/Fennix-Project/Lynx.git
synced 2025-05-25 22:14:44 +00:00
21 lines
263 B
NASM
21 lines
263 B
NASM
[bits 32]
|
|
global DetectCPUID
|
|
DetectCPUID:
|
|
pushfd
|
|
pop eax
|
|
mov ecx, eax
|
|
xor eax, 1 << 21
|
|
push eax
|
|
popfd
|
|
pushfd
|
|
pop eax
|
|
push ecx
|
|
popfd
|
|
xor eax, ecx
|
|
jz .NoCPUID
|
|
mov eax, 1
|
|
ret
|
|
.NoCPUID:
|
|
xor eax, eax
|
|
ret
|