Open NKID00 opened 2 months ago
The following code in bench_read_parallel is optimized out before benchmark:
bench_read_parallel
https://github.com/apache/opendal/blob/e869a70a63c0e6ccaaeabe7678ec77ecd614f5ac/core/benches/ops/read.rs#L98-L103
The entire loop is optimized out in emitted llvm ir displayed using cargo-show-asm:
cargo asm -p opendal --bench ops --features tests --release --llvm ops::read::bench_read_parallel 12
This piece of code should not be optimized out.
No response
Describe the bug
The following code in
bench_read_parallel
is optimized out before benchmark:https://github.com/apache/opendal/blob/e869a70a63c0e6ccaaeabe7678ec77ecd614f5ac/core/benches/ops/read.rs#L98-L103
Steps to Reproduce
The entire loop is optimized out in emitted llvm ir displayed using cargo-show-asm:
Expected Behavior
This piece of code should not be optimized out.
Additional Context
No response
Are you willing to submit a PR to fix this bug?