Re: [gem5-users] Installing Shared Libraries to Image in Full Simulation

2020-02-03 Thread Ayaz Akram
We have recently uploaded a disk image with ubuntu 18.04 installed which
should have basic packages/libraries available. See the following post on
the mailing list:

https://www.mail-archive.com/gem5-users@gem5.org/msg17274.html

You can also refer to gem5art's documentation on building your own disk
images:

https://gem5art.readthedocs.io/en/latest/main-doc/disks.html

-Ayaz



On Mon, Feb 3, 2020 at 4:04 AM Muhammet Abdullah Soytürk <
muhammetabdullahsoyt...@gmail.com> wrote:

> Hi all,
>
> What is the best way to install shared libraries to linux-x86.img? Since
> apt or dpkg is not installed, I don't know how to add the shared libraries
> to the images that I need to execute PageRank in GAP benchmark suite.
>
> Best,
> Muhammet
> ___
> gem5-users mailing list
> gem5-users@gem5.org
> http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users
___
gem5-users mailing list
gem5-users@gem5.org
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users

Re: [gem5-users] Illegal Instruction when running FS with SVE code

2020-02-03 Thread Giacomo Travaglini
Sorry, I have just realized you specified where you got the kernel
( https://www.rico.cat/files/ICS18-gem5-sve-tutorial.pdf )

As far as I can see from the slides it is suggesting to clone

git clone -b gem5/v4.4 https://github.com/gem5/linux-arm-gem5

This is an old kernel version from a deprecated repository (it states:
Deprecated Linux kernel for ARMv7 with gem5-specific tweaks. Use 
https://gem5.googlesource.com/arm/linux instead).
If I inspect the gem5_defconfig I cannot see any mention of SVE enablement

https://github.com/gem5/linux-arm-gem5-legacy/blob/gem5/v4.4/arch/arm64/configs/gem5_defconfig


So I think you have two options here:


1) If you want to build Linux yourself I suggest you to clone a newer version 
from https://gem5.googlesource.com/arm/linux
arm/linux - Git at Google
Linux kernel (Aarch32 & Aarch64) with patches for gem5 and Arm.
gem5.googlesource.com
making sure to enable CONFIG_ARM64_SVE (with menuconfig)


2) If you don't care about building it yourself you could download a prebuilt 
kernel image:

wget http://dist.gem5.org/dist/current/arm/aarch-system-201901106.tar.bz2

You could also automatically download the kernel by running regressions:

./tests/main.py -j`nproc` -t`nproc` --isa ARM

Let me know if you have any problem

Giacomo





From: gem5-users  on behalf of Giacomo Travaglini 

Sent: 03 February 2020 13:56
To: gem5 users mailing list 
Subject: Re: [gem5-users] Illegal Instruction when running FS with SVE code

Hi Jeckson.

Out of curiosity, where did you find that kernel image?

My assumption is that the kernel is not supporting SVE instructions (might be 
an old one?)
The reason for my guess is that the kernel is not recognizing the exception 
class:

"0x6600 -- UNRECOGNIZED EC"

Which is the EC_TRAPPED_SVE exception code. So gem5 is enabling SVE 
instructions (this is why you are not getting
an undefined instruction fault) but since EL1 (Linux) is not doing it the 
instruction gets trapped
(To avoid this you should enable SVE in the kernel so that it is properly 
setting the CPACR_EL1.ZEN bits)

Kind Regards

Giacomo



From: gem5-users  on behalf of Jeckson Souza 

Sent: 03 February 2020 13:20
To: gem5 users mailing list 
Subject: [gem5-users] Illegal Instruction when running FS with SVE code

Hi all, I am trying to run an application compiled using gcc generated SVE code 
(march=armv8-a+sve) using a full system simulation.
This is the command line I am using to run the simulation:

build/ARM/gem5.opt -d /path/to/output/ configs/example/arm/fs_bigLITTLE.py 
--cpu-type atomic --kernel /path/to/kernel/vmlinux.arm64  --disk 
/path/to/disk/linaro-minimal-aarch64.img  --big-cpus 2 --little-cpus 0 --param 
'system.sve_vl = 1' --bootscript /path/to/script/Script.rcS

The simulation starts up just fine but when I try to run the application I get:

