summaryrefslogtreecommitdiffstats
path: root/usr.bin/gprof/gprof.h
diff options
context:
space:
mode:
authorjdp <jdp@FreeBSD.org>1998-09-07 23:32:00 +0000
committerjdp <jdp@FreeBSD.org>1998-09-07 23:32:00 +0000
commit5b11e2a2f4237604a3b79eae0bd8f58cd296fca5 (patch)
tree3406d2b2dff7ee0b157826eb5429d6e93491b1a8 /usr.bin/gprof/gprof.h
parent06aec80098f1b2500b86064347079545f0d01eaf (diff)
downloadFreeBSD-src-5b11e2a2f4237604a3b79eae0bd8f58cd296fca5.zip
FreeBSD-src-5b11e2a2f4237604a3b79eae0bd8f58cd296fca5.tar.gz
Make profiling work for ELF. gprof now autodetects the format of
the executable file, so it will work for both a.out and ELF format files. I have split the object format specific code into separate source files. It's cleaner than it was before, but it's still pretty crufty. Don't cheat on your make world for this update. A lot of things have to be rebuilt for it to work, including the compiler and all of the profiled libraries.
Diffstat (limited to 'usr.bin/gprof/gprof.h')
-rw-r--r--usr.bin/gprof/gprof.h16
1 files changed, 6 insertions, 10 deletions
diff --git a/usr.bin/gprof/gprof.h b/usr.bin/gprof/gprof.h
index 750fd2e..ce164d5 100644
--- a/usr.bin/gprof/gprof.h
+++ b/usr.bin/gprof/gprof.h
@@ -37,7 +37,6 @@
#include <sys/stat.h>
#include <sys/gmon.h>
-#include <a.out.h>
#include <stdio.h>
#include <stdlib.h>
@@ -121,7 +120,7 @@ typedef struct arcstruct arctype;
* its address, the number of calls and compute its share of cpu time.
*/
struct nl {
- char *name; /* the name */
+ const char *name; /* the name */
unsigned long value; /* the pc entry point */
unsigned long svalue; /* entry point aligned to histograms */
double time; /* ticks in this routine */
@@ -217,9 +216,6 @@ double totime; /* total time for all routines */
double printtime; /* total of time being printed */
double scale; /* scale factor converting samples to pc
values: each sample covers scale bytes */
-char *strtab; /* string table in core */
-long ssiz; /* size of the string table */
-struct exec xbuf; /* exec header of a.out */
unsigned char *textspace; /* text space of a.out in core */
int cyclethreshold; /* with -C, minimum cycle size to ignore */
@@ -237,6 +233,7 @@ bool fflag; /* specific functions requested */
bool Fflag; /* functions requested with time */
bool kflag; /* arcs to be deleted */
bool sflag; /* sum multiple gmon.out files */
+bool uflag; /* suppress symbols hidden from C */
bool zflag; /* zero time/called functions, too */
/*
@@ -259,6 +256,7 @@ struct stringlist *ktolist;
/*
addarc();
*/
+int aout_getnfile(const char *, char ***);
int arccmp();
arctype *arclookup();
/*
@@ -280,17 +278,15 @@ bool dfn_numbered();
nltype **doarcs();
/*
done();
+*/
+int elf_getnfile(const char *, char ***);
+/*
findcalls();
flatprofheader();
flatprofline();
*/
-bool funcsymbol();
/*
- getnfile();
getpfile();
- getstrtab();
- getsymtab();
- gettextspace();
gprofheader();
gprofline();
main();
OpenPOWER on IntegriCloud