realfft icon indicating copy to clipboard operation
realfft copied to clipboard

Undefined behavior

Open ilmai opened this issue 2 years ago • 2 comments

Miri is reporting undefined behavior in process_with_scratch(), presumably because of the unsafe pointer cast shenanigans above this line?

    --> src/lib.rs:905:78
     |
905  |             .process_outofplace_with_scratch(&mut input[..output.len() / 2], buf_out, scratch);
     |                                                                              ^^^^^^^
     |                                                                              |
     |                                                                              trying to retag from <261438> for SharedReadWrite permission at alloc114704[0x0], but that tag does not exist in the borrow stack for this location
     |                                                                              this error occurs as part of two-phase retag at alloc114704[0x0..0x10]```

ilmai avatar Feb 23 '23 18:02 ilmai

See https://github.com/ejmahler/RustFFT/issues/98

WalterSmuts avatar Feb 23 '23 18:02 WalterSmuts

This has now been solved in RustFFT, so should be fixable by updating the dependency once they make a release

ilmai avatar Mar 12 '23 11:03 ilmai