On Wed, May 18, 2016 at 08:45:35PM +0200, Lluís Vilanova wrote: > Richard Henderson writes: > > > On 05/18/2016 03:47 AM, Lluís Vilanova wrote: > >> Signed-off-by: Lluís Vilanova <vilan...@ac.upc.edu> > >> --- > >> include/exec/cpu_ldst_template.h | 25 ++++++++++++++++ > >> include/exec/cpu_ldst_useronly_template.h | 22 ++++++++++++++ > >> tcg/tcg-op.c | 32 ++++++++++++++++++-- > >> trace-events | 22 ++++++++++++++ > >> trace/mem-internal.h | 46 > >> +++++++++++++++++++++++++++++ > >> trace/mem.h | 34 +++++++++++++++++++++ > >> 6 files changed, 177 insertions(+), 4 deletions(-) > >> create mode 100644 trace/mem-internal.h > >> create mode 100644 trace/mem.h > >> > >> diff --git a/include/exec/cpu_ldst_template.h > >> b/include/exec/cpu_ldst_template.h > >> index 3091c00..eaf69a1 100644 > >> --- a/include/exec/cpu_ldst_template.h > >> +++ b/include/exec/cpu_ldst_template.h > >> @@ -23,6 +23,13 @@ > >> * You should have received a copy of the GNU Lesser General Public > >> * License along with this library; if not, see > >> <http://www.gnu.org/licenses/>. > >> */ > >> + > >> +#if !defined(SOFTMMU_CODE_ACCESS) > >> +#include "trace.h" > >> +#endif > >> + > >> +#include "trace/mem.h" > >> + > >> #if DATA_SIZE == 8 > >> #define SUFFIX q > >> #define USUFFIX q > >> @@ -80,6 +87,12 @@ glue(glue(glue(cpu_ld, USUFFIX), MEMSUFFIX), > >> _ra)(CPUArchState *env, > >> int mmu_idx; > >> TCGMemOpIdx oi; > >> > >> +#if !defined(SOFTMMU_CODE_ACCESS) > >> + trace_guest_mem_before_exec( > >> + ENV_GET_CPU(env), ptr, > >> + trace_mem_build_info(SHIFT, false, MO_TE, false)); > >> +#endif > > > I don't understand what this event is supposed to be tracing. > > There's no documentation at all, even in the commit log. > > I'm not sure if you mean for this file or the "guest_mem_before" event on the > whole patch. The event description is in the "trace-events" file. Although > terse, I think it's pretty explanatory, but I can expand it if it's not clear.
Good idea, please do that in the commit description for this patch. Thanks, Stefan
signature.asc
Description: PGP signature