Re: Any tools for displaying a C/C++/Objective C call tree.
Re: Any tools for displaying a C/C++/Objective C call tree.
- Subject: Re: Any tools for displaying a C/C++/Objective C call tree.
- From: Marshall Clow <email@hidden>
- Date: Mon, 14 Jan 2008 20:47:45 -0800
At 2:58 PM -0800 1/14/08, Bill Bumgarner wrote:
On Jan 14, 2008, at 1:57 PM, Todd Heberlein wrote:
creating an accurate static call tree for Objective-C code isn't
possible in the general case
Well, in the general sense, this is true with C and C++ too when
using pointers to functions.
That isn't entirely true and not just because the use of
pointers-to-functions is comparatively rare to the invocation of
methods within Objective-C.
With a pointer to a function, there is a well known location that is
passed around and, thus, it is fairly easy to -- at the least --
identify points where the analysis breaks down and, in some case, to
actually analyze the code to the point of following where the call
into said pointer function may happen.
Virtual method calls make this kind of analysis much harder.
Things (boost, tr1)::bind can further hinder automated analysis.
With Objective-C, this is not true. There is no well defined
symbol at any given call site; the combination of target +
selector are both required to fully follow the flow of execution.
The target -- the class of the target more precisely -- can't be
specifically known at compile time.
I agree that objective-C is harder than C++ for this.
--
-- Marshall
Marshall Clow Idio Software <mailto:email@hidden>
It is by caffeine alone I set my mind in motion.
It is by the beans of Java that thoughts acquire speed,
the hands acquire shaking, the shaking becomes a warning.
It is by caffeine alone I set my mind in motion.
_______________________________________________
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