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]
Other format: [Raw text]

[Bug target/15617] building groff-1.19.1 with "-Os -march=pentium4" causes sig 11


------- Additional Comments From reichelt at gcc dot gnu dot org  2004-06-02 01:47 -------
The culprit is in the function box_object::print() in object.cpp,
where the program crashes. Removing the following 4 lines from the
assembler code makes things work again (the lines are missing if
one compiles the code with -march=pentium3):

========================================================
--- object.s	2004-06-02 03:02:24.000000000 +0200
+++ object.s	2004-06-02 03:01:24.000000000 +0200
@@ -5217,11 +5217,9 @@ _ZN10box_object5printEv:
 	subl	$8, %esp
 	leal	-124(%ebp), %esi
 	fchs
-	movsd	.LC125, %xmm0
 	leal	-108(%ebp), %ebx
 	fstpl	(%esp)
 	pushl	-24(%ebp)
-	movaps	%xmm0, -144(%ebp)
 	pushl	-28(%ebp)
 	pushl	%esi
 .LCFI482:
@@ -5331,9 +5329,7 @@ _ZN10box_object5printEv:
 	subl	$16, %esp
 	leal	-124(%ebp), %ebx
 	fldl	76(%eax)
-	movsd	.LC126, %xmm0
 	fabs
-	movaps	%xmm0, -160(%ebp)
 	fstpl	8(%esp)
 	fldl	68(%eax)
 	fabs
========================================================

I'll attach a short self-contained testcase to reproduce the function
box_object::print(). Just compile with "g++ -Os -march=pentium4".
(The assembler labels are of course different, but there are only
four lines that contain %xmm0.)

To actually run the code one has to build groff, though.
So this testcase is not completely self-contained,
but maybe this is enough to identify the bug.


-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|                            |1
   Last reconfirmed|0000-00-00 00:00:00         |2004-06-02 01:47:24
               date|                            |


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


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