Hi,

I fond the issue and its because the stats file was reopened every time
configuration is changed !!
I have attached a small patch that should fix this issue. I don't have a
setup that call's ptlcall_capture_stats() function so can you please test
this patch and confirm that this fixes the issue.

Thanks,
Avadh

On Sat, Feb 12, 2011 at 1:37 PM, Timothy Hayes <[email protected]> wrote:

> Hi,
>
> I'm trying to take a statistics snapshot before and after a particular
> kernel but it is giving me problems.
>
> My code looks like this:
> ---------------------------------------
> ptlcall_capture_stats("pre");
> // call to function
> ptlcall_capture_stats("post");
> ---------------------------------------
>
> My console shows me the following output:
> ---------------------------------------
>  Completed       2630000 cycles,        858781 commits:    459604 Hz,
>  114181 insns/sec: rip ffffffff813594c1ptlcall_mmio_write: calltype 2
> at rip 4196121 (inside_ptlsim = 1 )
> PTLCALL type PTLCALL_ENQUEUE
> MARSSx86::Command received : -snapshot-now pre
> ptlcall_mmio_write: calltype 2 at rip 4196121 (inside_ptlsim = 1 )
> PTLCALL type PTLCALL_ENQUEUE
> MARSSx86::Command received : -snapshot-now post
>  Completed       5825000 cycles,       1934160 commits:    428036 Hz,
>   119043 insns/sec: rip ffffffff81100b35ptlcall_mmio_write: calltype
> 2 at rip 4196905 (inside_ptlsim = 1 )
> PTLCALL type PTLCALL_ENQUEUE
> MARSSx86::Command received : -kill
> ---------------------------------------
>
> The logfile has the following too:
> ---------------------------------------
> *snipped*
> Start logging at level 0 in cycle 2689123
> Making stats snapshot uuid 0 named pre at cycle 2690000
> *snipped*
> Start logging at level 0 in cycle 2691898
> Completed       2692000 cycles,        890788 commits:    303511 Hz,
>  156685 insns/sec: rip 000000000040cab6
> Making stats snapshot uuid 0 named post at cycle 2692000
> *snipped*
> ---------------------------------------
>
> When I call ptlstats:
> ---------------------------------------
> ../ptlstats -snapshot pre ./kernel.stats
> ptlstats: Cannot get snapshot 'pre'
> ./ptlstats -snapshot post ./kernel.stats
> ptlstats: Cannot get snapshot 'post'
> ---------------------------------------
>
> There exists 3 snapshots in the stats file, but I don't believe they
> are what I'm looking for:
> ---------------------------------------
> 1.
>  snapshot_name = "user"; { (zero) }
>  snapshot_uuid = 0; { (zero) }
> 2.
>  snapshot_name = "kernel"; { (zero) }
>  snapshot_uuid = 1;
> 3.
>  snapshot_name = "global"; { (zero) }
>  snapshot_uuid = 2;
> ---------------------------------------
>
> I call my program as the website suggests
> ---------------------------------------
> ./start_sim; ./kernel ; ./kill_sim;
> ---------------------------------------
>
> I'm using the latest MARSS 'master' branch in the GIT repository.
>
> I'd really appreciate if you could explain what's going on. Is this an
> error on my part or a bug with MARSS? I want to do this so I can look
> at the statistics of this function in isolation.
>
> Kind regards
> Tim
>
> _______________________________________________
> http://www.marss86.org
> Marss86-Devel mailing list
> [email protected]
> https://www.cs.binghamton.edu/mailman/listinfo/marss86-devel
>

Attachment: stats_reopen_fix.patch
Description: Binary data

_______________________________________________
http://www.marss86.org
Marss86-Devel mailing list
[email protected]
https://www.cs.binghamton.edu/mailman/listinfo/marss86-devel

Reply via email to