Commit Graph

17622 Commits

Author SHA1 Message Date
Nathanael Premillieu
cf0881433b mem-cache: add pfIssued stat in MultiPrefetcher
Count issued prefetches for each prefetchter in a MultiPrefetcher

Change-Id: If03fb0669af9bb92ce9cf210b6201a9719a7c771
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47600
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Maintainer: Daniel Carvalho <odanrc@yahoo.com.br>
2021-07-09 22:30:45 +00:00
Nathanael Premillieu
85a8dbf761 mem-cache: move unusedPrefetches stat to prefetcher
This stat belongs to prefetchers.
It has been renamed to pfUnused to match the naming of
exisiting prefetcher stats.

Change-Id: Iec350a62da544535dfc0c2527fcdf73217ae4db7
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47599
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Maintainer: Daniel Carvalho <odanrc@yahoo.com.br>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-09 22:30:45 +00:00
Nathanael Premillieu
f3e7d02150 mem-cache: print prefetch queues in Queued prefetcher
Added to track the content of the prefetch queues in the debug output

Change-Id: I49d0f4f643ec0dbd7af3087b6267d454cfccddba
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47199
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-09 22:30:45 +00:00
Melissa Jost
4f8e792324 learning-gem5: This commit changes variable names in the tutorial
Changed files from part 1 and part 2 of the learning-gem5
tutorial to use variable names int_requestor,int_responder,
cpu_side_ports, and mem_side_ports instead of master and slave.

Change-Id: I06ba4a337d947d22c39b5de3ba6700d64bda02c4
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47839
Reviewed-by: Hoa Nguyen <hoanguyen@ucdavis.edu>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-09 22:22:56 +00:00
Kyle Roarty
1812041dc0 gpu-compute: Update GET_PROCESS_APERTURES IOCTLs
The apertures for non-gfx801 GPUs are set differently.
If the apertures aren't set properly, ROCm will error out.

This change sets the apertures appropriately based on the
gfx version of the simulated GPU. It also adds in new
functions to set the scratch and lds apertures in GFX9 to mimic
the linux kernel.

Change-Id: I1fa6f60bc20c7b6eb3896057841d96846460a9f8
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47529
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-09 16:22:07 +00:00
Kyle Roarty
29372c8bff configs: Set valid heap_type values
The variables that were used to set heap_type don't exist.
Explicitly set them to the proper values.

Also add pointer to what heap value means in the ROCm stack.

Change-Id: I8df7fca7442f6640be1154ef147c4e302ea491bb
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47528
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-09 16:11:20 +00:00
Kyle Roarty
ab9e28ddb8 configs,gpu-compute: Set proper dGPUPoolID defaults
In GPU.py, dGPUPoolID is defined as an int, but was defaulted
to False. Explicitly set it to 0, instead.

In apu_se.py, dGPUPoolID was being set to 1, but that was
resulting in crashes. Setting it to 0 avoids those crashes.

Change-Id: I0f1161588279a335bbd0d8ae7acda97fc23201b5
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47527
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-09 16:11:20 +00:00
Kyle Roarty
6d2404acc5 arch-x86: Ignore mbind syscall
mbind gets called when running with a dGPU in ROCm 4,
but we are able to ignore it without breaking anything

Change-Id: I7c1ba47656122a5eb856981dca2a05359098e3b2
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47526
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
2021-07-09 16:11:20 +00:00
Kyle Roarty
c7a69187dd configs: Don't report CPU cores on Fiji properties
ROCm determines if a device is a dGPU in two ways. The first
is by looking at the device ID. The second is through a flag that
gets set only if the reported cpu_cores_count is 0.

If these don't agree, ROCm breaks when doing memory operations.

Previously, cpu_cores_count was non-zero on the Fiji config.
This patch sets it to 0 to appease ROCm

Change-Id: I0fd0ce724f491ed6a4598188b3799468668585f4
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47525
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
2021-07-09 16:11:20 +00:00
Kyle Roarty
66cb3e1476 configs: Add shared_cpu_list to cache directories
The ROCm thunk uses this file instead of the
shared_cpu_map file.

Change-Id: I985512245c9f51106b8347412ed643f78b567b24
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47524
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
2021-07-09 16:11:20 +00:00
Kyle Roarty
76888a9cca gpu-compute: Add mmap functionality to GPURenderDriver
dGPUs mmap the GPURenderDriver, however it doesn't appear that they do
anything with it. This patch implements the mmap function by just
returning the address provided, while not doing anything else

