diff options
author | Mike Frysinger <vapier@gentoo.org> | 2016-01-04 22:24:03 -0500 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2016-01-04 22:24:03 -0500 |
commit | bc273e17510c7680bcffee75858d374aa93f7e4b (patch) | |
tree | 70fafc5ebb2b4104b5d0169578f8e24f4a497ba4 /sim/bfin/sim-main.h | |
parent | ac8eefeb243ad326946c3b2b78ba5d1367fe0f99 (diff) | |
download | gdb-bc273e17510c7680bcffee75858d374aa93f7e4b.zip gdb-bc273e17510c7680bcffee75858d374aa93f7e4b.tar.gz gdb-bc273e17510c7680bcffee75858d374aa93f7e4b.tar.bz2 |
sim: unify min/max macros
Import defines from gdb/defs.h to the sim core so we can delete the
various copies that already exist.
Diffstat (limited to 'sim/bfin/sim-main.h')
-rw-r--r-- | sim/bfin/sim-main.h | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/sim/bfin/sim-main.h b/sim/bfin/sim-main.h index 8804a71..51fb87e 100644 --- a/sim/bfin/sim-main.h +++ b/sim/bfin/sim-main.h @@ -56,13 +56,9 @@ struct sim_state { #include "sim-options.h" #include "dv-bfin_trace.h" -#undef MAX -#undef MIN #undef CLAMP #undef ALIGN -#define MAX(a, b) ((a) > (b) ? (a) : (b)) -#define MIN(a, b) ((a) < (b) ? (a) : (b)) -#define CLAMP(a, b, c) MIN (MAX (a, b), c) +#define CLAMP(a, b, c) min (max (a, b), c) #define ALIGN(addr, size) (((addr) + ((size)-1)) & ~((size)-1)) /* TODO: Move all this trace logic to the common code. */ |