re PR rtl-optimization/56117 (ICE: in cselib_subst_to_values, at cselib.c:1853 with -O2 -fsched2-use-superblocks and __builtin_prefetch())
PR rtl-optimization/56117 * sched-deps.c (sched_analyze_2) <case PREFETCH>: For use_cselib call cselib_lookup_from_insn on the MEM before calling add_insn_mem_dependence. * gcc.dg/pr56117.c: New test. From-SVN: r195513
This commit is contained in:
parent
1691776171
commit
db1fb332e1
@ -1,3 +1,10 @@
|
||||
2013-01-28 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR rtl-optimization/56117
|
||||
* sched-deps.c (sched_analyze_2) <case PREFETCH>: For use_cselib
|
||||
call cselib_lookup_from_insn on the MEM before calling
|
||||
add_insn_mem_dependence.
|
||||
|
||||
2013-01-28 Richard Biener <rguenther@suse.de>
|
||||
|
||||
* tree-inline.c (remap_gimple_stmt): Do not assing a BLOCK
|
||||
|
@ -2720,8 +2720,12 @@ sched_analyze_2 (struct deps_desc *deps, rtx x, rtx insn)
|
||||
prefetch has only the start address but it is better to have
|
||||
something than nothing. */
|
||||
if (!deps->readonly)
|
||||
add_insn_mem_dependence (deps, true, insn,
|
||||
gen_rtx_MEM (Pmode, XEXP (PATTERN (insn), 0)));
|
||||
{
|
||||
rtx x = gen_rtx_MEM (Pmode, XEXP (PATTERN (insn), 0));
|
||||
if (sched_deps_info->use_cselib)
|
||||
cselib_lookup_from_insn (x, Pmode, true, VOIDmode, insn);
|
||||
add_insn_mem_dependence (deps, true, insn, x);
|
||||
}
|
||||
break;
|
||||
|
||||
case UNSPEC_VOLATILE:
|
||||
|
@ -1,3 +1,8 @@
|
||||
2013-01-28 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR rtl-optimization/56117
|
||||
* gcc.dg/pr56117.c: New test.
|
||||
|
||||
2013-01-28 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/56034
|
||||
|
9
gcc/testsuite/gcc.dg/pr56117.c
Normal file
9
gcc/testsuite/gcc.dg/pr56117.c
Normal file
@ -0,0 +1,9 @@
|
||||
/* PR rtl-optimization/56117 */
|
||||
/* { dg-do compile } */
|
||||
/* { dg-options "-O2 -fsched2-use-superblocks" } */
|
||||
|
||||
void
|
||||
foo (void *p)
|
||||
{
|
||||
__builtin_prefetch (p);
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user