Change-Id: Ia010a2aebcf7e2c75e22d93dfb440937d1bef3b1
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47523
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-09 16:11:20 +00:00
Mahyar Samani
1fd4b1ce7d util-gem5art: Simplify gem5art Run
This changeset removes some of the duplicate information in the gem5 run
object making it a little simpler to use the createRun functions.

Change-Id: I36ee105166e41407c21e36d9bc71fd4db89fb1e8
Signed-off-by: Jason Lowe-Power <jason@lowepower.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47465
Reviewed-by: Hoa Nguyen <hoanguyen@ucdavis.edu>
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-09 16:09:24 +00:00
Hoa Nguyen
43004d9506 util-gem5art: Simplify rerunning failing runs
Often, a gem5 experiment will fail for some reason. This happens
non-deterministically when fastforwarding with KVM making it more
difficult to handle.

This change allows the user to specify a function `check_failure` to
check to see if the test has failed. An example would be to open the
terminal and check to see if the kernel has panicked.

Additionally, this change adds a rerun function to rerun a particular
run that has failed.

Change-Id: Ib4a8d47c824254ae89ac9e1593ebd2710e263146
Signed-off-by: Jason Lowe-Power <jason@lowepower.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47464
Reviewed-by: Hoa Nguyen <hoanguyen@ucdavis.edu>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-09 16:09:24 +00:00
Hoa Nguyen
d7cf6be93a util-gem5art: Decouple artifacts from mongodb
This commit does a few things to decouple the artifacts from mongodb.
- Creates an ArtifactFileDB which stores artifacts in a json file on the
local machine
- Adds tests fro the artifact file DB
- Sets the file database to be default if pymongo isn't installed
- Extends the Artifact class to prepare for downloading artifacts from
gem5-resources

Change-Id: I1bceef94dc53c066d1c0475e79c9a1ad1f1a6202
Signed-off-by: Jason Lowe-Power <jason@lowepower.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47463
Reviewed-by: Hoa Nguyen <hoanguyen@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-09 16:09:24 +00:00
Daniel R. Carvalho
bb596f55e3 base-stats: Use smart pointer for info's storageParams
Previously the storage params were not being deallocated.
Make sure this happens by managing it with smart pointers.

As a side effect, encapsulate this variable to facilitate
future changes.

Change-Id: I4c2496d08241f155793ed35e3463512d9ea06f83
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/38178
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Hoa Nguyen <hoanguyen@ucdavis.edu>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
2021-07-09 11:24:10 +00:00
Daniel R. Carvalho
70194795c3 base-stats: Use std vector in vector stats
Use std::vector in vector based stats to avoid data management.

Change-Id: I6b341f03e4861a5b8f80fa8741373065b7c755bf
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/27085
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
2021-07-09 11:24:10 +00:00
Daniel R. Carvalho
b63a802033 base-stats: Remove info dependency from stats storage
Info depends on the storage type, not the other way around.

Change-Id: Ie3deca17b859a217c0c7bd833c017d9436eee4b0
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/27083
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
2021-07-09 11:24:10 +00:00
Daniel R. Carvalho
e9bdc92039 base-stats,tests: Add unit test for Stats::Group
Add a unit test for Stats::Group.

Three bugs were found: groups are able to add
themselves/null groups as their sub-groups, and
one can create a cyclic dependency of sub-groups.

The ADD_STAT macro is not being tested.

Change-Id: I52326994b3f75e313024f872d214e8c45943f44d
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/43010
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Reviewed-by: Hoa Nguyen <hoanguyen@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-09 11:24:10 +00:00
Daniel R. Carvalho
d001f3f575 base-stats,tests: Add unit test for Stats::Info
Add a unit test for stats/info.

One test has been disabled due to not knowing the
expected behavior.

It is important to notice that Stats::Info can have
duplicate names using the new style. Stats::Group is
responsible for not allowing duplicate names in this
case.

Change-Id: I8b169d34c1309b37ba79fa9cf6895547b7e97fc0
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/43009
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-09 11:24:10 +00:00
Daniel R. Carvalho
79bab1dc5d mem: Adopt a memory namespace for memories
Encapsulate every class inheriting from Abstract or Physical
memories, and the memory controller in a memory namespace.

Change-Id: I228f7e55efc395089e3616ae0a0a6325867bd782
Issued-on: https://gem5.atlassian.net/browse/GEM5-983
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47309
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
2021-07-09 11:24:10 +00:00
Daniel R. Carvalho
5635b3aaa2 mem: Adopt the memory namespace in qos files
Encapsulate everything qos-related in the gem5::memory
namespace.

