This is the mail archive of the gcc-patches@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: [PATCH] GCSE after reload - resubmit (SPECint +1.5% fp -0.5%).


Hi Mostafa,

Your patch causes gcc.c-torture/execute/930628-1.c to fail on
h8300-elf when it is compiled with -ms -O3 -fomit-frame-pointer
-funroll-all-loops.

Specifying -fno-gcse-after-reload works around the problem.

Here is a slightly reduced testcase.  With -fgcse-after-reload,
abort() is called.

int
main (void)
{
  struct { long f[3]; long x[1][2]; } tp[2][2];
  long i, j, ki, kj, mi;
  long bdm[2][2][2][2];

  for (i = 0; i < 2; i++)
    for (j = i; j < 2; j++)
      for (ki = 0; ki < 2; ki++)
	for (kj = 0; kj < 2; kj++)
	  if ((j == i) && (ki == kj))
	    bdm[i][ki][j][kj] = 1000;
	  else
	    {
	      for (mi = 0; mi < 1; mi++)
		if (tp[i][ki].x[mi] == tp[j][kj].x[0])
		  abort ();
	      bdm[i][ki][j][kj] = 1000;
	    }

  return 0;
}

Would you mind looking into this?

Thanks,

Kazu Hirata


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