mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-16 05:59:28 +02:00
+ store also ecx and edx after cpuid call with eax=7
+ test VNNI and BIGALG instructions
This commit is contained in:
parent
1e77901452
commit
79cf1dd9cf
@ -253,6 +253,8 @@ unit cpu;
|
||||
movl $0,%ecx
|
||||
cpuid
|
||||
movl %ebx,_ebx
|
||||
movl %ecx,_ecx
|
||||
movl %edx,_edx
|
||||
popl %ebx
|
||||
end;
|
||||
_AVX2Support:=_AVXSupport and ((_ebx and $20)<>0);
|
||||
|
@ -228,6 +228,8 @@ unit cpu;
|
||||
movl $0,%ecx
|
||||
cpuid
|
||||
movl %ebx,_ebx
|
||||
movl %ecx,_ecx
|
||||
movl %edx,_edx
|
||||
end ['rax','rbx','rcx','rdx'];
|
||||
_AVX2Support:=_AVXSupport and ((_ebx and $20)<>0);
|
||||
_AVX512FSupport:=(_ebx and $10000)<>0;
|
||||
|
@ -40,8 +40,8 @@ begin
|
||||
begin
|
||||
writeln('yes');
|
||||
asm
|
||||
// vpxor %ymm0,%ymm0,%ymm0
|
||||
// vaddpd %zmm0,%zmm0,%zmm0
|
||||
vpxor %ymm0,%ymm0,%ymm0
|
||||
vpdpbusd %zmm0,%zmm0,%zmm0
|
||||
end;
|
||||
end
|
||||
else
|
||||
@ -51,8 +51,8 @@ begin
|
||||
begin
|
||||
writeln('yes');
|
||||
asm
|
||||
//vpxor %ymm0,%ymm0,%ymm0
|
||||
//vaddpd %zmm0,%zmm0,%zmm0
|
||||
vpxor %ymm0,%ymm0,%ymm0
|
||||
vpopcntb %zmm0,%zmm0
|
||||
end;
|
||||
end
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user