Change-Id: Ib906ddd6d76b9d4a56f2eb705efe6cd498829155
Issued-on: https://gem5.atlassian.net/browse/GEM5-983
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47308
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
2021-07-09 11:24:10 +00:00
Kyle Roarty
06da510020 arch-vega: Add decoding for implemented insts
Certain instructions were implemented in instructions.cc,
but weren't actually being decoded by the decoder, causing
the decoder to return nullptr for valid instructions.

This patch fixes the decoder to return the proper instruction
class for implemented instructions

Change-Id: I8d8525a1c435147017cb38d9df8e1675986ef04b
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47521
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Reviewed-by: Alex Dutu <alexandru.dutu@amd.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-09 03:49:29 +00:00
Kyle Roarty
9fe9d83e5b arch-vega: Add missing return to flat_load_dwordx4
Change-Id: Ibf56c25a3d22d3c12ae2c1bb11f00f4a44b5919a
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47520
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Reviewed-by: Alex Dutu <alexandru.dutu@amd.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-09 03:49:29 +00:00
Kyle Roarty
cb73fe1959 arch-vega: Fix s_endpgm instruction
Copy over changes that had been made to s_engpgm in GCN3
but weren't added to the Vega implementation

Change-Id: I1063f83b1ce8f7c5e451c8c227265715c8f725b9
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47519
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Reviewed-by: Alex Dutu <alexandru.dutu@amd.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-09 03:49:29 +00:00
Bobby R. Bruce
8134902e8b tests,util-gem5art: Add presubmit tests for gem5art
Change-Id: I7c10155e74de1a073fda861d498632c1d4be42b9
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47223
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-08 19:03:08 +00:00
Daniel R. Carvalho
80b5f43d29 sim: Align coding style of probes
Fix coding style of probes for the following aspects:
- Long lines
- Return type of multi-line functions
- Name of local parameters

Also, added missing overrides

Jira: https://gem5.atlassian.net/browse/GEM5-857

Change-Id: Ibd905d1941fc203ca8308f7a3930d58515b19a97
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/38697
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
2021-07-08 11:58:25 +00:00
Davide Basilio Bartolini
7bdd8b56e3 base-stats: Add basic test for hdf5 stats
Also rethrow hdf5 exceptions to propagate error message

Related JIRA issue: https://gem5.atlassian.net/browse/GEM5-1028

Change-Id: I67badcf261f04cd446d016a4ad3d7393bad9a6ba
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47740
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-08 10:33:35 +00:00
Davide Basilio Bartolini
86c3f08d13 base-stats: Fix stat descriptions
Change-Id: Ib43dc9261287f10c615786a0d533304ab55ac232
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47741
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-08 10:33:35 +00:00
Richard Cooper
c25ef2d191 arch-arm: Update ARMv8.1-PAN to allow unprivileged instructions.
Update the ARMv8.1-PAN implementation to allow specified unprivileged
instructions to execute even when the cpsr.pan bit is set. The
specified instructions generate memory requests with the
TLB::ArmFlags::UserMode flags bit set.

See sections D5.4.2 (About PSTATE.PAN) and G5.6.2 (About the PAN bit)
of the Arm Architecture Reference Manual for details.
https://developer.arm.com/documentation/ddi0487/latest/

Change-Id: I9e904e0154de72c2e4cc70cbc49b3c8407a3cb1d
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47779
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Giacomo Travaglini <giacomo.travaglini@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-08 08:48:51 +00:00
Richard Cooper
04a4fb53ad misc: Fix nesting of namespace{} and if-endif.
Fix a build error caused by the misaligned nesting of namespace{} and
if-endif. Previously, if HAVE_TUNTAP is not defined then the gem5
namespace is not closed.

Change-Id: I5e45d2271f97bb9e38c91565adb6aff0a7b43744
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47761
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-08 08:48:08 +00:00
Richard Cooper
704ef29f4f arch-arm: Fix for build error in recent MacOS 11.
On a recent version of MacOS 11, the build fails due to the missing
sysctl.h include. Updated the preprocessor macros to include this file
for __APPLE__ builds.

Change-Id: I985d6c2ea97b82b32750bb562b2051f87d6c2e65
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47760
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-08 08:48:08 +00:00
Richard Cooper
cd76334a2a sim-se: Fix for build error in MacOS.
On MacOS the build fails because the types of readfds, writefds, and
errorfds cannot be automatically converted to fd_set*. Added casts
similar to the ones used for the FD_ZERO calls to help the compiler.

