Skip to content

Commit

Permalink
Skip test when code could be using x87
Browse files Browse the repository at this point in the history
  • Loading branch information
abadams committed Dec 23, 2024
1 parent c11d977 commit 7eae9aa
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions test/correctness/saturating_casts.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -290,6 +290,13 @@ void test_one_source() {
}

int main(int argc, char **argv) {

#ifdef __i386__
printf("[SKIP] Skipping test because it requires bit-exact int to float casts,\n"
"and on i386 without SSE it is hard to guarantee that the test binary won't use x87 instructions.\n");
return 0;
#endif

test_one_source<int8_t>();
test_one_source<uint8_t>();
test_one_source<int16_t>();
Expand Down

0 comments on commit 7eae9aa

Please sign in to comment.