[gem5-dev] Cron m5test@zizzer /z/m5/regression/do-regression quick

2014-08-26 Thread Cron Daemon via gem5-dev
* build/ALPHA/tests/opt/quick/se/00.hello/alpha/linux/inorder-timing passed.
* build/ALPHA/tests/opt/quick/se/00.hello/alpha/linux/minor-timing passed.
* build/ALPHA/tests/opt/quick/se/00.hello/alpha/linux/o3-timing passed.
* build/ALPHA/tests/opt/quick/se/00.hello/alpha/linux/simple-atomic passed.
* build/ALPHA/tests/opt/quick/se/00.hello/alpha/tru64/minor-timing passed.
* build/ALPHA/tests/opt/quick/se/00.hello/alpha/linux/simple-timing passed.
* build/ALPHA/tests/opt/quick/se/00.hello/alpha/tru64/simple-atomic passed.
* build/ALPHA/tests/opt/quick/se/00.hello/alpha/linux/simple-timing-ruby 
passed.
* build/ALPHA/tests/opt/quick/se/00.hello/alpha/tru64/simple-timing passed.
* build/ALPHA/tests/opt/quick/se/00.hello/alpha/tru64/o3-timing passed.
* build/ALPHA/tests/opt/quick/se/00.hello/alpha/tru64/simple-timing-ruby 
passed.
* build/ALPHA/tests/opt/quick/se/01.hello-2T-smt/alpha/linux/o3-timing 
passed.
* build/ALPHA/tests/opt/quick/se/20.eio-short/alpha/eio/simple-atomic 
passed.
* build/ALPHA/tests/opt/quick/se/30.eio-mp/alpha/eio/simple-atomic-mp 
passed.
* build/ALPHA/tests/opt/quick/se/20.eio-short/alpha/eio/simple-timing 
passed.
* build/ALPHA/tests/opt/quick/se/30.eio-mp/alpha/eio/simple-timing-mp 
passed.
* build/ALPHA/tests/opt/quick/se/50.memtest/alpha/linux/memtest-ruby passed.
* build/ALPHA/tests/opt/quick/se/60.rubytest/alpha/linux/rubytest-ruby 
passed.
* 
build/ALPHA/tests/opt/quick/fs/10.linux-boot/alpha/linux/tsunami-simple-atomic 
passed.
* 
build/ALPHA/tests/opt/quick/fs/10.linux-boot/alpha/linux/tsunami-simple-atomic-dual
 passed.
* 
build/ALPHA/tests/opt/quick/fs/10.linux-boot/alpha/linux/tsunami-simple-timing-dual
 passed.
 * 
build/ALPHA/tests/opt/quick/fs/10.linux-boot/alpha/linux/tsunami-simple-timing 
passed.
* 
build/ALPHA/tests/opt/quick/fs/80.netperf-stream/alpha/linux/twosys-tsunami-simple-atomic
 passed.
* 
build/ALPHA_MOESI_hammer/tests/opt/quick/se/00.hello/alpha/linux/simple-timing-ruby-MOESI_hammer
 passed.
* 
build/ALPHA_MOESI_hammer/tests/opt/quick/se/00.hello/alpha/tru64/simple-timing-ruby-MOESI_hammer
 passed.
* 
build/ALPHA_MOESI_hammer/tests/opt/quick/se/50.memtest/alpha/linux/memtest-ruby-MOESI_hammer
 passed.
* 
build/ALPHA_MOESI_hammer/tests/opt/quick/se/60.rubytest/alpha/linux/rubytest-ruby-MOESI_hammer
 passed.
* 
build/ALPHA_MESI_Two_Level/tests/opt/quick/se/00.hello/alpha/linux/simple-timing-ruby-MESI_Two_Level
 passed.
* 
build/ALPHA_MESI_Two_Level/tests/opt/quick/se/00.hello/alpha/tru64/simple-timing-ruby-MESI_Two_Level
 passed.
* 
build/ALPHA_MESI_Two_Level/tests/opt/quick/se/50.memtest/alpha/linux/memtest-ruby-MESI_Two_Level
 passed.
* 
build/ALPHA_MESI_Two_Level/tests/opt/quick/se/60.rubytest/alpha/linux/rubytest-ruby-MESI_Two_Level
 passed.
* 
build/ALPHA_MOESI_CMP_directory/tests/opt/quick/se/00.hello/alpha/linux/simple-timing-ruby-MOESI_CMP_directory
 passed.
* 
build/ALPHA_MOESI_CMP_directory/tests/opt/quick/se/00.hello/alpha/tru64/simple-timing-ruby-MOESI_CMP_directory
 passed.
* 
build/ALPHA_MOESI_CMP_directory/tests/opt/quick/se/50.memtest/alpha/linux/memtest-ruby-MOESI_CMP_directory
 passed.
* 
build/ALPHA_MOESI_CMP_directory/tests/opt/quick/se/60.rubytest/alpha/linux/rubytest-ruby-MOESI_CMP_directory
 passed.
* 
build/ALPHA_MOESI_CMP_token/tests/opt/quick/se/00.hello/alpha/linux/simple-timing-ruby-MOESI_CMP_token
 passed.
* 
build/ALPHA_MOESI_CMP_token/tests/opt/quick/se/00.hello/alpha/tru64/simple-timing-ruby-MOESI_CMP_token
 passed.
* 
build/ALPHA_MOESI_CMP_token/tests/opt/quick/se/50.memtest/alpha/linux/memtest-ruby-MOESI_CMP_token
 passed.
* 
build/ALPHA_MOESI_CMP_token/tests/opt/quick/se/60.rubytest/alpha/linux/rubytest-ruby-MOESI_CMP_token
 passed.
* build/MIPS/tests/opt/quick/se/00.hello/mips/linux/inorder-timing passed.
* build/MIPS/tests/opt/quick/se/00.hello/mips/linux/o3-timing passed.
* build/MIPS/tests/opt/quick/se/00.hello/mips/linux/simple-timing passed.
* build/MIPS/tests/opt/quick/se/00.hello/mips/linux/simple-atomic passed.
* build/MIPS/tests/opt/quick/se/00.hello/mips/linux/simple-timing-ruby 
passed.
* build/NULL/tests/opt/quick/se/50.memtest/null/none/memtest passed.
* build/NULL/tests/opt/quick/se/70.tgen/null/none/tgen-dram-ctrl passed.
* build/NULL/tests/opt/quick/se/70.tgen/null/none/tgen-simple-mem passed.
* build/POWER/tests/opt/quick/se/00.hello/power/linux/o3-timing passed.
* build/POWER/tests/opt/quick/se/00.hello/power/linux/simple-atomic passed.
* build/SPARC/tests/opt/quick/se/00.hello/sparc/linux/inorder-timing passed.
* build/SPARC/tests/opt/quick/se/00.hello/sparc/linux/simple-atomic passed.
* build/SPARC/tests/opt/quick/se/00.hello/sparc/linux/simple-timing passed.
* build/SPARC/tests/opt/quick/se/00.hello/sparc/linux/simple-timing-ruby 
passed.
* 

