Hi Kon, The PARSEC patch file modifies the parsec ROI library so when you run an application like blackscholes, at the beginning of the ROI and at the end of the ROI the stats will be dumped/reset *in the execution of the benchmark!*
You are adding in extra dump/reset stats by calling `m5 dumpresetstats` manually in your rcs file. You should remove these from your rcs file. You should see the following output in the stats.txt with you current rcs file: Kernel boot through source env.sh ----- Beginning of blackscholes to the beginning of the ROI ----- The blackscholes ROI ----- The end of blackscholes ROI until blackscholes exits. ----- The beginning of canneal until the start of canneal's ROI ---- Canneal's ROI ----- The cleanup phase of canneal. ---- Some stats for sleep I hope this answers your question. Jason On Mon, Aug 6, 2018 at 7:33 PM kon.bick <[email protected]> wrote: > Dear all, > > > > I followed the guide posted over here > https://github.com/arm-university/arm-gem5-rsk/wiki step by step. > > *However, I encounter some errors with the m5ops like dumpstats and > resestats.* > > In the PARSEC patch file provided by the ARM people (qemu-patch.diff), > they implemented some m5ops in assembly like this: > > > > +static __attribute__((optimize("O0"))) void m5_dump_stats(uint64_t x, > uint64_t y) > > +{ > > + register uint64_t x0 asm("x0") = x; > > + register uint64_t x1 asm("x1") = y; > > + asm volatile (".inst 0xff410110;":: "r" (x0), "r" (x1)); > > +}; > > > > However, running several simulations, with varying num-cores (1 or 2, > mainly), the *problem that occurs is that sometimes dumpstats seems to be > executed twice.* > > > > 1) At first I thought the problem is related to running PARSEC on > dual core with two threads and the thread management is not perfect in gem5 > so dumpstats is called twice. > > è It turns out that the problem also occurs on single core when running > PARSEC single-threaded > > 2) My second thought was that the misbehavior had to do with the > assembly implementation and I tried executing m5ops only in the .rcS file > (like using “m5 dumpstats” etc) running a “m5op-free version” of PARSEC > > à Unfortunately, sometimes even the commands executed from the rcS file > cause a duplicated execution of dumpstats > > > > Now I am out of ideas what could be the problem and what would be a good > way of debugging it. Could it be related to compiler optimization settings > (in other words, should I try -O0?) > > > > Some additional information: > > > > *This is my run command:* > > ./build/ARM/gem5.opt -d fs_results/20180806_clean/custom_simsmall_1 > configs/example/arm/starter_fs.py --cpu=hpi --num-cores=1 > --disk-image=/home/kon/aarch-system-20180409/disks/parsec_qcompiled_64_clean.img > --dtb=/home/kon/aarch-system-20180409/binaries/armv8_gem5_v1_1cpu.dtb > --script=/home/kon/arm-gem5-rsk/parsec_rcs/custom.rcS > > > > *This is my custom.rcS:* > > #!/bin/bash > > > > PARSEC_DIR="/home/root/parsec-3.0" > > cd $PARSEC_DIR > > pwd > > source ./env.sh > > m5 dumpstats > > parsecmgmt -a run -p blackscholes -c gcc-hooks -i simmedium -n 1 > > m5 dumpresetstats > > parsecmgmt -a run -p canneal -c gcc-hooks -i simsmall -n 1 > > m5 dumpstats > > sleep 10 > > m5 exit > > > > I expected the stats.txt to have 4 chapters: > > First, from booting the system until sourcing env.sh > > Second, the execution of blackscholes > > Third, the execution of canneal > > Fourth, sleep to exit > > > > However, stats.txt indicates that shortly after the first dumpstats > command (at sim_seconds: 1.97) another one is executed (at sim_seconds: > 2.02). This duplicated execution is observed at later stages as well. > > > > Did anyone else experience this problem? > > > > On a side note: m5 resestats does not reset all counters? For example I > noticed that sim_insts is not reset while sim_seconds is. > > > > Best regards > > Kon > > > > > _______________________________________________ > 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
