From 118c70fed9abb13a1decb1f77a6f0af7db9bbafd Mon Sep 17 00:00:00 2001 From: bde Date: Thu, 21 Feb 2002 07:12:57 +0000 Subject: Moved the definition of the machine-independent macro UNITS_TO_CODE from machine-dependent headers to the one non-header here it is used so that it is easier to fix. This macro just divides the machine-dependent offset OFFSET_OF_CODE by the machine-independent scale factor sizeof(UNIT), as required for bug for bug compatibility with the scaling of pc's in gprof.c. UNIT is the type of a profiling counter, and its size has nothing to do with the correct scale factor except both are usually 2. --- usr.bin/gprof/mips.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'usr.bin/gprof/mips.h') diff --git a/usr.bin/gprof/mips.h b/usr.bin/gprof/mips.h index cd67a43..7a48afa 100644 --- a/usr.bin/gprof/mips.h +++ b/usr.bin/gprof/mips.h @@ -37,6 +37,7 @@ * @(#)mips.h 8.1 (Berkeley) 6/6/93 * * From: @(#)sparc.h 5.1 (Berkeley) 7/8/92 + * $FreeBSD$ */ /* @@ -44,7 +45,6 @@ * (see asgnsamples for use and explanation.) */ #define OFFSET_OF_CODE 0 -#define UNITS_TO_CODE (OFFSET_OF_CODE / sizeof(UNIT)) enum opermodes { dummy }; typedef enum opermodes operandenum; -- cgit v1.1