[ 2355.819013] Bad mode in Synchronous Abort handler detected, code 0x6600 
-- UNRECOGNIZED EC
[ 2355.819068] CPU: 0 PID: 997 Comm: atax_sve_omp Not tainted 4.4.0+ #1
[ 2355.819109] Hardware name: V2P-CA15 (DT)
[ 2355.819136] task: ffc077d68000 ti: ffc0785f task.ti: 
ffc0785f
[ 2355.819183] PC is at 0x4030f4
[ 2355.819204] LR is at 0x4030c4
[ 2355.819225] pc : [<004030f4>] lr : [<004030c4>] pstate: 
8000
[ 2355.819271] sp : 007ffa60
[ 2355.819294] x29: 007ffa60 x28: 
[ 2355.819333] x27: 0fa00fa0 x26: 007ffce8
[ 2355.819371] x25: 0001 x24: 007ffb30
[ 2355.819410] x23: 0002 x22: 007fb05ec040
[ 2355.819448] x21:  x20: 0fa0
[ 2355.819486] x19: 0fa0 x18: 
[ 2355.819525] x17: 00433c00 x16: 004b4018
[ 2355.819563] x15: 004bc7c8 x14: 0027
[ 2355.819601] x13: 004b5b10 x12: 007fb05eb010
[ 2355.819640] x11: 003d0f00 x10: 00418490
[ 2355.819678] x9 : 007fb05ea910 x8 : 0062
[ 2355.819716] x7 : 004bc448 x6 : 004bc448
[ 2355.819755] x5 : 007fb05eb0e0 x4 : 007fb05eb710
[ 2355.819793] x3 : 07d0 x2 : 
[ 2355.819831] x1 : 004bc700 x0 : 004bdae0
[ 2355.819869]
Illegal instruction

Running the same application compiled without SVE code works with no problems.
I believe the SVE code in the application is also working, as I was able to run 
it using system call emulation (although a single-threaded version) with the 
SVE instructions.

I have compiled the kernel using the guide in this tutorial 
https://www.rico.cat/files/ICS18-gem5-sve-tutorial.pdf and I am using the 
latest gem5 revision in the master branch 
(4ae8d1c0ed18f351b52f421553b28fe109f87665).

Has anybody gone through this problem or have any suggestions?

Regards,
Jeckson Dellagostin Souza
PhD Candidate
Instituto de Informática
Universidade Federal do 

Re: [gem5-users] Illegal Instruction when running FS with SVE code

2020-02-03 Thread Giacomo Travaglini
Hi Jeckson.

Out of curiosity, where did you find that kernel image?

My assumption is that the kernel is not supporting SVE instructions (might be 
an old one?)
The reason for my guess is that the kernel is not recognizing the exception 
class:

"0x6600 -- UNRECOGNIZED EC"

Which is the EC_TRAPPED_SVE exception code. So gem5 is enabling SVE 
instructions (this is why you are not getting
an undefined instruction fault) but since EL1 (Linux) is not doing it the 
instruction gets trapped
(To avoid this you should enable SVE in the kernel so that it is properly 
setting the CPACR_EL1.ZEN bits)

Kind Regards

Giacomo



From: gem5-users  on behalf of Jeckson Souza 

Sent: 03 February 2020 13:20
To: gem5 users mailing list 
Subject: [gem5-users] Illegal Instruction when running FS with SVE code

Hi all, I am trying to run an application compiled using gcc generated SVE code 
(march=armv8-a+sve) using a full system simulation.
This is the command line I am using to run the simulation:

build/ARM/gem5.opt -d /path/to/output/ configs/example/arm/fs_bigLITTLE.py 
--cpu-type atomic --kernel /path/to/kernel/vmlinux.arm64  --disk 
/path/to/disk/linaro-minimal-aarch64.img  --big-cpus 2 --little-cpus 0 --param 
'system.sve_vl = 1' --bootscript /path/to/script/Script.rcS

The simulation starts up just fine but when I try to run the application I get:

[ 2355.819013] Bad mode in Synchronous Abort handler detected, code 0x6600 
-- UNRECOGNIZED EC
[ 2355.819068] CPU: 0 PID: 997 Comm: atax_sve_omp Not tainted 4.4.0+ #1
[ 2355.819109] Hardware name: V2P-CA15 (DT)
[ 2355.819136] task: ffc077d68000 ti: ffc0785f task.ti: 
ffc0785f
[ 2355.819183] PC is at 0x4030f4
[ 2355.819204] LR is at 0x4030c4
[ 2355.819225] pc : [<004030f4>] lr : [<004030c4>] pstate: 
8000
[ 2355.819271] sp : 007ffa60
[ 2355.819294] x29: 007ffa60 x28: 
[ 2355.819333] x27: 0fa00fa0 x26: 007ffce8
[ 2355.819371] x25: 0001 x24: 007ffb30
[ 2355.819410] x23: 0002 x22: 007fb05ec040
[ 2355.819448] x21:  x20: 0fa0
[ 2355.819486] x19: 0fa0 x18: 
[ 2355.819525] x17: 00433c00 x16: 004b4018
[ 2355.819563] x15: 004bc7c8 x14: 0027
[ 2355.819601] x13: 004b5b10 x12: 007fb05eb010
[ 2355.819640] x11: 003d0f00 x10: 00418490
[ 2355.819678] x9 : 007fb05ea910 x8 : 0062
[ 2355.819716] x7 : 004bc448 x6 : 004bc448
[ 2355.819755] x5 : 007fb05eb0e0 x4 : 007fb05eb710
[ 2355.819793] x3 : 07d0 x2 : 
[ 2355.819831] x1 : 004bc700 x0 : 004bdae0
[ 2355.819869]
Illegal instruction

Running the same application compiled without SVE code works with no problems.
I believe the SVE code in the application is also working, as I was able to run 
it using system call emulation (although a single-threaded version) with the 
SVE instructions.

I have compiled the kernel using the guide in this tutorial 
https://www.rico.cat/files/ICS18-gem5-sve-tutorial.pdf and I am using the 
latest gem5 revision in the master branch 
(4ae8d1c0ed18f351b52f421553b28fe109f87665).

Has anybody gone through this problem or have any suggestions?

Regards,
Jeckson Dellagostin Souza
PhD Candidate
Instituto de Informática
Universidade Federal do Rio Grande do Sul
IMPORTANT NOTICE: The contents of this email and any attachments are 
confidential and may also be privileged. If you are not the intended recipient, 
please notify the sender immediately and do not disclose the contents to any 
other person, use it for any purpose, or store or copy the information in any 
medium. Thank you.
___
gem5-users mailing list
gem5-users@gem5.org
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users

Re: [gem5-users] Installing Shared Libraries to Image in Full Simulation

2020-02-03 Thread Giacomo Travaglini
I would recommend creating a disk image with buildroot so that it will come 
with a set of preinstalled packages

Giacomo

From: gem5-users  on behalf of Muhammet Abdullah 
Soyt?rk 
Sent: 03 February 2020 12:03
To: gem5 users mailing list 
Subject: [gem5-users] Installing Shared Libraries to Image in Full Simulation

Hi all,

What is the best way to install shared libraries to linux-x86.img? Since apt or 
dpkg is not installed, I don't know how to add the shared libraries to the 
images that I need to execute PageRank in GAP benchmark suite.

Best,
Muhammet
IMPORTANT NOTICE: The contents of this email and any attachments are 
confidential and may also be privileged. If you are not the intended recipient, 
please notify the sender immediately and do not disclose the contents to any 
other person, use it for any purpose, or store or copy the information in any 
medium. Thank you.
___
gem5-users mailing list
gem5-users@gem5.org
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users

[gem5-users] Illegal Instruction when running FS with SVE code

2020-02-03 Thread Jeckson Souza
 Hi all, I am trying to run an application compiled using gcc generated SVE
code (march=armv8-a+sve) using a full system simulation.
This is the command line I am using to run the simulation:

build/ARM/gem5.opt -d /path/to/output/ configs/example/arm/fs_bigLITTLE.py
--cpu-type atomic --kernel /path/to/kernel/vmlinux.arm64  --disk
/path/to/disk/linaro-minimal-aarch64.img  --big-cpus 2 --little-cpus 0
--param 'system.sve_vl = 1' --bootscript /path/to/script/Script.rcS

The simulation starts up just fine but when I try to run the application I
get:

[ 2355.819013] Bad mode in Synchronous Abort handler detected, code
0x6600 -- UNRECOGNIZED EC
[ 2355.819068] CPU: 0 PID: 997 Comm: atax_sve_omp Not tainted 4.4.0+ #1

