[cpu] more builtin version check changes

Signed-off-by: r4sas <r4sas@i2pmail.org>
This commit is contained in:
r4sas 2023-09-18 18:12:26 +00:00
parent 3da5061426
commit fb420bb563
No known key found for this signature in database
GPG Key ID: 66F6C87B98EBCFE2

View File

@ -35,10 +35,10 @@ namespace cpu
__builtin_cpu_init();
# endif
return __builtin_cpu_supports("aes");
#elif (defined(__GNUC__) && __GNUC__ >= 5)
#elif (defined(__GNUC__) && __GNUC__ >= 6)
__builtin_cpu_init();
return __builtin_cpu_supports("aes");
#elif (defined(__GNUC__) && __GNUC__ < 5)
#elif (defined(__GNUC__) && __GNUC__ < 6)
int cpu_info[4];
bool flag = false;
__cpuid(0, cpu_info[0], cpu_info[1], cpu_info[2], cpu_info[3]);