[gem5-dev] changeset in gem5: misc: README direct to website for dependencies

2014-08-26 Thread Andreas Hansson via gem5-dev
changeset d02872388224 in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=d02872388224
description:
misc: README direct to website for dependencies

This patch updates the README to direct the user to the appropriate
sections on the gem5.org website rather than duplicating information.

diffstat:

 README |  69 +++--
 1 files changed, 25 insertions(+), 44 deletions(-)

diffs (89 lines):

diff -r 79fde1c67ed8 -r d02872388224 README
--- a/READMEWed Aug 13 06:57:36 2014 -0400
+++ b/READMETue Aug 26 10:12:04 2014 -0400
@@ -1,54 +1,29 @@
 This is the gem5 simulator.
 
-For detailed information about building the simulator and getting
-started please refer to:
-* The main website: http://www.gem5.org
-* Documentation wiki:   http://www.gem5.org/Documentation 
-* Doxygen generated:http://www.gem5.org/docs
-* Tutorials:http://www.gem5.org/Tutorials
+The main website can be found at http://www.gem5.org
 
+A good starting point is http://www.gem5.org/Introduction, and for
+more information about building the simulator and getting started
+please see http://www.gem5.org/Documentation and
+http://www.gem5.org/Tutorials.
 
-Specific pages of interest are:
-http://www.gem5.org/Introduction
-http://www.gem5.org/Build_System
-http://www.gem5.org/Dependencies
-http://www.gem5.org/Running_gem5
+To build gem5, you will need the following software: g++ or clang,
+Python (gem5 links in the Python interpreter), SCons, SWIG, zlib, m4,
+and lastly protobuf if you want trace capture and playback
+support. Please see http://www.gem5.org/Dependencies for more details
+concerning the minimum versions of the aforementioned tools.
 
-Short version:
-External tools and required versions
+Once you have all dependencies resolved, type 'scons
+build/ARCH/gem5.opt' where ARCH is one of ALPHA, ARM, NULL, MIPS,
+POWER, SPARC, or X86. This will build an optimized version of the gem5
+binary (gem5.opt) for the the specified architecture. See
+http://www.gem5.org/Build_System for more details and options.
 
