Add test using a compiler builtin

This uses the `__floatditf` function which was reported as an issue in
[wasi-libc#543]. Compiling and running this test should prove that the
builtins are available in the `wasm32-*-threads` targets as long as the
tests use those targets (they do, right?).

[wasi-libc#543]: https://github.com/WebAssembly/wasi-libc/issues/543
pull/494/head
Andrew Brown 3 months ago
parent 021e8dc6f0
commit 38ae65b565

@ -0,0 +1,10 @@
// Primarily check that `libclang_rt.builtins-wasm32.a` functions are present
// and work as expected on all tested targets, not the builtin functionality.
#include <assert.h>
int main() {
tf_float f = __floatditf(0);
assert(f == 0.0);
return 0;
}
Loading…
Cancel
Save