Hi Prathap,
I have already implemented pseudo instructions for the ROI. The code is the
following:
//
// Mark beginning of ROI in simulated programs
//
void
roibegin(ThreadContext *tc)
{
DPRINTF(PseudoInst, "PseudoInst::roibegin()\n");
resetstats(tc, 0, 0);
}
//
// Mark end of ROI in simulated programs
//
void roiend(ThreadContext *tc)
{
dumpresetstats(tc, 0, 0);
exitSimLoop("roiend");
}
As I've said I would like to have a global variable that I can change in
these functions and have it be available in src/mem/cache/base.cc. I'm not
sure I understand the second part of your answer.
Cheers,
Victor
On Thu, 24 Oct 2019 at 00:58, Prathap Kolakkampadath <[email protected]>
wrote:
> Why don't you use existing m5_ pseudo instructions around ROI of the
> benchmark. Note to compile your benchmark with the m5 library.
>
> If you are looking for more data, you may also add them in respective
> mem/cache file and compile the gem.
>
> Regards,
> Prathap
>
> On Wed, Oct 23, 2019 at 4:41 PM Victor Kariofillis <
> [email protected]> wrote:
>
>> Hi,
>>
>> I have implemented pseudo instructions for recognizing the Region of
>> Interest of the benchmarks that I am running. What I want to do is to start
>> printing some information (cache data) to a file as soon as the ROI begins.
>> This printing will be done through the base.cc file in mem/cache. I tried
>> having a boolean "roi" variable in system.hh, so that it will globally
>> available, but I'm getting compiler errors of multiple definitions. How can
>> I have knowledge of whether the execution of the program is in the ROI in
>> the base.cc file?
>>
>> I have another question also. Is it possible to delay this printing until
>> the ROI ends? The problem I have with that is that when the "roiend" pseudo
>> instruction is encountered, I dump the stats and exit the simulation. Is it
>> possible to print these data from base.cc just as it is done with regstats
>> before exiting the simulation?
>>
>> Thanks,
>> Victor
>> _______________________________________________
>> gem5-users mailing list
>> [email protected]
>> http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users
>
> _______________________________________________
> gem5-users mailing list
> [email protected]
> http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users
_______________________________________________
gem5-users mailing list
[email protected]
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users