Change-Id: I40a2268f7f2ca1bece1ecafda52dfddf2212364d
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47759
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-08 08:48:08 +00:00
Kyle Roarty
ebb6c4b99b gpu-compute: Check for WAX dependences
This adds checking if the destination registers are free or busy
in the operandsReady() function for both scalar and vector
registers. This allows us to catch WAX dependences between instructions.

Change-Id: I0fb0b29e9608fca0d90c059422d4d9500d5b2a7d
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47539
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-08 01:18:01 +00:00
Kyle Roarty
02dd6b77ff arch-gcn3,arch-vega,gpu-compute: Move request counters
When the Vega ISA got committed, it lacked the request counter
tracking for memory requests that existed in the GCN3 code.

Instead of copying over the same lines from the GCN3 code to the Vega
code, this commit makes the various memory pipelines handle updating the
request counter information instead, as every memory instruction calls a
memory pipeline.

This commit also adds an issueRequest in scalar_memory_pipeline, as
previously, the gpuDynInsts were explicitly placed in the queue of
issuedRequests.

Change-Id: I5140d3b2f12be582f2ae9ff7c433167aeec5b68e
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/45347
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-08 01:18:01 +00:00
Kyle Roarty
3f9b03522c arch-gcn3,gpu-compute: Set gpuDynInst exec_mask before use
vector_register_file uses the exec_mask of a memory instruction in
order to determine if it should mark a register as in-use or not.
Previously, the exec_mask of memory instructions was only set on
execution of that instruction, which occurs after the code in
vector_register_file. This led to the code reading potentially garbage
data, leading to a scenario where a register would be marked used when
it shouldn't be.

This fix sets the exec_mask of memory instructions in schedule_stage,
which works because the only time the wavefront execMask() is updated is
on a instruction executing, and we know the previous instruction will
have executed by the time schedule_stage executes, due to the order the
pipeline is executed in.

This also undoes part of a patch from last year (62ec973) which treated
the symptom of accidental register allocation, without preventing the
registers from being allocated in the first place.

This patch also removes now redundant code that sets the exec_mask in
instructions.cc for memory instructions

Change-Id: Idabd35020000764fb06133ac2458606c1aaf6f04
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/45346
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Maintainer: Matthew Poremba <matthew.poremba@amd.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-08 01:18:01 +00:00
Kyle Roarty
ccfee78f3a arch-gcn3: Read registers in execute instead of initiateAcc
Certain memory writes were reading their registers in
initiateAcc, which lead to scenarios where a subsequent instruction
would execute, clobbering the value in that register before the memory
writes' initiateAcc method was called, causing the memory write to read
wrong data.

This patch moves all register reads to execute, preventing the above
scenario from happening.

Change-Id: Iee107c19e4b82c2e172bf2d6cc95b79983a43d83
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/45345
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Reviewed-by: Alex Dutu <alexandru.dutu@amd.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
2021-07-08 01:18:01 +00:00
Daniel R. Carvalho
5ff1fac819 misc: Rename Debug namespace as debug
As part of recent decisions regarding namespace
naming conventions, all namespaces will be changed
to snake case.

gem5::Debug became gem5::debug.

Change-Id: Ic04606baab3317d2e58ab3ca9b37fc201c406ee8
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47305
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Maintainer: Giacomo Travaglini <giacomo.travaglini@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-07 23:18:59 +00:00
Daniel R. Carvalho
7ded9b414c arch-arm: Rename debug variables
Pave the way for a "debug" namespace.

Change-Id: I1796711cbde527269637b30b0b09cd06c9e25fa1
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47304
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Maintainer: Giacomo Travaglini <giacomo.travaglini@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-07 23:18:59 +00:00
Daniel R. Carvalho
444cbe6250 cpu: Add a branch_prediction namespace
Encapsulate all branch-prediction-related files
in a branch_prediction namespace. This will allow
these files to be renamed to drop the BP suffix.

Issued-on: https://gem5.atlassian.net/browse/GEM5-982
Change-Id: I640c0caa846a3aade6fae95e9a93e4318ae9fca0
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47303
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-07 23:18:59 +00:00
Daniel R. Carvalho
60e4ad955d mem-ruby: Add a ruby namespace
Encapsulate all ruby-related files in a ruby namespace.

