+
+ * gprof.h (_): Undefine BFD's version.
+
+
+ * gprof.c (main): Conditionally call setlocale.
+ * gprof.h: Include <locale.h> if HAVE_LOCALE_H.
+ (LC_MESSAGES): Now can be defined even when ENABLE_NLS.
+
+
+ * corefile.c: Rename from core.c.
+ * corefile.h: Rename from core.h.
+ * Many .c files: Include corefile.h rather than core.h.
+ * Makefile.am (sources): Change core.c to corefile.c.
+ (noinst_HEADERS): Change core.h to corefile.h.
+ ($(OBJECTS)): Depend upon corefile.h rather than core.h.
+ (corefile.o): Rename target from core.o, depend upon corefile.c.
+ * Makefile.in, po/POTFILES.in: Rebuild.
+
+
+ * configure.in: Change version number to 2.9.4
+ * configure: Rebuild.
+
+
+ * po/Make-in (MKINSTALLDIRS): Don't look in $(top_srcdir).
+
+
+ * gprof.h: Added includes and defines for gettext.
+ * configure.in (ALL_LINGUAS): New macro.
+ Call CY_GNU_GETTEXT. Create po/Makefile.in and po/Makefile.
+ * acconfig.h (ENABLE_NLS, HAVE_CATGETS, HAVE_GETTEXT, HAVE_STPCPY,
+ HAVE_LC_MESSAGES): Define.
+ * gprof.c (main): Call setlocale, bindtextdomain, textdomain.
+ * Makefile.am (SUBDIRS): New macro.
+ (INCLUDES): Look in intl dirs for headers. Define LOCALEDIR.
+ (gprof_DEPENDENCIES): Added INTLDEPS.
+ (gprof_LDADD): Added INTLLLIBS.
+ (POTFILES): New macro.
+ (po/POTFILES.in): New target.
+ * Many files: Wrap user-visible strings with gettext invocation.
+
+
+ * Makefile.am (diststuff): New target.
+ * Makefile.in: Rebuild.
+
+
+ * configure.in: Set version to 2.9.1.
+ * configure: Rebuild.
+
+ * Branched binutils 2.9.
+
+
+ Fix some gcc -Wall warnings:
+ * cg_arcs.c (num_cycles): Change to unsigned int.
+ (numarcs): Likewise.
+ (arc_add): Change maxarcs to unsigned int.
+ (cg_assemble): Change index to unsigned int.
+ * cg_arcs.h (num_cycles, numarcs): Update declarations.
+ * cg_print.c (cg_print): Change index to unsigned int.
+ (cg_print_index): Change index, nnames, todo, i, and j to unsigned
+ int.
+ (cg_print_file_ordering): Change symbol_count and index2 to
+ unsigned int.
+ * core.c (symbol_map_count): Change to unsigned int.
+ (core_create_function_syms): Change j to unsigned int.
+ (core_create_line_syms): Add cast to avoid warning.
+ * hist.c (hist_assign_samples): Change j to unsigned int.
+ (hist_print): Change index to unsigned i nt. Add cast to avoid
+ warning.
+ * sym_ids.c (parse_spec): Add casts to avoid warning.
+ * symtab.c (symtab_finalize): Change j to unsigned int.
+ (sym_lookup): Update printf format strings.
+ * symtab.h (Sym_Table): Change len to unsigned int.
+ * tahoe.c (tahoe_reladdr): Add casts to avoid warnings.
+
+
+ Add --demangle and --no-demangle options:
+ * gprof.h (demangle): Declare.
+ * gprof.c (demangle): New global variable.
+ (OPTION_DEMANGLE, OPTION_NO_DEMANGLE): Define.
+ (long_options): Add "demangle" and "no-demangle".
+ (usage): Mention --demangle and --no-demangle.
+ (main): Handle OPTION_DEMANGLE and OPTION_NO_DEMANGLE.
+ * utils.c (print_name_only): Only demangle symbol name if demangle
+ is true.
+ * gprof.texi (Output Options): Document new options.
+
+
+ * Makefile.in: Rebuild with automake 1.2e.
+ * aclocal.m4, configure: Rebuild with libtool 1.2.
+
+
+ * gprof.c (usage): Update bug-gnu-utils address.
+
+
+ * configure, aclocal.m4: Rebuild with new libtool.
+
+
+ * alpha.c (alpha_Instruction): Use int, not signed.
+
+
+ * core.c (core_init): Adding missing "break".
+
+
+ * configure, Makefile.in, aclocal.m4: Rebuild with new libtool.
+
+
+ * bbconv.pl: New file.
+ * Makefile.am (EXTRA_DIST): Add bbconv.pl.
+ * Makefile.in: Rebuild.
+
+ * gprof.texi: Extensive additions to document all arguments and
+ output formats.
+
+ * symtab.c (symtab_finalize): Prefer function symbols over line
+ symbols.
+ (dbg_sym_lookup): Correct debugging messages.
+
+ * gprof.c (main): --sum implies --line.
+
+ * cg_print.c (cg_print): When doing line by line profiling, don't
+ use a non-function as a main listing item.
+
+ * call_graph.c (cg_tally): When using line by line profiling, use
+ the function symbol as the child.
+
+ * symtab.h (NBBS): Define.
+ (Sym): Add bb_addr and bb_calls fields.
+ * basic_blocks.c (bb_read_rec): Save multiple basic blocks per
+ symbol.
+ (bb_write_blocks): Adjust for multiple basic blocks per symbol.
+ (print_exec_counts): Don't check whether a symbol is the start of
+ a basic block. Print all basic blocks for a symbol.
+ (annotate_with_count): Rewrite to print all basic block counts and
+ to pay attention to width argument.
+ (print_annotated_source): Don't check whether symbol is the start
+ of a basic block.
+
+ Make it possible to build a cross gprof, although a few cases are
+ still not handled:
+ * configure.in: Don't set MY_TARGET.
+ * gprof.h: Don't include MACHINE_H. Don't define FOPEN_RB or
+ FOPEN_WB; just get them from sysdep.h.
+ * core.h (min_insn_size, offset_to_code): Declare.
+ * core.c (MIN_INSN_SIZE): Don't define.
+ (min_insn_size, offset_to_code): New variables.
+ (core_init): Initialize min_insn_size and offset_to_code.
+ (find_call): New function.
+ (core_create_line_syms): Don't use min_dist. Set is_static in
+ pass 2.
+ * hist.c (UNITS_TO_CODE): Define.
+ * gprof.c (default_excluded_list): Add "__mcount_internal".
+ * gmon.h: Change TARGET_alpha to __alpha__.
+ * hertz.h: Ifdef MACH, define hertz as HZ.
+ * alpha.c (alpha_Instruction): Rename from Instruction. Change
+ all references.
+ (alpha_find_call): Rename from find_call.
+ * alpha.h: Remove.
+ * dummy.c, dummy.h: Remove.
+ * i386.c (i386_iscall): Rename from iscall. Change all
+ references. Check for call instruction, not jump or lcall.
+ (i386_find_call): Rename from find_call. Correct for VMA.
+ Correct call destination computation. Don't dereference symbol if
+ it is NULL.
+ * i386.h: Remove.
+ * ns532.c, ns532.h: Remove.
+ * sparc.c (CALL): Define.
+ (sparc_find_call): Rename from find_call.
+ * sparc.h: Remove.
+ * tahoe.c: Include cg_arcs.h, core.h, hist.h, and symtab.h. Don't
+ include time_host.h.
+ (CALLF, PC): Define.
+ (enum tahoe_opermodes, tahoe_operandenum): Define. Rename all
+ references to opermodes or operandenum to these.
+ (tahoe_operandmode): Rename from operandmode. Call abort if
+ switch does not return.
+ (tahoe_operandname): Rename from operandname. Call abort if
+ switch does not return.
+ (tahoe_operandlength): Rename from operandlength. Call abort if
+ switch does not return.
+ (tahoe_reladdr): Rename from reladdr.
+ (tahoe_find_call): Rename from find_call. Use core_text_space
+ rather than textspace.
+ * tahoe.h: Remove.
+ * vax.c (CALLS, PC): Define.
+ (enum opermodes, operandenum, struct modebyte): Define.
+ (vax_operandmode): Rename from operandmode. Call abort if switch
+ does not return.
+ (vax_operandname): Rename from operandname. Call abort if switch
+ does not return.
+ (vax_operandlength): Rename from operandlength. Call abort if
+ switch does not return.
+ (vax_reladdr): Rename from reladdr.
+ (vax_find_call): Rename from find_call.
+ * vax.h: Remove.
+ * Makefile.am (AUTOMAKE_OPTIONS): Set to cygnus.
+ (MY_TARGET): Remove.
+ (INCLUDES): Remove -DTARGET_$(MY_TARGET) and -DMACHINE_H=
+ \"$(MY_TARGET).h\".
+ (gprof_SOURCES): Add i386.c, alpha.c, vax.c, tahoe.c, sparc.c.
+ (gprof_DEPENDENCIES): Remove $(MY_TARGET).o.
+ (gprof_LDADD): Likewise.
+ (noinst_HEADERS): Remove alpha.h, i386.h, ns532.h, sparc.h,
+ tahoe.h, vax.h, dummy.h.
+ (EXTRA_DIST): Remove alpha.c, i386.c, ns532.c, sparc.c, tahoe.c,
+ vax.c, dummy.c.
+ ($(OBJECTS)): Don't depend upon $(MY_TARGET).h.
+ ($(MY_TARGET).o): Remove target.
+ (i386.o, alpha.o, vax.o, tahoe.o, sparc.o): New targets.
+ * configure, Makefile.in, aclocal.m4: Rebuild.
+
+
+ * core.c (core_sym_class): Treat weak symbols as text symbols.
+
+
+ * aclocal.m4: Rebuild with new libtool.
+ * Makefile.in: Rebuild with current automake.
+ * configure: Rebuild.
+
+
+ * configure.in: Change version number to 2.8.2. Call
+ AM_PROG_LIBTOOL. Remove shared library handling; now handled by
+ libtool. Add AM_CONFIG_HEADER. Change AC_PROG_INSTALL to
+ AM_PROG_INSTALL. Add AM_EXEEXT.
+ * Makefile.am (LINK): Remove.
+ (gprof_LDFLAGS): Remove
+ (gprof_DEPENDENCIES): Change libbfd.a to libbfd.la.
+ (gprof_LDADD): Likewise.
+ ($(OBJECTS)): Depend upon gconfig.h and ../bfd/config.h.
+ * gprof.h: Undefine PACKAGE and VERSION after including BFD
+ sysdep.h file, then include new gconfig.h file.
+ * gprof.c (VERSION): Don't define.
+ * acconfig.h: New file.
+ * stamp-h.in: New file.
+ * gconfig.in: New file, created by autoheader.
+ * Makefile.in, configure, aclocal.m4: Rebuild.
+
+
+ * aclocal.m4, configure, Makefile.in: Rebuild with automake 1.2.
+
+
+ * Makefile.am (INCLUDES): Add -DDEBUG.
+ * Makefile.in: Rebuild.
+
+
+ Change to use automake:
+ * Makefile.am: New file.
+ * configure.in: Run AM_INIT_AUTOMAKE, AM_MAINTAINER_MODE, and
+ AM_CYGWIN32.
+ * aclocal.m4: New file, created by aclocal.
+ * Makefile.in: Replace with file created by automake --cygnus.
+ * configure: Rebuild.
+
+
+ * gprof.c (VERSION): Define as "2.8.1".
+
+ * Branched binutils 2.8.
+
+
+ * gprof.c (main): Correct copyright message.
+
+
+ * Makefile.in (.c.o): Define TARGET_$(MY_TARGET) when compiling.
+ * gmon.h: Use bytes counts rather than sizeof in struct raw_phdr
+ and struct raw_arc.
+
+
+ * cg_arcs.c (arc_add): memset() newly alloced arc to ensure
+ all fields are initialized with 0.
+
+
+ * symtab.h (find_call): Declare.
+ * cg_arcs.c (cg_assemble): Don't declare find_call.
+ * hist.c (scale_and_align_entries): Declare.
+
+
+ * configure.in: Define BSD44_FORMAT if the target looks like a
+ BSD4.4 derived system.
+ * configure: Rebuild.
+ * Makefile.in (.c.o): Add @DEFS@.
+ * gmon_io.c (gmon_out_read): In BSD44_FORMAT code, get profrate
+ from profrate field, not version field.
+
+
+ * dummy.c (find_call): Clear ignore_direct_calls.
+
+
+ * Makefile.in (.c.o): Add -D_GNU_SOURCE. Put $(CFLAGS) at the
+ end.
+ (gprof): Put $(CFLAGS) after the other options.
+
+
+ * configure: Rebuild with autoconf 2.12.
+
+
+ * sparc.c (find_call): Align p_lowpc to avoid bus error.
+
+
+ * gprof.c (usage): Print bug report address.
+ (main): Change version printing to match current GNU standards.
+
+
+ * gmon.h: Replace #elif with #else/#endif.
+
+
+ * configure.in (i[345]86-*-*): Recognize i686 for pentium pro.
+ * configure: Regenerate.
+
+
+ * configure.in: Set and substitute HLDENV.
+ * configure: Rebuild.
+ * Makefile.in (HLDENV): New variable.
+ (gprof): Use $(HLDENV).
+
+
+ * core.c (read_function_mappings): Cast xmalloc return.
+
+
+ * gprof.c (VERSION): Define as "2.7.1".
+
+ * Released binutils 2.7.
+
+ * bb_exit_func.c: Rename from __bb_exit_func.c, so that it can be
+ stored on a System V file system.
+
+
+ * configure.in: Call AC_ISC_POSIX.
+ * configure: Rebuild.
+ * Makefile.in (gprof): Pass $(CFLAGS) during link.
+ * hertz.c: Don't include <sys/time.h>; let sysdep.h handle that.
+ If HAVE_SETITIMER is not defined, try using sysconf.
+
+
+ * Makefile.in (exec_prefix, bindir, libdir, mandir, infodir, datadir,
+ INSTALL_PROGRAM, INSTALL_DATA): Use autoconf-set values.
+ * configure.in (AC_PREREQ): autoconf 2.5 or higher.
+ (AC_PROG_INSTALL): added.
+ * configure: Rebuilt.
+
+
+ * configure.in: On alpha*-*-osf*, link against libbfd.a if not
+ using shared libraries.
+ * configure: Rebuild with autoconf 2.10.
+
+
+ * core.c (core_create_line_syms): Use xstrdup rather than strdup.
+ * source.c (source_file_lookup_path): Likewise.
+
+
+ * configure.in: Permit --enable-shared to specify a list of
+ directories.
+ * configure: Rebuild.
+
+
+ * core.c (core_create_function_syms): Move filename and func_name
+ inside ifdef where they are used.
+
+ * core.c (core_sym_class): Parenthesize && within ||.
+ * symtab.c (symtab_finalize): Correct parenthesization.
+
+ * cg_print.h (cg_print_file_ordering): Declare.
+ (cg_print_function_ordering): Declare.
+
+ * __bb_exit_func.c (__bb_exit_func): Replace bcopy with memcpy.
+ * cg_arcs.c (arc_add): Likewise.
+ * cg_print.c (cg_print_function_ordering): Likewise.
+
+
+ * gprof.c (default_excluded_list): Add "__mcount".
+
+ * gprof.c (main): Change ifdef __osf__ to __alpha__.
+
+ * gmon_io.c (gmon_out_read): If BSD44_FORMAT is defined, get the
+ profiling rate from the header.
+
+ * gmon.h (struct raw_phdr): Only include pad if both __alpha__ and
+ __osf__ are defined. Add new fields if BSD44_FORMAT is defined.
+
+ * alpha.h (MIN_INSN_SIZE): Define.
+ * core.c (MIN_INSN_SIZE): If not defined, define as 1.
+ (core_sym_class): Ignore debugging symbols.
+ (core_create_line_syms): Use MIN_INSN_SIZE when gathering line
+ information.
+
+
+ * cg_print.c (cg_print_function_ordering): Fix __GNUC__ misspelled
+ as __GNU_C__.
+ (order_and_dump_functions_by_arcs): Likewise.
+
+
+ * configure: Rebuild with autoconf 2.8.
+
+
+ * configure.in: Check for 'do not mix' from native linker before
+ trying to use -rpath.
+ * configure: Rebuild.
+
+
+ * configure.in: Set HDLFLAGS for *-*-hpux with --enable-shared.
+ * configure: Rebuild.
+
+
+ * configure.in: Don't set CC. Look for --enable-shared. Set
+ BFDLIB and HLDFLAGS and substitute them.
+ * configure: Rebuild.
+ * Makefile.in (LIBS): Use @BFDLIB@.
+ (HLDFLAGS): New variable.
+ (gprof): Use $(HLDFLAGS).
+
+
+ Support for building bfd and opcodes as shared libraries, based on
+ * Makefile.in (LIBDEPS): New variable.
+ (LIBS): Use -L../bfd -lbfd.
+ (gprof): Depend upon $(LIBDEPS) rather than $(LIBS).
+
+
+ * gprof.c (long_options): Add "--function-ordering" and
+ "--file-ordering" options.
+ (usage): Add new options to usage message.
+ (main): Handle new options.
+ * gprof.h (STYLE_FUNCTION_ORDER): Define.
+ (STYLE_FILE_ORDER): Define.
+ (function_mapping_file): Declare.
+ * cg_arcs.c (arcs, numarcs): New globals.
+ (arc_add): Put new arcs into the arc array so the function/file
+ ordering code can examine them.
+ * cg_arcs.h (struct arc): New field "has_been_placed".
+ (arcs, numarcs): Declare new globals.
+ * core.c (symbol_map, symbol_map_count): New globals.
+ (read_function_mappings): New function to read in a function
+ to object map file.
+ (core_init): Call read_function_mappings if a function mapping
+ file exists.
+ (core_create_function_syms): Handle function to object file
+ mappings.
+ * symtab.h (struct sym): New fields "mapped", "has_been_placed",
+ "nuses", "prev".
+ * cg_print.c (cmp_arc_count): New function for sorting arcs.
+ (cmp_fun_nuses): Likewise for functions.
+ (cg_print_function_ordering): New function to print a suggested
+ function ordering.
+ (cg_print_file_ordering): Likewise for ordering .o files.
+ (order_and_dump_functions_by_arcs): Helper function for function
+ and object file ordering code.
+
+
+ * core.c (core_sym_class): Ignore symbols without BSF_FUNCTION
+ set if ignore_non_function is set.
+ * gprof.h (ignore_non_functions): Declare.
+ * gprof.c (ignore_non_functions): Define.
+ (long_options): Add "ignore-non-functions".
+ (usage): Add new options.
+ (main): Recognize "-D" and "--ignore-non-functions" option.
+
+
+ * Makefile.in (.m.c): Strip out directory name from function
+ name.
+
+ * hist.c (scale_and_align_entries): Don't use DEFUN_VOID. Do
+ UNITS_TO_CODE adjustment unconditionally; compiler can optimize
+ away zero-offset case. Refer to scaled_addr, not aligned_addr.
+
+ * vax.c: Don't include vax.h here.
+
+
+ Version 2.6 released.
+
+
+ * gprof.c (main): Cast getenv return value.
+
+
+ * Makefile.in (TAGS): New target.
+
+
+ * Makefile.in (DISTSTUFF): Rename to GEN_FILES, to avoid confusion.
+ (all): Depend on $(GEN_FILES), not diststuff (which also depends
+ on info).
+
+Wed Nov 1 15:23:15 1995 Manfred Hollstein KS/EF4A 60/1F/110 #40283 <
[email protected]>
+
+ * sym_ids.c: Include <ctype.h>.
+
+
+ * Makefile.in (diststuff): Also make info.
+ (mostlyclean): Don't remove gprof.info*.
+ (maintainer-clean realclean): Also remove *.info*.
+
+
+
+ * Makefile.in: Add dependecies for $(OBJS) on header files.
+
+ * cg_print.c (print_cycle, print_members, cg_print_index): Fix new
+ style output format to make it consistent.
+ * dummy.c (find_call): Fix typo in error message.
+
+
+ * Makefile.in (maintainer-clean): New target, synonym for
+ realclean.
+
+
+ * Makefile.in (install): Don't install in $(tooldir).
+
+
+ NS32K changes from Ian Dall:
+ * configure.in: Use ns32k, not ns532.
+ * ns532.c: Include symtab.h.
+ (find_call): Renamed from findcall. Print a message.
+ * ns532.h: Remove dummy.h comments.
+
+
+ * Makefile.in (install): Remove "brokensed" hack, unnecessary now
+ that we're using autoconf.
+
+
+ * core.c (get_src_info): Cast arg 7 of bfd_find_nearest_line
+ to proper type of "unsigned int *".
+
+
+ * configure.in: Use changequote around use of [].
+
+
+ * Makefile.in (distclean, realclean): Remove config.cache and
+ config.log.
+
+
+ * Makefile.in (Makefile): Added config.status to dependency list.
+ (config.status): New target.
+ (SHELL): New definition.
+
+
+ * Makefile.in (install): Depend on "all".
+
+
+ * Makefile.in: Change all references to MY_MACHINE to MY_TARGET,
+ to match configure script.
+
+
+ * gen-c-prog.awk: Changed reference to "make-c-prog.awk" in
+ comment emitted by this script to gen-c-prog.awk.
+
+ * Makefile.in, configure.in: Converted to use autoconf.
+ * configure: New file, generated with autoconf 2.3.
+ * config/{mt-alpha, mt-dummy, mt-i386, mt-ns532, mt-sparc,
+ mt-tahoe, mt-vax}: Removed.
+
+
+ * __bb_exit_func.c: New file, from David Mosberger-Tang.
+
+
+ * All *.c: More cleanup towards GNU format.
+
+ * gmon_out.h (struct gmon_hist_hdr, struct gmon_cg_arc_record):
+ replaced sizeof (bfd_vma) by size (char*) because Ken tells me
+ that bfd_vma is only guaranteed to be at least as big as a pointer.
+
+ (GMON_Record_tag): added explicit enumeration values to ensure
+ compatibility across compilers.
+
+ * gmon_io.c (get_vma, put_vma): replaced sizeof(bfd_vma) by
+ sizeof(char*).
+
+
+ * All *.c and *.h files: Ran "indent -gnu". Cleaned up a couple
+ of constructs GNU indent couldn't handle. Block comments not yet
+ rewritten in GNU format.
+
+ * gprof.c (VERSION): Changed to 2.6, to get in sync for next
+ binutils release.
+
+
+ * symtab.c (symtab_finalize): ensure globals symbols really
+ are favored over static ones---even if their name looks less
+ preferable; this is important for HP-UX; for example, there
+ is a static label Ltext_something that aliases the global
+ symbol _start
+
+ * hist.c (hist_print): auto-scaling is now in effect for FSF-style
+ output only; also, auto-scaling is now performed based on
+ per-call, rather than total execution time, which is what it was
+ meant to be.
+
+ * gprof.h (File_Format): new type.
+
+ * gprof.c (VERSION): upped to 2.7---seems to be completely out of
+ sync with Cygnus version numbers though...
+
+ (long_options): renamed --gmon-info to --file-info, --width added,
+ renamed --old-file-format to --file-format
+ (main): dito; also added support to read prof files, but as
+ mon_out_read() is not implemented, it's #ifdef'd out for now
+
+ (usage): update to reflect new options.
+
+ * gmon_io.c: replaced "old_file_format" by more general
+ "file_format" option
+
+ * gmon.h (struct raw_phdr): fixed declaration for OSF/1.
+
+ * core.c (core_sym_class): added back check for __gnu_compiled and
+ ___gnu_compiled for the benefit of systems without
+ bfd_find_nearest_line() support
+
+ (get_src_info): now the libbfd is fixed, invoke bfd_find_nearest_line()
+ with section-relative addresses
+
+ (core_create_function_syms): get_src_info() calls are currently
+ enabled for OSF/1 only. It appears to work allright for SunOS
+ 4.1.x as well, but on SPARCs it gets painfully slow with the
+ current implementation of aout_32_find_nearest_line();
+ unfortunately, this means that static functions will not have their
+ filename printed in the call-graph function index; line-level
+ profiling should still work, but requires some patience
+
+ * cg_print.c (cg_print_index): sanitised printing of index when
+ using FSF-style output; in particular, output width is now controlled
+ via option --width and the function tries hard to keep columns
+ aligned even in the presence of (occasional) long names
+
+ * NOTES: a first shot at updating the documentation.
+
+
+ * core.c (core_create_function_syms): fixed computation of min_vma
+ and max_vma.
+
+ * *.c: removed rcsid.
+
+
+ * Lots of changes from David Mosberger-Tang:
+
+
+ * gprof.c (main): put parentheses around & within &&.
+
+ * basic_blocks.c (bb_read_rec): print warning message (once) when
+ ignoring basic-block execution counts.
+
+ * source.c (source_file_lookup_name): corrected second argument to
+ strcmp().
+
+ * hist.c (print_header): merged Fri Oct 21 18:58:02 1994 change by
+
+ * gmon_io.c (gmon_out_read): the output stule STYLE_GMON_INFO is now
+ supported both for old and new (versioned) gmon.out files. Old
+ files are identified as version 0.
+
+ * gmon.h (struct raw_arc): count field is now sizeof(long) bytes
+ long (instead of 4) because that is what OSF/1 v3.0 uses.
+
+ * core.c: minor fixes and debugging info changes.
+
+
+ * core.c (core_init): if .text cannot be found, try $CODE$ (the
+ name of the text-section under HP-UX).
+
+ * hist.c (hist_assign_samples): fixed off-by-one bug: highpc
+ points one past the last sampling bin, so hist_scale should be
+ computed as "hist_scale /= hist_num_bins", not "hist_scale /=
+ hist_num_bins - 1".
+
+ * gmon_io.c, hist.c, hist.h: renamed hist_num_samples to
+ hist_num_bins.
+
+ * configure.in: added alpha-*-*) for per-target config.
+
+ * alpha.c, alpha.h: created.
+
+ * gprof.c (default_excluded_list): <locore>, <hicore> added.
+
+ * core.c (core_create_function_syms, core_create_line_syms):
+ explicitly keep two sentinels "<locore>" and "<hicore>" that catch
+ all addresses outside the text-space. Thus, sym_lookup(&symtab,
+ addr) continues to guarantee not to return 0 on any address. It
+ also avoids incorrectly crediting the first/last symbol in the
+ text-space.
+
+ * core.c (core_create_line_syms): always create function symbols
+ first, then merge in line symbols; this is so that if parts of the
+ program were compiled without -g, function-level symbols are
+ available still.
+
+ * utils.c (print_name_only): support for print_path added.
+
+ * symtab.c (cmp_addr): also use is_func flag in comparison.
+ (symtab_finalize): return immediately when table empty; now
+ more careful about getting rid of the right duplicate symbol.
+
+ * sparc.c (find_call): many fixes---this function was rather
+ botched in binutils-2.4 already; it should work again.
+
+ * source.c (source_file_lookup_path): PATH is now strdup'ed (it is
+ not good to rely on get_src_info() to return distinct string
+ pointers).
+
+ * search_list.c (search_list_append): added cast for xmalloc().
+
+ * hist.c: added explicit initialization to some of the global
+ variables; fixed SItab (scales were off by a factor of 10).
+
+ * hist.h: include of bfd.h added.
+
+ * gprof.c, gprof.h (print_path): added.
+
+ * gprof.h (MAX): fixed.
+
+ * gmon_out.h: renamed gmon_time_hist_hdr to gmon_hist_hdr.
+
+ * gmon_io.c: added some casts to (long) so we can always print as %lx
+
+ * core.c (core_get_text_space): fixed to make it work.
+
+ * cg_print.c (cg_print_index): added support for print_path option.
+
+ * cg_dfn.h (cg_dfn): wrap prototype in PARAMS().
+
+ * call_graph.c, gmon_io.c, hist.c: avoid taking address of array
+ as some compilers complain (e.g., DEC's OSF/1 compiler)
+
+ * basic_blocks.c, gmon_io.c, hist.c, source.c, sym_ids.c,
+ symtab.c: calls to memset() had 2nd and 3rd args reversed.
+
+
+ * gprof.c: added "_mcount" to default_excluded_list.
+ (main): if output_style==0 and there is either a histogram or a
+ call-graph, always generate flat and call-graph, no matter what
+ line_granularity is set to.
+
+ * source.c (source_file_lookup_name): if searching for sf->name
+ fails, try again with filename obtained after stripping off any
+ partial path from sf->name.
+
+ * gprof.h (SRCDEBUG): added.
+
+ * search_list.c (search_list_append): directories were added in wrong
+ order.
+
+ * reimplemented selection mechanism from ground up; it is now possible
+ to accurately control what gets included/excluded in each of the
+ output styles; a "symbol-specification" (spec) is the basic means
+ to select a set of symbols; a spec has the syntax:
+
+ spec == (FILENAME:(FUNCNAME|LINE_NUM) | NAME).
+ arc == spec/spec.
+
+ any of the terminal symbols can be empty, in which case they
+ match anything (wildcards). NAME is interpreted as a FILENAME
+ if it contains a dot (e.g., foo.c), as LINE_NUM if it starts
+ with a digit, and as FUNCNAME otherwise.
+
+ For example, to get a call-graph display that ignores arcs
+ from foo() to bar(), you'd say "--no-graph=foo/bar"; to
+ show only arcs into bar() (no matter what the caller),
+ you'd say "--graph=/bar"; and to get a call-graph without
+ any arc info, you'd say "--graph=/"; similarly, to
+ get a flat profile without mcount, you'd say "--no-flat=mcount"
+ and to get a flat profile that shows includes all functions
+ you'd say "--flat=""" (i.e., an empty spec)
+
+ * hist.c (hist_print): top_time wasn't initialized to 0.0.
+
+
+ * gmon_out.h: all headers now declared in terms of characters
+ to avoid getting into trouble with different compilers introducing
+ different amount of padding; the code already accessed the fields
+ through bfd functions, so that didn't have to change.
+
+ * hist.c (hist_read_rec, hist_write_rec): added support for
+ collection pc histograms measuring quantities other than time;
+ the histogram header now includes a field that specifies the
+ dimension of the quantity measured by the histogram bins
+ (normally, this is "seconds", but other meaningful dimensions
+ include such things as "I-cache misses", "instruction issue stalls"
+ etc.); there is also a field to specify a one-character
+ abbreviation for the dimension; in the case of time, this would
+ be 's'; in most other cases it probably would be '1' (not a physical
+ dimension).
+
+
+ * gprof.c, gmon_io.[ch]: BSD_COMPATIBLE is gone and new_file_version
+ has become old_file_version; gmon_io.c now always supports old-style
+ gmon.out files; it first tries to read gmon.out as a new version
+ file, if that fails, it tries to read it in the old format;
+ although not very likely, it is possible for gprof to mistake an
+ old-style file as a new one (the first 4 bytes would have to
+ be "gmon"---including the trailing '\0'); in that case, it is
+ necessary to specify --old-file-version
+
+ * gprof.h: removed dependency on SYSV; the code now always uses
+ strrchr(), memset(), and memcpy() and does not include either
+ of string.h or strings.h; this should make gprof compile on
+ any (Unix) system without configuration (per suggestion of
+
+ * gprof.c (usage): fixed location of --new-file-format option.
+
+ * cg_arcs.c (propagate_flags): fixed typo in declaration.
+
+ * flat_bl.m: removed formfeed at end of file; the form-feed
+ is now printed cg_print.c only when necessary.
+
+ * major rewrite of gprof---too many changes to mention all of
+ them. new features:
+
+ + -l now requests profiling at the line level (as opposed
+ to function level); in this mode, gprof creates a "symbol"
+ (aka name-list entry) for each line of source code, instead
+ of one per function)
+
+ + support for a new gmon.out file format; the new format
+ consists of a header with a magic and a version number,
+ followed by a sequence of profile data; profile data
+ can any of: (a) PC histogram, (b) call-graph arcs, or
+ (c) basic-block execution counts; the version number makes
+ it possible to extend gmon.out in a backwards compatible
+ fashion
+
+ + support for tcov style annotated output: if the gmon.out file
+ contains basic-block execution counts, the user can request
+ the generation of annotated source files, much like Sun's
+ tcov used to do
+
+ + long options
+
+ + new scheme to suppress symbols that aren't function names
+ (e.g., avoids mistaking a goto label as a function)
+
+ + reorganized source code to make it more managable; as a
+ side effect, gprof now compiles cleanly with "gcc -Wall"
+
+
+ * gprof.c (funcsymbol): bfd_find_nearest_line() is now used as a
+ final cross-check to determine whether a static symbol should be
+ considered as a function-name.
+
+
+ * gmon_io.c (gmon_out_read): recognize "-" as the filename for
+ stdin; this is useful if you wanna keep gmon.out files compressed;
+ this way you can "gzcat" the compressed file into gprof.
+
+ * gprof.c: flag_min_count now initialized with 1 instead of 0.
+
+ * basic_blocks.c (bb_annotate_source): added support for creating
+ .tcov files when option flag_annotate_make_files is TRUE.
+ (annotate_with_count): all counts less than the minimum count
+ specified by -m are now annotated with hash-marks.
+
+ * gprof.c (main): -A is now followed by a string of option chars.
+
+ * basic_blocks.c (annotate_with_count): replaced b->count with
+ cnt.
+
+ * source.c: flag_annotate_source replaced by source_lock_map.
+
+ * source.h: source_lock_map added.
+
+ * gprof.c (main): new command-line syntax: -S simply specifies
+ which source-files user is interested in; -A requests annotated
+ source files and -AA requests that all lines in a source file
+ are annotated.
+
+
+ * basic_blocks.c (PATH_MAX): if undefined, define as 1024.
+
+ * sparc.c, i386.c, tahoe.c, vax.c: added include of "time_hist.h"
+ so s_lowpc etc. get declared.
+
+ * arcs.h (doarcs): created.
+
+ * arcs.c: reordered static functions such that they get defined
+ before use.
+
+ * gprof.c (main): added options:
+ -A: request annotation of all source lines (with -S)
+ -m: minimum execution count (with default basic-block display)
+ -N: force new file format (only if BSD_COMPATIBLE is defined)
+ -S: annotate source file
+ -t: set table length (with -S)
+
+ * Makefile (OBJS): added basic_blocks.o call_graph.o gmon_io.o
+ source.o time_hist.o
+
+
+ * gprof.c (asgnsamples): computation of "pcl" and "pch" depended
+ on the fact being able to store a long in a double without loss of
+ precision; this does not hold on machines with 64 bit longs and 64
+ bit doubles.
+
+
+ * printgprof.c (flatprofheader): Always set totime to 1.0 if not
+ greater than 0.0. Suggested by Harold Assink
+
+
+ * printgprof.c (printprof): Use free, not cfree.
+ (printgprof, printindex): Ditto.
+
+
+ * gprof.h (kfromlist, ktolist, flist, Flist, elist, Elist): Make
+ decls extern to keep native HP compiler quiet.
+
+
+ * gprof.c (funcsymbol): Ignore ___gnu_compiled as well as
+ __gnu_compiled, for the benefit of systems which add a leading
+ underscore.
+
+
+ * configure.in: Change i386-*-* to i[345]86-*-*.
+
+
+ * ns532.c, ns532.h: New Files. ns532 support.
+
+ * config/mt-ns532: New File. ns532 support.
+
+ * gprof.c: user register int i instead of defaulting the int.
+ Allows compilation with -Dregister= for debugging.
+
+ * configure.in: Add ns532 support.
+
* Makefile.in (gprof): Depend on $(LIBS).
- * Makefile.in (MY_MACHINE): Renamed from MACHINE to avoid losing
- makes (osf1) in which the value of MACHINE can not be changed.
- * config/*.mt: Changed appropriately.
+ * Makefile.in (MY_MACHINE): Renamed from MACHINE to avoid losing
+ makes (osf1) in which the value of MACHINE can not be changed.
+ * config/*.mt: Changed appropriately.
* Makefile.in: Undo 15 June change.
-
+
* gmon.h, gprof.h: structs of chars used to hold external
representations.
* gprof.c (getpfile, openpfile, readsamples): Swap data in using
- * gprof.1: updated SYNOPSIS to match actual behavior.
+ * gprof.1: updated SYNOPSIS to match actual behavior.