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]

other/10900: trampolines crash on apple-powerpc-darwin


>Number:         10900
>Category:       other
>Synopsis:       trampolines crash on apple-powerpc-darwin
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed May 21 10:16:01 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     gcc@microbizz.nl
>Release:        gcc-3.3
>Organization:
>Environment:
apple-powerpc-darwin 6.4
ppc7400
>Description:
trampolines crash on apple-powerpc-darwin (known for a long time, but still not fixed in gcc-3.3)
>How-To-Repeat:

>Fix:
# bug fix for trampolines (Andrew Reynolds)

*** gcc/config/rs6000/darwin-tramp.asm.orig	Sat Dec 29 09:07:56 2001
--- gcc/config/rs6000/darwin-tramp.asm	Mon Feb 10 01:55:39 2003
***************
*** 60,75 ****

  	.globl ___trampoline_setup
  ___trampoline_setup:
! 	mflr	r0		/* save return address */
!         bcl 20,31,LCF0		/* load up __trampoline_initial into r7 */
! LCF0:
!         mflr	r11
!         addi	r7,r11,ha16(LTRAMP-LCF0)
! 	lwz	r7,lo16(LTRAMP-LCF0)(r7)
! 	subi	r7,r7,4
! 	li	r8,trampoline_size	/* verify trampoline big enough */
! 	cmpw	cr1,r8,r4
! 	srwi	r4,r4,2		/* # words to move */
  	addi	r9,r3,-4	/* adjust pointer for lwzu */
  	mtctr	r4
  	blt	cr1,Labort
--- 60,74 ----

  	.globl ___trampoline_setup
  ___trampoline_setup:
!  		mflr	r0		/* save return address */
!           bcl 20,31,LCF0		/* load up __trampoline_initial into r7 */
!  LCF0:
!  Ltrampoline_address = Ltrampoline_initial-4-.
!          mflr	r11
!          addi	r7,r11,Ltrampoline_address
!  	li	r8,trampoline_size	/* verify trampoline big enough */
!  	cmpw	cr1,r8,r4
!  	srwi	r4,r4,2		/* # words to move */
  	addi	r9,r3,-4	/* adjust pointer for lwzu */
  	mtctr	r4
  	blt	cr1,Labort
***************
*** 124,131 ****
  #else
  	bl	_abort
  #endif
- .data
- 	.align 2
- LTRAMP:
- 	.long Ltrampoline_initial

--- 123,126 ----

>Release-Note:
>Audit-Trail:
>Unformatted:


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