Skip to content

Commit

Permalink
Merge pull request #255 from chfast/ci_arm64
Browse files Browse the repository at this point in the history
ci: Add arm64 build
  • Loading branch information
chfast authored Mar 9, 2022
2 parents 21c7834 + efb2c54 commit e994349
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 4 deletions.
10 changes: 10 additions & 0 deletions circle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,15 @@ jobs:
- build_and_test
- benchmark

arm64:
environment:
BUILD_TYPE: Release
machine:
image: ubuntu-2004:202101-01
resource_class: arm.medium
steps:
- build_and_test

no-exceptions:
environment:
BUILD_TYPE: Release
Expand Down Expand Up @@ -289,3 +298,4 @@ workflows:
- fuzzing
- macos
- cmake-min
- arm64
6 changes: 3 additions & 3 deletions test/benchmarks/bench_div.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,11 +52,11 @@ inline uint64_t reciprocal_naive(uint64_t d) noexcept
const auto u = uint128{~uint64_t{0}, ~d};
uint64_t v;

#if _MSC_VER
v = (u / d).lo;
#else
#if __x86_64__
uint64_t _;
asm("divq %4" : "=d"(_), "=a"(v) : "d"(u[1]), "a"(u[0]), "g"(d));
#else
v = (u / d)[0];
#endif

return v;
Expand Down
2 changes: 1 addition & 1 deletion test/unittests/test_builtins.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ TEST(builtins, is_constant_evaluated)
auto is_constexpr_false = is_constant_evaluated();
auto nonconstexpr_func_res = func();

#if (defined(__clang__) && __clang_major__ >= 9) || (defined(__GNUC__) && __GNUC__ >= 9) || \
#if (defined(__clang__) && __clang_major__ >= 9) || (defined(__GNUC__) && __GNUC__ >= 10) || \
(defined(_MSC_VER) && _MSC_VER >= 1925)
EXPECT_FALSE(is_constexpr_false);
EXPECT_EQ(nonconstexpr_func_res, 2);
Expand Down

0 comments on commit e994349

Please sign in to comment.