[Bug middle-end/55279] New pseudo registers aren't supported in CSE

2023-05-19 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55279

--- Comment #10 from Andrew Pinski  ---
(In reply to Andrew Pinski from comment #3)
> I think combine was changed for the similar reason to support psedudos but I
> cannot find the patch right now.

Note combine was only fully fixed recently in GCC 12 with
r12-8030-g61bee6aed26eb3.

[Bug middle-end/55279] New pseudo registers aren't supported in CSE

2012-12-09 Thread hjl.tools at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55279



--- Comment #9 from H.J. Lu  2012-12-10 01:05:09 
UTC ---

(In reply to comment #8)

> (In reply to comment #7)

> > (In reply to comment #5)

> > > Why can't cse_reg_info_table() be modified to intercept this?

> > Correction: get_cse_reg_info()

> 

> Like so, quick-and-dirty hack. HJ, can you try and see if this

> keeps valgrind happy?

> 

> Index: cse.c

> ===

> --- cse.c   (revision 194325)

> +++ cse.c   (working copy)

> @@ -833,6 +833,7 @@

>  static inline struct cse_reg_info *

>  get_cse_reg_info (unsigned int regno)

>  {

> +  init_cse_reg_info (regno + 1);

>struct cse_reg_info *p = &cse_reg_info_table[regno];

> 

>/* If this entry has not been initialized, go ahead and initialize



I got



/export/gnu/import/git/sources/gcc-release/gcc/testsuite/gcc.dg/Warray-bounds.c:92:1:

internal compiler error: in insert_regs, at cse.c:1159^M

0xce1db0 insert_regs^M

/export/gnu/import/git/sources/gcc-release/gcc/cse.c:1159^M 

0xce4fbb cse_insn^M

/export/gnu/import/git/sources/gcc-release/gcc/cse.c:5793^M

0xce719b cse_extended_basic_block^M

/export/gnu/import/git/sources/gcc-release/gcc/cse.c:6408^M

0xce719b cse_main^M

/export/gnu/import/git/sources/gcc-release/gcc/cse.c:6586^M

0xce7675 rest_of_handle_cse^M

/export/gnu/import/git/sources/gcc-release/gcc/cse.c:7436^M

Please submit a full bug report,^M

with preprocessed source if appropriate.^M

Please include the complete backtrace with any bug report.^M

See  for instructions.^M


[Bug middle-end/55279] New pseudo registers aren't supported in CSE

2012-12-09 Thread steven at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55279



--- Comment #8 from Steven Bosscher  2012-12-09 
16:13:12 UTC ---

(In reply to comment #7)

> (In reply to comment #5)

> > Why can't cse_reg_info_table() be modified to intercept this?

> Correction: get_cse_reg_info()



Like so, quick-and-dirty hack. HJ, can you try and see if this

keeps valgrind happy?



Index: cse.c

===

--- cse.c   (revision 194325)

+++ cse.c   (working copy)

@@ -833,6 +833,7 @@

 static inline struct cse_reg_info *

 get_cse_reg_info (unsigned int regno)

 {

+  init_cse_reg_info (regno + 1);

   struct cse_reg_info *p = &cse_reg_info_table[regno];



   /* If this entry has not been initialized, go ahead and initialize


[Bug middle-end/55279] New pseudo registers aren't supported in CSE

2012-12-09 Thread steven at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55279



Steven Bosscher  changed:



   What|Removed |Added



 CC||steven at gcc dot gnu.org



--- Comment #7 from Steven Bosscher  2012-12-09 
16:09:44 UTC ---

(In reply to comment #5)

> Why can't cse_reg_info_table() be modified to intercept this?

Correction: get_cse_reg_info()


[Bug middle-end/55279] New pseudo registers aren't supported in CSE

2012-12-09 Thread steven at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55279



--- Comment #6 from Steven Bosscher  2012-12-09 
16:09:04 UTC ---

(In reply to comment #5)



There shouldn't be any such tables. Before the DF merge, there was 

no_new_pseudos, but it had its problems.



Why can't cse_reg_info_table() be modified to intercept this?


[Bug middle-end/55279] New pseudo registers aren't supported in CSE

2012-12-09 Thread hjl.tools at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55279



--- Comment #5 from H.J. Lu  2012-12-09 15:33:53 
UTC ---

Any passes which allocate a table for maximum number of registers

can't deal with new pseudo registers.  But there is nothing to

check and enforce it.


[Bug middle-end/55279] New pseudo registers aren't supported in CSE

2012-12-09 Thread steven at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55279



Steven Bosscher  changed:



   What|Removed |Added



 Status|UNCONFIRMED |NEW

   Last reconfirmed||2012-12-09

 CC||jakub at gcc dot gnu.org

 Ever Confirmed|0   |1



--- Comment #4 from Steven Bosscher  2012-12-09 
10:58:34 UTC ---

Potentially silent wrong code -> RM?


[Bug middle-end/55279] New pseudo registers aren't supported in CSE

2012-12-08 Thread pinskia at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55279



Andrew Pinski  changed:



   What|Removed |Added



   Keywords||ice-on-valid-code



--- Comment #3 from Andrew Pinski  2012-12-09 
01:23:00 UTC ---

I think combine was changed for the similar reason to support psedudos but I

cannot find the patch right now.


[Bug middle-end/55279] New pseudo registers aren't supported in CSE

2012-11-11 Thread hjl.tools at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55279



--- Comment #2 from H.J. Lu  2012-11-12 07:25:27 
UTC ---

If we revert the explow.c change:



http://gcc.gnu.org/viewcvs?view=revision&revision=177592



gcc.dg/Warray-bounds.c will cause valgrind error with



-fno-diagnostics-show-caret -O2 -Warray-bounds -S -mx32 -maddress-mode=long


[Bug middle-end/55279] New pseudo registers aren't supported in CSE

2012-11-11 Thread pinskia at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55279



--- Comment #1 from Andrew Pinski  2012-11-12 
03:49:22 UTC ---

Can you explain how you hit this with what patch and what testcase on what

target?