Skip to content

Commit cecf757

Browse files
Nicoshevfacebook-github-bot
authored andcommitted
Remove AVX compilation on aarch64 builds (#5045)
Summary: X-link: facebookresearch/FBGEMM#2056 We are no longer using SIMDE to build AVX code targeting aarch64 Build times should decrease Reviewed By: mcfi Differential Revision: D85361586
1 parent c7ba1c9 commit cecf757

File tree

3 files changed

+9
-1
lines changed

3 files changed

+9
-1
lines changed

src/TransposeUtils.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ void transpose_simd(
5757
#else
5858
static const auto iset = fbgemmInstructionSet();
5959
// Run time CPU detection
60-
#if defined(FBGEMM_FBCODE) || !defined(__aarch64__)
60+
#if defined(FBGEMM_FBCODE)
6161
if (isZmm(iset)) {
6262
internal::transpose_avx512<T>(M, N, src, ld_src, dst, ld_dst);
6363
} else if (isYmm(iset)) {

src/UtilsAvx2.cc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@
1515

1616
namespace fbgemm::internal {
1717

18+
#ifdef __AVX2__
19+
1820
template <>
1921
void transpose_avx2(
2022
int64_t M,
@@ -336,4 +338,6 @@ void transpose_avx2(
336338
}
337339
}
338340

341+
#endif // __AVX2__
342+
339343
} // namespace fbgemm::internal

src/UtilsAvx512.cc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ namespace fbgemm {
1616

1717
namespace {
1818

19+
#ifdef __AVX512F__
20+
1921
// 16 * 6 = 96 instructions
2022
inline void transpose_kernel_16x16_avx512(
2123
const float* src,
@@ -2441,6 +2443,8 @@ void transpose_avx512(
24412443
}
24422444
}
24432445

2446+
#endif // __AVX512F__
2447+
24442448
} // namespace internal
24452449

24462450
} // namespace fbgemm

0 commit comments

Comments
 (0)