cranelift: Implement nan canonicalization for vectors (#3146)
This fixes some fuzz bugs that came about enabling simd where nan canonicalization is performed on the fuzzers but cranelift would panic on these ops for vectors. This adds some custom codegen with `bitselect` to ensure any nan lanes are canonical-nan lanes in the canonicalized operations.
This commit is contained in:
@@ -40,6 +40,10 @@ fn run_wast(wast: &str, strategy: Strategy, pooling: bool) -> anyhow::Result<()>
|
||||
.strategy(strategy)?
|
||||
.cranelift_debug_verifier(true);
|
||||
|
||||
if wast.ends_with("canonicalize-nan.wast") {
|
||||
cfg.cranelift_nan_canonicalization(true);
|
||||
}
|
||||
|
||||
// By default we'll allocate huge chunks (6gb) of the address space for each
|
||||
// linear memory. This is typically fine but when we emulate tests with QEMU
|
||||
// it turns out that it causes memory usage to balloon massively. Leave a
|
||||
|
||||
Reference in New Issue
Block a user