[DAGCombiner] Avoid combining adjacent stores at -O0 to improve debug experience
authorShivam Gupta <shivam98.tkg@gmail.com>
Thu, 23 Dec 2021 05:17:16 +0000 (10:47 +0530)
committerShivam Gupta <shivam98.tkg@gmail.com>
Thu, 23 Dec 2021 05:18:28 +0000 (10:48 +0530)
commit0489e891199afe766e6340be890b0d6cd91f0938
treeec29fa9902ffa1bf0b60da2a63a3ed021fb22b6d
parentd019de23a1d761225fdaf0c47394ba58143aea9a
[DAGCombiner] Avoid combining adjacent stores at -O0 to improve debug experience

When the source has a series of assignments, users reasonably want to
have the debugger step through each one individually. Turn off the combine
for adjacent stores so we get this behavior at -O0.

Similar to D7181.

Reviewed By: spatel, xgupta

Differential Revision: https://reviews.llvm.org/D115808
llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
llvm/test/CodeGen/RISCV/optnone-store-no-combine.ll [new file with mode: 0644]