mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-18 19:27:13 +00:00
5e8ebd841a
Doing this probing inside of the Makefiles means we have a maze of ifdefs inside the source code and child Makefiles that need to make proper decisions on this too. Instead, we do it at Kconfig time, like many other compiler and assembler options, which allows us to set up the dependencies normally for full compilation units. In the process, the ADX test changes to use %eax instead of %r10 so that it's valid in both 32-bit and 64-bit mode. Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com> Acked-by: Ingo Molnar <mingo@kernel.org> Reviewed-by: Nick Desaulniers <ndesaulniers@google.com> Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
18 lines
452 B
Plaintext
18 lines
452 B
Plaintext
# SPDX-License-Identifier: GPL-2.0
|
|
# Copyright (C) 2020 Jason A. Donenfeld <Jason@zx2c4.com>. All Rights Reserved.
|
|
|
|
config AS_AVX2
|
|
def_bool $(as-instr,vpbroadcastb %xmm0$(comma)%ymm1)
|
|
|
|
config AS_AVX512
|
|
def_bool $(as-instr,vpmovm2b %k1$(comma)%zmm5)
|
|
|
|
config AS_SHA1_NI
|
|
def_bool $(as-instr,sha1msg1 %xmm0$(comma)%xmm1)
|
|
|
|
config AS_SHA256_NI
|
|
def_bool $(as-instr,sha256msg1 %xmm0$(comma)%xmm1)
|
|
|
|
config AS_ADX
|
|
def_bool $(as-instr,adox %eax$(comma)%eax)
|