• 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: Aurélien Hugelé <email@hidden>
  • Date: Wed, 15 Feb 2006 10:17:15 +0100

i forgot to add that i use GDB for something other than my code... so i do not know the names of parameters and variables....
i often add a (future)breakpoints to cocoa's method and look at their arguments etc... to know how to use it...


any suggestion ?

aurelien

On 15 févr. 06, at 10:09, Jonas Maebe wrote:


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:
40gumitech.com


This email sent to email@hidden


_______________________________________________ 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: Jonas Maebe <email@hidden>
References: 
 >debugging on Intel macs (From: Aurélien Hugelé <email@hidden>)
 >Re: debugging on Intel macs (From: Jonas Maebe <email@hidden>)

  • Prev by Date: Re: debugging on Intel macs
  • Next by Date: Re: debugging on Intel macs
  • Previous by thread: Re: debugging on Intel macs
  • Next by thread: Re: debugging on Intel macs
  • Index(es):
    • Date
    • Thread