Hello:
The easiest method that I would go about doing this would be to do this
inside Opal. All dynamic instructions have a m_priv flag (which can be
queried using getPrivilegeMode()), and in addition the priviledge mode bit
is set in the pstate, which is part of the fetch abstract_pc_t object. An
example of reading the priviledge bit is as follows:
(m_fetch_at->pstate >> 2) & 0x1;
Which will return 1 if the PC is currently fetching priviledged
instructions, and 0 if in user mode.
Idle cycles can be calculated by storing some info when the front-end
stalls and resumes fetch, if that is what you meant by idle cycles.
Luke
On Thu, 3 Mar 2005, Weihang Jiang wrote:
> Hi,
> I want to break down execution cycles into different categories:
> user cycles, kernel cycles, privilage instructions cycles and idle
> cycles. (as in Memory System Characterization of Commerical
> Workloads).
>
> I found something from ruby0.dump-stat :
> Resource Usage
> --------------
> page_size: 4096
> user_time: 1334
> system_time: 29
>
> Is it the right place to look at?
>
> TIA
>
> --
> Weihang Jiang
> _______________________________________________
> Gems-users mailing list
> Gems-users@xxxxxxxxxxx
> https://lists.cs.wisc.edu/mailman/listinfo/gems-users
>
|