-To build gem5, you will need the following software:
-g++ version 4.3 or newer.
-Python, version 2.4 - 2.7 (we don't support Python 3.X). gem5 links in the 
-Python interpreter, so you need the Python header files and shared 
-library (e.g., /usr/lib/libpython2.4.so) in addition to the interpreter
-executable. These may or may not be installed by default. For example,
-on Debian/Ubuntu, you need the python-dev package in addition to the
-python package. If you need a newer or different Python installation
- but can't or don't want to upgrade the default Python on your system,
- see http://www.gem5.org/Using_a_non-default_Python_installation
-SCons, version 0.98.1 or newer. SCons is a powerful replacement for make. 
-If you don't have administrator privileges on your machine, you can use the
-scons-local package to install scons in your m5 directory, or install 
SCons
-in your home directory using the '--prefix=' option.  
-SWIG, version 1.3.34 or newer
-zlib, any recent version. For Debian/Ubuntu, you will need the zlib-dev or
-zlib1g-dev package to get the zlib.h header file as well as the library
-itself.
-m4, the macro processor.
-
-
-4. In this directory, type 'scons build/ARCH/gem5.opt' where ARCH is one
-of ALPHA, ARM, MIPS, POWER, SPARC, or X86. This will build an optimized version
-of the gem5 binary (gem5.opt) for the the specified architecture.
-
-If you have questions, please send mail to gem5-us...@gem5.org
-
-WHAT'S INCLUDED (AND NOT)
--
+With the simulator built, have a look at
+http://www.gem5.org/Running_gem5 for more information on how to use
+gem5.
 
 The basic source release includes these subdirectories:
- - gem5:
- configs: example simulation configuration scripts
- ext: less-common external packages needed to build gem5
- src: source code of the gem5 simulator
@@ -57,5 +32,10 @@
- util: useful utility programs and files
 
 To run full-system simulations, you will need compiled system firmware
-(console and PALcode for Alpha), kernel binaries and one or more disk images. 
-Please see the gem5 download page for these items at 
http://www.gem5.org/Download 
+(console and PALcode for Alpha), kernel binaries and one or more disk
+images. Please see the gem5 download page for these items at
+http://www.gem5.org/Download
+
+If you have questions, please send mail to gem5-us...@gem5.org
+
+Enjoy using gem5 and please share your modifications and extensions.
___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev


[gem5-dev] changeset in gem5: mem: Update DRAM controller comments

2014-08-26 Thread Andreas Hansson via gem5-dev
changeset 4966471a1ba1 in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=4966471a1ba1
description:
mem: Update DRAM controller comments

Update comments and add a reference for more information.

diffstat:

 src/mem/dram_ctrl.hh |  34 ++
 1 files changed, 18 insertions(+), 16 deletions(-)

diffs (45 lines):

diff -r e95a0ab1d368 -r 4966471a1ba1 src/mem/dram_ctrl.hh
--- a/src/mem/dram_ctrl.hh  Tue Aug 26 10:12:45 2014 -0400
+++ b/src/mem/dram_ctrl.hh  Tue Aug 26 10:13:03 2014 -0400
@@ -62,23 +62,25 @@
 #include sim/eventq.hh
 
 /**
- * The DRAM controller is a basic single-channel memory controller
- * aiming to mimic a high-level DRAM controller and the most important
- * timing constraints associated with the DRAM. The focus is really on
- * modelling the impact on the system rather than the DRAM itself,
- * hence the focus is on the controller model and not on the
- * memory. By adhering to the correct timing constraints, ultimately
- * there is no need for a memory model in addition to the controller
- * model.
+ * The DRAM controller is a single-channel memory controller capturing
+ * the most important timing constraints associated with a
+ * contemporary DRAM. For multi-channel memory systems, the controller
+ * is combined with a crossbar model, with the channel address
+ * interleaving taking part in the crossbar.
  *
- * As a basic design principle, this controller is not cycle callable,
- * but instead uses events to decide when new decisions can be made,
- * when resources become available, when things are to be considered
- * done, and when to send things back. Through these simple
- * principles, we achieve a performant model that is not
- * cycle-accurate, but enables us to evaluate the system impact of a
- * wide range of memory technologies, and also collect statistics
- * about the use of the memory.
+ * As a basic design principle, this controller
+ * model is not cycle callable, but instead uses events to: 1) decide
+ * when new decisions can be made, 2) when resources become available,
+ * 3) when things are to be considered done, and 4) when to send
+ * things back. Through these simple principles, the model delivers
+ * high performance, and lots of flexibility, allowing users to
+ * evaluate the system impact of a wide range of memory technologies,
+ * such as DDR3/4, LPDDR2/3/4, WideIO1/2, HBM and HMC.
+ *
+ * For more details, please see Hansson et al, Simulating DRAM
+ * controllers for future system architecture exploration,
+ * Proc. ISPASS, 2014. If you use this model as part of your research
+ * please cite the paper.
  */
 class DRAMCtrl : public AbstractMemory
 {
___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev


[gem5-dev] changeset in gem5: sparc: Fixup bit ordering in the PSTATE bit u...

2014-08-26 Thread Andreas Sandberg via gem5-dev
changeset e475a7861078 in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=e475a7861078
description:
sparc: Fixup bit ordering in the PSTATE bit union

The order of the MSB and LSB bit of the mm field in the PSTATE union
is wrong. Any access to this field will currently be ignored and reads
will always return zero. This patch fixes the ordering so it is MSB,
LSB instead of LSB, MSB.

diffstat:

 src/arch/sparc/miscregs.hh |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (12 lines):

diff -r 4966471a1ba1 -r e475a7861078 src/arch/sparc/miscregs.hh
--- a/src/arch/sparc/miscregs.hhTue Aug 26 10:13:03 2014 -0400
+++ b/src/arch/sparc/miscregs.hhTue Aug 26 10:13:23 2014 -0400
@@ -129,7 +129,7 @@
 Bitfield2 priv;
 Bitfield3 am;
 Bitfield4 pef;
-Bitfield6, 7 mm;
+Bitfield7, 6 mm;
 Bitfield8 tle;
 Bitfield9 cle;
 Bitfield10 pid0;
___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev


[gem5-dev] changeset in gem5: sim: bump checkpoint version for multiple eve...

2014-08-26 Thread Curtis Dunham via gem5-dev
changeset 6cb378bad253 in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=6cb378bad253
description:
sim: bump checkpoint version for multiple event queues

This patch adds a fix for older checkpoints before support for
multiple event queues were added in changeset 2cce74fe359e. The change
in checkpoint version should really hav ebeen part of the
aforementioned changeset.

diffstat:

 src/sim/serialize.hh |  2 +-
 util/cpt_upgrader.py |  7 +++
 2 files changed, 8 insertions(+), 1 deletions(-)

diffs (36 lines):

diff -r d02872388224 -r 6cb378bad253 src/sim/serialize.hh
--- a/src/sim/serialize.hh  Tue Aug 26 10:12:04 2014 -0400
+++ b/src/sim/serialize.hh  Wed Feb 05 16:17:41 2014 -0600
@@ -58,7 +58,7 @@
  * SimObject shouldn't cause the version number to increase, only changes to
  * existing objects such as serializing/unserializing more state, changing 
sizes
  * of serialized arrays, etc. */
-static const uint64_t gem5CheckpointVersion = 0x000b;
+static const uint64_t gem5CheckpointVersion = 0x000c;
 
 template class T
 void paramOut(std::ostream os, const std::string name, const T param);
diff -r d02872388224 -r 6cb378bad253 util/cpt_upgrader.py
--- a/util/cpt_upgrader.py  Tue Aug 26 10:12:04 2014 -0400
+++ b/util/cpt_upgrader.py  Wed Feb 05 16:17:41 2014 -0600
@@ -569,6 +569,12 @@
 else:
 continue
 
+# The change between versions C and D is the addition of support for multiple
+# event queues, so for old checkpoints we must specify that there's only one.
+def from_B(cpt):
+cpt.set('Globals', 'numMainEventQueues', '1')
+
+
 migrations = []
 migrations.append(from_0)
 migrations.append(from_1)
@@ -581,6 +587,7 @@
 migrations.append(from_8)
 migrations.append(from_9)
 migrations.append(from_A)
+migrations.append(from_B)
 
 verbose_print = False
 
___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev


[gem5-dev] changeset in gem5: base: Add a static assert to check bit union ...

2014-08-26 Thread Andreas Sandberg via gem5-dev
changeset 4593282280e4 in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=4593282280e4
description:
base: Add a static assert to check bit union ranges

If a bit field in a bit union specified as BitfieldLSB, MSB instead
of BitfieldMSB, LSB the code silently fails and the field is read as
zero. This changeset introduces a static assert that tests, at compile
time, that the bit order is correct.

diffstat:

 src/base/bitunion.hh |  3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diffs (13 lines):

diff -r e475a7861078 -r 4593282280e4 src/base/bitunion.hh
--- a/src/base/bitunion.hh  Tue Aug 26 10:13:23 2014 -0400
+++ b/src/base/bitunion.hh  Tue Aug 26 10:13:28 2014 -0400
@@ -85,6 +85,9 @@
 templateint first, int last=first
 class Bitfield : public BitfieldBaseType
 {
+static_assert(first = last,
+  Bitfield ranges must be specified as msb, lsb);
+
   public:
 operator const uint64_t () const
 {
___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev


[gem5-dev] changeset in gem5: mem: Fix address interleaving bug in DRAM con...

2014-08-26 Thread Andreas Hansson via gem5-dev
changeset e95a0ab1d368 in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=e95a0ab1d368
description:
mem: Fix address interleaving bug in DRAM controller

This patch fixes a bug in the DRAM controller address decoding. In
cases where the DRAM burst size (e.g. 32 bytes in a rank with a single
LPDDR3 x32) was smaller than the channel interleaving size
(e.g. systems with a 64-byte cache line) one address bit effectively
got used as a channel bit when it should have been a low-order column
bit.

This patch adds a notion of columns per stripe, and more clearly
deals with the low-order column bits and high-order column bits. The
patch also relaxes the granularity check such that it is possible to
use interleaving granularities other than the cache line size.

The patch also adds a missing M5_CLASS_VAR_USED to the tCK member as
it is only used in the debug build for now.

diffstat:

 src/mem/dram_ctrl.cc |  54 +--
 src/mem/dram_ctrl.hh |   3 +-
 2 files changed, 41 insertions(+), 16 deletions(-)

diffs (132 lines):

diff -r 6cb378bad253 -r e95a0ab1d368 src/mem/dram_ctrl.cc
--- a/src/mem/dram_ctrl.cc  Wed Feb 05 16:17:41 2014 -0600
+++ b/src/mem/dram_ctrl.cc  Tue Aug 26 10:12:45 2014 -0400
@@ -67,6 +67,7 @@
 burstSize((devicesPerRank * burstLength * deviceBusWidth) / 8),
 rowBufferSize(devicesPerRank * deviceRowBufferSize),
 columnsPerRowBuffer(rowBufferSize / burstSize),
+columnsPerStripe(range.granularity() / burstSize),
 ranksPerChannel(p-ranks_per_channel),
 banksPerRank(p-banks_per_rank), channels(p-channels), rowsPerBank(0),
 readBufferSize(p-read_buffer_size),
@@ -122,6 +123,7 @@
 
 rowsPerBank = capacity / (rowBufferSize * banksPerRank * ranksPerChannel);
 
+// a bit of sanity checks on the interleaving
 if (range.interleaved()) {
 if (channels != range.stripes())
 fatal(%s has %d interleaved address stripes but %d channel(s)\n,
@@ -129,18 +131,34 @@
 
 if (addrMapping == Enums::RoRaBaChCo) {
 if (rowBufferSize != range.granularity()) {
-fatal(Interleaving of %s doesn't match RoRaBaChCo 
+fatal(Channel interleaving of %s doesn't match RoRaBaChCo 
   address map\n, name());
 }
-} else if (addrMapping == Enums::RoRaBaCoCh) {
-if (system()-cacheLineSize() != range.granularity()) {
-fatal(Interleaving of %s doesn't match RoRaBaCoCh 
-  address map\n, name());
+} else if (addrMapping == Enums::RoRaBaCoCh ||
+   addrMapping == Enums::RoCoRaBaCh) {
+// for the interleavings with channel bits in the bottom,
+// if the system uses a channel striping granularity that
+// is larger than the DRAM burst size, then map the
+// sequential accesses within a stripe to a number of
+// columns in the DRAM, effectively placing some of the
+// lower-order column bits as the least-significant bits
+// of the address (above the ones denoting the burst size)
+assert(columnsPerStripe = 1);
+
+// channel striping has to be done at a granularity that
+// is equal or larger to a cache line
+if (system()-cacheLineSize()  range.granularity()) {
+fatal(Channel interleaving of %s must be at least as large 
+  as the cache line size\n, name());
 }
-} else if (addrMapping == Enums::RoCoRaBaCh) {
-if (system()-cacheLineSize() != range.granularity())
-fatal(Interleaving of %s doesn't match RoCoRaBaCh 
-  address map\n, name());
+
+// ...and equal or smaller than the row-buffer size
+if (rowBufferSize  range.granularity()) {
+fatal(Channel interleaving of %s must be at most as large 
+  as the row-buffer size\n, name());
+}
+// this is essentially the check above, so just to be sure
+assert(columnsPerStripe = columnsPerRowBuffer);
 }
 }
 
@@ -228,7 +246,8 @@
 // always the top bits, and check before creating the DRAMPacket
 uint64_t row;
 
-// truncate the address to the access granularity
+// truncate the address to a DRAM burst, which makes it unique to
+// a specific column, row, bank, rank and channel
 Addr addr = dramPktAddr / burstSize;
 
 // we have removed the lowest order address bits that denote the
@@ -255,11 +274,14 @@
 row = addr % rowsPerBank;
 addr = addr / rowsPerBank;
 } else if (addrMapping == Enums::RoRaBaCoCh) {
+// take out the lower-order column bits
+addr = addr / columnsPerStripe;
+
 // take out the channel part of 

[gem5-dev] changeset in gem5: style: Fixup strange semantics in hg m5style

2014-08-26 Thread Andreas Sandberg via gem5-dev
changeset 62c95c428a3d in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=62c95c428a3d
description:
style: Fixup strange semantics in hg m5style

The 'hg m5style' command had some rather strange semantics. When
called without arguments, it applied the style checker to all added
files and modified regions of modified files. However, when providing
a list of files, it used that list as an ignore list instead of
specifically checking those files.

This patch makes the m5style command behave more like other Mercurial
commands where the arguments are used to specify which files to work
on instead of which files to ignore.

diffstat:

 util/style.py |  114 -
 1 files changed, 64 insertions(+), 50 deletions(-)

diffs (159 lines):

diff -r 933dfb9d8279 -r 62c95c428a3d util/style.py
--- a/util/style.py Tue Aug 26 10:13:45 2014 -0400
+++ b/util/style.py Tue Aug 26 10:14:07 2014 -0400
@@ -1,4 +1,16 @@
 #! /usr/bin/env python
+# Copyright (c) 2014 ARM Limited
+# All rights reserved
+#
+# The license below extends only to copyright in the software and shall
+# not be construed as granting a license to any other intellectual
+# property including but not limited to intellectual property relating
+# to a hardware implementation of the functionality of the software
+# licensed hereunder.  You may use the software subject to the license
+# terms below provided that you ensure that this notice is replicated
+# unmodified and in its entirety in all distributions of the software,
+# modified or unmodified, in source code or in binary form.
+#
 # Copyright (c) 2006 The Regents of The University of Michigan
 # Copyright (c) 2007,2011 The Hewlett-Packard Development Company
 # All rights reserved.
@@ -35,7 +47,7 @@
 
 from os.path import dirname, join as joinpath
 from itertools import count
-from mercurial import bdiff, mdiff
+from mercurial import bdiff, mdiff, commands
 
 current_dir = dirname(__file__)
 sys.path.insert(0, current_dir)
@@ -378,27 +390,25 @@
 msg(i, line, 'improper spacing after %s' % match.group(1))
 bad()
 
-def do_check_style(hgui, repo, *files, **args):
-check files for proper m5 style guidelines
+
+def do_check_style(hgui, repo, *pats, **opts):
+check files for proper m5 style guidelines
+
+Without an argument, checks all modified and added files for gem5
+coding style violations. A list of files can be specified to limit
+the checker to a subset of the repository. The style rules are
+normally applied on a diff of the repository state (i.e., added
+files are checked in their entirety while only modifications of
+modified files are checked).
+
+The --all option can be specified to include clean files and check
+modified files in their entirety.
+
 from mercurial import mdiff, util
 
-auto = args.get('auto', False)
-if auto:
-auto = 'f'
-ui = MercurialUI(hgui, hgui.verbose, auto)
-
-if files:
-files = frozenset(files)
-
-def skip(name):
-# We never want to handle symlinks, so always skip them: If the 
location
-# pointed to is a directory, skip it. If the location is a file inside
-# the gem5 directory, it will be checked as a file, so symlink can be
-# skipped. If the location is a file outside gem5, we don't want to
-# check it anyway.
-if os.path.islink(name):
-return True
-return files and name in files
+opt_fix_white = opts.get('fix_white', False)
+opt_all = opts.get('all', False)
+ui = MercurialUI(hgui, hgui.verbose, opt_fix_white)
 
 def prompt(name, func, regions=all_regions):
 result = ui.prompt((a)bort, (i)gnore, or (f)ix?, 'aif', 'a')
@@ -409,39 +419,40 @@
 
 return False
 
-modified, added, removed, deleted, unknown, ignore, clean = repo.status()
+
+# Import the match (repository file name matching helper)
+# function. Different versions of Mercurial keep it in different
+# modules and implement them differently.
+try:
+from mercurial import scmutil
+m = scmutil.match(repo[None], pats, opts)
+except ImportError:
+from mercurial import cmdutil
+m = cmdutil.match(repo, pats, opts)
+
+modified, added, removed, deleted, unknown, ignore, clean = \
+repo.status(match=m, clean=opt_all)
+if not opt_all:
+try:
+wctx = repo.workingctx()
+except:
+from mercurial import context
+wctx = context.workingctx(repo)
+
+files = [ (fn, all_regions) for fn in added ] + \
+[ (fn,  modregions(wctx, fn)) for fn in modified ]
+else:
+files = [ (fn, all_regions) for fn in added + modified + clean ]
 
 whitespace = Whitespace(ui)
 sorted_includes = SortedIncludes(ui)
-for fname in added:

[gem5-dev] changeset in gem5: mips: Fix RLIMIT_RSS naming

2014-08-26 Thread Mitch Hayenga via gem5-dev
changeset b7715fb7cf9f in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=b7715fb7cf9f
description:
mips: Fix RLIMIT_RSS naming

MIPS defined RLIMIT_RSS in a way that could cause a naming conflict with
RLIMIT_RSS from the host system.  Broke clang+MacOS build.

diffstat:

 src/arch/mips/linux/linux.hh |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (12 lines):

diff -r 4593282280e4 -r b7715fb7cf9f src/arch/mips/linux/linux.hh
--- a/src/arch/mips/linux/linux.hh  Tue Aug 26 10:13:28 2014 -0400
+++ b/src/arch/mips/linux/linux.hh  Tue Aug 26 10:13:31 2014 -0400
@@ -117,7 +117,7 @@
 /// Resource constants for getrlimit() (overide some generics).
 static const unsigned TGT_RLIMIT_NPROC = 8;
 static const unsigned TGT_RLIMIT_AS = 6;
-static const unsigned RLIMIT_RSS = 7;
+static const unsigned TGT_RLIMIT_RSS = 7;
 static const unsigned TGT_RLIMIT_NOFILE = 5;
 static const unsigned TGT_RLIMIT_MEMLOCK = 9;
 
___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev


[gem5-dev] changeset in gem5: base: Add compiler macros for C++11 final/ove...

2014-08-26 Thread Andreas Sandberg via gem5-dev
changeset 56772eb01583 in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=56772eb01583
description:
base: Add compiler macros for C++11 final/override

Add the macros M5_ATTR_FINAL and M5_ATTR_OVERRIDE which are defined to
final and override respectively if supported by the compiler. This is
done to allow a smooth transition to gcc = 4.7.

diffstat:

 src/base/compiler.hh |  50 ++
 1 files changed, 38 insertions(+), 12 deletions(-)

diffs (65 lines):

diff -r b7715fb7cf9f -r 56772eb01583 src/base/compiler.hh
--- a/src/base/compiler.hh  Tue Aug 26 10:13:31 2014 -0400
+++ b/src/base/compiler.hh  Tue Aug 26 10:13:33 2014 -0400
@@ -43,23 +43,49 @@
 #ifndef __BASE_COMPILER_HH__
 #define __BASE_COMPILER_HH__
 
+// gcc C++11 status: http://gcc.gnu.org/projects/cxx0x.html
+// clang C++11 status: http://clang.llvm.org/cxx_status.html
 // http://gcc.gnu.org/onlinedocs/gcc/Function-Attributes.html
 
-#if defined(__GNUC__)
-#define M5_ATTR_NORETURN  __attribute__((noreturn))
-#define M5_DUMMY_RETURN
-#define M5_VAR_USED __attribute__((unused))
+/* Support for override control (final/override) */
+#undef M5_COMP_HAS_OVERRIDE_CONTROL
+
+#if defined(__GNUC__)  !defined(__clang__) /* Check for gcc */
+
+#  define M5_GCC_VERSION(maj, min) \
+(__GNUC__  (maj) || (__GNUC__ == (maj)  __GNUC_MINOR__ = (min)))
+
+#  define M5_COMP_HAS_OVERRIDE_CONTROL M5_GCC_VERSION(4, 7)
+
+#elif defined(__clang__) /* Check for clang */
+
+#  define M5_COMP_HAS_OVERRIDE_CONTROL __has_feature(cxx_override_control)
+
+#else
+#  error Need to define compiler options in base/compiler.hh
+#endif
+
+
+#if M5_COMP_HAS_OVERRIDE_CONTROL
+#  define M5_ATTR_FINAL final
+#  define M5_ATTR_OVERRIDE override
+#else
+#  define M5_ATTR_FINAL
+#  define M5_ATTR_OVERRIDE
+#endif
+
+#if defined(__GNUC__) // clang or gcc
+#  define M5_ATTR_NORETURN  __attribute__((noreturn))
+#  define M5_DUMMY_RETURN
+#  define M5_VAR_USED __attribute__((unused))
+#  define M5_ATTR_PACKED __attribute__ ((__packed__))
+#  define M5_NO_INLINE __attribute__ ((__noinline__))
+#endif
 
 #if defined(__clang__)
-#define M5_CLASS_VAR_USED M5_VAR_USED
+#  define M5_CLASS_VAR_USED M5_VAR_USED
 #else
-#define M5_CLASS_VAR_USED
-#endif
-
-#define M5_ATTR_PACKED __attribute__ ((__packed__))
-#define M5_NO_INLINE __attribute__ ((__noinline__))
-#else
-#error Need to define compiler options in base/compiler.hh
+#  define M5_CLASS_VAR_USED
 #endif
 
 #endif // __BASE_COMPILER_HH__
___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev


[gem5-dev] changeset in gem5: style: Add support for a style ignore list an...

2014-08-26 Thread Andreas Sandberg via gem5-dev
changeset b58f6afe14c5 in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=b58f6afe14c5
description:
style: Add support for a style ignore list and ignore ext/

There are some directories within the repository where we don't want
to enforce our coding style. Specifically, we don't want the style
hooks to warn whenever we update external code in the ext/ directory.

diffstat:

 util/style.py |  36 
 1 files changed, 36 insertions(+), 0 deletions(-)

diffs (67 lines):

diff -r 62c95c428a3d -r b58f6afe14c5 util/style.py
--- a/util/style.py Tue Aug 26 10:14:07 2014 -0400
+++ b/util/style.py Tue Aug 26 10:14:30 2014 -0400
@@ -67,6 +67,37 @@
 
 format_types = set(('C', 'C++'))
 
+
+def re_ignore(expr):
+Helper function to create regular expression ignore file
+matcher functions
+
+rex = re.compile(expr)
+def match_re(fname):
+return rex.match(fname)
+return match_re
+
+# This list contains a list of functions that are called to determine
+# if a file should be excluded from the style matching rules or
+# not. The functions are called with the file name relative to the
+# repository root (without a leading slash) as their argument. A file
+# is excluded if any function in the list returns true.
+style_ignores = [
+# Ignore external projects as they are unlikely to follow the gem5
+# coding convention.
+re_ignore(^ext/),
+]
+
+def check_ignores(fname):
+Check if a file name matches any of the ignore rules
+
+for rule in style_ignores:
+if rule(fname):
+return True
+
+return False
+
+
 def modified_regions(old_data, new_data):
 regions = Regions()
 beg = None
@@ -408,6 +439,7 @@
 
 opt_fix_white = opts.get('fix_white', False)
 opt_all = opts.get('all', False)
+opt_no_ignore = opts.get('no_ignore', False)
 ui = MercurialUI(hgui, hgui.verbose, opt_fix_white)
 
 def prompt(name, func, regions=all_regions):
@@ -447,6 +479,9 @@
 whitespace = Whitespace(ui)
 sorted_includes = SortedIncludes(ui)
 for fname, mod_regions in files:
+if not opt_no_ignore and check_ignores(fname):
+continue
+
 fpath = joinpath(repo.root, fname)
 
 if whitespace.apply(fpath, prompt, mod_regions):
@@ -515,6 +550,7 @@
 ('w', 'fix-white', False, _(automatically fix whitespace)),
 ('a', 'all', False,
  _(include clean files and unmodified parts of modified files)),
+('', 'no-ignore', False, _(ignore the style ignore list)),
 ] +  commands.walkopts,
 _('hg m5style [-a] [FILE]...')),
 '^m5format' :
___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev


[gem5-dev] changeset in gem5: mem: Fix DRAMSim2 cycle check when restoring ...

2014-08-26 Thread Andreas Hansson via gem5-dev
changeset 35738ad3c7c6 in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=35738ad3c7c6
description:
mem: Fix DRAMSim2 cycle check when restoring from checkpoint

This patch ensures the cycle check is still valid even restoring from
a checkpoint. In this case the DRAMSim2 cycle count is relative to the
startTick rather than 0.

diffstat:

 src/mem/dramsim2.cc |  8 +---
 src/mem/dramsim2.hh |  5 +
 2 files changed, 10 insertions(+), 3 deletions(-)

diffs (54 lines):

diff -r 9b9ef42122bc -r 35738ad3c7c6 src/mem/dramsim2.cc
--- a/src/mem/dramsim2.cc   Tue Aug 26 10:14:32 2014 -0400
+++ b/src/mem/dramsim2.cc   Tue Aug 26 10:14:38 2014 -0400
@@ -50,7 +50,7 @@
 port(name() + .port, *this),
 wrapper(p-deviceConfigFile, p-systemConfigFile, p-filePath,
 p-traceFile, p-range.size() / 1024 / 1024, p-enableDebug),
-retryReq(false), retryResp(false),
+retryReq(false), retryResp(false), startTick(0),
 nbrOutstandingReads(0), nbrOutstandingWrites(0),
 drainManager(NULL),
 sendResponseEvent(this), tickEvent(this)
@@ -91,6 +91,8 @@
 void
 DRAMSim2::startup()
 {
+startTick = curTick();
+
 // kick off the clock ticks
 schedule(tickEvent, clockEdge());
 }
@@ -287,7 +289,7 @@
 
 void DRAMSim2::readComplete(unsigned id, uint64_t addr, uint64_t cycle)
 {
-assert(cycle == divCeil(curTick(),
+assert(cycle == divCeil(curTick() - startTick,
 wrapper.clockPeriod() * SimClock::Int::ns));
 
 DPRINTF(DRAMSim2, Read to address %lld complete\n, addr);
@@ -315,7 +317,7 @@
 
 void DRAMSim2::writeComplete(unsigned id, uint64_t addr, uint64_t cycle)
 {
-assert(cycle == divCeil(curTick(),
+assert(cycle == divCeil(curTick() - startTick,
 wrapper.clockPeriod() * SimClock::Int::ns));
 
 DPRINTF(DRAMSim2, Write to address %lld complete\n, addr);
diff -r 9b9ef42122bc -r 35738ad3c7c6 src/mem/dramsim2.hh
--- a/src/mem/dramsim2.hh   Tue Aug 26 10:14:32 2014 -0400
+++ b/src/mem/dramsim2.hh   Tue Aug 26 10:14:38 2014 -0400
@@ -104,6 +104,11 @@
 bool retryResp;
 
 /**
+ * Keep track of when the wrapper is started.
+ */
+Tick startTick;
+
+/**
  * Keep track of what packets are outstanding per
  * address, and do so separately for reads and writes. This is
  * done so that we can return the right packet on completion from
___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev


[gem5-dev] changeset in gem5: base: Replace the internal varargs stuff with...

2014-08-26 Thread Andreas Sandberg via gem5-dev
changeset 933dfb9d8279 in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=933dfb9d8279
description:
base: Replace the internal varargs stuff with C++11 constructs

We currently use our own home-baked support for type-safe variadic
functions. This is confusing and somewhat limited (e.g., cprintf only
supports a limited number of arguments). This changeset converts all
uses of our internal varargs support to use C++11 variadic macros.

diffstat:

 src/arch/generic/debugfaults.hh |5 +-
 src/arch/x86/bios/intelmp.cc|2 +-
 src/base/cprintf.hh |   76 -
 src/base/misc.cc|   80 -
 src/base/misc.hh|   67 ++--
 src/base/trace.cc   |   55 +-
 src/base/trace.hh   |   28 +++-
 src/base/varargs.hh |  308 
 8 files changed, 167 insertions(+), 454 deletions(-)

diffs (truncated from 840 to 300 lines):

diff -r 56772eb01583 -r 933dfb9d8279 src/arch/generic/debugfaults.hh
--- a/src/arch/generic/debugfaults.hh   Tue Aug 26 10:13:33 2014 -0400
+++ b/src/arch/generic/debugfaults.hh   Tue Aug 26 10:13:45 2014 -0400
@@ -112,8 +112,9 @@
 class M5VarArgsFault : public M5DebugFault
 {
   public:
-M5VarArgsFault(const std::string format, CPRINTF_DECLARATION) :
-M5DebugFault((DebugFunc)Func, csprintf(format, VARARGS_ALLARGS))
+templatetypename ...Args
+M5VarArgsFault(const std::string format, const Args ...args) :
+M5DebugFault((DebugFunc)Func, csprintf(format, args...))
 {}
 };
 
diff -r 56772eb01583 -r 933dfb9d8279 src/arch/x86/bios/intelmp.cc
--- a/src/arch/x86/bios/intelmp.cc  Tue Aug 26 10:13:33 2014 -0400
+++ b/src/arch/x86/bios/intelmp.cc  Tue Aug 26 10:13:45 2014 -0400
@@ -92,7 +92,7 @@
 if (str.length()  length) {
 memcpy(cleanedString, str.c_str(), length);
 warn(Intel MP configuration table string \%s\ 
-will be truncated to \%s\.\n, str, cleanedString);
+ will be truncated to \%s\.\n, str, (char *)cleanedString);
 } else {
 memcpy(cleanedString, str.c_str(), str.length());
 memset(cleanedString + str.length(), 0, length - str.length());
diff -r 56772eb01583 -r 933dfb9d8279 src/base/cprintf.hh
--- a/src/base/cprintf.hh   Tue Aug 26 10:13:33 2014 -0400
+++ b/src/base/cprintf.hh   Tue Aug 26 10:13:45 2014 -0400
@@ -1,4 +1,5 @@
 /*
+ * Copyright (c) 2014 ARM Limited
  * Copyright (c) 2002-2006 The Regents of The University of Michigan
  * All rights reserved.
  *
@@ -27,6 +28,7 @@
  *
  * Authors: Nathan Binkert
  *  Steve Reinhardt
+ *  Andreas Sandberg
  */
 
 #ifndef __BASE_CPRINTF_HH__
@@ -38,13 +40,9 @@
 #include string
 
 #include base/cprintf_formats.hh
-#include base/varargs.hh
 
 namespace cp {
 
-#define CPRINTF_DECLARATION VARARGS_DECLARATION(cp::Print)
-#define CPRINTF_DEFINITION VARARGS_DEFINITION(cp::Print)
-
 struct Print
 {
   protected:
@@ -128,33 +126,42 @@
 
 } // namespace cp
 
-typedef VarArgs::Listcp::Print CPrintfArgsList;
+inline void
+ccprintf(cp::Print print)
+{
+print.end_args();
+}
 
-inline void
-ccprintf(std::ostream stream, const char *format, const CPrintfArgsList args)
+
+templatetypename T, typename ...Args void
+ccprintf(cp::Print print, const T value, const Args ...args)
+{
+print.add_arg(value);
+
+ccprintf(print, args...);
+}
+
+
+templatetypename ...Args void
+ccprintf(std::ostream stream, const char *format, const Args ...args)
 {
 cp::Print print(stream, format);
-args.add_args(print);
+
+ccprintf(print, args...);
 }
 
-inline void
-ccprintf(std::ostream stream, const char *format, CPRINTF_DECLARATION)
+
+templatetypename ...Args void
+cprintf(const char *format, const Args ...args)
 {
-cp::Print print(stream, format);
-VARARGS_ADDARGS(print);
+ccprintf(std::cout, format, args...);
 }
 
-inline void
-cprintf(const char *format, CPRINTF_DECLARATION)
-{
-ccprintf(std::cout, format, VARARGS_ALLARGS);
-}
-
-inline std::string
-csprintf(const char *format, CPRINTF_DECLARATION)
+templatetypename ...Args std::string
+csprintf(const char *format, const Args ...args)
 {
 std::stringstream stream;
-ccprintf(stream, format, VARARGS_ALLARGS);
+ccprintf(stream, format, args...);
 return stream.str();
 }
 
@@ -163,31 +170,22 @@
  * time converting const char * to std::string since we don't take
  * advantage of it.
  */
-inline void
-ccprintf(std::ostream stream, const std::string format,
- const CPrintfArgsList args)
+templatetypename ...Args void
+ccprintf(std::ostream stream, const std::string format, const Args ...args)
 {
-ccprintf(stream, format.c_str(), args);
+ccprintf(stream, format.c_str(), args...);
 }
 
-inline void
-ccprintf(std::ostream stream, const std::string format, CPRINTF_DECLARATION)
+templatetypename ...Args void
+cprintf(const std::string format, const Args 

[gem5-dev] changeset in gem5: base: Add const to intmath and be more flexib...

2014-08-26 Thread Andreas Hansson via gem5-dev
changeset 9b9ef42122bc in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=9b9ef42122bc
description:
base: Add const to intmath and be more flexible with typing

This patch ensures the functions can be used on const variables.

diffstat:

 src/base/intmath.hh |  20 ++--
 1 files changed, 10 insertions(+), 10 deletions(-)

diffs (77 lines):

diff -r b58f6afe14c5 -r 9b9ef42122bc src/base/intmath.hh
--- a/src/base/intmath.hh   Tue Aug 26 10:14:30 2014 -0400
+++ b/src/base/intmath.hh   Tue Aug 26 10:14:32 2014 -0400
@@ -42,7 +42,7 @@
 // Determine if a number is prime
 template class T
 inline bool
-isPrime(T n)
+isPrime(const T n)
 {
 T i;
 
@@ -63,14 +63,14 @@
 
 template class T
 inline T
-leastSigBit(T n)
+leastSigBit(const T n)
 {
 return n  ~(n - 1);
 }
 
 template class T
 inline bool
-isPowerOf2(T n)
+isPowerOf2(const T n)
 {
 return n != 0  leastSigBit(n) == n;
 }
@@ -171,7 +171,7 @@
 
 template class T
 inline int
-ceilLog2(T n)
+ceilLog2(const T n)
 {
 if (n == 1)
 return 0;
@@ -181,14 +181,14 @@
 
 template class T
 inline T
-floorPow2(T n)
+floorPow2(const T n)
 {
 return (T)1  floorLog2(n);
 }
 
 template class T
 inline T
-ceilPow2(T n)
+ceilPow2(const T n)
 {
 return (T)1  ceilLog2(n);
 }
@@ -200,17 +200,17 @@
 return (a + b - 1) / b;
 }
 
-template class T
+template class T, class U
 inline T
-roundUp(T val, int align)
+roundUp(const T val, const U align)
 {
 T mask = (T)align - 1;
 return (val + mask)  ~mask;
 }
 
-template class T
+template class T, class U
 inline T
-roundDown(T val, int align)
+roundDown(const T val, const U align)
 {
 T mask = (T)align - 1;
 return val  ~mask;
___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev


Re: [gem5-dev] Review Request 2327: arm: support 16kb vm granules

2014-08-26 Thread Curtis Dunham via gem5-dev


 On Aug. 20, 2014, 5:39 p.m., Nilay Vaish wrote:
  While I am ok with the changes made,  do you think it is possible to
  retain the Enum instead of using 12, 14 and 16?

I think this should be fine.  I'll update patch shortly.


- Curtis


---
This is an automatically generated e-mail. To reply, visit:
http://reviews.gem5.org/r/2327/#review5285
---


On Aug. 18, 2014, 9:55 p.m., Andreas Hansson wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 http://reviews.gem5.org/r/2327/
 ---
 
 (Updated Aug. 18, 2014, 9:55 p.m.)
 
 
 Review request for Default.
 
 
 Repository: gem5
 
 
 Description
 ---
 
 Changeset 10288:3f7ff9a4c112
 ---
 arm: support 16kb vm granules
 
 
 Diffs
 -
 
   src/arch/arm/miscregs.hh 79fde1c67ed8 
   src/arch/arm/table_walker.hh 79fde1c67ed8 
   src/arch/arm/table_walker.cc 79fde1c67ed8 
 
 Diff: http://reviews.gem5.org/r/2327/diff/
 
 
 Testing
 ---
 
 
 Thanks,
 
 Andreas Hansson
 


___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev


Re: [gem5-dev] changeset in gem5: style: Fixup strange semantics in hg m5style

2014-08-26 Thread Steve Reinhardt via gem5-dev
Thanks for this, Andreas!  I've tried to use it in the past and it never
did what I wanted... I assumed it was broken, not that it was working
correctly according to obscure semantics.

Is there any documentation for this beyond the brief 'usage'  lines in the
script?  It would be great if there were (1) an extended help text like
other mercurial commands and (2) something on the wiki to let people know
it exists and how to get it to work with hg.

Thanks,

Steve



On Tue, Aug 26, 2014 at 8:14 AM, Andreas Sandberg via gem5-dev 
gem5-dev@gem5.org wrote:

 changeset 62c95c428a3d in /z/repo/gem5
 details: http://repo.gem5.org/gem5?cmd=changeset;node=62c95c428a3d
 description:
 style: Fixup strange semantics in hg m5style

 The 'hg m5style' command had some rather strange semantics. When
 called without arguments, it applied the style checker to all added
 files and modified regions of modified files. However, when
 providing
 a list of files, it used that list as an ignore list instead of
 specifically checking those files.

 This patch makes the m5style command behave more like other
 Mercurial
 commands where the arguments are used to specify which files to
 work
 on instead of which files to ignore.

 diffstat:

  util/style.py |  114
 -
  1 files changed, 64 insertions(+), 50 deletions(-)

 diffs (159 lines):

 diff -r 933dfb9d8279 -r 62c95c428a3d util/style.py
 --- a/util/style.py Tue Aug 26 10:13:45 2014 -0400
 +++ b/util/style.py Tue Aug 26 10:14:07 2014 -0400
 @@ -1,4 +1,16 @@
  #! /usr/bin/env python
 +# Copyright (c) 2014 ARM Limited
 +# All rights reserved
 +#
 +# The license below extends only to copyright in the software and shall
 +# not be construed as granting a license to any other intellectual
 +# property including but not limited to intellectual property relating
 +# to a hardware implementation of the functionality of the software
 +# licensed hereunder.  You may use the software subject to the license
 +# terms below provided that you ensure that this notice is replicated
 +# unmodified and in its entirety in all distributions of the software,
 +# modified or unmodified, in source code or in binary form.
 +#
  # Copyright (c) 2006 The Regents of The University of Michigan
  # Copyright (c) 2007,2011 The Hewlett-Packard Development Company
  # All rights reserved.
 @@ -35,7 +47,7 @@

  from os.path import dirname, join as joinpath
  from itertools import count
 -from mercurial import bdiff, mdiff
 +from mercurial import bdiff, mdiff, commands

  current_dir = dirname(__file__)
  sys.path.insert(0, current_dir)
 @@ -378,27 +390,25 @@
  msg(i, line, 'improper spacing after %s' %
 match.group(1))
  bad()

 -def do_check_style(hgui, repo, *files, **args):
 -check files for proper m5 style guidelines
 +
 +def do_check_style(hgui, repo, *pats, **opts):
 +check files for proper m5 style guidelines
 +
 +Without an argument, checks all modified and added files for gem5
 +coding style violations. A list of files can be specified to limit
 +the checker to a subset of the repository. The style rules are
 +normally applied on a diff of the repository state (i.e., added
 +files are checked in their entirety while only modifications of
 +modified files are checked).
 +
 +The --all option can be specified to include clean files and check
 +modified files in their entirety.
 +
  from mercurial import mdiff, util

 -auto = args.get('auto', False)
 -if auto:
 -auto = 'f'
 -ui = MercurialUI(hgui, hgui.verbose, auto)
 -
 -if files:
 -files = frozenset(files)
 -
 -def skip(name):
 -# We never want to handle symlinks, so always skip them: If the
 location
 -# pointed to is a directory, skip it. If the location is a file
 inside
 -# the gem5 directory, it will be checked as a file, so symlink
 can be
 -# skipped. If the location is a file outside gem5, we don't want
 to
 -# check it anyway.
 -if os.path.islink(name):
 -return True
 -return files and name in files
 +opt_fix_white = opts.get('fix_white', False)
 +opt_all = opts.get('all', False)
 +ui = MercurialUI(hgui, hgui.verbose, opt_fix_white)

  def prompt(name, func, regions=all_regions):
  result = ui.prompt((a)bort, (i)gnore, or (f)ix?, 'aif', 'a')
 @@ -409,39 +419,40 @@

  return False

 -modified, added, removed, deleted, unknown, ignore, clean =
 repo.status()
 +
 +# Import the match (repository file name matching helper)
 +# function. Different versions of Mercurial keep it in different
 +# modules and implement them differently.
 +try:
 +from mercurial import scmutil
 +m = scmutil.match(repo[None], pats, opts)
 +except ImportError:
 +from mercurial 

[gem5-dev] Review Request 2366: tests: Use medium dataset for perlbmk regressions

2014-08-26 Thread Andreas Hansson via gem5-dev

---
This is an automatically generated e-mail. To reply, visit:
http://reviews.gem5.org/r/2366/
---

Review request for Default.


Repository: gem5


Description
---

Changeset 10327:2311e7ab3014
---
tests: Use medium dataset for perlbmk regressions

This patch changes the perlbmk regression script from the large to the
medium dataset to reduce the regression run time. For all ISAs and CPU
models, the total perlbmk host CPU time with the large dataset is
roughly 12 hours (constituting 30% of the total regression host
time). There is, most likely, almost no added value in terms of code
coverage for this rather excessive run time.


Diffs
-

  tests/long/se/40.perlbmk/test.py 35738ad3c7c6 

Diff: http://reviews.gem5.org/r/2366/diff/


Testing
---


Thanks,

Andreas Hansson

___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev


[gem5-dev] changeset in gem5: Added tag stable_2014_08_26 for changeset cb2...

2014-08-26 Thread Nilay Vaish via gem5-dev
changeset 2a1d75864ad2 in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=2a1d75864ad2
description:
Added tag stable_2014_08_26 for changeset cb2e6950956d

diffstat:

 .hgtags |  1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diffs (8 lines):

diff -r 35738ad3c7c6 -r 2a1d75864ad2 .hgtags
--- a/.hgtags   Tue Aug 26 10:14:38 2014 -0400
+++ b/.hgtags   Tue Aug 26 14:41:23 2014 -0500
@@ -24,3 +24,4 @@
 07352f119e489452b3c0bbf6d4f70e21e80e17e3 stable_2013_06_16
 6a043adb1e8d67fbb03ac5cee58dd26f75663714 stable_2013_10_14
 459491344fcf7f9e29250e71f33a7c7150f54d64 stable_2014_02_15
+cb2e6950956d475da97b04c41f19769ce2e8541a stable_2014_08_26
___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev


Re: [gem5-dev] Updating gem5-stable

2014-08-26 Thread Nilay Vaish via gem5-dev

I have updated gem5-stable to the following changeset from gem5:

---

changeset: 10231:cb2e6950956d
user: Steve Reinhardt steve.reinha...@amd.com
date: Sat May 31 18:00:23 2014 -0700
summary: style: eliminate equality tests with true and false


---

--
Nilay
___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev


Re: [gem5-dev] Review Request 2327: arm: support 16kb vm granules

2014-08-26 Thread Andreas Hansson via gem5-dev

---
This is an automatically generated e-mail. To reply, visit:
http://reviews.gem5.org/r/2327/
---

(Updated Aug. 26, 2014, 9:04 p.m.)


Review request for Default.


Repository: gem5


Description (updated)
---

Changeset 10303:d7a21596221d
---
arm: support 16kb vm granules


Diffs (updated)
-

  src/arch/arm/miscregs.hh 35738ad3c7c6 
  src/arch/arm/table_walker.hh 35738ad3c7c6 
  src/arch/arm/table_walker.cc 35738ad3c7c6 

Diff: http://reviews.gem5.org/r/2327/diff/


Testing
---


Thanks,

Andreas Hansson

___
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev