[gem5-users] Re: Not able to access webpage to run_npb.py

2022-02-22 Thread Bobby Bruce via gem5-users
Hey David,

There's no problem with gem5 or the script here. The issue is with your
system. As the error suggests, you need to change the value in
`/proc/sys/kenel/perf_event_paranoid`  to 1.

--
Dr. Bobby R. Bruce
Room 3050,
Kemper Hall, UC Davis
Davis,
CA, 95616

web: https://www.bobbybruce.net


On Tue, Feb 22, 2022 at 1:07 PM David Fong  wrote:

> Hi Bobby,
>
>
>
> After downloading the latest (V21.2.1) and rebuilding gem5 I’m now getting
> a core dump.
>
>
>
> Here’s the message from cmd-line up to before core dump.
>
>
>
> ./build/X86/gem5.opt configs/example/x86-npb-benchmarks.py --benchmark ep
> --size A
>
> gem5 Simulator System.  http://gem5.org
>
> gem5 is copyrighted software; use the --copyright option for details.
>
>
>
> gem5 version 21.2.1.0
>
> gem5 compiled Feb 22 2022 12:28:52
>
> gem5 started Feb 22 2022 12:54:21
>
> gem5 executing on sundial.chronostech.com, pid 27366
>
> command line: ./build/X86/gem5.opt configs/example/x86-npb-benchmarks.py
> --benchmark ep --size A
>
>
>
> Resource 'x86-linux-kernel-4.19.83' was not found locally. Downloading to
> '/home/dfong/.cache/gem5/x86-linux-kernel-4.19.83'...
>
> Finished downloading resource 'x86-linux-kernel-4.19.83'.
>
> Resource 'x86-npb' was not found locally. Downloading to
> '/home/dfong/.cache/gem5/x86-npb.gz'...
>
> Finished downloading resource 'x86-npb'.
>
> Decompressing resource 'x86-npb' ('/home/dfong/.cache/gem5/x86-npb.gz')...
>
> Finished decompressing resource 'x86-npb'.
>
> Global frequency set at 1 ticks per second
>
> warn: No dot file generated. Please install pydot to generate the dot file
> and pdf.
>
> build/X86/mem/mem_interface.cc:793: warn: DRAM device capacity (16384
> Mbytes) does not match the address range assigned (2048 Mbytes)
>
> build/X86/mem/mem_interface.cc:793: warn: DRAM device capacity (16384
> Mbytes) does not match the address range assigned (2048 Mbytes)
>
> build/X86/sim/kernel_workload.cc:46: info: kernel located at:
> /home/dfong/.cache/gem5/x86-linux-kernel-4.19.83
>
> build/X86/base/statistics.hh:280: warn: One of the stats is a legacy stat.
> Legacy stat is a stat that does not belong to any statistics::Group. Legacy
> stat is deprecated.
>
>   0: system.pc.south_bridge.cmos.rtc: Real-time clock set to Sun Jan
> 1 00:00:00 2012
>
> build/X86/dev/serial/terminal.cc:170: warn: Sockets disabled, not
> accepting terminal connections
>
> build/X86/dev/intel_8254_timer.cc:125: warn: Reading current count from
> inactive timer.
>
> build/X86/base/remote_gdb.cc:381: warn: Sockets disabled, not accepting
> gdb connections
>
> Running the simulation
>
> Using KVM cpu
>
> build/X86/cpu/kvm/base.cc:148: info: KVM: Coalesced MMIO disabled by
> config.
>
> build/X86/arch/x86/cpuid.cc:181: warn: x86 cpuid family 0x:
> unimplemented function 2
>
> build/X86/arch/x86/cpuid.cc:181: warn: x86 cpuid family 0x:
> unimplemented function 3
>
> build/X86/arch/x86/cpuid.cc:181: warn: x86 cpuid family 0x:
> unimplemented function 4
>
> build/X86/arch/x86/cpuid.cc:181: warn: x86 cpuid family 0x:
> unimplemented function 5
>
> build/X86/arch/x86/cpuid.cc:181: warn: x86 cpuid family 0x:
> unimplemented function 6
>
> build/X86/arch/x86/cpuid.cc:181: warn: x86 cpuid family 0x:
> unimplemented function 8
>
> build/X86/cpu/kvm/base.cc:148: info: KVM: Coalesced MMIO disabled by
> config.
>
> build/X86/arch/x86/cpuid.cc:181: warn: x86 cpuid family 0x:
> unimplemented function 2
>
> build/X86/arch/x86/cpuid.cc:181: warn: x86 cpuid family 0x:
> unimplemented function 3
>
> build/X86/arch/x86/cpuid.cc:181: warn: x86 cpuid family 0x:
> unimplemented function 4
>
> build/X86/arch/x86/cpuid.cc:181: warn: x86 cpuid family 0x:
> unimplemented function 5
>
> build/X86/arch/x86/cpuid.cc:181: warn: x86 cpuid family 0x:
> unimplemented function 6
>
> build/X86/arch/x86/cpuid.cc:181: warn: x86 cpuid family 0x:
> unimplemented function 8
>
> build/X86/sim/simulate.cc:194: info: Entering event queue @ 0.  Starting
> simulation...
>
> build/X86/cpu/kvm/perfevent.cc:181: panic: PerfKvmCounter::attach recieved
> error EACCESS
>
>   This error may be caused by a too restrictive setting
>
>   in the file '/proc/sys/kernel/perf_event_paranoid'
>
>   The default value was changed to 2 in kernel 4.6
>
>   A value greater than 1 prevents gem5 from making
>
>   the syscall to perf_event_open
>
> Memory Usage: 3979164 KBytes
>
> build/X86/cpu/kvm/perfevent.cc:181: Program aborted at tick 0
>
> panic: PerfKvmCounter::attach recieved error EACCESS
>
>   This error may be caused by a too restrictive setting
>
>   in the file '/proc/sys/kernel/perf_event_paranoid'
>
>   The default value was changed to 2 in kernel 4.6
>
>   A value greater than 1 prevents gem5 from making
>
>   the syscall to perf_event_open
>
> Memory Usage: 3979164 KBytes
>
> Aborted (core dumped)
>
>
>
> cat /proc/sys/kernel/perf_event_paranoid
>
> 2
>
>
>
> Any ideas to fix the core dump issue ?
>
>
>
> David
>
>
>
>
>

[gem5-users] Re: Not able to access webpage to run_npb.py

2022-02-22 Thread Bobby Bruce via gem5-users
Hey David,

It looks like you're mixing and matching some stuff between gem5 versions
here. I'm pretty sure you took that 'x86-npb-benchmarks.py' script from the
the repo checkout out fo v21.2, but you're running it on gem5 v21.1. I
suspect that's the problem. If you want to run this script you'll need to
checkout the latest version of gem5:

```
git checkout stable && git pull
```

Delete the build directory and recompile. This will get you gem5 v21.2.1
which should work with the x86-npb-benchmark.py script

--
Dr. Bobby R. Bruce
Room 3050,
Kemper Hall, UC Davis
Davis,
CA, 95616

web: https://www.bobbybruce.net


On Tue, Feb 22, 2022 at 9:08 AM David Fong  wrote:

> Hi Ayaz,
>
>
>
> I’m not clear about how the
>
>
>
>
>
> configs/example/x86-npb-performance.py
>
>
>
> works
>
>
>
> since the python is trying to get the package or module
>
>
>
> gem5
>
>
>
> and it is NOT “import” ed into the python.
>
>
>
> See my cmd-line and error below:
>
>
>
> ./build/X86/gem5.opt configs/example/x86-npb-benchmarks.py
> --disk-image=../disk-image/npb/npb-image/npb
> --kernel=../linux-stable/vmlinux |& tee x86_npb_benchmarks.log
>
> gem5 Simulator System.  http://gem5.org
>
> gem5 is copyrighted software; use the --copyright option for details.
>
>
>
> gem5 version 21.1.0.2
>
> gem5 compiled Feb 18 2022 18:42:01
>
> gem5 started Feb 22 2022 09:06:22
>
> gem5 executing on sundial.chronostech.com, pid 38198
>
> command line: ./build/X86/gem5.opt configs/example/x86-npb-benchmarks.py
> --disk-image=../disk-image/npb/npb-image/npb
> --kernel=../linux-stable/vmlinux
>
>
>
> Traceback (most recent call last):
>
>   File "", line 1, in 
>
>   File "build/X86/python/m5/main.py", line 455, in main
>
> exec(filecode, scope)
>
>   File "configs/example/x86-npb-benchmarks.py", line 47, in 
>
> from gem5.utils.requires import requires
>
> ModuleNotFoundError: No module named 'gem5'
>
>
>
>
>
> Is there some PYTHONPAH setting or I’m missing a “gem5” package separate
> from the gem5.opt build install that needs to be done ?
>
>
>
> Thanks,
>
>
>
> David
>
>
>
>
>
> *From:* Ayaz Akram 
> *Sent:* Friday, February 18, 2022 12:49 PM
> *To:* gem5 users mailing list 
> *Cc:* Bobby Bruce ; David Fong 
> *Subject:* Re: [gem5-users] Re: Not able to access webpage to run_npb.py
>
>
>
> Hi David,
>
>
>
> Please find my response to your questions below:
>
>
>
>
>
>
>1. It seems like I don’t need to do the “Setting up the environment”
>since I don’t plan to create or modify npb-tests.
>
> I thought the npb tests are already on the disk image from “Creating a
> disk image” section.
> Please confirm.
> If the npb-tests are necessary please explain “your-remote-add”.  Is this
> on my host machine and needs to be accessible as a webpage on my local hard
> disk?
> git remote add origin https://your-remote-add/npb-tests.git
> 
>
>
>
> The tutorial you have referenced provides instructions to run NPB with
> gem5art. Since, gem5art tries to create a reproducible test environment
> where every change can be tracked (more details on gem5art can be found
> here: https://arch.cs.ucdavis.edu/simulation/2021/03/28/gem5art.html
> ),
> "Setting up the environment" section of the tutorial provides
> the instructions to set up the base environment. Basically, we create  a
> github repo to treat it as the primary directory from where all the tests
> would be run. gem5art uses the metadata of this github repo to track any
> changes to it. The "your-remote-add" is meant to be a user-defined remote
> where they might keep this github repo.
>
>
>
>
>
>
>1. To run one test I just use at gem5 directory
>
> `./build/X86/gem5.opt configs/example/gem5_library/x86-npb-benchmarks.py
> --benchmark ep --size A`
>
>
>1. To run a suite of NPB benchmark tests I can create the
>launch_npb_tests.py
>
> This file seems to rebuild everything from scratch and run a regression
> As a first order I prefer to not get so sophisticated until I get a few
> simple tests to run.
>
>
> Could I run in sequential order something like below
> `./build/X86/gem5.opt configs/example/gem5_library/x86-npb-benchmarks.py
> --benchmark ep --size A`
> `./build/X86/gem5.opt configs/example/gem5_library/x86-npb-benchmarks.py
> --benchmark bt --size A`
> `./build/X86/gem5.opt configs/example/gem5_library/x86-npb-benchmarks.py
> --benchmark cg --size A`
> `./build/X86/gem5.opt 

[gem5-users] Re: Not able to access webpage to run_npb.py

2022-02-22 Thread David Fong via gem5-users
Hi Ayaz,

I’m not clear about how the


configs/example/x86-npb-performance.py

works

since the python is trying to get the package or module

gem5

and it is NOT “import” ed into the python.

See my cmd-line and error below:

./build/X86/gem5.opt configs/example/x86-npb-benchmarks.py 
--disk-image=../disk-image/npb/npb-image/npb --kernel=../linux-stable/vmlinux 
|& tee x86_npb_benchmarks.log
gem5 Simulator System.  http://gem5.org
gem5 is copyrighted software; use the --copyright option for details.

gem5 version 21.1.0.2
gem5 compiled Feb 18 2022 18:42:01
gem5 started Feb 22 2022 09:06:22
gem5 executing on sundial.chronostech.com, pid 38198
command line: ./build/X86/gem5.opt configs/example/x86-npb-benchmarks.py 
--disk-image=../disk-image/npb/npb-image/npb --kernel=../linux-stable/vmlinux

Traceback (most recent call last):
  File "", line 1, in 
  File "build/X86/python/m5/main.py", line 455, in main
exec(filecode, scope)
  File "configs/example/x86-npb-benchmarks.py", line 47, in 
from gem5.utils.requires import requires
ModuleNotFoundError: No module named 'gem5'


Is there some PYTHONPAH setting or I’m missing a “gem5” package separate from 
the gem5.opt build install that needs to be done ?

Thanks,

David


From: Ayaz Akram 
Sent: Friday, February 18, 2022 12:49 PM
To: gem5 users mailing list 
Cc: Bobby Bruce ; David Fong 
Subject: Re: [gem5-users] Re: Not able to access webpage to run_npb.py

Hi David,

Please find my response to your questions below:



  1.  It seems like I don’t need to do the “Setting up the environment” since I 
don’t plan to create or modify npb-tests.
I thought the npb tests are already on the disk image from “Creating a disk 
image” section.
Please confirm.
If the npb-tests are necessary please explain “your-remote-add”.  Is this on my 
host machine and needs to be accessible as a webpage on my local hard disk?
git remote add origin 
https://your-remote-add/npb-tests.git

The tutorial you have referenced provides instructions to run NPB with gem5art. 
Since, gem5art tries to create a reproducible test environment where every 
change can be tracked (more details on gem5art can be found here: 
https://arch.cs.ucdavis.edu/simulation/2021/03/28/gem5art.html),
 "Setting up the environment" section of the tutorial provides the instructions 
to set up the base environment. Basically, we create  a github repo to treat it 
as the primary directory from where all the tests would be run. gem5art uses 
the metadata of this github repo to track any changes to it. The 
"your-remote-add" is meant to be a user-defined remote where they might keep 
this github repo.




  1.  To run one test I just use at gem5 directory
`./build/X86/gem5.opt configs/example/gem5_library/x86-npb-benchmarks.py 
--benchmark ep --size A`


  1.  To run a suite of NPB benchmark tests I can create the launch_npb_tests.py
This file seems to rebuild everything from scratch and run a regression
As a first order I prefer to not get so sophisticated until I get a few simple 
tests to run.

Could I run in sequential order something like below
`./build/X86/gem5.opt configs/example/gem5_library/x86-npb-benchmarks.py 
--benchmark ep --size A`
`./build/X86/gem5.opt configs/example/gem5_library/x86-npb-benchmarks.py 
--benchmark bt --size A`
`./build/X86/gem5.opt configs/example/gem5_library/x86-npb-benchmarks.py 
--benchmark cg --size A`
`./build/X86/gem5.opt configs/example/gem5_library/x86-npb-benchmarks.py 
--benchmark ft --size A`

You should be able to run the single tests using the above commands.  
`launch_npb_tests.py` runs a suite of tests using gem5art, by 
registering/documenting different artifacts that will be used to run this suite 
of tests.


  1.  Extract NPB performance data
I’m not familiar with celery and but familiar with python.
Do I need to install celery on host system ?
Which directory and how to extract the NPB run data which is on the virtual 
machine over to the host machine ?
What kind of statistics are output : runtime of test , latencies of certain 
paths ?

You do not need celery to run your jobs with gem5art. Please look at the 
reference to 'python multiprocessing library' on this page: 

[gem5-users] Re: Run benchmark with multiple input arguments

2022-02-22 Thread Rosen Lu via gem5-users
Hi Jordi,

It works. Thanks for the answer.

Best,
Rosen

Jordi Vaquero  于2022年2月22日周二 03:14写道:

> Hi Rosen,
> try adding  a space before the "-c". So the -o option stays like *-o ' -c
> 10' *
> I found that before and the extra space avoids the problem.
>
> Jordi
>
>
>
>
>  Activat Tue, 22 Feb 2022 07:17:57 +0100 *Rosen Lu via gem5-users
> >* va escriure 
>
> Dear All,
>
> I just downloaded the version from
> https://gem5.googlesource.com/public/gem5. I want to run a benchmark with
> multiple input arguments. For example, run the command ./*queens -c 10 *in
> SE mode. I remember in a version from a few years ago, I could run it in
> the simulator with the -o option:
> *build/X86/gem5.opt ./configs/example/se.py -c './queens' -o '-c 10'  *
> But it doesn't work anymore for the current version.  se.py: error:
> argument -o/--options: expected one argument.
>
> Do you have any ideas or suggestions about solving this problem in the
> current version?
> Thank you very much.
>
> Rosen
>
>
>
> ___
> gem5-users mailing list -- gem5-users@gem5.org
> To unsubscribe send an email to gem5-users-le...@gem5.org
> %(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s
>
>
>
>
___
gem5-users mailing list -- gem5-users@gem5.org
To unsubscribe send an email to gem5-users-le...@gem5.org
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

[gem5-users] Re: Run benchmark with multiple input arguments

2022-02-22 Thread Jordi Vaquero via gem5-users
Hi Rosen, 

try adding  a space before the "-c". So the -o option stays like -o ' -c 10' 

I found that before and the extra space avoids the problem. 



Jordi










 Activat Tue, 22 Feb 2022 07:17:57 +0100 Rosen Lu via gem5-users 
 va escriure 



Dear All,



I just downloaded the version from https://gem5.googlesource.com/public/gem5. I 
want to run a benchmark with multiple input arguments. For example, run the 
command ./queens -c 10 in SE mode. I remember in a version from a few years 
ago, I could run it in the simulator with the -o option:

build/X86/gem5.opt ./configs/example/se.py -c './queens' -o '-c 10'  

But it doesn't work anymore for the current version.  se.py: error: argument 
-o/--options: expected one argument.



Do you have any ideas or suggestions about solving this problem in the current 
version?
Thank you very much. 

Rosen







___
gem5-users mailing list -- mailto:gem5-users@gem5.org 
To unsubscribe send an email to mailto:gem5-users-le...@gem5.org 
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s___
gem5-users mailing list -- gem5-users@gem5.org
To unsubscribe send an email to gem5-users-le...@gem5.org
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s