block_of_code: Encapsulate CPU feature detection code

This commit is contained in:
MerryMage 2020-06-09 21:25:57 +01:00
parent feddf69cb4
commit f495018f53
14 changed files with 259 additions and 184 deletions

View file

@ -18,7 +18,7 @@ namespace Dynarmic::Backend::X64 {
#define MAYBE_AVX(OPCODE, ...) \
[&] { \
if (code.DoesCpuSupport(Xbyak::util::Cpu::tAVX)) { \
if (code.HasAVX()) { \
code.v##OPCODE(__VA_ARGS__); \
} else { \
code.OPCODE(__VA_ARGS__); \