Daniel R. Carvalho [Thu, 20 Feb 2020 15:23:16 +0000 (16:23 +0100)]
mem-cache: Protect tag from being mishandled
Make the tag variable private, so that every access to it must pass
through a getter and a setter. This protects it from being incorrectly
updated when there is no direct match between a tag and a data entry,
as is the case of sector, compressed, decoupled, and many other table
layouts.
As a side effect, a block matching function has been created, which
also depends directly on the mapping between tag and data entries.
Change-Id: I848a154404feb5cbcea8d0fd2509bf49e1d73bd0
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34955
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Earl Ou [Mon, 5 Oct 2020 07:51:56 +0000 (15:51 +0800)]
scons: only wrap message with positive value
In case we have small TTY, scons failed with wrong testwrap value. Fix
the issue.
Change-Id: I8ec1d55c6856c1e592a57a68067091b796ac84ae
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35596
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Earl Ou [Mon, 5 Oct 2020 07:29:51 +0000 (15:29 +0800)]
scons: avoid interactive access in non-tty
We saw some strange behavior when building scons without an interactive
TTY. This seems be caused by the control signal set from
curses.initscr() and endwin(). To avoid issues, we should avoid those
operation when running in non interactive situation.
Change-Id: I9cf8e48a786d47d567ba193f0b069f638e8db647
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35595
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Bobby R. Bruce [Thu, 1 Oct 2020 03:56:50 +0000 (20:56 -0700)]
misc: Changed gem5 version info for gem5 20.2 dev
Change-Id: I34505c054f1ec83f5da169bfde90702f3da3917e
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35439
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Gabe Black [Tue, 29 Sep 2020 01:48:01 +0000 (18:48 -0700)]
base: Add some error handling to compiler.hh.
Rather than just leaving some macros undefined if none of the scenarios
we checked for match, we should report an error so it's clear what
happened. Otherwise the places the macros are used will just not compile
properly, or worse will silently not work correctly.
Change-Id: Ie010d6b6d1b6a1496a45d9ebc0d75d1c804df12f
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35275
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Bobby R. Bruce [Thu, 1 Oct 2020 03:53:14 +0000 (20:53 -0700)]
misc: Re-add -Werror for the gem5 20.2 development
This reverts commit
2a4357bfd0c688a19cfd6b1c600bb2d2d6fa6151,
https://gem5-review.googlesource.com/c/public/gem5/+/35455
Change-Id: I10de506658bcad542abbb6d2b4f0c416d55bc121
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35495
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
Bobby R. Bruce [Thu, 1 Oct 2020 03:39:06 +0000 (20:39 -0700)]
misc: Merge branch 'release-staging-v20.1.0.0' into develop
Change-Id: I3694b251855b969c7bd3807f34e1b4241d47d586
Bobby R. Bruce [Wed, 30 Sep 2020 18:14:02 +0000 (11:14 -0700)]
misc: Updated version to 20.1.0.0
Change-Id: Ic7a37581c58caa354eeecab051122116177d0721
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35456
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>
Bobby R. Bruce [Wed, 30 Sep 2020 17:55:03 +0000 (10:55 -0700)]
scons: Removed -Werror for the gem5 20.1 release
While gem5 compiles on all our supported compilers, removing the -Werror
flag on the stable branch ensures that, as new compilers are released
with stricter warnings, gem5 remains compilable.
Change-Id: I9a356472dc4d729a3fef9f1455814c900103bd66
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35455
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Bobby R. Bruce [Wed, 30 Sep 2020 22:11:17 +0000 (15:11 -0700)]
misc: Updated CONTRIBUTING.md: 'master' -> 'stable'
The `master` branch is now the `stable` branch. This commit updates
CONTRIBUTING.md accordingly.
Change-Id: Ic5231eda336520e8a7260efac6474b4f0af08c37
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35457
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Jason Lowe-Power [Wed, 30 Sep 2020 00:03:08 +0000 (17:03 -0700)]
misc: Add release notes for 20.1
Change-Id: I011ff987e222326dd7f0787c41043578b52b236a
Signed-off-by: Jason Lowe-Power <jason@lowepower.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35375
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Sungkeun Kim [Thu, 24 Sep 2020 11:42:18 +0000 (06:42 -0500)]
sim: Adding missing argument of panic function
panic function call in panicFsOnlyPseudoInst (src/sim/pseudo_inst.cc) needs to be invoked with argument (name).
Jira Issue: https://gem5.atlassian.net/jira/software/c/projects/GEM5/issues/GEM5-786?filter=allissues
Change-Id: Iecacab7b9e0383373b69e9b790fa822d173d29c3
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35040
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Nikos Nikoleris [Tue, 29 Sep 2020 09:28:24 +0000 (10:28 +0100)]
ext: Disable range-loop-analysis warnings for pybind11
Change-Id: I9d9e118c1c70c2f6b11260fff31ecd763e491115
Signed-off-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35296
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
Matthew Poremba [Fri, 25 Sep 2020 20:50:31 +0000 (15:50 -0500)]
mem-ruby: Fixing token port responses in GPUCoalescer
The is a bug in the GPUCoalescer which occurs in the following
situation:
1) An instruction crosses a page boundary causing multiple TLB requests
to be sent.
2) The TLB responses arrive at different times, causing the vector
memory requests to be sent at different times.
3) The first vector memory request completes before the second vector
memory request arrives at the coalescer.
This caused the coalescer to consider the instruction sequence number
done and return its token. Then the second request would arrive and
complete sending back another token. Eventually this increases the token
count beyond the maximum tripping an assert.
This change keeps track of the number of per-lane requests which are
expected to be sent in the vector memory request by looking at the exec
mask of the instruction. The token is not returned until the expected
number of per-lane requests have been coalesced. This fixes "#7" in the
list of issues in JIRA-300. There are also style fixes for local
variables in code nearby the changes in this CL.
Change-Id: I152fd9397920ad82ba6079112908387e71ff3cce
JIRA: https://gem5.atlassian.net/browse/GEM5-300
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35176
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Kyle Roarty <kyleroarty1716@gmail.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Matthew Poremba [Fri, 25 Sep 2020 17:04:38 +0000 (10:04 -0700)]
configs,gpu-compute: Fixes to connect gmTokenPort
When the TokenPort was moved from the GCN3 staging branch to develop the
TokenPort was changed from being the port connecting the ComputeUnit to
Ruby's vector memory port to a sideband port which inhibits requests to
Ruby's vector memory port. As such, it needs to be explicitly connected
as a new port. This changes the getPort method in ComputeUnit to be
aware of the port as well as modifying the example config to connect to
TCPs.
The iteration to connect in the config file was modified since it was
not properly connecting to TCPs each time and Ruby.py does not
explicitly return a list of each MachineType.
Change-Id: Ia70a6756b2af54d95e94d19bec5d8aadd3c2d5c0
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35096
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Matthew Poremba [Fri, 25 Sep 2020 17:05:16 +0000 (10:05 -0700)]
configs: Fix typo in apu_se.py
Change parser.add_options to parser.add_option
Change-Id: I8b0235a1bf9e01e915dec71d85b9da02c477eb34
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35175
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Giacomo Travaglini [Wed, 27 Nov 2019 16:29:52 +0000 (16:29 +0000)]
cpu: Never use a empty byteEnable
The byteEnable variable is used for masking bytes in a memory request.
The default behaviour is to provide from the ExecContext to the CPU
(and then to the LSQ) an empty vector, which is the same as providing
a vector where every element is true.
Such vectors basically mean: do not mask any byte in the memory request.
This behaviour adds more complexity to the downstream LSQs, which now
have to distinguish between an empty and non-empty byteEnable.
This patch is simplifying things by transforming an empty vector into
a all true one, making sure the CPUs are always receiving a non empty
byteEnable.
JIRA: https://gem5.atlassian.net/browse/GEM5-196
Change-Id: I1d1cecd86ed64c53a314ed700f28810d76c195c3
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/23285
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Tested-by: kokoro <noreply+kokoro@google.com>
Giacomo Travaglini [Tue, 10 Dec 2019 10:55:26 +0000 (10:55 +0000)]
arch-x86: Add byteEnable mask in x86 memhelpers
Next patch will make the byteEnable mandatory in the ExecContext
interface so we need to amend the existing helpers to make them
use generate the boolean vector.
JIRA: https://gem5.atlassian.net/browse/GEM5-196
Change-Id: Ib24550aa1e22049487ef4ec2748b786be456d342
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/23529
Tested-by: kokoro <noreply+kokoro@google.com>
Maintainer: Anthony Gutierrez <anthony.gutierrez@amd.com>
Reviewed-by: Anthony Gutierrez <anthony.gutierrez@amd.com>
Giacomo Travaglini [Mon, 9 Dec 2019 14:02:18 +0000 (14:02 +0000)]
arch-arm: Using new "raw" memhelpers
JIRA: https://gem5.atlassian.net/browse/GEM5-196
Change-Id: Ie5ea0fc845a8f6d77a5723bacaff25ba04562f9c
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/23528
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Giacomo Travaglini [Mon, 9 Dec 2019 14:01:33 +0000 (14:01 +0000)]
arch: Add raw read/writeMem helpers
With some exceptions (in arm/x86) the standard memory read/write interface
for instructions relies upon the helper functions in
src/arch/generic/memhelpers.hh
which wrap the ExecContext interface.
(readMem, writeMem...)
Those helpers rely on the source/destination data to be provided (as
expected) but not on the size of the transaction. The latter gets
evaluated via the host size of the source/destination data
(sizeof(MemT)).
For this reason some instructions, which are instead using an
incompatible MemT data (as an example, a SIMD operation loading data in
an array of integers), make direct use of the ExecContext interface,
which is simply requesting for a pointer and a number of bytes.
Some other instructions are using the ExecContext interface since the
helpers do not accept a byteEnable argument.
This patch is adding some helpers to address these issues. The idea is
to deprecate direct usage of the ExecContext APIs.
These new wrappers do not work with the type detection mechanism
to evaluate the number of bytes we are accessing.
JIRA: https://gem5.atlassian.net/browse/GEM5-196
Change-Id: I5b822d278bdf325a68a01aa1861b6487c6628245
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/23527
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Gabe Black <gabeblack@google.com>
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Maintainer: Gabe Black <gabeblack@google.com>
Giacomo Travaglini [Mon, 9 Dec 2019 14:00:47 +0000 (14:00 +0000)]
arch: Do value-initialization for MemOperand
With this patch we are properly initializing the MemOperand
variable, with value-initialization.
Prior to this patch, the variable was simply default-initialized.
For a native type, this means the variable is undefined.
With value initialization we are sure the variable is not undefined
and the compiler doesn't complain about it.
JIRA: https://gem5.atlassian.net/browse/GEM5-196
Change-Id: I55a5b8f047b8e691529807b61d38f0d47fcfe61e
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/23526
Tested-by: kokoro <noreply+kokoro@google.com>
Tested-by: Gem5 Cloud Project GCB service account <345032938727@cloudbuild.gserviceaccount.com>
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Bobby R. Bruce [Fri, 25 Sep 2020 17:25:43 +0000 (10:25 -0700)]
tests,misc: Updated TestLib and boot-tests for gzipped imgs
In efforts to reduce storage costs and download times, the images hosted
by us have been gzipped. The TestLib framework has therefore been
extended to decompress gzipped files after download.
The x86-boot-tests are, at present, the only tests which use the gem5
images. These tests have been updated to download the gzipped image.
Change-Id: I6b2dbe9472a604148834820db8ea70e91e94376f
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35257
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Tue, 29 Sep 2020 07:39:01 +0000 (00:39 -0700)]
arch: Wrap a docstring in isa_parser.py.
This brings the ISA parser in line with the style guide. Note that the
docstring needs to be a single string literal for python to consider it
a docstring, and the parser itself needs each line of the docstring to
be a rule in its CFG. We can accomplish both by taking advantage of the
fact that two directly adjacent quoted strings are treated as a single
string literal by python, and by escaping the newline so that they're
actually considered adjacent.
Change-Id: I7f4d252998877808425aafb0159600ba4c3bf9ad
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35276
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Maintainer: Giacomo Travaglini <giacomo.travaglini@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Tue, 1 Sep 2020 04:13:06 +0000 (21:13 -0700)]
base: Expose the ObjectFile class to python.
This will make it possible to inspect a binary and determine, for
example, what architecture or operating system it was compiled for.
Change-Id: Ib40f1e1c02448dc5bf084bb0dd98d3767f463fef
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/33899
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Adrian Herrera [Tue, 29 Sep 2020 09:31:49 +0000 (10:31 +0100)]
dev-arm: SMMUv3, default CMDQ entries to 128
From Linux
587e6c10a7ce89a5924fdbeff2ec524fbd6a124b, SMMUv3
implementations in 64-bit platforms must report a minimum of 128 CMDQ
entries via SMMU_IDR1. Otherwise, the SMMUv3 Linux driver returns -ENXIO.
Change-Id: I304aac1b734515b3077003e8d67cc19730afc67f
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35297
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Maintainer: Giacomo Travaglini <giacomo.travaglini@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Bobby R. Bruce [Mon, 28 Sep 2020 18:56:19 +0000 (11:56 -0700)]
scons,python: Add warning for when python3-config is not used
We cannot say for certain whether 'python-config' is python2 or python3,
but this patch will produce a warning if 'python3-config' is not used,
stating that support for python2 will be dropped in future releases of
gem5.
Change-Id: I114da359c8768071bf7dd7f2701aae85e3459678
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35256
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Bobby R. Bruce [Tue, 22 Sep 2020 20:05:02 +0000 (13:05 -0700)]
tests: Removing gem5/hello_se/ref/simerr
This is not needed in any comparison we make. It was probably added in
error.
Change-Id: Ie771654f73d101d0ef90ca6e2864a7cb684b3919
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34996
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Bobby R. Bruce [Mon, 28 Sep 2020 18:23:38 +0000 (11:23 -0700)]
scons,python: Add python2-config to PYTHON_CONFIG
PYTHON_CONFIG can be python2-config as well as python2.7-config.
Change-Id: I482cb922fcf26b37f67f2aca392e04968ca144bd
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35255
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Bobby R. Bruce [Mon, 21 Sep 2020 20:51:19 +0000 (13:51 -0700)]
scons,python: Prioritize Python3 for PYTHON_CONFIG
Change-Id: I0ac4d90b93f2e0a9384216f759937f7b0aa23d41
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34899
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Bobby R. Bruce [Tue, 22 Sep 2020 19:37:34 +0000 (12:37 -0700)]
python: Flush the simulation stdout/stderr buffers
Occasionally gem5's stdout/stderr, when run within the TestLib
framework, will be shuffled. This is resolved by flushing the
stdout/stderr buffer before and after simulation.
In addition to this, the verifier.py has been improved to remove
boilerplate gem5 code from the stdout comparison.
Change-Id: I04c8f9cee4475b8eab2f1ba9bb76bfa3cfcca6ec
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34995
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Mon, 13 Apr 2020 04:58:55 +0000 (21:58 -0700)]
x86: Use the common pseudoInst dispatch function.
Instead of hand invoking each individual pseudo inst. New instructions
added in the future will automatically become available without a lot of
extra hand implementation. It also simplifies the x86 ISA description.
Change-Id: Ibb671dc2656e61679b7ed016c51a6c879e12910a
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/27789
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Timothy Hayes [Wed, 23 Sep 2020 13:39:46 +0000 (14:39 +0100)]
arch-arm: Instantiate a single HTM checkpoint at ISA::startup
Change-Id: I48cc71dce607233f025387379507bcd485943dde
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35016
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Giacomo Travaglini <giacomo.travaglini@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Timothy Hayes [Wed, 23 Sep 2020 11:10:37 +0000 (12:10 +0100)]
cpu: Allow storing an invalid HTM checkpoint
Commits
02745afd and
f9b4e32 introduced a mechanism for creating checkpoint
objects for hardware transactional memory (HTM) and Arm TME. Because the
checkpoint object also contains the local UID of a transaction, it is
needed before any architectural checkpointing takes places. This caused
segfaults when running HTM codes.
This commit allows ISAs to allocate a checkpoint once at the beginning
of simulation. In order to do that we need to remove the validity check
assertion; the cpt will become valid only after a first successfull
transaction start
Change-Id: I233d01805f8ab655131ed8cd6404950a2bf6fbc7
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35015
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Giacomo Travaglini <giacomo.travaglini@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Giacomo Travaglini [Thu, 14 May 2020 15:29:23 +0000 (16:29 +0100)]
ext: Add timing indications to every TestCase
The log_call helper is now accepting a time parameter (dictionary). If
the param is not None, the function will fill the timing indications
(user and system time) for the TestCase.
There are some TestCases whose user time is not of our interest; for
example we don't really care about the cpu time of a stdout diff
(MatchStdout tests). In those cases the resulting cpu time in the
generated JUnit file (results.xml) will be 0.
JIRA: https://gem5.atlassian.net/browse/GEM5-548
Change-Id: I53c1b59f8ad93900aeac06197e39189c00a9053c
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/32653
Tested-by: kokoro <noreply+kokoro@google.com>
Nikos Nikoleris [Thu, 17 Sep 2020 17:09:32 +0000 (18:09 +0100)]
mem: Fix some reference use in range loops
This change fixes two cases of range loops, one where we can't use
lvalue reference, and one more where we have to use an lvalue
reference as we can't create a copy. In both cases clang would warn.
Change-Id: I760aa094af66be32a150bad37acc21d6fd512a65
Signed-off-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34776
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Sun, 27 Sep 2020 01:26:02 +0000 (18:26 -0700)]
misc: Update attribute syntax, and reorganize compiler.hh.
This change replaces the __attribute__ syntax with the now standard [[]]
syntax. It also reorganizes compiler.hh so that all special macros have
some explanatory text saying what they do, and each attribute which has a
standard version can use that if available and what version of c++ it's
standard in is put in a comment.
Also, the requirements as far as where you put [[]] style attributes are
a little more strict than the old school __attribute__ style. The use of
the attribute macros was updated to fit these new, more strict
requirements.
Change-Id: Iace44306a534111f1c38b9856dc9e88cd9b49d2a
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35219
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Sat, 26 Sep 2020 23:24:17 +0000 (16:24 -0700)]
base,mem: Use the standard [[deprecated]] attribute.
The [[deprecated]] attribute is now standard, and so we don't need to
wrap it in our own macro any more.
Change-Id: I363df9a9c6b820dee8c21b1716335c0d15fbc62d
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35216
Maintainer: Gabe Black <gabeblack@google.com>
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Tested-by: kokoro <noreply+kokoro@google.com>
Ciro Santilli [Wed, 23 Sep 2020 18:54:53 +0000 (19:54 +0100)]
cpu: make ExecSymbol show the symbol in addition to address
Before this commit, ExecSymbol would show only the symbol and no address:
0: system.cpu: A0 T0 : @_kernel_flags_le_lo32+6 : mrs x0, currentel
After this commit, it shows the symbol in addition to the address:
0: system.cpu: A0 T0 : 0x10 @_kernel_flags_le_lo32+6 : mrs x0, currentel
Change-Id: I665802f50ce9aeac6bb9e174b5dd06196e757c60
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35077
Reviewed-by: Richard Cooper <richard.cooper@arm.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Sat, 26 Sep 2020 23:33:28 +0000 (16:33 -0700)]
base,dev: Use the standard attribute [[noreturn]].
The [[noreturn]] attribute has been standard since c++11, and so we
don't (and haven't for a while) need to wrap it in a macro.
Change-Id: Ifba62c87c19224bb366e93ebba685a063cc750ce
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35218
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Sat, 26 Sep 2020 23:30:28 +0000 (16:30 -0700)]
arch,base,cpu,dev: Get rid of the M5_DUMMY_RETURN macro.
This macro probably would have been defined to "return" in some cases,
to be put after a call to a function that doesn't return so that the
compiler wouldn't think control would reach the end of a non-void
function. It was only ever defined to expand to nothing, and now that
[[noreturn]] is a standard attribute, it should never be needed going
forward.
Change-Id: I37625eab72deeaede77f9347116b9fddd75febf7
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35217
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Sat, 26 Sep 2020 23:00:35 +0000 (16:00 -0700)]
arm,base,gpu: Use std::make_unique instead of m5::make_unique.
Now that we're using c++14, we can just assume that std::make_unique
exists. We no longer have to conditionally inject our own version.
Change-Id: I5d851afb02dd05c7af93864ffec3b3184f3d4ec8
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35215
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Earl Ou [Tue, 22 Sep 2020 06:06:30 +0000 (14:06 +0800)]
base,sim: implement a faster mutex for single thread case
This change applies an atomic variable to check if we really need to
obtain a mutex, and uses a condition variable to notify.
See about 5% improvement in the simulation speed.
Change-Id: I7e165987dcb587b27fae90978b9b3fde6f5563ef
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34915
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Reviewed-by: Richard Cooper <richard.cooper@arm.com>
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Fri, 25 Sep 2020 07:56:24 +0000 (00:56 -0700)]
mem: When loading an image directly in memory, use the right CL size.
Some code was added fairly recently which would load a memory image
into a memory directly in order to make it easier to set up ROMs.
Unfortunately, that code accidentally used the image size instead of
the cache line size when setting up the port proxy which would actually
write the data. This happens to work when the image size is a power of
two since that's all the proxy checks for, but there's no guarantee
that every image will be sized that way.
This change instead looks into the system object, retrieves the cache
line size from it, and uses that to set up the port proxy.
Change-Id: I227ac475b855d9516e1feb881769e12ec4e7d598
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35155
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Sat, 19 Sep 2020 06:07:00 +0000 (23:07 -0700)]
sim: Remove check whether the System port is connected.
The port will report an error if something tries to use it and
it's not connected. If it isn't needed, there's no reason to force
users to hook something up to it just to satisfy the check.
Change-Id: I0668b8a86c8cb323aba51670fb7914d35acc5198
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34815
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Gabe Black [Fri, 25 Sep 2020 07:59:12 +0000 (00:59 -0700)]
base: When creating an ELF file memory image, ignore empty segments.
Sometimes ELF files have segments in them which are marked as loadable,
but which actually have zero size in memory. When setting up a memory
image we should drop those to avoid confusing other code which tries
to find the footprint of a memory image. No part of these segments,
including their starting address or ending address, need to actually
land on top of memory since they don't actually contain any data.
Change-Id: If8b61d10db139e0f688b6ceabcb8e6a898557469
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35156
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Matthew Poremba [Thu, 24 Sep 2020 18:10:04 +0000 (13:10 -0500)]
configs: Set kvm_map in DRAMInterface in Ruby.py
The kvm_map parameter from AbstractMemory has been moved from MemCtrl
(formerly DRAMCtrl) to DRAMInterface. Assign it to DRAMInterface
instead.
Change-Id: I4508aefcf5eb859d9ffe05c81d85a1b84ee0a196
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35095
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Richard Cooper [Fri, 14 Aug 2020 11:19:55 +0000 (12:19 +0100)]
ext: Monkeypatch os.waitpid to extract CPU time from subprocess
Added utility class `TimedWaitPID` which monkey-patches os.waitpid()
with a functor that has the same signature, but calls os.wait4()
instead. This allows the process's user and system CPU time to be
obtained from the OS when using APIs (such as subprocess) which use
os.waitpid() internally.
The process CPU time is stored within the functor and can be read back
later by calling TimedWaitPID.get_time_for_pid().
JIRA: https://gem5.atlassian.net/browse/GEM5-548
Change-Id: I9ebe9ca1241a4f28c90ad31f672f32ac52786664
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/32652
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Hoa Nguyen <hoanguyen@ucdavis.edu>
Bobby R. Bruce [Fri, 25 Sep 2020 05:28:11 +0000 (22:28 -0700)]
misc: Merge branch 'release-staging-v20.1.0.0' into develop
Change-Id: I656a2d9512b1822a7e8d82606da7a0a5504d6820
Gabe Black [Mon, 7 Sep 2020 07:50:44 +0000 (00:50 -0700)]
base: Minor cleanup of the ChunkGenerator.
Minor style fixes, switched to Addr for some types so they'll definitely
be large enough.
Change-Id: I985004116c48ce6fb236c04e04fe54ed49a68277
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34177
Reviewed-by: Steve Reinhardt <stever@gmail.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Thu, 24 Sep 2020 07:36:21 +0000 (00:36 -0700)]
fastmodel: Update the IRIS ThreadContext base class.
The syscall() method has been removed, and HTM related methods have
been added.
Change-Id: I796c1a554bfd4b1ee01a62c9c7ad403dd699cc0f
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35038
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Maintainer: Giacomo Travaglini <giacomo.travaglini@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Thu, 24 Sep 2020 07:37:04 +0000 (00:37 -0700)]
arm,fastmodel: Update the VExpressFastModel to use ArmInterruptPins.
The HDLCD device now uses an ArmInterruptPin instead of a GIC and
interrupt number parameter.
Change-Id: I31122e66a1c18f61592f3dca214ee057baad8f88
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35039
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Thu, 24 Sep 2020 07:34:54 +0000 (00:34 -0700)]
fastmodel: Update for the isa_traits.hh changes.
arch/arm/isa_traits.hh no longer has using namespace ArmISA, and also
no longer directly or indirectly provides interrupt number related
constants.
Change-Id: Ieda31d1db4f85632a555b2f72ee8bff0aa159eee
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35037
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Maintainer: Giacomo Travaglini <giacomo.travaglini@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Kyle Roarty [Thu, 24 Sep 2020 03:25:02 +0000 (22:25 -0500)]
gpu-compute: set exec_mask for permute,bpermute instructions
This change sets gpuDynInst->exec_mask for permute and bpermute
instructions, fixing a bug where they would never write their data.
permute and bpermute instructions are load instructions that write
to a VGPR. Because of that, they use gpuDynInst->exec_mask when
checking what lanes should write to the VGPR.
gpuDynInst->exec_mask gets set to wf->execMask() as that is what other
load instructions that write to VGPRs do.
Change-Id: Ie443283488cbd2ab9c17fc255e7cc44418353419
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35036
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Anthony Gutierrez <anthony.gutierrez@amd.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Maintainer: Anthony Gutierrez <anthony.gutierrez@amd.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Kyle Roarty [Wed, 16 Sep 2020 21:58:05 +0000 (16:58 -0500)]
gpu-compute: replace uint32_t* casts with bits API calls
The uint32_t* casting was challenging to fully understand what was
being done at a glance. Replaced with calls to various bits functions
as it's functionally equivalent and much more clear.
This also fixes a segfault in GPUInitAbi DPRINTFs from a mis-typed
uint32_t* cast.
Change-Id: Id5d1863942848dd7a9e5e17e8180c33adbc72f15
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34677
Reviewed-by: Anthony Gutierrez <anthony.gutierrez@amd.com>
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Anthony Gutierrez <anthony.gutierrez@amd.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Adrian Herrera [Wed, 8 Jul 2020 16:03:34 +0000 (17:03 +0100)]
dev-arm: FVPBasePwrCtrl, fix vector resizing
(1) ThreadContexts are registered into System in BaseCPU::init.
(2) FVPBasePwrCtrl state is resized based on registered ThreadContexts
in FVPBasePwrCtrl::init.
FVPBasePwrCtrl::init may be called before BaseCPU::init based on the
model names alphabetical order, leading to segmentation faults.
To fix this, (2) is now carried out in FVPBasePwrCtrl::startup.
Change-Id: Ica6c5b7448da556d61aee53f8777a709fcad2212
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35075
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Maintainer: Giacomo Travaglini <giacomo.travaglini@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Sat, 19 Sep 2020 06:28:40 +0000 (23:28 -0700)]
cpu: Use cprintf and C++ type magic to get rid of a THE_ISA.
It should be fine to let operator overloading take care of figuring out
how to print the ExtMachInst type for a given ISA.
Change-Id: I173fd9f49013d92191118775d20344219a69337e
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34822
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Fri, 18 Sep 2020 05:33:37 +0000 (22:33 -0700)]
scons: Adjust the version of C++ to C++14.
Change-Id: I318d337fc61bca0ae40413c23ee36d59d45a79bc
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34820
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Reviewed-by: Richard Cooper <richard.cooper@arm.com>
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Earl Ou [Thu, 17 Sep 2020 06:31:44 +0000 (14:31 +0800)]
systemc: avoid mutex lock in non async cases
Avoid acquiring a mutex lock in case there is no async update in the
scheduler. This helps increasing simulation speed by about 4%.
Change-Id: I971c7bf1a1eeb46208eeee6e5da6385c907092b3
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34695
Reviewed-by: Earl Ou <shunhsingou@google.com>
Maintainer: Earl Ou <shunhsingou@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Giacomo Travaglini [Fri, 18 Sep 2020 08:01:34 +0000 (09:01 +0100)]
dev-arm: Implement GICv4.1 GICD_TYPER2 as RES0
If GICv4.1 is not implemented (our case) the register should be
treated as RES0
Change-Id: Ia60f6dce9741c34bf167805f60c3fc8bf0897510
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-by: Ciro Santilli <ciro.santilli@arm.com>
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34875
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Giacomo Travaglini [Thu, 17 Sep 2020 15:46:27 +0000 (16:46 +0100)]
arch-arm: TLBI ALLE2IS should broadcast to the IS domain
This was implemented as a normal ALLE2 hence affecting the
current PE only
Change-Id: Ib369dd5a4b738daf96a01b5535d7481a97bb3730
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34795
Tested-by: kokoro <noreply+kokoro@google.com>
Ciro Santilli [Fri, 18 Sep 2020 11:12:54 +0000 (12:12 +0100)]
util: add pkg-config to ubuntu all-dependencies Dockerfiles
Without this, HDF5 is not built, e.g. a run such as
http://jenkins.gem5.org/job/Nightly/68/console contains:
Checking for hdf5-serial using pkg-config... pkg-config not found
Checking for hdf5 using pkg-config... pkg-config not found
Checking for H5Fcreate("", 0, 0, 0) in C library hdf5... (cached) no
Warning: Couldn't find any HDF5 C++ libraries. Disabling
HDF5 support.
This is done to increase coverage a bit, and serve as dependency
documentation to users.
Change-Id: Ibf820a3aa76c29eeee1201646924ee181615a162
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34777
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Bobby R. Bruce [Tue, 22 Sep 2020 01:48:12 +0000 (18:48 -0700)]
misc: Merge branch 'release-staging-v20.1.0.0' into develop
Change-Id: I1b33eeda67e7641ab71935e140fd24d4735be596
Bobby R. Bruce [Mon, 21 Sep 2020 19:13:08 +0000 (12:13 -0700)]
tests,base: Fixed unittests for .fast
unittests.fast, unittests.prof, and unittests.perf had failing tests due
to the stripping of asserts via compiler optimization. This patch alters
the unittests to skip these tests when TRACING_ON == 0.
Change-Id: I2d4ab795ecfc2c4556b5eb1877635409d0836ec6
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34898
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Sun, 23 Aug 2020 08:33:22 +0000 (01:33 -0700)]
arch,cpu,sim: Route system calls through the workload.
System calls should now be requested from the workload directly and not
routed through ExecContext or ThreadContext interfaces. That removes a
major special case for SE mode from those interfaces.
For now, when the SE workload gets a request for a system call, it
dispatches it to the appropriate Process object. In the future, the
ISA specific Workload subclasses will be responsible for handling system
calls and not the Process classes.
For simplicity, the Workload syscall() method is defined in the base
class but will panic everywhere except when SEWorkload overrides it. In
the future, this mechanism will turn into a way to request generic
services from the workload which are not necessarily system calls. For
instance, it could be a way to request handling of a page fault without
having to have another PseudoInst just for that purpose.
Change-Id: I18d36d64c54adf4f4f17a62e7e006ff2fc0b22f1
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/33282
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Sun, 23 Aug 2020 06:33:10 +0000 (23:33 -0700)]
sim: Create a Workload object for SE mode.
The workload object is still optional for the sake of compatibility,
even though it probably shouldn't be in the long term. If a simulation
is just a collection of components with nothing in particular running on
it, for instance driven by a traffic generator, should it even have a
System object in the first place?
Change-Id: I8bcda72bdfa3730248226fb62f0bba9a83243d95
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/33278
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Mon, 7 Sep 2020 07:51:54 +0000 (00:51 -0700)]
dev: Stop using the OS page size in the IDE controller.
This size was used to break up DMA transactions so that a single
transaction would not cross a page boundary. This was because on Alpha,
there was an actual page table which translated between PCI and DMA
address spaces. On all currently implemented systems, the mapping is
simply to add a scalar offset, so it's not possible for a legal region
of memory to be contiguous in one space but not in the other.
Additionally, if it *was* possible for there to be a mismatch, it was
only coincidence that Alpha used a page table which had the same sized
pages as it normally used. There is no requirement that there even would
be fixed sized pages in the first place.
To avoid this artificial dependency between the IDE controller and the
ISA, this change simply changes the chunk size for DMA accesses to 4K.
That's the page size at least on x86 and probably other architectures,
and will be a pretty close approximation of the previous behavior.
It's possible that even having this chunking in the first place is
unnecessary and functionally useless, but there are some checks which
happen between chunks, and changing how big they are would change the
frequency of those checks. For instance, the controller/disk may not
notice in the same amount of time if a DMA was cancelled somehow.
Change-Id: I1ec840d1f158c3faa31ba0184458b69bf654c252
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34178
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Fri, 18 Sep 2020 05:31:50 +0000 (22:31 -0700)]
scons: Increase the minimum clang version to 3.9.
This matches what's documented elsewhere. We *need* version 3.4 to
support c++14, but we support only as far back as 3.9. Also, the
argument to set c++14 as the standard is different in 3.4 and earlier
(-std=c++1y), so it makes life slightly easier to move past it to 3.9.
Change-Id: I66fa578dd3222c62907496a888f8068ed0918c7b
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34819
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Fri, 18 Sep 2020 03:50:27 +0000 (20:50 -0700)]
base: Use M5_UNLIKELY with conditional DPRINTF family functions.
Most DPRINTFs will be skipped over most of the time, and when they
aren't they'll already have overhead from string handling, output to the
console and/or a file, etc, which will drown out the behavior of a
branch.
Change-Id: I5475d7b5add63b44f60c0a1d46b4b14e6bf30fd3
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34818
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Fri, 18 Sep 2020 03:46:19 +0000 (20:46 -0700)]
base: Use M5_UNLIKELY for conditional panic, etc., macros.
panic_if and fail_if should happen at most once in any given simulation,
and warn_if, etc., should still not happen most of the time.
Change-Id: Iaa6cb03c11b86d84f51cc4738efb8f203de4201c
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34817
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Fri, 18 Sep 2020 03:44:47 +0000 (20:44 -0700)]
base: Add M5_LIKELY and M5_UNLIKELY macros to compiler.hh.
The clang/gcc implementation uses the nonstandard __builtin_expect(). In
C++20, new standard attributes can be used instead. We can't use those
yet though.
Change-Id: Idd2541a7eca0d97ac6c643abbf2910cbc343d7e5
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34816
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Sat, 19 Sep 2020 06:27:27 +0000 (23:27 -0700)]
cpu: Clear out some unnecessary ISA dependence in thread_context.hh.
The ISA version of the ISA class isn't used any more. Neither is
TheISA::MachInst.
Change-Id: I9085ad2b51ba19bf6e5bb17769dd048ac6384fec
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34821
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Mon, 7 Sep 2020 07:08:58 +0000 (00:08 -0700)]
gpu: Stop using TheISA in the GPU TLB.
This class is defined inside the X86ISA namespace, so there's no point
in pretending it's generic. Remove TheISA and let the code access what
it needs from X86ISA naturally since it's there already.
Change-Id: I21b5d2d2b9af6aa0c10ddbb5b3ddca1692188dcc
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34173
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Ciro Santilli [Mon, 14 Sep 2020 15:57:50 +0000 (16:57 +0100)]
tests: cleanup all SE tests previously moved to gem5-resources
The move was done at:
https://gem5-review.googlesource.com/c/public/gem5-resources/+/32074
All files keep exact same name, or are obvious renames like underscore to
-. threads/ is the only non obvious and remaps to src/simple/std_thread.cpp
Only m5-exit is left because it does squashfs generation which wasn't yet
moved.
Change-Id: I72ad104c9311c2f81af49458bdd44e24a6bafc0a
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34476
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Fri, 18 Sep 2020 03:39:53 +0000 (20:39 -0700)]
systemc: Add a missing override.
A recent change accidentally left off the override, upsetting gcc.
Change-Id: I78cf1969aa6ac462539a2793a8a91dea32002f3a
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34756
Maintainer: Gabe Black <gabeblack@google.com>
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Kyle Roarty [Tue, 15 Sep 2020 13:57:39 +0000 (08:57 -0500)]
gpu-compute: Fix deadlock in fetch_unit after branch instruction
The following deadlock was occuring in fetch_unit w/timingSim:
1. exec() is called, a wave is ready to fetch, so it sets pendingFetch
2. A packet is sent to ITLB to fetch for that wave
3. The wave executes a branch, causing the fetch buffer to be cleared
4. The packet is handled, and fetch() is called. However, because the
fetch buffer was cleared, it returns doing nothing.
5. exec() gets called again, but the wave will never be scheduled to
fetch, as pendingFetch is still set to true.
This patch clears pendingFetch (and dropFetch) before returning in fetch()
when the fetch buffer has been cleared.
dropFetch needed to be cleared otherwise gem5 would crash.
Change-Id: Iccbac7defc4849c19e8b17aa2492da641defb772
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34555
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Anthony Gutierrez <anthony.gutierrez@amd.com>
Maintainer: Anthony Gutierrez <anthony.gutierrez@amd.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Bobby R. Bruce [Wed, 16 Sep 2020 16:45:13 +0000 (09:45 -0700)]
util: Removed libelf-dev dep from Dockerfiles
The libelf-dev dependency is no longer required in our Dockerfiles.
This reverts commit
0cf67fb36281b17956d4dc10f05054bf711b4ba3,
https://gem5-review.googlesource.com/c/public/gem5/+/33596.
The libelf-dev dependency has been kept for the "all_dependencies"
Dockerfiles.
The corresponding Docker images have been built and uploaded to:
https://gcr.io/gem5-test.
Change-Id: Iacbd8240f69d476ad3a649baaccb6b85fec2487c
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34676
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Sat, 11 Apr 2020 06:06:16 +0000 (23:06 -0700)]
util: Add an unmap_m5_mem() function to the m5 util's m5_mmap.*.
This cleans up the mmap-ing. This is primarily used for testing since
the tests may end up mmap-ing the backing file many times, and we don't
want all those earlier mappings lying around.
This change also makes the original mmap-ing function close the file it
opens, since the man page for mmap explicitly says you can do that and
not lose the mapping. That means we don't have to keep track of the file
descriptor which corresponds to the mmap-ed file when we do the
unmapping, and it's slightly cleaner in general.
Change-Id: I90e3e755cebf3d03e2bf644adf8ef3e157236172
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/27750
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Pouya Fotouhi <pfotouhi@ucdavis.edu>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Fri, 10 Apr 2020 09:46:33 +0000 (02:46 -0700)]
util: Add a "semi" call type unit test to the m5 utility.
This is largely similar to the "inst" call type test since it's also
another form of illegal instruction, but there's more checking to do
since the way arguments are passed is more complex.
Change-Id: Ie61bb4da8befab579c3044fd2ddee753926de174
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/27749
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Earl Ou [Wed, 16 Sep 2020 07:17:26 +0000 (15:17 +0800)]
systemc: self-manage TimeSlot in Scheduler
TimeSlot is new and deleted frequently. Having a recycling memory
manager can help saving the time spent new and delete. Tested and see
about 4% improvement in simulation speed.
Change-Id: I0ab173168336a883b85f768d7fdf07a936a14d69
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34615
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Earl Ou [Tue, 15 Sep 2020 05:07:25 +0000 (13:07 +0800)]
systemc: use list instead of map in scheduler
The queue in systemC scheduler is implemented as a std::map. This provides
the best big-O solution. However, most of simulation usecases has very
small number of pending events. This is expected as we usually only trigger a
few new events after some events are processed. In such scenario, we
should optimize for insert/erase instead of search. This change use
std::list instead of std::map.
As a proof, we can find that gem5's original event_queue is also
implemented as a list instead of tree.
We see 5% speed improvement with the example provided by Matthias Jung:
https://gist.github.com/myzinsky/
557200aa04556de44a317e0a10f51840
Change-Id: I75c30df9134e94df42fd778115cf923488ff5886
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34515
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Bobby R. Bruce [Thu, 17 Sep 2020 00:16:17 +0000 (17:16 -0700)]
misc: Merge branch 'release-staging-v20.1.0.0' into develop
Change-Id: I8c3277af7903f0b055b26e497139455a03678524
Jason Lowe-Power [Wed, 16 Sep 2020 17:12:37 +0000 (10:12 -0700)]
misc: Add Matt Poremba as GPU maintainer
Change-Id: I90494955b6db628695ef8a42111977decba27618
Signed-off-by: Jason Lowe-Power <jason@lowepower.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34655
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Matthew Poremba <matthew.poremba@amd.com>
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Jason Lowe-Power [Wed, 16 Sep 2020 00:59:51 +0000 (17:59 -0700)]
configs: Add special case in MemConfig
SimpleMemory doesn't implement a full MemCtrl interface. Thus, like the
NVM and HMC memories, we need to add a special case to MemConfig.py. The
--mem-type command line option now works for SimpleMemory and all of the
DRAM interfaces (it does not work for the NVM interfaces, though).
Issue-on: https://gem5.atlassian.net/browse/GEM5-777
Change-Id: I6d60649215be324bdd2a104b1976752f936c960e
Signed-off-by: Jason Lowe-Power <jason@lowepower.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34595
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Sun, 30 Aug 2020 09:40:21 +0000 (02:40 -0700)]
arch,cpu: Get rid of the IsMemRef StaticInst flag.
A comment at the top of StaticInstFlags.py says that if IsMemRef is set,
exactly one of IsStore or IsLoad will be set. That's not strictly true
since IsAtomic may be set as well, in which case neither IsStore or
IsLoad will be set (in one example I found).
The isMemRef accessor still exists, and now just ors the IsStore,
IsLoad, and IsAtomic flags.
Change-Id: Ic5ff104da68978273977a6eff2abab5dd0ae7fda
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/33744
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Wed, 26 Aug 2020 04:48:04 +0000 (21:48 -0700)]
base: Create a SConscript for the loader subdirectory.
These files had been handled in base/SConscript, but there are enough of
them that they deserve their own.
Change-Id: I0c4166d8ff3c761c25940d2af5d7f0a9a6c874fa
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/33898
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
Gabe Black [Sun, 30 Aug 2020 09:28:33 +0000 (02:28 -0700)]
arch,cpu: Rearrange StaticInst flags for memory barriers.
There were three different StaticInst flags for memory barriers,
IsMemBarrier, IsReadBarrier, and IsWriteBarrier. IsReadBarrier was never
used, and IsMemBarrier was for both loads and stores, so a composite of
IsReadBarrier and IsWriteBarrier.
This change gets rid of IsMemBarrier and replaces by setting
IsReadBarrier and IsWriteBarrier at the same time. An isMemBarrier
accessor is left, but is now implemented by checking if both of the
other flags are set, and renamed to isFullMemBarrier to make it clear
that it's checking both for both types of barrier, not one or the other.
Change-Id: I702633a047f4777be4b180b42d62438ca69f52ea
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/33743
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Earl Ou [Fri, 11 Sep 2020 01:21:52 +0000 (09:21 +0800)]
base: use setjmp to speed up fiber
ucontext is an order of magnitude slower compared to most of the fiber
implementation, mainly due to the additional signal mask operation.
This change applies the trick provided in
http://www.1024cores.net/home/lock-free-algorithms/tricks/fibers,
which uses _setjmp/_longjmp to switch between contexts created by
ucontext.
Combine with NodeList improvement, we see 81% speed improvement with the
example provided by Matthias Jung:
https://gist.github.com/myzinsky/
557200aa04556de44a317e0a10f51840
Compared with Accellera's SystemC, gem5 SystemC was originally 10x
slower, and with this change it's about 1.8x.
Change-Id: I0ffb6978e83dc8be049b750dc1baebb3d251601c
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34356
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Tue, 15 Sep 2020 02:46:47 +0000 (19:46 -0700)]
mem-ruby: Remove conditional includes based on THE_ISA in ruby.
These were including instruction class definitions from x86 for some
reason. There was no code in those .cc files which actually used
anything from them, as evidenced by the fact that the GCN3_X86 build
still works. No other code in the file was conditionally compiled as of
today.
Change-Id: I3cef8348fb601dd7af67665cf64bbf514c91c3db
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34577
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Tue, 15 Sep 2020 02:45:13 +0000 (19:45 -0700)]
gpu: Fix a syntax error in X86GPUTLB.py.
The recent changes which removed master/slave terminology also
accidentally deleted an "=", making the syntax in that file illegal.
Change-Id: I50aa945f0f66765db36775380b98a88caff23c13
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34576
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Tue, 15 Sep 2020 02:40:42 +0000 (19:40 -0700)]
arm: Use zero initialization for the BigRegVect types.
These were being initialized with BigRegVect brv = {0}, which made the
compiler complain because there is internal structure. The first element
of the union is actually an array, and this was telling it to initialize
that array to scalar 0. It was warning about this which was breaking the
build.
Instead, use zero initlization like BigRegVect brv = {}. This
initializes the first element of the union to all zeroes, with all
padding bits initialized to zero as well.
This satisfies the compiler and avoids a build error.
Change-Id: I31e7a8730c538637ff2e0c7fb00a4e12ed05e074
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34575
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Sun, 30 Aug 2020 08:24:50 +0000 (01:24 -0700)]
mips,cpu: Eliminate the unused IsIndexed StaticInst flag.
It's set by some MIPS instructions, but does not have an accessor in
StaticInst and is not used by anything.
Change-Id: I3466f7d2723fb1b0ac195064867e3840e3a8f21b
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/33735
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Tue, 15 Sep 2020 03:15:37 +0000 (20:15 -0700)]
mem: Remove #if THE_ISA in the AbstractMemory class.
This used to guard the extraction of the endianness when tracing memory
accesses. Since that's now always possible even in NULL_ISA, we don't
need conditional compilation.
Change-Id: Ie5ec76f5b0f27dd4123bc0f0a4c02438bed629ad
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34499
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Maintainer: Gabe Black <gabeblack@google.com>
Gabe Black [Sun, 30 Aug 2020 09:51:21 +0000 (02:51 -0700)]
cpu: Get rid of the unused IsMicroBranch StaticInst flag.
This flag was never set, nor read.
Change-Id: I74506c220d96b53dcd44740639286b1dbbe84d2e
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/33742
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Gabe Black [Sun, 30 Aug 2020 09:48:37 +0000 (02:48 -0700)]
x86,cpu: Get rid of the unused IsCC StaticInst flag.
This flag was set when some registers were used in x86, but never
actually checked by anything.
Change-Id: Id0f9847aeca5017455929ab4bbf28210288a3553
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/33741
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Gabe Black [Sun, 30 Aug 2020 08:46:31 +0000 (01:46 -0700)]
mips,cpu: Get rid of the IsDpsOp StaticInst flag.
This flag was set by MIPS for a few instructions, but didn't have an
accessor in StaticInst and was never used for anything.
Change-Id: I153cedde0d16cb1d78b2705bd7340ebfd10e4fb6
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/33740
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Bobby R. Bruce [Tue, 15 Sep 2020 16:03:55 +0000 (09:03 -0700)]
misc: Merge branch 'release-staging-v20.1.0.0' into develop
Change-Id: I1eacbc5719aa85c5a7650ec33fd99f673fdf443d
Bobby R. Bruce [Tue, 15 Sep 2020 03:29:24 +0000 (20:29 -0700)]
cpu,misc: Revert problematic terminology renames in BaseCPU
Due to gem5's use of duck-typing, we must termorarly revert the
terminology in BaseCPU back to master/slave to avoid issues.
This fixes https://gem5.atlassian.net/browse/GEM5-775.
Change-Id: Idf1cb99aa9568ee70943ebec96f27394d8167f8c
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34495
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>
Earl Ou [Fri, 11 Sep 2020 01:03:04 +0000 (09:03 +0800)]
systemc: avoid dynamic_cast in the critical path
NodeList is in the critical path of the systemc scheduler in gem5. A
unnecessary dynamic_cast in the NodeList slow down the event process by
about 15%. Fix the issue by avoiding dynamic_cast.
We see about 15% speed improvement on the example provided by Matthias Jung:
https://gist.github.com/myzinsky/
557200aa04556de44a317e0a10f51840
Compare with Accellera implementation, gem5 version is originally 10x
slower and now it's about 8.5x slower.
Change-Id: I3b4ddca31e58e1d4e96144a4021b0a5bb956fda4
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34355
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Gabe Black [Sun, 30 Aug 2020 08:38:47 +0000 (01:38 -0700)]
mips,cpu: Get rid of the IsIprAccess StaticInst flag.
This was set by MIPS in two places, I think largely just because it was
available. This flag refers to IPRs which are an Alpha concept. In the
O3 CPU, IsIprAccess was used as a possible indicator to determine if an
instruction IsSerializeBefore, but we've already got a flag for that. In
the minor CPU, which hasn't been made to work with MIPS as far as I
know, it was used in a condition but not mentioned in the comment
alongside the condition. I think there it was added for the sake of
Alpha.
This change eliminates that flag and removes it from the O3 and minor
CPUs. In the MIPS ISA description, the instructions that were marked as
IsIprAccess have now been marked as IsSerializeBefore since, if there
was a real reason for them to be marked as IsIprAccess, it would have
been to get it them to work in O3, and there IsSerializeBefore gets
equivalent behavior.
Change-Id: Ia874cde12fa70b998d3e638458f13d69798d40b7
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/33739
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Gabe Black [Sun, 30 Aug 2020 08:32:43 +0000 (01:32 -0700)]
mips,cpu: Get rid of the IsERET StaticInst flag.
This is set by MIPS but doesn't have an accessor in StaticInst, and
isn't used by anything.
Change-Id: Ie28d2df134dcf264bca17c9c66dd32515a240492
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/33738
Maintainer: Gabe Black <gabeblack@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>