For example, 'scons ALPHA_SE/test/opt/quick' will build
ALPHA_SE/m5.opt if necessary and run all the self-identified
"quick" tests on it. Other possibilities:
- Run just test1: scons ALPHA_SE/test/opt/test1
- Run all tests: scons ALPHA_SE/test/opt
- Run all tests on debug build: scons ALPHA_SE/test/debug
- Update test1 reference outputs in m5-test:
scons update_ref=y ALPHA_SE/test/opt/test1
The proper tests will be selected based on the setting
of FULL_SYSTEM, ALPHA_TLASER, etc.
README:
Update directions to use scons-based test invocation.
SConscript:
Return list of generated build environments to SConstruct
so it can associate tests with each of them.
Set 'M5Binary' attribute on each env to record name of
generated binary to be tested.
build/SConstruct:
- Support invoking m5-test tests via scons.
- Add new non-sticky option category, for 'update_ref'.
- Move existing "sticky" option definitions out of
build_dir loop. Someday we can generate help text
from these.
- Make 'CC' and 'CXX' sticky options; use environment vars as
defaults if available.
- Make config builder more scons-y.
python/m5/__init__.py:
Make AddToPath() correctly handle relative path arguments.
Assumes that sys.path[0] has the directory where the current
Python file lives; new m5execfile() function sets this up
properly for exec'd files.
--HG--
extra : convert_revision : 48896688592e210d8e63f96c34e57474853d0e66
Special mpy importer is gone; everything is just plain
Python now (funky, but straight-up).
May not completely work yet... generates identical ini
files for many configs/kernel settings, but I have yet
to run it against regressions. This commit is for my
own convenience and won't be pushed until more testing
is done.
python/m5/__init__.py:
Get rid of mpy_importer and param_types.
python/m5/config.py:
Major cleanup. We now have separate classes and
instances for SimObjects. Proxy handling and param
conversion significantly reorganized. No explicit
instantiation step anymore; we can dump an ini file
straight from the original tree.
Still needs more/better/truer comments.
test/genini.py:
Replace LoadMpyFile() with built-in execfile().
Export __main__.m5_build_env.
python/m5/objects/AlphaConsole.py:
python/m5/objects/AlphaFullCPU.py:
python/m5/objects/AlphaTLB.py:
python/m5/objects/BadDevice.py:
python/m5/objects/BaseCPU.py:
python/m5/objects/BaseCache.py:
python/m5/objects/BaseSystem.py:
python/m5/objects/Bus.py:
python/m5/objects/CoherenceProtocol.py:
python/m5/objects/Device.py:
python/m5/objects/DiskImage.py:
python/m5/objects/Ethernet.py:
python/m5/objects/Ide.py:
python/m5/objects/IntrControl.py:
python/m5/objects/MemTest.py:
python/m5/objects/Pci.py:
python/m5/objects/PhysicalMemory.py:
python/m5/objects/Platform.py:
python/m5/objects/Process.py:
python/m5/objects/Repl.py:
python/m5/objects/Root.py:
python/m5/objects/SimConsole.py:
python/m5/objects/SimpleDisk.py:
python/m5/objects/Tsunami.py:
python/m5/objects/Uart.py:
Fixes for eliminating mpy_importer, and modified
handling of frequency/latency params.
Also renamed parent to Parent.
--HG--
rename : python/m5/objects/AlphaConsole.mpy => python/m5/objects/AlphaConsole.py
rename : python/m5/objects/AlphaFullCPU.mpy => python/m5/objects/AlphaFullCPU.py
rename : python/m5/objects/AlphaTLB.mpy => python/m5/objects/AlphaTLB.py
rename : python/m5/objects/BadDevice.mpy => python/m5/objects/BadDevice.py
rename : python/m5/objects/BaseCPU.mpy => python/m5/objects/BaseCPU.py
rename : python/m5/objects/BaseCache.mpy => python/m5/objects/BaseCache.py
rename : python/m5/objects/BaseSystem.mpy => python/m5/objects/BaseSystem.py
rename : python/m5/objects/Bus.mpy => python/m5/objects/Bus.py
rename : python/m5/objects/CoherenceProtocol.mpy => python/m5/objects/CoherenceProtocol.py
rename : python/m5/objects/Device.mpy => python/m5/objects/Device.py
rename : python/m5/objects/DiskImage.mpy => python/m5/objects/DiskImage.py
rename : python/m5/objects/Ethernet.mpy => python/m5/objects/Ethernet.py
rename : python/m5/objects/Ide.mpy => python/m5/objects/Ide.py
rename : python/m5/objects/IntrControl.mpy => python/m5/objects/IntrControl.py
rename : python/m5/objects/MemTest.mpy => python/m5/objects/MemTest.py
rename : python/m5/objects/Pci.mpy => python/m5/objects/Pci.py
rename : python/m5/objects/PhysicalMemory.mpy => python/m5/objects/PhysicalMemory.py
rename : python/m5/objects/Platform.mpy => python/m5/objects/Platform.py
rename : python/m5/objects/Process.mpy => python/m5/objects/Process.py
rename : python/m5/objects/Repl.mpy => python/m5/objects/Repl.py
rename : python/m5/objects/Root.mpy => python/m5/objects/Root.py
rename : python/m5/objects/SimConsole.mpy => python/m5/objects/SimConsole.py
rename : python/m5/objects/SimpleDisk.mpy => python/m5/objects/SimpleDisk.py
rename : python/m5/objects/Tsunami.mpy => python/m5/objects/Tsunami.py
rename : python/m5/objects/Uart.mpy => python/m5/objects/Uart.py
extra : convert_revision : 9dc55103a6f5b40eada4ed181a71a96fae6b0b76
Mostly cleanup of mpy_importer.mpy_parse().
python/m5/__init__.py:
Move panic() up to top in case we want to use it
in mpy_importer (though I ended up not doing that
after all).
python/m5/config.py:
Add a couple of comments and a check for expressions
like parent.any.foo (which is illegal).
--HG--
extra : convert_revision : dfc99ac9b1a2d91a736ca0b773b6d3c528a4f3cc
.mpy SimObject descriptions. Structs are defined
in simobj/param/ObjectName.hh.
- Move compile-time python params (from CPPDEFINES) to
separate dict from run-time params (from os.environ).
The former are needed to generate proper param structs.
This also helps prevent users from messing things up
by setting the wrong environment vars (which could have
overridden compile-time settings in the old system).
- Other misc cleanup of m5 python package.
SConscript:
Include simobj/SConscript
build/SConstruct:
Fix type in comment
python/SConscript:
Move CPPDEFINES dict-generating code to m5scons.flatten_defines
python/m5/__init__.py:
- Generate a build_env SmartDict here to hold compile-time
params (passed in via __main__.m5_build_env).
- Move panic and env here from config.py.
python/m5/config.py:
Move panic, env to top level (m5/__init__.py)
python/m5/objects/BaseCPU.mpy:
Use build_env instead of env for compile-time params
python/m5/smartdict.py:
Add some comments.
sim/sim_object.hh:
Include auto-generated Param struct. Not used yet,
just here as proof of concept.
test/genini.py:
Put -E arguments in build_env as well as os.environ
--HG--
extra : convert_revision : cf6f4a2565b230c495b33b18612d6030988adac5
- global tracking of legitimate param types in
separate dict keeps us from having to import
objects in config.py, which gets rid of nasty
circular dependence
- use __all__ in config.py and restrict imports
from mpy_importer to reduce m5 namespace pollution
python/m5/__init__.py:
Try to limit namespace pollution by only importing
what's needed from mpy_importer.
Explicitly set up legal parameter types rather than
relying on eval().
python/m5/config.py:
Use empty ParamType base class to distinguish
types that are legitimate SimObject params.
Explicitly add these to global param_types map.
Rework CheckedInt and Range classes a little bit
to fit in better with the model.
No need to import objects here any longer.
Add __all__ list to specify subset of names that
get exported on 'from m5.config import *'.
--HG--
extra : convert_revision : 01c6e82e0b175fc9b3df25dd0cc80ecd842680bc