Skip to content

Commit c894511

Browse files
committed
[Apple Silicon] Add arm64 macOS support to benchmark suite
1 parent dd26811 commit c894511

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

Diff for: benchmark/cmake/modules/AddSwiftBenchmarkSuite.cmake

+2-6
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ macro(configure_build)
105105
endmacro()
106106

107107
macro(configure_sdks_darwin)
108-
set(macosx_arch "x86_64")
108+
set(macosx_arch "x86_64" "arm64")
109109
set(iphoneos_arch "arm64" "arm64e" "armv7")
110110
set(appletvos_arch "arm64")
111111
set(watchos_arch "armv7k")
@@ -609,11 +609,7 @@ function (swift_benchmark_compile_archopts)
609609

610610
if(is_darwin)
611611
# If host == target.
612-
if("${BENCH_COMPILE_ARCHOPTS_PLATFORM}" STREQUAL "macosx")
613-
set(OUTPUT_EXEC "${benchmark-bin-dir}/Benchmark_${BENCH_COMPILE_ARCHOPTS_OPT}")
614-
else()
615-
set(OUTPUT_EXEC "${benchmark-bin-dir}/Benchmark_${BENCH_COMPILE_ARCHOPTS_OPT}-${target}")
616-
endif()
612+
set(OUTPUT_EXEC "${benchmark-bin-dir}/Benchmark_${BENCH_COMPILE_ARCHOPTS_OPT}-${target}")
617613
else()
618614
# If we are on Linux, we do not support cross compiling.
619615
set(OUTPUT_EXEC "${benchmark-bin-dir}/Benchmark_${BENCH_COMPILE_ARCHOPTS_OPT}")

0 commit comments

Comments
 (0)