• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: debugging on Intel macs
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: debugging on Intel macs


  • Subject: Re: debugging on Intel macs
  • From: Jonas Maebe <email@hidden>
  • Date: Wed, 15 Feb 2006 10:09:59 +0100


On 15 feb 2006, at 08:26, Aurélien Hugelé wrote:

currently, on my PowerPC Mac, i use gdb pr/print function to display the content of the registers (i'm coding in cocoa):
$r3 (self), $r4 (_cmd), $r5->rX (arguments)


i've read somewhere that, due to the reduced number of registers in Intel processors, the arguments are passed by the stack and not by registers. I fear not to be able to continue to use my favorite registers in GDB

Can someone confirm my fears ? will I be able to print "self" in $r3, the current selector in $r4 and arguments in $r5 -> rX ? or things will be different ?

Just print the parameters/variables by name, gdb will fetch them from the correct location. Also note that printing the contents of those registers on PPC will give you wrong results in many instances, because the parameters are only guaranteed to be in those registers at the start of the routine. They can be located anywhere (including in memory) inside the body of the routine.



Jonas _______________________________________________ Do not post admin requests to the list. They will be ignored. Xcode-users mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
  • Follow-Ups:
    • Re: debugging on Intel macs
      • From: Aurélien Hugelé <email@hidden>
References: 
 >debugging on Intel macs (From: Aurélien Hugelé <email@hidden>)

  • Prev by Date: Re: Fun with fork/exec in the XCode debugger
  • Next by Date: Re: debugging on Intel macs
  • Previous by thread: debugging on Intel macs
  • Next by thread: Re: debugging on Intel macs
  • Index(es):
    • Date
    • Thread