Skip to content

Commit

Permalink
Mark the cache/perf counter experiments as x86-64 only.
Browse files Browse the repository at this point in the history
The experimental code depends on x86-64 specific intrinsics, and breaks the
build on Apple silicon and other non-x86 platforms.
  • Loading branch information
ondrasej committed Oct 21, 2023
1 parent 4e33169 commit 3e7d20b
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions gematria/experiments/access_pattern_bm/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ cc_library(
srcs = ["linked_list.cc"],
hdrs = ["linked_list.h"],
copts = FEATURE_OPTS,
target_compatible_with = [
"@platforms//cpu:x86_64",
],
)

cc_test(
Expand All @@ -49,6 +52,9 @@ cc_library(
srcs = ["contiguous_matrix.cc"],
hdrs = ["contiguous_matrix.h"],
copts = FEATURE_OPTS,
target_compatible_with = [
"@platforms//cpu:x86_64",
],
deps = ["@com_google_absl//absl/base:core_headers"],
)

Expand All @@ -72,6 +78,9 @@ cc_library(
srcs = ["vec_of_vec_matrix.cc"],
hdrs = ["vec_of_vec_matrix.h"],
copts = FEATURE_OPTS,
target_compatible_with = [
"@platforms//cpu:x86_64",
],
deps = ["@com_google_absl//absl/base:core_headers"],
)

Expand Down Expand Up @@ -99,6 +108,9 @@ cc_test(
"stl_container_test.cc",
],
copts = BALANCE_FLUSHING_TIME_OPTS + FEATURE_OPTS, # Since templated functions using _mm_clflushopt are defined in the header.
target_compatible_with = [
"@platforms//cpu:x86_64",
],
deps = [
"@com_github_google_benchmark//:benchmark_main",
],
Expand All @@ -113,6 +125,9 @@ cc_test(
"stl_assoc_container_test.cc",
],
copts = BALANCE_FLUSHING_TIME_OPTS + FEATURE_OPTS, # Since templated functions using _mm_clflushopt are defined in the header.
target_compatible_with = [
"@platforms//cpu:x86_64",
],
deps = [
"@com_github_google_benchmark//:benchmark_main",
],
Expand Down

0 comments on commit 3e7d20b

Please sign in to comment.