Permalink
Browse files

gsdx: requires/allow BMI instruction in AVX2 build

So far BMI is inclusive in AVX2 CPU. Help compiler to generate better code
  • Loading branch information...
1 parent eda22c2 commit dc42c65dfb08545b250eeef795a2482205db2545 @gregory38 gregory38 committed Jan 30, 2017
Showing with 3 additions and 1 deletion.
  1. +1 −1 plugins/GSdx/CMakeLists.txt
  2. +2 −0 plugins/GSdx/GSUtil.cpp
@@ -226,7 +226,7 @@ else()
# Don't append -SSE2 on the first build to keep same name as SIMD build
add_pcsx2_plugin("${Output}" "${GSdxFinalSources}" "${GSdxFinalLibs}" "${GSdxFinalFlags}")
add_pcsx2_plugin("${Output}-SSE4" "${GSdxFinalSources}" "${GSdxFinalLibs}" "${GSdxFinalFlags} -mssse3 -msse4 -msse4.1")
- add_pcsx2_plugin("${Output}-AVX2" "${GSdxFinalSources}" "${GSdxFinalLibs}" "${GSdxFinalFlags} -mavx -mavx2")
+ add_pcsx2_plugin("${Output}-AVX2" "${GSdxFinalSources}" "${GSdxFinalLibs}" "${GSdxFinalFlags} -mavx -mavx2 -mbmi -mbmi2")
else()
add_pcsx2_plugin(${Output} "${GSdxFinalSources}" "${GSdxFinalLibs}" "${GSdxFinalFlags}")
endif()
@@ -225,6 +225,8 @@ bool GSUtil::CheckSSE()
#endif
#if _M_SSE >= 0x501
{Xbyak::util::Cpu::tAVX2, "AVX2"},
+ {Xbyak::util::Cpu::tBMI1, "BMI1"},
+ {Xbyak::util::Cpu::tBMI2, "BMI2"},
#endif
};

0 comments on commit dc42c65

Please sign in to comment.