3 * gprof.texi: Fix "the the" typo.
7 * gprof.texi (Compiling): Describe how to use gprof when source
8 files are not compiled with -pg. Mention other profiling options
10 (How do I?): Mention the function call overhead introduced by -pg.
14 * gprof.texi: Apply patch supplied by Eric S Raymond via RMS:
15 (Compiling): Mention that -pg must be passed to both the compiler
17 Mention that -a is now deprecated.
18 (How do I?): Add an entry describing how to get more information
19 about program hotspots.
23 * corefile.c (core_create_function_syms): Don't refer directly to
24 _cooked_size and vma; Use bfd_section_size and bfd_get_section_vma.
28 * po/de.po: New German translation.
29 * configure.in (ALL_LINGUAS): Add de.
30 * configure: Regenerate.
31 * Makefile.in: Regenerate.
32 * aclocal.m4: Regenerate.
33 * gconfig.in: Regenerate.
37 * po/tr.po: Updated Turkish translation.
41 * dep-in.sed: Remove libintl.h.
42 * Makefile.am (POTFILES.in): Unset LC_COLLATE.
43 * Makefile.in: Regenerate.
47 * po/fr.po: Updated French translation.
51 * po/Make-in (.po.gmo): Do check if the .gmo file is writable
56 * po/es.po: New Spanish translation.
60 * po/gprof.pot: Regenerate.
64 * po/Make-in (DESTDIR): New.
65 (install-data-yes): Support $(DESTDIR).
66 (uninstall): Likewise.
70 * gmon_io.c (enum gmon_ptr_size, enum gmon_ptr_signedness): New.
71 (gmon_get_ptr_size, gmon_get_ptr_signedness): New.
72 (gmon_io_read_vma, gmon_io_write_vma, gmon_read_raw_arc)
73 (gmon_write_raw_arc, gmon_out_read, gmon_out_write): Adjust to
74 use new functions and enums.
78 * corefile.c (core_create_line_syms): Check for a NULL sentinel
79 value before using it.
83 * configure.in (LINGUAS): Add pt_BR.
84 * configure: Regenerate.
85 * po/pt_BR: New Brazillian Portugese translation.
89 * basic_blocks.c, basic_blocks.h, cg_arcs.c, cg_dfn.c, cg_print.c,
90 corefile.c, gmon_io.c, gprof.c, gprof.h, hist.c, mips.c, source.c,
91 source.h, sym_ids.c, sym_ids.h, symtab.h, tahoe.c, vax.c: Replace
92 boolean with bfd_boolean, true with TRUE, false with FALSE.
97 * configure.in (ALL_LINGUAS): Add da.
98 * configure: Regenerate.
99 * po/da.po: New Danish translation.
103 * gprof.c (main): Turn off default excluded functions in FLAT
108 * gmon_io.c (gmon_io_read_64, gmon_io_write_64): Define only if
109 BFD_HOST_U_64_BIT is defined.
110 (gmon_io_read_vma, gmon_io_write_vma): Add ifdefs.
114 * po/tr.po: Updated Turkish translation.
118 * alpha.c, cg_arcs.c, cg_dfn.c, gmon.h, gprof.c, gprof.h, hertz.c,
119 i386.c, mips.c, sparc.c, tahoe.c, utils.c, vax.c: Update Copyright
120 notice so that it applies even if the sources are modified.
124 * gprof.texi (Executing the Program): Add documentation on how to use
125 bbconv.pl. Patch by Eric Hanchrow.
129 * po/es.po: Updated Spanish translation.
130 * po/fr.po: Updated French translation.
134 * corefile.c (core_create_function_syms): Use the end of the section
135 containing the symbol to compute max_vma.
139 * po/sv.po: Updated Swedish translation.
140 * po/es.po: Updated Spanish translation.
144 * po/fr.po: Updated French translation.
145 * po/id.po: New Indonesian translation.
146 * configure.in (LINGUAS): Add id.
147 * configure: Regenerate.
151 * po/Make-in (.po.gmo): Do not attempt to create a .gmo file if
152 the sources are read-only.
156 * dep-in.sed: Cope with absolute paths.
157 * Makefile.am (dep.sed): Subst TOPDIR.
159 * Makefile.in: Regenerate.
163 * Makefile.am: Run "make dep-am".
164 * Makefile.in: Regenerate.
168 * po/fr.po: Updated version.
172 * po/fr.po: Updated version.
176 * gprof.texi: Wrap @menu in @ifnottex, not @ifinfo.
180 * hist.c (hist_print): Rewrite log_scale calculation loop.
184 * Makefile.am: "make dep-am".
185 * Makefile.in: Regenerate.
189 * gprof.c: Include "getopt.h" after other includes, so that
190 the proper macros are defined.
191 * gen-c-prog.awk: Emit a prototype for the generated function.
195 * configure.in (build_warnings): Add -Wstrict-prototypes
196 -Wmissing-prototypes.
197 * aclocal.m4: Regenerate.
198 * gconfig.in: Regenerate.
199 * configure: Regenerate.
200 * Makefile.am: Run "make dep-am".
201 * Makefile.in: Regenerate.
203 * alpha.c (alpha_find_call): Warning fixes.
204 * mips.c (mips_find_call): Likewise.
205 * sparc.c (sparc_find_call): Likewise.
206 * basic_blocks.c: Warning fixes. Eliminate DEFUN.
207 * call_graph.c: Likewise.
208 * cg_arcs.c: Likewise.
209 * cg_dfn.cp: Likewise.
213 * search_list.c: Likewise.
214 * source.c: Likewise.
215 * source.h: Likewise.
216 * sym_ids.c: Likewise.
217 * symtab.c: Likewise.
218 * symtab.h: Likewise.
220 * cg_print.c: Likewise.
221 (struct function_map, symbol_map, symbol_map_count): Move
224 * corefile.c: Warning fixes. Eliminate DEFUN.
225 (struct function_map): Remove declaration.
226 * gmon_io.c: Warning fixes. Eliminate DEFUN.
227 (gmon_io_read_64): Make static.
228 (gmon_io_write_64): Likewise.
229 (gmon_read_raw_arc): Likewise.
230 (gmon_write_raw_arc): Likewise.
231 (gmon_io_write_8): Don't pass char, pass int param.
232 * gmon_io.h (gmon_io_write_8): Likewise.
234 * Makefile.am: Run "make dep-am"
235 * Makefile.in: Regenerate.
237 * basic_blocks.c: Replace bool with boolean, TRUE with true and
238 FALSE with false throughout.
239 * basic_blocks.h: Likewise.
240 * cg_arcs.c: Likewise.
241 * cg_dfn.c: Likewise.
242 * cg_print.c: Likewise.
243 * corefile.c: Likewise.
244 * gmon_io.c: Likewise.
248 * source.c: Likewise.
249 * source.h: Likewise.
250 * sym_ids.c: Likewise.
251 * sym_ids.h: Likewise.
252 * symtab.h: Likewise.
256 (TRUE): Don't define.
257 (FALSE): Don't define.
261 * TODO: Remove "host architecture pointer size" item.
262 * acconfig.h: Remove.
263 * gconfig.in: Regenerate.
264 * configure.in: Remove check for gmon pointer size.
265 * configure: Regenerate.
266 * gmon.h (GMON_HDRSIZE_BSD44_32): Define.
267 (GMON_HDRSIZE_BSD44_64): Ditto.
268 (GMON_HDRSIZE_OLDBSD_32): Ditto.
269 (GMON_HDRSIZE_OLDBSD_64): Ditto.
270 (struct raw_phdr): Wrap in #if 0, keeping it for
271 documentation purposes only.
272 (struct old_raw_phdr): Likewise.
273 (struct raw_arc): Likewise. Change type/size of
274 "count" member to long match 4.4BSD.
275 * gmon_io: Update copyright years.
276 (gmon_io_read_64): New function.
277 (gmon_io_read_vma): Use bfd_arch_bits_per_address to
278 determine target pointer size. Use gmon_io_read_32
280 (gmon_io_write_64): New function.
281 (gmon_io_write_vma): Use bfd_arch_bits_per_address to
282 determine target pointer size. Use gmon_io_write_32
283 and gmon_io_write_64.
286 (gmon_read_raw_arc): New function.
287 (gmon_write_raw_arc): New function.
288 (gmon_out_read): Do not use struct raw_phdr or
289 struct old_raw_phdr to read the gmon header. Use
290 gmon_read_raw_arc to read call graph records.
291 (gmon_out_write): Do not use struct raw_phdr or
292 struct old_raw_phdr to write the gmon header. Use
293 gmon_write_raw_arc to write call graph records.
294 * po/gprof.pot: Regenerate.
295 * Makefile.in: Regenerate.
299 * alpha.c (alpha_Instruction): Don't use.
300 (alpha_find_call): Avoid use of bitfields and casts between
301 pointers and integers of different sizes. Avoid endian problems
302 when cross-compiling.
303 * vax.c (vax_find_call): Likewise.
304 (struct modebyte): Don't use.
305 (vax_operandmode): Pass in an unsigned char *.
306 (vax_operandlength): Likewise.
307 (vax_reladdr): Rename to vax_offset and return relative offset
309 * i386.c (i386_find_call): Avoid casts between pointers and
310 integers of different sizes.
311 * sparc.c (sparc_find_call): Likewise. Avoid endian problems.
312 * tahoe.c (tahoe_find_call): Likewise.
313 (tahoe_reladdr): Rename to tahoe_offset and return relative offset
316 * basic_blocks.h: Don't include headers here.
317 * call_graph.h: Likewise.
318 * cg_arcs.h: Likewise.
319 * cg_print.h: Likewise.
320 * corefile.h: Likewise.
321 * gmon_io.h: Likewise.
322 * gmon_out.h: Likewise.
325 * source.h: Likewise.
326 * sym_ids.h: Likewise.
327 * symtab.h: Likewise.
328 * gprof.h: Don't include ansidecl.h, do include bfd.h.
329 (bool): Don't typedef.
330 * alpha.c: Adjust #include's for above header changes.
331 * basic_blocks.c: Likewise.
332 * call_graph.c: Likewise.
333 * cg_arcs.c: Likewise.
334 * cg_dfn.c: Likewise.
335 * cg_print.c: Likewise.
336 * corefile.c: Likewise.
337 * gmon_io.c: Likewise.
344 * sym_ids.c: Likewise.
345 * symtab.c: Likewise.
350 * po/POTFILES.in: Regenerate.
354 * configure: Regenerated.
358 * i386.c (i386_iscall): Static.
359 * tahoe.c (indirectchild, tahoe_operandmode): Static.
360 (tahoe_operandlength, tahoe_reladdr): Static.
361 * vax.c (indirectchild): Static.
365 * Makefile.am (install): Depend on install-info.
366 * Makefile.in: Regenerate.
371 * Makefile.am (sources): Add mips.c.
373 * Makefile.in: Regenerate.
374 * corefile.c: Update copyright years.
375 (find_call): Call mips_find_call for bfd_arch_mips.
379 * po/fr.po: Updated version.
383 * po/es.po: Updated version.
387 * po/gprof.pot: Regenerate.
391 * po/es.po: New file: Spanish translation.
392 * configure.in (ALL_LINGUAS): Add es.
393 * configure: Regenerate.
397 * gmon_io.c (gmon_out_read): Remove use of ngettext(). It is not
402 * cg_print.c (print_header): Fix spelling typo.
404 * gmon_io.c (gmon_out_read): Fix formatting of text messages to
405 allow easier translation into other languages.
409 * configure.in (ALL_LINGUAS): Add sv.
410 * configure: Regenerate.
411 * po/sv.po: Import from translation project web site.
415 * configure.in (LINGUAS): Add tr.
416 * configure: Regenerate.
417 * po/tr.po: Import from translation project's web site.
421 * configure.in (ALL_LINGUAS): Add 'fr'.
422 * configure: Regernate.
423 * po/fr.po: New file.
427 * configure: Regenerate.
431 * Makefile.am (Makefile): Depend on bfd/configure.in.
433 * Makefile.in: Regenerate.
437 * gprof.c (main): For gettext, also set the LC_CTYPE locate facet.
438 * sym_ids.c: Include "safe-ctype.h" instead of <ctype.h>.
439 (parse_spec): Use ISDIGIT instead of isdigit.
443 * sparc.c (sparc_find_call): Warning fix.
444 * alpha.c (alpha_find_call): Likewise.
448 * alpha.c: Add missing prototypes.
453 (i386_iscall): Don't use DEFUN.
457 * NOTES: Rename to README for consistency with other binutils.
461 * Makefile.am (diststuff): Add $(MANS).
462 (gprof.1): Remove the prefix `$(srcdir)/'.
463 * Makefile.in: Regenerated.
469 * gprof.texi (File Format): Profile data files are stored in
470 target byte order, not host byte order.
474 * gmon_io.c (gmon_io_read, gmon_io_write_vma,
475 gmon_io_write_32, gmon_io_write_8, gmon_io_write): Adjust
476 argument list for K&R C.
480 * gprof.texi: Put @c man begin and @c man end indications
481 to generate man page using texi2pod and pod2man. Added SEEALSO,
482 SYNOPSIS, BUGS, FILES and DESCRIPTION from original gprof.1
483 enclosed in @ifset man condition.
484 * Makefile.am (MANCONF, TEXI2POD, POD2MAN): New variable.
485 Generate gprof.1 from gprof.texi.
486 * gprof.1: Generate from gprof.texi.
487 * Makefile.in: Regenerate.
491 * hist.c (hist_dimension): Declare as an array of 16 characters.
492 (hist_read_rec): If SAMPLEDEBUG, print each histogram bin count.
494 * basic_blocks.c: Whitespace and formatting changes.
495 * bb_exit_func.c: Ditto.
496 * call_graph.c: Ditto.
497 * call_graph.h: Ditto.
510 * search_list.c: Ditto.
511 * search_list.h: Ditto.
522 * gmon_out.h (gmon_hist_hdr): Delete.
523 (gmon_cg_arc_record): Delete.
525 * gmon_io.c (put_vma): Declare "static".
527 (gmon_io_write): New function.
528 (gmon_io_write_8): Ditto.
529 (gmon_io_write_32): Ditto.
530 (gmon_io_write_vma): Ditto.
531 (gmon_io_read): Ditto.
532 (gmon_io_read_32): Ditto.
533 (gmon_io_read_vma): Ditto.
534 * basic_blocks.c (bb_read_rec): Use gmon_io_read* / gmon_io_write*
535 to read/write data file in a more portable fashion.
536 (bb_write_blocks): Ditto.
537 * call_graph.c (cg_read_rec): Ditto.
538 (cg_write_arcs): Ditto.
539 * hist.c (hist_read_rec): Ditto.
540 (hist_write_hist): Ditto.
543 * gmon_out.h: Use GMON_PTR_SIZE instead of sizeof(char*).
545 * configure.in: Get GMON_PTR_SIZE from existing <sys/gmon_out.h>
547 * acconfig.h: New file. Mention and document GMON_PTR_SIZE.
548 * gconfig.h: Regenerate.
549 * configure: Regenerate.
550 * Makefile.in: Regenerate.
554 * configure.in (BFD_VERSION): New.
555 (AM_INIT_AUTOMAKE): Use $BFD_VERSION.
556 * configure: Regenerate.
557 * gconfig.in: Regenerate.
558 * Makefile.am: Run "make dep-am"
559 * Makefile.in: Regenerate.
563 * basic_blocks.c: #include <unistd.h> only if it exists.
567 * gprof.texi: Add GNU Free Documentation License.
571 * configure.in (AC_ISC_POSIX): Put after AC_CANONICAL_SYSTEM.
572 * configure: Rebuild.
576 * aclocal.m4, configure: Rebuilt with new libtool.m4.
580 * configure.in: Increase version number to 2.10.91.
581 * configure: Regenerate.
582 * aclocal.m4: Regenerate.
583 * config.in: Regenerate.
587 * acinclude.m4: Include libtool and gettext macros from the
589 * aclocal.m4, configure: Rebuilt.
593 * bb_exit_func.c: Assign copyright to FSF. Note that David
598 * basic_blocks.c: Add copyright notice.
599 * basic_blocks.h: Add copyright notice.
600 * call_graph.c: Add copyright notice.
601 * call_graph.h: Add copyright notice.
602 * cg_print.c: Add copyright notice.
603 * cg_print.h: Add copyright notice.
604 * corefile.c: Add copyright notice.
605 * corefile.h: Add copyright notice.
606 * gmon_io.c: Add copyright notice.
607 * gmon_io.h: Add copyright notice.
608 * gmon_out.h: Add copyright notice.
609 * hist.c: Add copyright notice.
610 * hist.h: Add copyright notice.
611 * search_list.c: Add copyright notice.
612 * search_list.h: Add copyright notice.
613 * source.c: Add copyright notice.
614 * source.h: Add copyright notice.
615 * sym_ids.c: Add copyright notice.
616 * sym_ids.h: Add copyright notice.
617 * symtab.c: Add copyright notice.
618 * symtab.h: Add copyright notice.
622 * gprof.c: Add optional style to demangle switch
623 * gprof.texi: Document optional style to demangle switch.
631 * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
632 (CLEANFILES): Add DEPA.
633 * Makefile.in: Regenerate.
637 * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
639 * Makefile.in: Regenerate.
643 * source.c (annotate_source): Correct pointer comparison when
644 checking for backslashes.
648 * configure: Regenerate.
652 * configure.in (VERSION): Update to show this is the CVS mainline.
656 * source.c: Remove direct inclusion of sys/stat.h.
660 * gprof.h (_): Revert previous delta. We want to use gettext,
661 not dgettext in the _ macro.
665 * gprof.h (_): Use BFD version.
669 * gprof.c (main): When calling getopt_long indicate that the 'd'
670 switch takes an optional argument, whereas the 'D' switch takes no
675 * dep-in.sed: Copy from ../binutils.
676 * Makefile.am: Update dependencies with "make dep-am"
677 * Makefile.in: Regenerate.
679 * gprof.h: Remove most nls defines. They are pulled in by
680 bfd/sysdep.h. #include "ansidecl.h" not <ansidecl.h>
684 * gprof.texi: Fix numerous typos. Mention some DOS/Windows related
687 * configure.in: Check for setmode function.
688 * configure: Regenerate.
690 * gmon_io.h (SET_BINARY) [HAVE_SETMODE]: Define.
692 * gmon_io.c (gmon_out_read) [SET_BINARY]: Switch stdin into binary
695 * source.c: Include filenames.h and sys/stat.h.
696 (source_file_lookup_path, source_file_lookup_name): Use
697 FILENAME_CMP to compare file names.
698 (annotate_source) [__MSDOS__]: If "filename-ann" would overwrite
699 "filename", replace the extension with ".ann".
700 [HAVE_DOS_BASED_FILE_SYSTEM]: Support file names with
701 backslashes and drive letters.
702 Use IS_ABSOLUTE_PATH.
704 * search_list.h (PATH_SEP_CHAR): Define.
706 * search_list.c (search_list_append): Use PATH_SEP_CHAR.
708 * hertz.c (HERTZ) [__MSDOS__]: Don't define unless they have
709 neither HAVE_SETITIMER nor HAVE_SYSCONF.
710 [HAVE_SETITIMER]: If they define both HAVE_SETITIMER and
711 HAVE_SYSCONF, try setitimer and fall back on sysconf.
715 * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
716 --enable-build-warnings option.
717 * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
718 * Makefile.in, configure, aclocal.m4: Re-generate.
722 * gprof.c (copyright): Do not use N_ in array initializer.
726 * po/gprof.pot: Regenerate.
728 * gprof.c (usage): Restore translated part of bug string.
730 * Makefile.am (BASEDIR): Define.
734 (INCLUDES): Add "-I."
735 (DEP, DEP1, dep.sed, dep, dep-in, dep-am): New targets.
736 (CLEANFILES): Define.
738 * Makefile.in: Regenerate.
742 * gprof.h: #include "bin-bugs.h".
743 * gprof.c (usage): Use REPORT_BUGS_TO.
747 * symtab.c (symtab_finalize): Don't use post-increment on
748 structure copy, to work around a ppc gcc bug.
752 * hertz.h [MACH] (hertz): Remove macro. The
753 <machine/mach_param.h> include doesn't exist on al Mach based
754 systems, and the definition of hertz breaks compilation of hertz.c
760 * i386.c (i386_find_call): Add cast to ensure that printf argument
762 * tahoe.c (tahoe_find_call): Likewise.
763 * vax.c (vax_find_call): Likewise.
767 * utils.c (print_name_only): Don't pass error strings to
768 printf as format arg.
772 * gmon_io.c (gmon_out_read): Make sure that sensible values
773 are extracted from a raw header.
778 * corefile.c (core_create_line_syms): Add cast for printf.
783 * configure.bat: Remove; obsolete.
787 * configure.in: Bump version number to 2.9.5.
788 * configure: Rebuild.
792 * corefile.c (core_create_function_syms): Add ATTRIBUTED_UNUSED.
793 * sym-ids.c (non_existent_file): Fully initialize structure.
797 * Many files: Add casts in many print statements to cast bfd_vma
798 values to unsigned long when calling printf.
799 * Makefile.am ($(OBJECTS)): Add gmon.h.
800 * Makefile.in: Rebuild.
804 * gprof.texi: Fix typo.
809 * cg_dfn.c: Include "libiberty.h"
810 (DFN_INCR_DEPTH): Define instead of DFN_DEPTH.
811 (dfn_stack): Define as pointer rather than array.
812 (pre_visit): Reallocate dfn_stack as needed.
816 * aclocal.m4, configure: Updated for new version of libtool.
820 * gprof.h (LC_MESSAGES): Never define.
821 * gprof.c (main): Don't pass LC_MESSAGES to setlocale if the
822 system does not define it.
826 * corefile.c (core_create_line_syms): Don't use fixed size array
827 for prev_name and prev_filename.
831 * gprof.h (FF_BSD44): Define.
832 * gmon.h (struct raw_phdr): Add version, profrate, and spare
833 fields unconditionally.
834 (struct old_raw_phdr): New struct.
835 * gprof.c (main): Handle -O 4.4bsd.
836 * gmon_io.c (gmon_out_read): Handle BSD 4.4 format, either
837 automatically or by user specification.
838 (gmon_out_write): Handle BSD 4.4 format.
839 * configure.in: Don't set BSD44_FORMAT.
840 * gprof.texi (Miscellaneous Options): Document -O 4.4bsd.
841 * configure, gconfig.in: Rebuild.
845 * configure.in: Change AC_PREREQ to 2.13. Change AM_PROG_INSTALL
846 to AC_PROG_INSTALL. Remove AM_CYGWIN32. Change AM_EXEEXT to
847 AC_EXEEXT. Add comment to AC_DEFINE.
848 * acconfig.h: Remove.
849 * aclocal.m4: Rebuild.
850 * configure: Rebuild.
851 * Makefile.in: Rebuild.
852 * gconfig.in: Rebuild.
856 * gprof.texi (Symspecs): Mention that you have to add any
857 underscore yourself when naming a symbol.
861 * configure.in: detect cygwin* instead of cygwin32*
862 * configure: regenerate
866 Avoid some overflow cases:
867 * basic_blocks.h (bb_min_calls): Change to unsigned long.
868 * call_graph.h (cg_tally): Change count parameter to unsigned
870 * cg_arcs.h (Arc): Change count field to unsigned long.
871 (arc_add): Change count parameter to unsigned long.
872 * source.h (Source_File): Change ncalls field to unsigned long.
873 * symtab.h (Sym): Change fields ncalls, bb_calls, and
874 cg.self_calls to unsigned long.
875 * Many files: Update accordingly.
877 * configure, Makefile.in, aclocal.m4: Rebuild with current tools.
881 * configure.in (BSD44_FORMAT): Define for cygwin32, win32, mingw32
882 * configure: Rebuild.
886 * po/Make-in (all-yes): If maintainer mode, depend on .pot file.
887 ($(PACKAGE).pot): Unconditionally depend on POTFILES.
891 * po/Make-in (install-info): New target.
895 * gprof.h (_): Undefine BFD's version.
899 * gprof.c (main): Conditionally call setlocale.
900 * gprof.h: Include <locale.h> if HAVE_LOCALE_H.
901 (LC_MESSAGES): Now can be defined even when ENABLE_NLS.
905 * corefile.c: Rename from core.c.
906 * corefile.h: Rename from core.h.
907 * Many .c files: Include corefile.h rather than core.h.
908 * Makefile.am (sources): Change core.c to corefile.c.
909 (noinst_HEADERS): Change core.h to corefile.h.
910 ($(OBJECTS)): Depend upon corefile.h rather than core.h.
911 (corefile.o): Rename target from core.o, depend upon corefile.c.
912 * Makefile.in, po/POTFILES.in: Rebuild.
916 * configure.in: Change version number to 2.9.4
917 * configure: Rebuild.
921 * po/Make-in (MKINSTALLDIRS): Don't look in $(top_srcdir).
925 * gprof.h: Added includes and defines for gettext.
926 * configure.in (ALL_LINGUAS): New macro.
927 Call CY_GNU_GETTEXT. Create po/Makefile.in and po/Makefile.
928 * acconfig.h (ENABLE_NLS, HAVE_CATGETS, HAVE_GETTEXT, HAVE_STPCPY,
929 HAVE_LC_MESSAGES): Define.
930 * gprof.c (main): Call setlocale, bindtextdomain, textdomain.
931 * Makefile.am (SUBDIRS): New macro.
932 (INCLUDES): Look in intl dirs for headers. Define LOCALEDIR.
933 (gprof_DEPENDENCIES): Added INTLDEPS.
934 (gprof_LDADD): Added INTLLLIBS.
935 (POTFILES): New macro.
936 (po/POTFILES.in): New target.
937 * Many files: Wrap user-visible strings with gettext invocation.
942 * Makefile.am (diststuff): New target.
943 * Makefile.in: Rebuild.
947 * configure.in: Set version to 2.9.1.
948 * configure: Rebuild.
950 * Branched binutils 2.9.
954 Fix some gcc -Wall warnings:
955 * cg_arcs.c (num_cycles): Change to unsigned int.
957 (arc_add): Change maxarcs to unsigned int.
958 (cg_assemble): Change index to unsigned int.
959 * cg_arcs.h (num_cycles, numarcs): Update declarations.
960 * cg_print.c (cg_print): Change index to unsigned int.
961 (cg_print_index): Change index, nnames, todo, i, and j to unsigned
963 (cg_print_file_ordering): Change symbol_count and index2 to
965 * core.c (symbol_map_count): Change to unsigned int.
966 (core_create_function_syms): Change j to unsigned int.
967 (core_create_line_syms): Add cast to avoid warning.
968 * hist.c (hist_assign_samples): Change j to unsigned int.
969 (hist_print): Change index to unsigned i nt. Add cast to avoid
971 * sym_ids.c (parse_spec): Add casts to avoid warning.
972 * symtab.c (symtab_finalize): Change j to unsigned int.
973 (sym_lookup): Update printf format strings.
974 * symtab.h (Sym_Table): Change len to unsigned int.
975 * tahoe.c (tahoe_reladdr): Add casts to avoid warnings.
979 Add --demangle and --no-demangle options:
980 * gprof.h (demangle): Declare.
981 * gprof.c (demangle): New global variable.
982 (OPTION_DEMANGLE, OPTION_NO_DEMANGLE): Define.
983 (long_options): Add "demangle" and "no-demangle".
984 (usage): Mention --demangle and --no-demangle.
985 (main): Handle OPTION_DEMANGLE and OPTION_NO_DEMANGLE.
986 * utils.c (print_name_only): Only demangle symbol name if demangle
988 * gprof.texi (Output Options): Document new options.
992 * Makefile.in: Rebuild with automake 1.2e.
993 * aclocal.m4, configure: Rebuild with libtool 1.2.
997 * gprof.c (usage): Update bug-gnu-utils address.
1001 * configure, aclocal.m4: Rebuild with new libtool.
1005 * alpha.c (alpha_Instruction): Use int, not signed.
1009 * core.c (core_init): Adding missing "break".
1013 * configure, Makefile.in, aclocal.m4: Rebuild with new libtool.
1017 * bbconv.pl: New file.
1018 * Makefile.am (EXTRA_DIST): Add bbconv.pl.
1019 * Makefile.in: Rebuild.
1021 * gprof.texi: Extensive additions to document all arguments and
1024 * symtab.c (symtab_finalize): Prefer function symbols over line
1026 (dbg_sym_lookup): Correct debugging messages.
1028 * gprof.c (main): --sum implies --line.
1030 * cg_print.c (cg_print): When doing line by line profiling, don't
1031 use a non-function as a main listing item.
1033 * call_graph.c (cg_tally): When using line by line profiling, use
1034 the function symbol as the child.
1036 * symtab.h (NBBS): Define.
1037 (Sym): Add bb_addr and bb_calls fields.
1038 * basic_blocks.c (bb_read_rec): Save multiple basic blocks per
1040 (bb_write_blocks): Adjust for multiple basic blocks per symbol.
1041 (print_exec_counts): Don't check whether a symbol is the start of
1042 a basic block. Print all basic blocks for a symbol.
1043 (annotate_with_count): Rewrite to print all basic block counts and
1044 to pay attention to width argument.
1045 (print_annotated_source): Don't check whether symbol is the start
1048 Make it possible to build a cross gprof, although a few cases are
1050 * configure.in: Don't set MY_TARGET.
1051 * gprof.h: Don't include MACHINE_H. Don't define FOPEN_RB or
1052 FOPEN_WB; just get them from sysdep.h.
1053 * core.h (min_insn_size, offset_to_code): Declare.
1054 * core.c (MIN_INSN_SIZE): Don't define.
1055 (min_insn_size, offset_to_code): New variables.
1056 (core_init): Initialize min_insn_size and offset_to_code.
1057 (find_call): New function.
1058 (core_create_line_syms): Don't use min_dist. Set is_static in
1060 * hist.c (UNITS_TO_CODE): Define.
1061 * gprof.c (default_excluded_list): Add "__mcount_internal".
1062 * gmon.h: Change TARGET_alpha to __alpha__.
1063 * hertz.h: Ifdef MACH, define hertz as HZ.
1064 * alpha.c (alpha_Instruction): Rename from Instruction. Change
1066 (alpha_find_call): Rename from find_call.
1068 * dummy.c, dummy.h: Remove.
1069 * i386.c (i386_iscall): Rename from iscall. Change all
1070 references. Check for call instruction, not jump or lcall.
1071 (i386_find_call): Rename from find_call. Correct for VMA.
1072 Correct call destination computation. Don't dereference symbol if
1075 * ns532.c, ns532.h: Remove.
1076 * sparc.c (CALL): Define.
1077 (sparc_find_call): Rename from find_call.
1079 * tahoe.c: Include cg_arcs.h, core.h, hist.h, and symtab.h. Don't
1080 include time_host.h.
1081 (CALLF, PC): Define.
1082 (enum tahoe_opermodes, tahoe_operandenum): Define. Rename all
1083 references to opermodes or operandenum to these.
1084 (tahoe_operandmode): Rename from operandmode. Call abort if
1085 switch does not return.
1086 (tahoe_operandname): Rename from operandname. Call abort if
1087 switch does not return.
1088 (tahoe_operandlength): Rename from operandlength. Call abort if
1089 switch does not return.
1090 (tahoe_reladdr): Rename from reladdr.
1091 (tahoe_find_call): Rename from find_call. Use core_text_space
1092 rather than textspace.
1094 * vax.c (CALLS, PC): Define.
1095 (enum opermodes, operandenum, struct modebyte): Define.
1096 (vax_operandmode): Rename from operandmode. Call abort if switch
1098 (vax_operandname): Rename from operandname. Call abort if switch
1100 (vax_operandlength): Rename from operandlength. Call abort if
1101 switch does not return.
1102 (vax_reladdr): Rename from reladdr.
1103 (vax_find_call): Rename from find_call.
1105 * Makefile.am (AUTOMAKE_OPTIONS): Set to cygnus.
1106 (MY_TARGET): Remove.
1107 (INCLUDES): Remove -DTARGET_$(MY_TARGET) and -DMACHINE_H=
1109 (gprof_SOURCES): Add i386.c, alpha.c, vax.c, tahoe.c, sparc.c.
1110 (gprof_DEPENDENCIES): Remove $(MY_TARGET).o.
1111 (gprof_LDADD): Likewise.
1112 (noinst_HEADERS): Remove alpha.h, i386.h, ns532.h, sparc.h,
1113 tahoe.h, vax.h, dummy.h.
1114 (EXTRA_DIST): Remove alpha.c, i386.c, ns532.c, sparc.c, tahoe.c,
1116 ($(OBJECTS)): Don't depend upon $(MY_TARGET).h.
1117 ($(MY_TARGET).o): Remove target.
1118 (i386.o, alpha.o, vax.o, tahoe.o, sparc.o): New targets.
1119 * configure, Makefile.in, aclocal.m4: Rebuild.
1123 * core.c (core_sym_class): Treat weak symbols as text symbols.
1128 * aclocal.m4: Rebuild with new libtool.
1129 * Makefile.in: Rebuild with current automake.
1130 * configure: Rebuild.
1134 * configure.in: Change version number to 2.8.2. Call
1135 AM_PROG_LIBTOOL. Remove shared library handling; now handled by
1136 libtool. Add AM_CONFIG_HEADER. Change AC_PROG_INSTALL to
1137 AM_PROG_INSTALL. Add AM_EXEEXT.
1138 * Makefile.am (LINK): Remove.
1139 (gprof_LDFLAGS): Remove
1140 (gprof_DEPENDENCIES): Change libbfd.a to libbfd.la.
1141 (gprof_LDADD): Likewise.
1142 ($(OBJECTS)): Depend upon gconfig.h and ../bfd/config.h.
1143 * gprof.h: Undefine PACKAGE and VERSION after including BFD
1144 sysdep.h file, then include new gconfig.h file.
1145 * gprof.c (VERSION): Don't define.
1146 * acconfig.h: New file.
1147 * stamp-h.in: New file.
1148 * gconfig.in: New file, created by autoheader.
1149 * Makefile.in, configure, aclocal.m4: Rebuild.
1153 * aclocal.m4, configure, Makefile.in: Rebuild with automake 1.2.
1157 * Makefile.am (INCLUDES): Add -DDEBUG.
1158 * Makefile.in: Rebuild.
1162 Change to use automake:
1163 * Makefile.am: New file.
1164 * configure.in: Run AM_INIT_AUTOMAKE, AM_MAINTAINER_MODE, and
1166 * aclocal.m4: New file, created by aclocal.
1167 * Makefile.in: Replace with file created by automake --cygnus.
1168 * configure: Rebuild.
1172 * gprof.c (VERSION): Define as "2.8.1".
1174 * Branched binutils 2.8.
1178 * gprof.c (main): Correct copyright message.
1182 * Makefile.in (.c.o): Define TARGET_$(MY_TARGET) when compiling.
1183 * gmon.h: Use bytes counts rather than sizeof in struct raw_phdr
1188 * cg_arcs.c (arc_add): memset() newly alloced arc to ensure
1189 all fields are initialized with 0.
1193 * symtab.h (find_call): Declare.
1194 * cg_arcs.c (cg_assemble): Don't declare find_call.
1195 * hist.c (scale_and_align_entries): Declare.
1199 * configure.in: Define BSD44_FORMAT if the target looks like a
1200 BSD4.4 derived system.
1201 * configure: Rebuild.
1202 * Makefile.in (.c.o): Add @DEFS@.
1203 * gmon_io.c (gmon_out_read): In BSD44_FORMAT code, get profrate
1204 from profrate field, not version field.
1208 * dummy.c (find_call): Clear ignore_direct_calls.
1212 * Makefile.in (.c.o): Add -D_GNU_SOURCE. Put $(CFLAGS) at the
1214 (gprof): Put $(CFLAGS) after the other options.
1218 * configure: Rebuild with autoconf 2.12.
1222 * sparc.c (find_call): Align p_lowpc to avoid bus error.
1226 * gprof.c (usage): Print bug report address.
1227 (main): Change version printing to match current GNU standards.
1231 * gmon.h: Replace #elif with #else/#endif.
1235 * configure.in (i[345]86-*-*): Recognize i686 for pentium pro.
1236 * configure: Regenerate.
1240 * configure.in: Set and substitute HLDENV.
1241 * configure: Rebuild.
1242 * Makefile.in (HLDENV): New variable.
1243 (gprof): Use $(HLDENV).
1247 * core.c (read_function_mappings): Cast xmalloc return.
1251 * gprof.c (VERSION): Define as "2.7.1".
1253 * Released binutils 2.7.
1255 * bb_exit_func.c: Rename from __bb_exit_func.c, so that it can be
1256 stored on a System V file system.
1260 * configure.in: Call AC_ISC_POSIX.
1261 * configure: Rebuild.
1262 * Makefile.in (gprof): Pass $(CFLAGS) during link.
1263 * hertz.c: Don't include <sys/time.h>; let sysdep.h handle that.
1264 If HAVE_SETITIMER is not defined, try using sysconf.
1268 * Makefile.in (exec_prefix, bindir, libdir, mandir, infodir, datadir,
1269 INSTALL_PROGRAM, INSTALL_DATA): Use autoconf-set values.
1270 * configure.in (AC_PREREQ): autoconf 2.5 or higher.
1271 (AC_PROG_INSTALL): added.
1272 * configure: Rebuilt.
1276 * configure.in: On alpha*-*-osf*, link against libbfd.a if not
1277 using shared libraries.
1278 * configure: Rebuild with autoconf 2.10.
1282 * core.c (core_create_line_syms): Use xstrdup rather than strdup.
1283 * source.c (source_file_lookup_path): Likewise.
1287 * configure.in: Permit --enable-shared to specify a list of
1289 * configure: Rebuild.
1293 * core.c (core_create_function_syms): Move filename and func_name
1294 inside ifdef where they are used.
1296 * core.c (core_sym_class): Parenthesize && within ||.
1297 * symtab.c (symtab_finalize): Correct parenthesization.
1299 * cg_print.h (cg_print_file_ordering): Declare.
1300 (cg_print_function_ordering): Declare.
1302 * __bb_exit_func.c (__bb_exit_func): Replace bcopy with memcpy.
1303 * cg_arcs.c (arc_add): Likewise.
1304 * cg_print.c (cg_print_function_ordering): Likewise.
1308 * gprof.c (default_excluded_list): Add "__mcount".
1310 * gprof.c (main): Change ifdef __osf__ to __alpha__.
1312 * gmon_io.c (gmon_out_read): If BSD44_FORMAT is defined, get the
1313 profiling rate from the header.
1315 * gmon.h (struct raw_phdr): Only include pad if both __alpha__ and
1316 __osf__ are defined. Add new fields if BSD44_FORMAT is defined.
1318 * alpha.h (MIN_INSN_SIZE): Define.
1319 * core.c (MIN_INSN_SIZE): If not defined, define as 1.
1320 (core_sym_class): Ignore debugging symbols.
1321 (core_create_line_syms): Use MIN_INSN_SIZE when gathering line
1326 * cg_print.c (cg_print_function_ordering): Fix __GNUC__ misspelled
1328 (order_and_dump_functions_by_arcs): Likewise.
1332 * configure: Rebuild with autoconf 2.8.
1336 * configure.in: Check for 'do not mix' from native linker before
1337 trying to use -rpath.
1338 * configure: Rebuild.
1342 * configure.in: Set HDLFLAGS for *-*-hpux with --enable-shared.
1343 * configure: Rebuild.
1347 * configure.in: Don't set CC. Look for --enable-shared. Set
1348 BFDLIB and HLDFLAGS and substitute them.
1349 * configure: Rebuild.
1350 * Makefile.in (LIBS): Use @BFDLIB@.
1351 (HLDFLAGS): New variable.
1352 (gprof): Use $(HLDFLAGS).
1356 Support for building bfd and opcodes as shared libraries, based on
1358 * Makefile.in (LIBDEPS): New variable.
1359 (LIBS): Use -L../bfd -lbfd.
1360 (gprof): Depend upon $(LIBDEPS) rather than $(LIBS).
1364 * gprof.c (long_options): Add "--function-ordering" and
1365 "--file-ordering" options.
1366 (usage): Add new options to usage message.
1367 (main): Handle new options.
1368 * gprof.h (STYLE_FUNCTION_ORDER): Define.
1369 (STYLE_FILE_ORDER): Define.
1370 (function_mapping_file): Declare.
1371 * cg_arcs.c (arcs, numarcs): New globals.
1372 (arc_add): Put new arcs into the arc array so the function/file
1373 ordering code can examine them.
1374 * cg_arcs.h (struct arc): New field "has_been_placed".
1375 (arcs, numarcs): Declare new globals.
1376 * core.c (symbol_map, symbol_map_count): New globals.
1377 (read_function_mappings): New function to read in a function
1379 (core_init): Call read_function_mappings if a function mapping
1381 (core_create_function_syms): Handle function to object file
1383 * symtab.h (struct sym): New fields "mapped", "has_been_placed",
1385 * cg_print.c (cmp_arc_count): New function for sorting arcs.
1386 (cmp_fun_nuses): Likewise for functions.
1387 (cg_print_function_ordering): New function to print a suggested
1389 (cg_print_file_ordering): Likewise for ordering .o files.
1390 (order_and_dump_functions_by_arcs): Helper function for function
1391 and object file ordering code.
1395 * core.c (core_sym_class): Ignore symbols without BSF_FUNCTION
1396 set if ignore_non_function is set.
1397 * gprof.h (ignore_non_functions): Declare.
1398 * gprof.c (ignore_non_functions): Define.
1399 (long_options): Add "ignore-non-functions".
1400 (usage): Add new options.
1401 (main): Recognize "-D" and "--ignore-non-functions" option.
1405 * Makefile.in (.m.c): Strip out directory name from function
1408 * hist.c (scale_and_align_entries): Don't use DEFUN_VOID. Do
1409 UNITS_TO_CODE adjustment unconditionally; compiler can optimize
1410 away zero-offset case. Refer to scaled_addr, not aligned_addr.
1412 * vax.c: Don't include vax.h here.
1416 Version 2.6 released.
1420 * gprof.c (main): Cast getenv return value.
1424 * Makefile.in (TAGS): New target.
1428 * Makefile.in (DISTSTUFF): Rename to GEN_FILES, to avoid confusion.
1429 (all): Depend on $(GEN_FILES), not diststuff (which also depends
1434 * sym_ids.c: Include <ctype.h>.
1438 * Makefile.in (diststuff): Also make info.
1439 (mostlyclean): Don't remove gprof.info*.
1440 (maintainer-clean realclean): Also remove *.info*.
1446 * Makefile.in: Add dependecies for $(OBJS) on header files.
1448 * cg_print.c (print_cycle, print_members, cg_print_index): Fix new
1449 style output format to make it consistent.
1450 * dummy.c (find_call): Fix typo in error message.
1454 * Makefile.in (maintainer-clean): New target, synonym for
1459 * Makefile.in (install): Don't install in $(tooldir).
1463 NS32K changes from Ian Dall:
1464 * configure.in: Use ns32k, not ns532.
1465 * ns532.c: Include symtab.h.
1466 (find_call): Renamed from findcall. Print a message.
1467 * ns532.h: Remove dummy.h comments.
1471 * Makefile.in (install): Remove "brokensed" hack, unnecessary now
1472 that we're using autoconf.
1476 * core.c (get_src_info): Cast arg 7 of bfd_find_nearest_line
1477 to proper type of "unsigned int *".
1481 * configure.in: Use changequote around use of [].
1485 * Makefile.in (distclean, realclean): Remove config.cache and
1490 * Makefile.in (Makefile): Added config.status to dependency list.
1491 (config.status): New target.
1492 (SHELL): New definition.
1496 * Makefile.in (install): Depend on "all".
1500 * Makefile.in: Change all references to MY_MACHINE to MY_TARGET,
1501 to match configure script.
1505 * gen-c-prog.awk: Changed reference to "make-c-prog.awk" in
1506 comment emitted by this script to gen-c-prog.awk.
1508 * Makefile.in, configure.in: Converted to use autoconf.
1509 * configure: New file, generated with autoconf 2.3.
1510 * config/{mt-alpha, mt-dummy, mt-i386, mt-ns532, mt-sparc,
1511 mt-tahoe, mt-vax}: Removed.
1515 * __bb_exit_func.c: New file, from David Mosberger-Tang.
1519 * All *.c: More cleanup towards GNU format.
1521 * gmon_out.h (struct gmon_hist_hdr, struct gmon_cg_arc_record):
1522 replaced sizeof (bfd_vma) by size (char*) because Ken tells me
1523 that bfd_vma is only guaranteed to be at least as big as a pointer.
1525 (GMON_Record_tag): added explicit enumeration values to ensure
1526 compatibility across compilers.
1528 * gmon_io.c (get_vma, put_vma): replaced sizeof(bfd_vma) by
1533 * All *.c and *.h files: Ran "indent -gnu". Cleaned up a couple
1534 of constructs GNU indent couldn't handle. Block comments not yet
1535 rewritten in GNU format.
1537 * gprof.c (VERSION): Changed to 2.6, to get in sync for next
1542 * symtab.c (symtab_finalize): ensure globals symbols really
1543 are favored over static ones---even if their name looks less
1544 preferable; this is important for HP-UX; for example, there
1545 is a static label Ltext_something that aliases the global
1548 * hist.c (hist_print): auto-scaling is now in effect for FSF-style
1549 output only; also, auto-scaling is now performed based on
1550 per-call, rather than total execution time, which is what it was
1553 * gprof.h (File_Format): new type.
1555 * gprof.c (VERSION): upped to 2.7---seems to be completely out of
1556 sync with Cygnus version numbers though...
1558 (long_options): renamed --gmon-info to --file-info, --width added,
1559 renamed --old-file-format to --file-format
1560 (main): dito; also added support to read prof files, but as
1561 mon_out_read() is not implemented, it's #ifdef'd out for now
1563 (usage): update to reflect new options.
1565 * gmon_io.c: replaced "old_file_format" by more general
1566 "file_format" option
1568 * gmon.h (struct raw_phdr): fixed declaration for OSF/1.
1570 * core.c (core_sym_class): added back check for __gnu_compiled and
1571 ___gnu_compiled for the benefit of systems without
1572 bfd_find_nearest_line() support
1574 (get_src_info): now the libbfd is fixed, invoke bfd_find_nearest_line()
1575 with section-relative addresses
1577 (core_create_function_syms): get_src_info() calls are currently
1578 enabled for OSF/1 only. It appears to work allright for SunOS
1579 4.1.x as well, but on SPARCs it gets painfully slow with the
1580 current implementation of aout_32_find_nearest_line();
1581 unfortunately, this means that static functions will not have their
1582 filename printed in the call-graph function index; line-level
1583 profiling should still work, but requires some patience
1585 * cg_print.c (cg_print_index): sanitised printing of index when
1586 using FSF-style output; in particular, output width is now controlled
1587 via option --width and the function tries hard to keep columns
1588 aligned even in the presence of (occasional) long names
1590 * NOTES: a first shot at updating the documentation.
1594 * core.c (core_create_function_syms): fixed computation of min_vma
1597 * *.c: removed rcsid.
1601 * Lots of changes from David Mosberger-Tang:
1605 * gprof.c (main): put parentheses around & within &&.
1607 * basic_blocks.c (bb_read_rec): print warning message (once) when
1608 ignoring basic-block execution counts.
1610 * source.c (source_file_lookup_name): corrected second argument to
1613 * hist.c (print_header): merged Fri Oct 21 18:58:02 1994 change by
1616 * gmon_io.c (gmon_out_read): the output stule STYLE_GMON_INFO is now
1617 supported both for old and new (versioned) gmon.out files. Old
1618 files are identified as version 0.
1620 * gmon.h (struct raw_arc): count field is now sizeof(long) bytes
1621 long (instead of 4) because that is what OSF/1 v3.0 uses.
1623 * core.c: minor fixes and debugging info changes.
1627 * core.c (core_init): if .text cannot be found, try $CODE$ (the
1628 name of the text-section under HP-UX).
1630 * hist.c (hist_assign_samples): fixed off-by-one bug: highpc
1631 points one past the last sampling bin, so hist_scale should be
1632 computed as "hist_scale /= hist_num_bins", not "hist_scale /=
1635 * gmon_io.c, hist.c, hist.h: renamed hist_num_samples to
1638 * configure.in: added alpha-*-*) for per-target config.
1640 * alpha.c, alpha.h: created.
1642 * gprof.c (default_excluded_list): <locore>, <hicore> added.
1644 * core.c (core_create_function_syms, core_create_line_syms):
1645 explicitly keep two sentinels "<locore>" and "<hicore>" that catch
1646 all addresses outside the text-space. Thus, sym_lookup(&symtab,
1647 addr) continues to guarantee not to return 0 on any address. It
1648 also avoids incorrectly crediting the first/last symbol in the
1651 * core.c (core_create_line_syms): always create function symbols
1652 first, then merge in line symbols; this is so that if parts of the
1653 program were compiled without -g, function-level symbols are
1656 * utils.c (print_name_only): support for print_path added.
1658 * symtab.c (cmp_addr): also use is_func flag in comparison.
1659 (symtab_finalize): return immediately when table empty; now
1660 more careful about getting rid of the right duplicate symbol.
1662 * sparc.c (find_call): many fixes---this function was rather
1663 botched in binutils-2.4 already; it should work again.
1665 * source.c (source_file_lookup_path): PATH is now strdup'ed (it is
1666 not good to rely on get_src_info() to return distinct string
1669 * search_list.c (search_list_append): added cast for xmalloc().
1671 * hist.c: added explicit initialization to some of the global
1672 variables; fixed SItab (scales were off by a factor of 10).
1674 * hist.h: include of bfd.h added.
1676 * gprof.c, gprof.h (print_path): added.
1678 * gprof.h (MAX): fixed.
1680 * gmon_out.h: renamed gmon_time_hist_hdr to gmon_hist_hdr.
1682 * gmon_io.c: added some casts to (long) so we can always print as %lx
1684 * core.c (core_get_text_space): fixed to make it work.
1686 * cg_print.c (cg_print_index): added support for print_path option.
1688 * cg_dfn.h (cg_dfn): wrap prototype in PARAMS().
1690 * call_graph.c, gmon_io.c, hist.c: avoid taking address of array
1691 as some compilers complain (e.g., DEC's OSF/1 compiler)
1693 * basic_blocks.c, gmon_io.c, hist.c, source.c, sym_ids.c,
1694 symtab.c: calls to memset() had 2nd and 3rd args reversed.
1698 * gprof.c: added "_mcount" to default_excluded_list.
1699 (main): if output_style==0 and there is either a histogram or a
1700 call-graph, always generate flat and call-graph, no matter what
1701 line_granularity is set to.
1703 * source.c (source_file_lookup_name): if searching for sf->name
1704 fails, try again with filename obtained after stripping off any
1705 partial path from sf->name.
1707 * gprof.h (SRCDEBUG): added.
1709 * search_list.c (search_list_append): directories were added in wrong
1712 * reimplemented selection mechanism from ground up; it is now possible
1713 to accurately control what gets included/excluded in each of the
1714 output styles; a "symbol-specification" (spec) is the basic means
1715 to select a set of symbols; a spec has the syntax:
1717 spec == (FILENAME:(FUNCNAME|LINE_NUM) | NAME).
1720 any of the terminal symbols can be empty, in which case they
1721 match anything (wildcards). NAME is interpreted as a FILENAME
1722 if it contains a dot (e.g., foo.c), as LINE_NUM if it starts
1723 with a digit, and as FUNCNAME otherwise.
1725 For example, to get a call-graph display that ignores arcs
1726 from foo() to bar(), you'd say "--no-graph=foo/bar"; to
1727 show only arcs into bar() (no matter what the caller),
1728 you'd say "--graph=/bar"; and to get a call-graph without
1729 any arc info, you'd say "--graph=/"; similarly, to
1730 get a flat profile without mcount, you'd say "--no-flat=mcount"
1731 and to get a flat profile that shows includes all functions
1732 you'd say "--flat=""" (i.e., an empty spec)
1734 * hist.c (hist_print): top_time wasn't initialized to 0.0.
1738 * gmon_out.h: all headers now declared in terms of characters
1739 to avoid getting into trouble with different compilers introducing
1740 different amount of padding; the code already accessed the fields
1741 through bfd functions, so that didn't have to change.
1743 * hist.c (hist_read_rec, hist_write_rec): added support for
1744 collection pc histograms measuring quantities other than time;
1745 the histogram header now includes a field that specifies the
1746 dimension of the quantity measured by the histogram bins
1747 (normally, this is "seconds", but other meaningful dimensions
1748 include such things as "I-cache misses", "instruction issue stalls"
1749 etc.); there is also a field to specify a one-character
1750 abbreviation for the dimension; in the case of time, this would
1751 be 's'; in most other cases it probably would be '1' (not a physical
1756 * gprof.c, gmon_io.[ch]: BSD_COMPATIBLE is gone and new_file_version
1757 has become old_file_version; gmon_io.c now always supports old-style
1758 gmon.out files; it first tries to read gmon.out as a new version
1759 file, if that fails, it tries to read it in the old format;
1760 although not very likely, it is possible for gprof to mistake an
1761 old-style file as a new one (the first 4 bytes would have to
1762 be "gmon"---including the trailing '\0'); in that case, it is
1763 necessary to specify --old-file-version
1765 * gprof.h: removed dependency on SYSV; the code now always uses
1766 strrchr(), memset(), and memcpy() and does not include either
1767 of string.h or strings.h; this should make gprof compile on
1768 any (Unix) system without configuration (per suggestion of
1771 * gprof.c (usage): fixed location of --new-file-format option.
1773 * cg_arcs.c (propagate_flags): fixed typo in declaration.
1775 * flat_bl.m: removed formfeed at end of file; the form-feed
1776 is now printed cg_print.c only when necessary.
1778 * major rewrite of gprof---too many changes to mention all of
1781 + -l now requests profiling at the line level (as opposed
1782 to function level); in this mode, gprof creates a "symbol"
1783 (aka name-list entry) for each line of source code, instead
1784 of one per function)
1786 + support for a new gmon.out file format; the new format
1787 consists of a header with a magic and a version number,
1788 followed by a sequence of profile data; profile data
1789 can any of: (a) PC histogram, (b) call-graph arcs, or
1790 (c) basic-block execution counts; the version number makes
1791 it possible to extend gmon.out in a backwards compatible
1794 + support for tcov style annotated output: if the gmon.out file
1795 contains basic-block execution counts, the user can request
1796 the generation of annotated source files, much like Sun's
1801 + new scheme to suppress symbols that aren't function names
1802 (e.g., avoids mistaking a goto label as a function)
1804 + reorganized source code to make it more managable; as a
1805 side effect, gprof now compiles cleanly with "gcc -Wall"
1809 * gprof.c (funcsymbol): bfd_find_nearest_line() is now used as a
1810 final cross-check to determine whether a static symbol should be
1811 considered as a function-name.
1815 * gmon_io.c (gmon_out_read): recognize "-" as the filename for
1816 stdin; this is useful if you wanna keep gmon.out files compressed;
1817 this way you can "gzcat" the compressed file into gprof.
1819 * gprof.c: flag_min_count now initialized with 1 instead of 0.
1821 * basic_blocks.c (bb_annotate_source): added support for creating
1822 .tcov files when option flag_annotate_make_files is TRUE.
1823 (annotate_with_count): all counts less than the minimum count
1824 specified by -m are now annotated with hash-marks.
1826 * gprof.c (main): -A is now followed by a string of option chars.
1828 * basic_blocks.c (annotate_with_count): replaced b->count with
1831 * source.c: flag_annotate_source replaced by source_lock_map.
1833 * source.h: source_lock_map added.
1835 * gprof.c (main): new command-line syntax: -S simply specifies
1836 which source-files user is interested in; -A requests annotated
1837 source files and -AA requests that all lines in a source file
1842 * basic_blocks.c (PATH_MAX): if undefined, define as 1024.
1844 * sparc.c, i386.c, tahoe.c, vax.c: added include of "time_hist.h"
1845 so s_lowpc etc. get declared.
1847 * arcs.h (doarcs): created.
1849 * arcs.c: reordered static functions such that they get defined
1852 * gprof.c (main): added options:
1853 -A: request annotation of all source lines (with -S)
1854 -m: minimum execution count (with default basic-block display)
1855 -N: force new file format (only if BSD_COMPATIBLE is defined)
1856 -S: annotate source file
1857 -t: set table length (with -S)
1859 * Makefile.am (OBJS): added basic_blocks.o call_graph.o gmon_io.o
1860 source.o time_hist.o
1864 * gprof.c (asgnsamples): computation of "pcl" and "pch" depended
1865 on the fact being able to store a long in a double without loss of
1866 precision; this does not hold on machines with 64 bit longs and 64
1871 * printgprof.c (flatprofheader): Always set totime to 1.0 if not
1872 greater than 0.0. Suggested by Harold Assink
1877 * printgprof.c (printprof): Use free, not cfree.
1878 (printgprof, printindex): Ditto.
1882 * gprof.h (kfromlist, ktolist, flist, Flist, elist, Elist): Make
1883 decls extern to keep native HP compiler quiet.
1887 * gprof.c (funcsymbol): Ignore ___gnu_compiled as well as
1888 __gnu_compiled, for the benefit of systems which add a leading
1893 * configure.in: Change i386-*-* to i[345]86-*-*.
1897 * ns532.c, ns532.h: New Files. ns532 support.
1899 * config/mt-ns532: New File. ns532 support.
1901 * gprof.c: user register int i instead of defaulting the int.
1902 Allows compilation with -Dregister= for debugging.
1904 * configure.in: Add ns532 support.
1908 * Makefile.in (gprof): Depend on $(LIBS).
1912 From binutils-2.4 release:
1916 * configure.bat: [new] build makefile from makefile.in (dos)
1917 * hertz.c: allow static HERTZ (msdos needs it)
1918 * gprof.c: allow target to select "r" or "rb" for fopen
1919 * gprof.c: ignore __gnu_compiled symbols
1920 * i386.h: dfine FOPEN_RB to "rb" for dos.
1924 * Makefile.in (.m.c:): Added .SUFFIXES : .m
1925 so flat_bl.c would make from flat_bl.m file.
1929 * Makefile.in (install-info): Check for gprof.info in build dir,
1930 fall back to srcdir. Depend on it.
1932 * gprof.h (TRUE, FALSE): Always use undef before defining them.
1936 * Makefile.in (MY_MACHINE): Renamed from MACHINE to avoid losing
1937 makes (osf1) in which the value of MACHINE can not be changed.
1938 * config/*.mt: Changed appropriately.
1942 * gprof.c (getsymtab): Change nosyms to long. Rename
1943 get_symtab_upper_bound to bfd_get_symtab_upper_bound. Check for
1944 errors from bfd_get_symtab_upper_bound and
1945 bfd_canonicalize_symtab.
1949 * gprof.c (funcsymbol): Use bfd_get_symbol_info instead of
1950 bfd_decode_symclass.
1954 * Makefile.in: Avoid bug in hpux sed.
1958 * gprof.texi (Invoking): add text about -v flag
1960 * gprof.1: add text about -v flag
1964 * gprof.c (VERSION): defined a version macro, print the value
1965 when the -v option is used
1969 * Makefile.in: Install correctly.
1973 * gprof.c (main): Get whoami from argv, instead of hardcoding.
1974 Use it in usage message. Split usage message to fit in 80 cols.
1978 * Makefile.in: Undo 15 June change.
1982 * gmon.h, gprof.h: structs of chars used to hold external
1984 * gprof.c (getpfile, openpfile, readsamples): Swap data in using
1989 * Makefile.in (.c.o): Look in ../include, not ../bfd, for bfd.h.
1991 Mon Jun 14 16:22:59 1993 david d `zoo' zuhn (zoo at rtl.cygnus.com)
1993 * Makefile.in: remove parentdir support
1997 * Makefile.in (INCLUDES): Add -I../bfd for sysdep.h and bfd.h.
1998 * configure.in: No longer need to configure to get sysdep.h.
2000 Tue May 18 21:44:11 1993 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
2002 * Makefile.in (install): should not depend on install-info
2006 * gprof.h: Include ansidecl.h before sysdep.h. Undefine hz.
2010 * Makefile.in: Add -g to CFLAGS.
2011 Ads LDFLAGS and use in place of CFLAGS where appropriate.
2012 * configure.in: Make a sysdep.hlink in the same way other
2013 bfd-based directories do.
2014 * gprof.h (UNIT): Replace non-standard 'u_short' by 'unsigned
2016 * gprof.h: #include sysdep.h instead of a bunch of stuff.
2017 * gprof.c (main): Fix typo gproff->gprof.
2019 Thu Mar 25 19:00:37 1993 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
2021 * gprof.texi: add INFO-DIR-ENTRY
2023 Tue Mar 23 00:03:11 1993 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
2025 * Makefile.in: add installcheck target
2029 * gprof.c (funcsymbol): Invert test for aflag.
2033 * printgprof (xmalloc, xrealloc): Cast results of malloc
2038 * Makefile.in: created info, install-info, dvi
2040 Wed Jan 6 00:58:09 1993 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
2042 * Makefile.in: fix install rule for $(PROG)
2046 * gprof.1: updated SYNOPSIS to match actual behavior.
2050 * gen-c-prog.awk: New awk script, lightly changed from
2051 previously deleted make-c-prog.awk. Converts a text file
2052 to a c function that prints that text.
2053 * flat_bl.m, fsf_callg_bl.m, bsd_callg_bl.m: New files.
2054 Inputs to gen-c-prog.awk, containing text describing
2056 * blurbs.c: Removed. Use *_bl.c instead.
2057 * Makefile.in: Use gen-cprog.awk to generate *_bl.c files
2058 from *_bl.m files. Also, improve *clean rules.
2059 * printgprof.c (printgprof): Usw new function names from *_bl.c.
2064 * gprof.h, gprof.c, printfgprof.c: Add support for two
2065 output styles: The default is similar to the old FSF gprof,
2066 while -T sets the variable bsd_style_output, which causes
2067 output matching Berkeley's gprof. The biggest differences
2068 are that with the FSF style output, the flat profile comes
2069 before the call graph; numbers come before explanations;
2070 and there is less gratuitous white space.
2071 * gprof.h, gprof.c, printfgprof.c: New discard_underscores
2072 variable causes discarding of initial underscores when
2073 printing symbol names. It is set unless there is a "main"
2074 symbol (without an underscore).
2075 * printfgprof.c: New function printnameonly(), called
2076 by printname(). It handles stripping of initial '_',
2077 as well as C++ name-demangling.
2078 * gprof.callg, gprof.flat, make-c-prog.awk: Removed.
2079 It is just as convenient to edit blurbs.c directly.
2080 * Makefile.in: Removed rule for making blurbs.c.
2081 * blurbs.c: This is now a true source file (as opposed
2082 to being generated from gprof.callg and gprof.flat).
2083 Change style to use one long string literal, instead of
2084 one literal per output line. Add FSF-style blurb for call graph.
2088 * Makefile.in: always create installation directories.
2092 * Makefile.in: change ${MACHINE} to $(MACHINE).
2094 Sun Jul 19 17:34:01 1992 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
2096 * Makefile.in: removed installation of the now useless
2097 call.{flag,callg} files.
2099 * gprof.1: now uses the standard man macros instead of the new BSD
2102 Sun Jul 12 19:06:00 1992 John Gilmore (gnu at cygnus.com)
2104 * configure.in: Remove host section, expand target section.
2105 * config/mt-{tahoe,vax}: Add, to match existing support files.
2106 * config/tmake-*: Remove leftover crud.
2108 * blurbs.c: New file, created from gprof.flat and gprof.callg by
2109 * make-c-prog.awk: which processes text files into C programs.
2110 * printgprof.c (flatprofheader, gprofheader): Call new functions
2112 (printblurb): Remove.
2113 * Makefile.in: Infrastructure to build blurbs.
2114 * pathnames.h: has been removed. Gprof now has no filename
2118 Sat Jul 11 18:07:21 1992 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
2120 * Makefile.in: define man1dir and install the man page
2124 * Makefile.in: added dummy info and install-info targets
2126 Thu Jun 4 11:34:02 1992 Mark Eichin (eichin at cygnus.com)
2128 * lookup.c: fixed fencepost in nllookup and added dbg_nllookup for
2129 help in debugging the problem (with -DDEBUG)
2130 * gprof.c: symbol values are now real values, don't add the vma
2131 anymore. (done for solaris; should verify this on other platforms)
2137 version-control: never