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]

Maybe it is a bug of GCC (2) ?


Hi, guys,

This is the source code of a1.c and a2.c. 

I compile them on RedHat linux 6.0 ,  the CPU is celeron 300, and the gcc
version is:
"Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/specs
gcc version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release) "


 --

Regards,

Ma Yu
____________________
email: mayu@master.ihep.ac.cn
http://alpha01.ihep.ac.cn/~may

main()
{
       	float	a, b, c, d, t1, t2, t3, t_11, t_12, t_13, t;

                t = 0.005;
		t_11 = 1 -t;			/*	( 1 -  t )  */
		t_12 = t_11* t_11;		/*	(1 -t ) *^2  */
		t_13 = t_12* t_11;		/*	(1 - t ) ^ 3 * /
		t1  = t;				/* 	t	*/
		t2 = t * t;			/*	t ^2 	*/
		t3 = t2 * t;			/* 	t^3	*/

		a = t_13;
		b = 3 * t * t_12;
		c = 3 * t2 * t_11;
		d = t3;
	printf("a =%f b =%f c =%f d = %f \n", a, b, c, d);
}

main()
{
       	float	a, b, c, d, t1, t2, t3, t_11, t_12, t_13, t;

                t = 0.005;
		t_11 = 1 -t;			/*	( 1 -  t )  */
		t_12 = t_11* t_11;		/*	(1 -t ) *^2  */
		t_13 = t_12* t_11;		/*	(1 - t ) ^ 3 * /
		t1  = t;				/* 	t	*/
		t2 = t * t;			/*	t ^2 	*/
		t3 = t2 * t;			/* 	t^3	*/

		a = t_13;
		b = 3 * t1* t_12;
		c = 3 * t2 * t_11;
		d = t3;
	printf("a =%f b =%f c =%f d = %f \n", a, b, c, d);
}

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