[ 2355.819109] Hardware name: V2P-CA15 (DT)
[ 2355.819136] task: ffc077d68000 ti: ffc0785f task.ti:
ffc0785f
[ 2355.819183] PC is at 0x4030f4

[ 2355.819204] LR is at 0x4030c4

[ 2355.819225] pc : [<004030f4>] lr : [<004030c4>] pstate:
8000
[ 2355.819271] sp : 007ffa60

[ 2355.819294] x29: 007ffa60 x28: 

[ 2355.819333] x27: 0fa00fa0 x26: 007ffce8

[ 2355.819371] x25: 0001 x24: 007ffb30

[ 2355.819410] x23: 0002 x22: 007fb05ec040

[ 2355.819448] x21:  x20: 0fa0

[ 2355.819486] x19: 0fa0 x18: 

[ 2355.819525] x17: 00433c00 x16: 004b4018

[ 2355.819563] x15: 004bc7c8 x14: 0027

[ 2355.819601] x13: 004b5b10 x12: 007fb05eb010

[ 2355.819640] x11: 003d0f00 x10: 00418490

[ 2355.819678] x9 : 007fb05ea910 x8 : 0062

[ 2355.819716] x7 : 004bc448 x6 : 004bc448

[ 2355.819755] x5 : 007fb05eb0e0 x4 : 007fb05eb710

[ 2355.819793] x3 : 07d0 x2 : 

[ 2355.819831] x1 : 004bc700 x0 : 004bdae0

[ 2355.819869]

Illegal instruction

Running the same application compiled without SVE code works with no
problems.
I believe the SVE code in the application is also working, as I was able to
run it using system call emulation (although a single-threaded version)
with the SVE instructions.

I have compiled the kernel using the guide in this tutorial
https://www.rico.cat/files/ICS18-gem5-sve-tutorial.pdf and I am using the
latest gem5 revision in the master branch
(4ae8d1c0ed18f351b52f421553b28fe109f87665).

Has anybody gone through this problem or have any suggestions?

Regards,
Jeckson Dellagostin Souza
PhD Candidate
Instituto de Informática
Universidade Federal do Rio Grande do Sul
___
gem5-users mailing list
gem5-users@gem5.org
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users

[gem5-users] Installing Shared Libraries to Image in Full Simulation

2020-02-03 Thread Muhammet Abdullah Soytürk
Hi all,

What is the best way to install shared libraries to linux-x86.img? Since
apt or dpkg is not installed, I don't know how to add the shared libraries
to the images that I need to execute PageRank in GAP benchmark suite.

Best,
Muhammet
___
gem5-users mailing list
gem5-users@gem5.org
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users

Re: [gem5-users] Thread Creation Failed Error

2020-02-03 Thread Ayaz Akram
Hi Muhammet,

If I am not mistaken configs/learning_gem5/part1/simple.py is supposed to
run a simulation in system emulation (SE) mode. I don't think you will be
able to run benchmarks from GAPBS without using full system (FS) simulation
mode of gem5.

Regards
Ayaz

On Mon, Feb 3, 2020 at 12:36 AM Muhammet Abdullah Soytürk <
muhammetabdullahsoyt...@gmail.com> wrote:

> Hi all,
>
> I am trying to simulate the PageRank application available in GAP
> Benchmark Suite. I get the following error when I try to run it with a
> simple configuration.
>
> Command: build/X86/gem5.opt configs/learning_gem5/part1/simple.py. (I have
> modified simple.py to run PageRank.)
>
> "Thread creation failed: Resource temporarily unavailable".
>
> Is anyone have an idea why this happens?
>
> Best,
> Muhammet
> ___
> gem5-users mailing list
> gem5-users@gem5.org
> http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users
___
gem5-users mailing list
gem5-users@gem5.org
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users

[gem5-users] Thread Creation Failed Error

2020-02-03 Thread Muhammet Abdullah Soytürk
Hi all,

I am trying to simulate the PageRank application available in GAP Benchmark
Suite. I get the following error when I try to run it with a simple
configuration.

Command: build/X86/gem5.opt configs/learning_gem5/part1/simple.py. (I have
modified simple.py to run PageRank.)

"Thread creation failed: Resource temporarily unavailable".

Is anyone have an idea why this happens?

Best,
Muhammet
___
gem5-users mailing list
gem5-users@gem5.org
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users