This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: 3.3 PRs


> 
> Jan --
> 
> There are a bunch of 3.3 PRs with your name on them.  Let's get these
> resolved ASAP.
> 
> target/9929 ice-on-legal-code:
> 
>   Janis tracked this problem to one of your changes.
> 
>   You proposed a patch for this, and the discussion ends here:
> 
>     http://gcc.gnu.org/ml/gcc-patches/2003-03/msg02281.html
> 
>   RTH suggested an alternative way of fixing the problem; please
>   prepare a patch and submit it.
> 
> optimization/8634 wrong-code:
> 
>   Janis tracked this problem to one of your changes.
> 
> optimization/10056 ice-on-legal-code:
> 
>   You checked in a patch for this on March 25:
> 
>     Tue Mar 25 20:48:05 CET 2003  Jan Hubicka  <jh at suse dot cz>
> 
> 	    PR opt/10056
> 
>   but the PR is still open.  If you fixed it, would you close the PR?
> 
>   If not, what's up?
> 
> optimization/10024 ice-on-legal-code:
> 
>   This seems like the same issue as 10056.

Actually it is not.  The attached patch should fix it

OK for mainline/branch?  I will install the testcase into compile of
gcc-torture
 
   extern int * allegro_errno;
   typedef long fixed;
   extern inline int fixfloor (fixed x) { if (x >= 0) return (x >> 16);
   else return ~((~x) >> 16); }
   extern inline int fixtoi (fixed x) { return fixfloor(x) + ((x &
   0x8000) >> 15); }
   extern inline fixed ftofix (double x) { if (x > 32767.0) {
   *allegro_errno = 34; return 0x7FFFFFFF; } if (x < -32767.0) {
   *allegro_errno = 34; return -0x7FFFFFFF; } return (long)(x * 65536.0 +
   (x < 0 ? -0.5 : 0.5)); }
   extern inline double fixtof (fixed x) { return (double)x / 65536.0; }
   extern inline fixed fixdiv (fixed x, fixed y) { if (y == 0) {
   *allegro_errno = 34; return (x < 0) ? -0x7FFFFFFF : 0x7FFFFFFF; } else
   return ftofix(fixtof(x) / fixtof(y)); }
   extern inline fixed itofix (int x) { return x << 16; }
   int foo(int n) { return fixtoi(fixdiv(itofix(512), itofix(n))); }

Tue Apr  1 19:02:47 CEST 2003  Jan Hubicka  <jh at suse dot cz>

	PR opt/10024
	* cfglayout.c (cfg_layout_redirect_edge):  Update the jump.
	* cfgrtl.c (force_nonfallthru_and_redirect):  Do not special
	case the fallthru edges when called via cfglayout.c

Index: cfglayout.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cfglayout.c,v
retrieving revision 1.30
diff -c -3 -p -r1.30 cfglayout.c
*** cfglayout.c	30 Mar 2003 20:46:56 -0000	1.30
--- cfglayout.c	1 Apr 2003 17:02:13 -0000
*************** cfg_layout_redirect_edge (e, dest)
*** 904,909 ****
--- 902,914 ----
    src->next_bb = NULL;
    if (e->flags & EDGE_FALLTHRU)
      {
+       /* Redirect also the branch edges unified with the fallthru one.  */
+       if (GET_CODE (src->end) == JUMP_INSN
+ 	  && JUMP_LABEL (src->end) == e->dest->head)
+ 	{
+           if (!redirect_jump (src->end, block_label (dest), 0))
+ 	    abort ();
+ 	}
        /* In case we are redirecting fallthru edge to the branch edge
           of conditional jump, remove it.  */
        if (src->succ->succ_next
Index: cfgrtl.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cfgrtl.c,v
retrieving revision 1.70
diff -c -3 -p -r1.70 cfgrtl.c
*** cfgrtl.c	30 Mar 2003 20:46:56 -0000	1.70
--- cfgrtl.c	1 Apr 2003 17:02:14 -0000
*************** force_nonfallthru_and_redirect (e, targe
*** 926,931 ****
--- 926,934 ----
       by creating an basic block afterwards to redirect fallthru edge.  */
    if (e->src != ENTRY_BLOCK_PTR && e->dest != EXIT_BLOCK_PTR
        && any_condjump_p (e->src->end)
+       /* We may be called from cfglayout when the fallthru edges can go
+          arbitarily.  */
+       && e->src->next_bb == e->dest
        && JUMP_LABEL (e->src->end) == e->dest->head)
      {
        rtx note;


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]