• 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 dreams?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Debugging dreams?


  • Subject: Re: Debugging dreams?
  • From: Cem Karan <email@hidden>
  • Date: Wed, 7 Jun 2006 11:35:16 -0400

I'm in the process of trying to track down an error in how my object graph is being updated, and would like to be able to visualize the current state of the graph at all times. The debugger in XCode allows me to either a) view the current state of the variables of my structs using the default format or b) create a custom formatter that only displays text. I would rather use GraphViz to display a graphical rendering of what my object graph is like as I'm stepping thru my code, but this requires knowledge of the current state of the machine at each step.

I've had the same issue. It may be resolved by writing a function that dump the graph in a .dot file, and then open this file with GraphViz.

This is actually what I'm doing right now, except that instead of dumping the entire graph, I dump just the deltas, and then postprocess, detecting the deltas and building up the graph as I go.



Don't forget that you may run (with the gdb prompt of Xcode's debugger) any function you want, like the classical "print-object my_objc_var" or "p (void)CFSHow(my_corefoundation_var)". Here, this will be a :
p (void)DumpMyGraph("/tmp/dump.dot", my_graph_root)


You just need to write the function DumpMyGraph, and check that it is not optimized away.

I hadn't thought about that! I'll have to spend some time playing with it... Thank you!


Thanks,
Cem Karan
_______________________________________________
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 dreams?
      • From: Chris Espinosa <email@hidden>
References: 
 >Debugging dreams? (From: Cem Karan <email@hidden>)
 >Re: Debugging dreams? (From: Damien Bobillot <email@hidden>)

  • Prev by Date: Re: Debugging dreams?
  • Next by Date: Re: Debugging dreams?
  • Previous by thread: Re: Debugging dreams?
  • Next by thread: Re: Debugging dreams?
  • Index(es):
    • Date
    • Thread