| Index: crosstest/test_bitmanip.cpp
|
| diff --git a/crosstest/test_bitmanip.cpp b/crosstest/test_bitmanip.cpp
|
| index 7106767b305cc7df00774441e06c91e663eba91e..181286e492d88ede1c02e110dee74695899024b1 100644
|
| --- a/crosstest/test_bitmanip.cpp
|
| +++ b/crosstest/test_bitmanip.cpp
|
| @@ -40,6 +40,18 @@ FOR_ALL_BMI_OP_TYPES(X)
|
| #undef X
|
|
|
| #define X(type, builtin_name) \
|
| - type test_bswap(type a) { return builtin_name(a); }
|
| + type test_bswap(type a) { return builtin_name(a); } \
|
| + type test_bswap_alloca(type a) { \
|
| + const size_t buf_size = 8; \
|
| + type buf[buf_size]; \
|
| + for (size_t i = 0; i < buf_size; ++i) { \
|
| + buf[i] = builtin_name(a * i) + builtin_name(a + i); \
|
| + } \
|
| + type sum = 0; \
|
| + for (size_t i = 0; i < buf_size; ++i) { \
|
| + sum += buf[i]; \
|
| + } \
|
| + return sum; \
|
| + }
|
| BSWAP_TABLE
|
| #undef X
|
|
|