Skip to content

Commit 3485437

Browse files
committed
Auto merge of #147462 - Enselic:fix-basic-stepping-array, r=saethlin
rustc_codegen_llvm: Require `opt-level >= 1` for index-based write_operand_repeatedly() loop To make debugger stepping intuitive with `-Copt-level=0`. See the adjusted `basic-stepping.rs` test. This is kind of a revert of **bd0aae92dc76d9 (cg_llvm: use index-based loop in write_operand_repeatedly)**, except we don't revert it, we just make it conditional on `opt-level`. That commit regressed `basic-stepping.rs`, but it was not noticed since that test did not exist back then (it was added later in rust-lang/rust#144876). I have retroactively bisected to find that out. It seems messy to sprinkle if-cases inside of `write_operand_repeatedly()` so make the whole function conditional. The test that bd0aae92dc76d9 added in `tests/codegen/issues/issue-111603.rs` already use `-Copt-level=3`, so we don't need to adjust the compiler flags for it to keep passing. This PR takes us one step closer to fixing rust-lang/rust#33013. CC rust-lang/rust#147426 which is related (there will be trivial conflicts for me to resolve in basic-stepping.rs once one of them lands)
2 parents bd4cd7e + 5ff4396 commit 3485437

File tree

0 file changed

+0
-0
lines changed

    0 file changed

    +0
    -0
    lines changed

    0 commit comments

    Comments
     (0)