This is the mail archive of the gcc-bugs@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]

Bug with Feb 28 gcc snapshot




   I'm not sure if my bug report got through to you before, the mail
server was acting weird, so I'll submit it again.

---------- Forwarded message ----------
Date: Fri, 3 Mar 2000 03:14:09 +0000 (GMT)
From: Nicholas Vinen <hb@sonique.com>
To: gcc-bugs@gcc.gnu.org
Subject: Bug with Feb 28 gcc snapshot


   When compiling this C++ function:



void ScarabSurface::InterpolatePointsToFunction(uint8* pDest, uint32
DestLen, uint32 DestStride, const GradientPoint* Points, uint32 NumPoints)
const
{
	GradientPoint TempPoints[4];
	uint32 n;

	for (n = 0; n < NumPoints-1; n++)
	{
		if (n == 0)
		{
			memcpy(TempPoints+1, Points, 3*sizeof(*TempPoints));
			TempPoints[0].x = TempPoints[1].x*2 -
TempPoints[2].x;
			TempPoints[0].y = TempPoints[1].y*2 -
TempPoints[2].y;
//			TempPoints[0] = TempPoints[1] - (TempPoints[2] -
TempPoints[1]);

			InterpolateFunctionLineSegment(pDest, DestLen,
DestStride, TempPoints);
		} else if (n == NumPoints-2) {
			memcpy(TempPoints, Points+NumPoints-3,
3*sizeof(*TempPoints));
			TempPoints[3].x = TempPoints[2].x*2 -
TempPoints[1].x;
			TempPoints[3].y = TempPoints[2].y*2 -
TempPoints[1].y;
//			TempPoints[3] = TempPoints[2] - (TempPoints[1] -
TempPoints[2]);

			InterpolateFunctionLineSegment(pDest, DestLen,
DestStride, TempPoints);
		} else {
			InterpolateFunctionLineSegment(pDest, DestLen,
DestStride, Points+(n-1));
		}
	}

}



   I got this internal compiler error:

../ScarabSurface.cpp: In method oid
../ScarabSurface.cpp: ScarabSurface::InterpolatePointsToFunction (uint8
../ScarabSurface.cpp: *, long unsigned int, long unsigned int, const
../ScarabSurface.cpp: GradientPoint *, long unsigned int) const':
../ScarabSurface.cpp:1697: Unrecognizable insn:
(insn 352 214 215 (set (reg:SI 4 esi)
        (plus:SI (plus:SI (mem/f:SI (plus:SI (reg:SI 6 ebp)
                        (const_int 24 [0x18])) 0)
                (reg:SI 0 eax))
            (const_int -36 [0xffffffdc]))) -1 (nil)
    (nil))
../ScarabSurface.cpp:1697: Internal compiler error in xtract_insn',
../ScarabSurface.cpp:1697: at recog.c:2044
../ScarabSurface.cpp:1697: Please submit a full bug report.
../ScarabSurface.cpp:1697: See
../ScarabSurface.cpp:1697: <URL:http://www.gnu.org/software/gcc/bugs.html>
../ScarabSurface.cpp:1697: for instructions.



   sorry I can't expand much more. Removing the memcpy()s seemed to remove
this error.


	Nicholas Vinen




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