X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=sim%2Fcommon%2Fsim-profile.h;h=938ad7140fcffdbe3148758083360cff83a93331;hb=51a0e41ca956e6bdf072aea6a7e15c4e7269c2d0;hp=69a774fd02e341159b66a632e4c37d6a09a342c4;hpb=4744ac1bb0d2f2294c7762577262fdcafb67883b;p=platform%2Fupstream%2Fbinutils.git diff --git a/sim/common/sim-profile.h b/sim/common/sim-profile.h index 69a774f..938ad71 100644 --- a/sim/common/sim-profile.h +++ b/sim/common/sim-profile.h @@ -1,5 +1,5 @@ /* Profile header for simulators using common framework. - Copyright (C) 1996, 1997, 1998, 2007 Free Software Foundation, Inc. + Copyright (C) 1996-2014 Free Software Foundation, Inc. Contributed by Cygnus Support. This file is part of GDB, the GNU debugger. @@ -289,8 +289,24 @@ do { \ #define PROFILE_COUNT_CORE(cpu, addr, size, map) #endif /* ! core */ +#if WITH_PROFILE_MODEL_P +#define PROFILE_BRANCH_TAKEN(cpu) \ +do { \ + if (PROFILE_MODEL_P (cpu)) \ + ++ PROFILE_MODEL_TAKEN_COUNT (CPU_PROFILE_DATA (cpu)); \ +} while (0) +#define PROFILE_BRANCH_UNTAKEN(cpu) \ +do { \ + if (PROFILE_MODEL_P (cpu)) \ + ++ PROFILE_MODEL_UNTAKEN_COUNT (CPU_PROFILE_DATA (cpu)); \ +} while (0) +#else +#define PROFILE_BRANCH_TAKEN(cpu) +#define PROFILE_BRANCH_UNTAKEN(cpu) +#endif /* ! model */ + /* Misc. utilities. */ -extern void sim_profile_print_bar (SIM_DESC, unsigned int, unsigned int, unsigned int); +extern void sim_profile_print_bar (SIM_DESC, sim_cpu *, unsigned int, unsigned int, unsigned int); #endif /* SIM_PROFILE_H */