Change-Id: If642c9751ecefc35b45c5dd69d85e67813cc5224
Issued-on: https://gem5.atlassian.net/browse/GEM5-984
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47307
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-07 23:18:59 +00:00
Boris Shingarov
eeedf63c86 cpu: Check for instruction-count events before fetch
Instruction fetch should not commence if there already is an
instruction-count event in the queue.

The most conspicuous scenario where this leads to obvious breakage,
is guest debugging.  Imagine the first bytes in the program pointed to
by _start are invalid instruction encoding, and we pass the --wait-gdb
flag.  Then in GDB we set $pc to point to valid instructions, and we
"continue".  gem5 will abort with "invalid instruction".

This is not how real targets behave: neither software- (e.g. ptrace)
based debuggers, nor low-level (e.g. OpenOCD or XMD connected over
JTAG to debug early initialization code eg when the MMU has not been
switched on yet, etc.)  Fetching should start from where $pc was set
to.  This patch tries to model this behavior.

Change-Id: Ibce6fdbbb082edf1073ae96745bc7867878f99ca
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/27587
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-07 22:55:06 +00:00
Boris Shingarov
c046e61216 base: Dump page table over RSP
Add a non-standard extension to the RSP protocol: the "." command
requests a dump of the simulated page table.
The dump consists of concatenated records, one record per page table
entry.  Each record contains the entry's "virtual" value written as
hex, followed by a colon (:), followed by the entry's "physical" value
written as hex, followed by a semicolon (;).

At the time of writing, one practical use of this feature (in
combination with the "shared_backstore" parameter) is extremely fast
Miranda-Ingalls simulation of JIT compilers.

Change-Id: I333ed11d4ce671251d0b93cddae3bbcea44ea4ca
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47719
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-07 22:54:27 +00:00
Hoa Nguyen
9a2efa07c5 scons: Explicitly add librt to scons
gem5 uses the `shm_open()` funciton from <sys/mman.h>.
This function requires linking to librt.

JIRA: https://gem5.atlassian.net/browse/GEM5-1015

Change-Id: I461400e3cb7474a80a995b264af2e03b19fea29c
Signed-off-by: Hoa Nguyen <hoanguyen@ucdavis.edu>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47659
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Gabe Black <gabe.black@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-07 21:37:15 +00:00
Gabe Black
1c7c825757 arch,kern: Use CRTP to build open flags tables, not macros.
Change-Id: I433c064c66254c6e082fd6e37b4364576c2fbc3a
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/45903
Reviewed-by: Gabe Black <gabe.black@gmail.com>
Maintainer: Gabe Black <gabe.black@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-07 18:05:51 +00:00
Bobby R. Bruce
4cfe934204 util-gem5art: Update .gitignore to ingore run results
Change-Id: Iedb944c2be7889dbf3d9eaabb78c4a1bc967af3e
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47222
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
2021-07-07 17:17:24 +00:00
Bobby R. Bruce
f1f101d981 util-gem5art: Fix the artifact test with incorrect git repo
The gem5art tests add the current repository as an artifact. Previously
this repository was called "gem5art". Since moving to the gem5 repo, it
is now called "gem5". Therefore the test checking the repository name
needed fixed.

Note: We need a better solution for testing gem5art's git functionality.
Using the current repository is not stable, as this fix shows. Noted
in Jira: https://gem5.atlassian.net/browse/GEM5-1013.

Change-Id: I017ff039ccb1c0a290f9aa1a09bd738c1820f88f
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47220
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
2021-07-07 17:17:24 +00:00
Bobby R. Bruce
512564fd73 util-docker: Add Python test dependencies to Docker
These are needed to run our Python tests

Change-Id: Ifd6904a59ad3b6217a337bd5e912c3e7e2e10c17
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47219
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-07 17:17:24 +00:00
Bobby R. Bruce
684ba89390 docker-util: Remove building of GCC 5 and 6 Docker images
Building of these images is no longer required as GCC 5 and 6 have been
dropped.

Change-Id: Ife0331843214fe545c5620a2f77ede3adb436700
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47462
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
2021-07-07 15:48:25 +00:00
Bobby R. Bruce
263be6a994 misc,tests: Remove support for GCC 6
Supporting GCC 7 onwards will allow us to move to the C++17 standard.

Change-Id: I805945230d77dacdc6b0a863153b28276025ecdc
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47460
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-07 15:48:25 +00:00
Giacomo Travaglini
3472fdadc3 arch-arm: Forward declare kvm_vcpu_init
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Change-Id: I6fa5be48498d1a8f9c070e9ded11e8cadd4b89a1
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/47679
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
2021-07-07 08:44:24 +00:00