mirror of git://gcc.gnu.org/git/gcc.git
re PR rtl-optimization/88478 (valgrind error in cselib_record_sets)
PR rtl-optimization/88478 * cselib.c (cselib_record_sets): Move sets[i].src_elt tests after REG_P (dest) test. * g++.dg/opt/pr88478.C: New test. From-SVN: r267159
This commit is contained in:
parent
302db8ba61
commit
bbc8d04f0e
|
|
@ -1,3 +1,9 @@
|
||||||
|
2018-12-15 Jakub Jelinek <jakub@redhat.com>
|
||||||
|
|
||||||
|
PR rtl-optimization/88478
|
||||||
|
* cselib.c (cselib_record_sets): Move sets[i].src_elt tests
|
||||||
|
after REG_P (dest) test.
|
||||||
|
|
||||||
2018-12-14 Martin Sebor <msebor@redhat.com>
|
2018-12-14 Martin Sebor <msebor@redhat.com>
|
||||||
|
|
||||||
PR tree-optimization/88372
|
PR tree-optimization/88372
|
||||||
|
|
|
||||||
|
|
@ -2616,10 +2616,10 @@ cselib_record_sets (rtx_insn *insn)
|
||||||
preserves the upper bits that di:SI=zero_extend(flags:CCNO<=0). */
|
preserves the upper bits that di:SI=zero_extend(flags:CCNO<=0). */
|
||||||
scalar_int_mode mode;
|
scalar_int_mode mode;
|
||||||
if (dest != orig
|
if (dest != orig
|
||||||
&& sets[i].src_elt
|
|
||||||
&& cselib_record_sets_hook
|
&& cselib_record_sets_hook
|
||||||
&& REG_P (dest)
|
&& REG_P (dest)
|
||||||
&& HARD_REGISTER_P (dest)
|
&& HARD_REGISTER_P (dest)
|
||||||
|
&& sets[i].src_elt
|
||||||
&& is_a <scalar_int_mode> (GET_MODE (dest), &mode)
|
&& is_a <scalar_int_mode> (GET_MODE (dest), &mode)
|
||||||
&& n_sets + n_strict_low_parts < MAX_SETS)
|
&& n_sets + n_strict_low_parts < MAX_SETS)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,8 @@
|
||||||
|
2018-12-15 Jakub Jelinek <jakub@redhat.com>
|
||||||
|
|
||||||
|
PR rtl-optimization/88478
|
||||||
|
* g++.dg/opt/pr88478.C: New test.
|
||||||
|
|
||||||
2018-12-14 Martin Sebor <msebor@redhat.com>
|
2018-12-14 Martin Sebor <msebor@redhat.com>
|
||||||
|
|
||||||
PR tree-optimization/88372
|
PR tree-optimization/88372
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,17 @@
|
||||||
|
// PR rtl-optimization/88478
|
||||||
|
// { dg-do compile }
|
||||||
|
// { dg-options "-O2" }
|
||||||
|
|
||||||
|
struct A {
|
||||||
|
bool b;
|
||||||
|
int s;
|
||||||
|
template <typename T, typename U>
|
||||||
|
A (T, U) {}
|
||||||
|
};
|
||||||
|
enum F {} f;
|
||||||
|
|
||||||
|
A
|
||||||
|
foo ()
|
||||||
|
{
|
||||||
|
return A (false, f);
|
||||||
|
}
|
||||||
Loading…
Reference in New Issue