ranlib: fix it
[odcctools-svp.git] / gprof / notes
blob1ba38cb1d358b620a2f2d071b73c8d168b8a052c
1 TODO:
2 - Consider porting the 4.4bsd gprof (adding all the dylib stuff and order
3   stuff).
4 - Add multi-arch support for findcalls() and make work better (use disasm).
6 Changes for the 5.18 release (the cctools-583 release):
7 - Changed the Makefile so that when RC_XBS is set to YES then the compiler
8   options -MD and -dependency-file as well as the md(1) program are not used.
9   Radar bug #4029936.
11 Changes for the 5.16 release (the cctools-513 release):
12 - Added an #ifdef __OPENSTEP__ around the #include <mach-o/rld.h> in getnfile.c
13   as this header does not exist on some Mac OS X systems now.
15 Changes for the 5.12 release (the cctools-466 release):
16 - Fixed the incorrect casts on the comparison of the nlist struct's n_strx field
17   where the value being compared to was casted to a long.  The correct fix was
18   to cast n_strx to an unsigned long.
19 - Backed out one of the changes below that made "index" in doflags() in arcs.c
20   an unsigned long when it should have been left as a long.  Radar bug #3212306.
22 Changes for the 5.12 release (the cctools-464 release):
23 - Made changes to build cleanly with gcc3.3
24   - Removed -Wno-precomp from the Makefile and added RC_OS = macos
25   - Fixed warnings for "comparison between signed and unsigned" in gprof.c,
26     arcs.c, printgprof.c and getnfile.c .
28 Changes for the 5.11 release (the cctools-440 release):
29 - Fixed the warnings about extra tokens at end of #endif directive in
30   dfn.c, getnfile.c and printgprof.c (Radar bug #3072042).
32 Changes for the 5.10 release (the cctools-421 release):
33 - Changed new_sample_set() in gprof.c to not read the samples one at a time
34   but to allocate a buffer for the samples and read them all at once.  This
35   makes running gprof faster.  Radar bug #2876478.
37 Changes for the 5.10 release (the cctools-400 release):
38 - Changed the Makefile back to again use the -dependency-file with gcc.
40 Changes for the 5.10 release (the cctools-396 release):
41 - Changed the Makefile to not use the -dependency-file with gcc as well as
42   mwccppc.
44 Changes for the 5.10 release (the cctools-385 release):
45 - Fixed a bug in creating the gprof(1) -S order file in not picking up the
46   file names for symbols.  Changed count_N_SO_stabs() and load_files() in
47   getnfile.c to ignore the N_SO stabs for directory names that end in '/'.
48   These stabs were created by the compiler starting after DP4 (from Cheetah on).
49   Radar bug #2748170.
51 Changes for the 5.9 release (the cctools-373 release):
52 - Maded the nl variable in gprof.c into a __private_extern__ to avoid the
53   warning about "unused multiple definitions" when building with
54   -twolevel_namespace as the default.
56 Changes for the 5.9 release (the cctools-359 release):
57 - Added -Wno-long-double to shutup the compiler for
58   <architecture/m88k/fp_regs.h>.
60 Changes for the 5.7 release (the cctools-327 release):
61 - Changed back where gprof(1) picks up its the System Framework's private
62   headers.  It will continue to look in
63   /System/Library/Frameworks/System.framework/PrivateHeaders and may someday
64   will lookin in
65   /MacOSX/System/Frameworks/System.framework/PrivateHeaders in some post-DP4
66   release.
68 Changes for the 5.6 release (the cctools-323 release):
69 - Changed back where gprof picks up its the System Framework's private 
70   headers back to /System/Library/Frameworks/System.framework/PrivateHeaders
71   from /MacOSX/System/Frameworks/System.framework/PrivateHeaders for the Space
72   release.  This won't change till post-DP4.
74 Changes the 5.3 release (the cctools-303 release):
75 - Changed the 6 uses of short in the structs in scatter.c to int and 0x7fff to
76   INT_MAX.  The 'w' field was overflowing and causing it to crash. Radar bug
77   #2377933.
79 Changes the 5.3 release (the cctools-292 release):
80 - Changed the return type of main() in gprof.c from void to int to remove a
81   warning from the egcs compiler.  Also changed the exit() call at the end to
82   return().
83 - Added -I$(NEXT_ROOT)/System/Library/Frameworks/System.framework/PrivateHeaders
84   to the Makefile as the egcs compiler's cpp no longer searches this by default.
85   This is needed to pick up <streams/streams.h> for use with the rld interface.
87 Changes for the 5.3 release (the cctools-285 release)
88 - Removed the old sccsid and rcsid's from the source that was #if !defined(NeXT)
89 - Picked up the fix for Radar bug #2287470 (see below).  Updated this change to
90   include ifdef __OPENSTEP__'s in the code and Makefile changes to use $(RC_OS).
92 Changes for the 5.3 release, MacOS X bring up (the cctools-282 release):
93 - Changed ifdef's __SLICK__ to __OPENSTEP__.
94 - Changed the Makefile to allow for RC_OS=macos for MacOS X builds.
95 - Added a few casts in places to get it to compile with the MetroWerks compiler
96   without -relax_pointers.
98 Changes for the 5.2 release (the cctools-281.2 release)
99 - Moved text files gprof.flat and gprof.callg from /usr/lib to usr/share .
100   The files gprof/Makefile and gprof/gprof.h were changed (Radar bug #2287470).
102 Changes for the 5.2 release (the cctools-267 release):
103 - Fixed a warning in new_sample_set() in gprof.c in a print format.  Radar bug
104   #2227608.
105 - Removed the #ifdef notdef code in gprof.c that multiplied the hertz by 100
106   which had a comment about the kernel being broken.  The kernel was fixed in
107   Titan1P to sample correctly. Radar bug #2227608.
109 Changes for the 5.1 release (the cctools-260 release):
110 - Added -c to all the install commands in the Makefile.
112 Changes for the 5.1 release (the cctools-258 release):
113 - Added code for picking up the profrate from the 4.4bsd header.
114 - Added code for checking the version in the 4.4bsd header.
115 - Fixed a bug in new_sample_set() in setting the scale value which is a double
116   from interger arithmetic of (a-b)/c when a-b = c-1 which causes the value
117   to round to zero rather than getting .999999 which is much closer to the
118   approxmate value of 1.0 .  The fix was to cast the integer values to double
119   in the calculation ((double)a-(double)b)/(double)c .
120 - All of the above changes are under Radar bug #2204555.
122 Changes for the 5.1 release (the cctools-253 release):
123 - Changed the Makefile so /usr/ucb is not created for Rhapsody builds.
125 Changes for the 5.1 release (the cctools-248 release):
126 - Removed the copy of gmon.h in this directory.  For Rhapsody gmon.h will be
127   owned by some other project than cctools.  That is the version in
128   <mach-o/gmon.h> will not be installed.  The new gmon.h has a different 
129   structure for the profile header.  This effected gprof.h and gprof.c and
130   #ifdef __SLICK__ code was added.
132 Changes for the 5.1 release (the cctools-247 release):
133 - Added MKDIRS if code to the Makefile to build native on Rhapsody.
134 - Changed the Makefile to use gnutar instead of tar because it works on Rhapsody
135   where tar does not.
136 - Changed the Makefile to install gprof in /usr/bin for RC_OS teflon
137   and in /usr/ucb for RC_OS nextstep (Radar 1682569).
138 - Changed the code ifdef __TEFLON__ to ifndef __SLICK__ (where __TEFLON__ will
139   nolonger be defined for Rhapsody builds) so the default builds will be native
140   Rhapsody builds.  The changes were to getnfile.c, gprof.c, scatter.c and
141   gprof.h
143 Changes for the 5.0 release (the cctools-235 release):
144 - Picked up the copyrights from the OpenBSD sources and added them to the files
145   here.  No code was changed.
147 Changes for the 4.0 release (the cctools-183 release):
148 - Ifndef'ed __TEFLON__ out all rld uses.
150 Changes for the 4.0 release (the cctools-170 release):
151 - Changed the name of the time based order file from callt.order to
152   time.order.
154 Changes for the 4.0 release (the cctools-168 release):
155 - Added producing a time based order file (callt.order) for use with shared
156   pcsample buffers.
157 - Allowed MH_DYLIB and MH_DYLINKER files to be given for the a.out file.
159 Changes for the 4.0 release (the cctools-167 release):
160 - Added a the following print statement to find_file() in scatter.c:
161     fprintf(stderr, "In producing order files can't find module name "
162             "for functions (make sure all modules are compiled -g and "
163             "the program is not already ordered)\n");
164   in order to help people understand the common problems (bug #53173).
166 Changes for the 4.0 release (the cctools-160 release):
167 - Fixed two places in getnfile.c that had the wrong if test for the debug flag.
169 Changes for the 4.0 release (the cctools-154 release):
170 - Removed the use of nmedit now that libstuff has __private_extern__'s.
172 Changes for the 4.0 release (the cctools-147 release):
173 - Added support for profiling dyld loaded code.
174 - Removed old code that loaded FVMLIBs symbol tables.
176 Changes for the 3.1 release (the cctools-24 release):
177 - Fixed bug #33796 which turns out every where but in scatter.c the debug stuff
178   is conditional on the -d command line flag as well as the DEBUG macro.  The
179   fix was to add #undef DEBUG to scatter.c.
181 Changes for the 3.1 release (the cctools-15 release):
182 - Added multiple profile areas and rld loaded state support (bug #19664).
183 - Major cleanup of gprof code to allow compiling with -Wall cleanly and
184   remove a few vax'ism.
186 Changes for the 3.1 release (the cctools-14 release):
187 - Fixed bug #15775 in which the ncnt field is zero in the gmon.out file and
188   causes gprof to core dump.
190 Changes for the 3.1 release (the cctools-6 release):
191 - Added fat file support (tossed mach-o.c and replaced it).
193 Changes for the 3.0 release (the -52 compiler release):
194 - Added ignoring LC_PREPAGE to mach-o.c (2 places).
196 Changes for the 3.0 release (the -49 compiler release):
197 - Changed the Makefile to meet the RC api.
198 - Removed the mlist stuff.
200 Changes for the 3.0 release (the -47 compiler release):
201 - Changed an include in mach_o.c to match the header file change:
202   m68k/mach/thread_status.h -> mach/m68k/thread_status.h
204 Changes for the 3.0 release (the -44 compiler release):
205 - Switch over to the new header file organization.  This also involed changing
206   thread_status structure names and constants.  But then ifdef'ed off code in
207   mach_o.c that delt with threads since it got warnings and wasn't used.  Also
208   Fixed a few warnings from the compiler.
210 Changes for some 1991 release (the -34 compiler release):
211 - Added installsrc, installIBMsrc and installGNUsrc targets to the Makefile.
213 Changes for the Warp ?? release (the -24 compiler release):
214 - Fixed a bug when the text symbol for the highest value was looked up it would
215   print the message "binary lookup failed" then it returned NULL and later gprof
216   would core dump.  Their were two problems the first was in the function
217   getsymtab() in gprof.c in the Mach-O case the last entry in the nl[] array
218   did not have it's value set to -1.  The other problem was that in the function
219   nllookup() in lookup.c was searching to index "nname - 1" and not to nname
220   which would have picked up the last nl[] entry with the -1 in it.
221 - Changed DFN_DEPTH from 100 to 1000 as per bug report #4851.
223 Changes for the 2.0 impulse X.X release (the -23 compiler release):
224 - Changed the installed mode to not be writeable (755 to 555 and 644 to 444).
225 - Now is linked with libsys.
227 Changes for the 2.0 impulse X.X release (the -19 compiler release):
228 - Fixed the modified mlist function that includes printing categories which
229   did not allocate enough space.
231 Changes for the 2.0 impulse X.X release (the -19 compiler release):
232 - Put in the modified mlist function that includes printing categories.
234 Changes for the 0.91 release (the -12 compiler release):
235 - Added MH_PRELOAD to the types of files gprof will take.
236 - Updated the printing of method names for for the new objective-C runtime.
237 - Ifdef'ed off code in mach_o.c that delt with shared libraries.  It was
238   calling itself, read_mach_o(), totally wrong.  This code could have never
239   worked and since all the symbols are in the executable and since the kernel
240   can't handle shared libs it is meaningless.