Skip to content

Instantly share code, notes, and snippets.

View jollyjonson's full-sized avatar

JHL jollyjonson

View GitHub Profile
@jollyjonson
jollyjonson / find_avx.cmake
Last active December 10, 2023 16:10 — forked from UnaNancyOwen/find_avx.cmake
Check for the presence of AVX and figure out the flags to use for it.
# Check for the presence of AVX and figure out the flags to use for it.
macro(CHECK_FOR_AVX)
set(AVX_FLAGS)
include(CheckCXXSourceRuns)
set(CMAKE_REQUIRED_FLAGS)
# Check for AVX
if (MSVC)
if (NOT MSVC_VERSION LESS 1600)