PR tree-optimization/83047
commite0099abc36fc723720f663f39985743c2f9dd33f
authorjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 21 Nov 2017 08:41:47 +0000 (21 08:41 +0000)
committerjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 21 Nov 2017 08:41:47 +0000 (21 08:41 +0000)
tree80338b57205c17318e206161d3551baac09fb8df
parent805f9bbc5d31c4dd504f38abb65b3caafd72f4f5
PR tree-optimization/83047
* gimple-ssa-store-merging.c
(imm_store_chain_info::output_merged_store): If the loads with the
same vuse are in different basic blocks, for load_gsi pick a load
location that is dominated by the other loads.

* gcc.dg/pr83047.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@254992 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ChangeLog
gcc/gimple-ssa-store-merging.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/pr83047.c [new file with mode: 0644]