poke-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Jitter v0.9.246] VM instruction profiling (by instrumentation counters)


From: Luca Saiu
Subject: [Jitter v0.9.246] VM instruction profiling (by instrumentation counters)
Date: Thu, 24 Dec 2020 07:26:52 +0100
User-agent: Gnus (Gnus v5.13), GNU Emacs 27.0.50, x86_64-pc-linux-gnu

Hello José.

VM instrumentation profiling is now in Jitter, tag v0.9.246, master.

You may want to check structured-main.c and vm-main.c as examples; if
order to enable the feature you need to define the macro
JITTER_INSTRUMENT_FOR_PROFILING when compiling Jitter and your VM.

Notice that profiles are recorded separately within each VM state: if
you want to merge profiles from multiple states, as I think you need to,
you may need this solution:

  pvm_profile p = pvm_profile_make ();
  pvm_profile_merge_from (p, state1);
  pvm_profile_merge_from (p, state2);
  ...
  pvm_profile_merge_from (p, stateN);

The profile to print is p.  Then, at the end,

  pvm_profile_destroy (p);

(There is no need to destroy the profiles within each state: those are
destroyed when each state is destroyed.)

The feature could be improved, but I find it already useful as it stands.

Regards,

-- 
Luca Saiu
* My personal web site:  http://ageinghacker.net
* GNU epsilon:           http://www.gnu.org/software/epsilon
* Jitter:                http://ageinghacker.net/projects/jitter

I support everyone's freedom of mocking any opinion or belief, no
matter how deeply held, with open disrespect and the same unrelented
enthusiasm of a toddler who has just learned the word "poo".

Attachment: signature.asc
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]