summaryrefslogtreecommitdiff
path: root/src/python
AgeCommit message (Collapse)Author
2008-12-06traceflags: Make "All" a valid trace flag.Nathan Binkert
2008-12-06SimObject: change naming of vectors so there are the same numbers of digits.Nathan Binkert
i.e. we used to have Foo0, Foo1, ..., Foo10, Foo11, ..., Foo100 now we have Foo000, Foo001, ..., Foo010, Foo011, ..., Foo100
2008-11-17Sort trace flags before printing them.Steve Reinhardt
2008-11-10python: Fix the reference counting for python events placed on the eventq.Nathan Binkert
We need to add a reference when an object is put on the C++ queue, and remove a reference when the object is removed from the queue. This was not happening before and caused a memory problem.
2008-10-27Checkpointing: createCountedDrain function, it was only returning an Event, ↵Clint Smullen
which does not expose a setCount method to Python. Signed-off By: Ali Saidi
2008-10-14eventq: make python events actually workNathan Binkert
2008-10-10output: Make panic/fatal/warn more flexible so we can add some new ones.Nathan Binkert
The major thrust of this change is to limit the amount of code duplication surrounding the code for these functions. This code also adds two new message types called info and hack. Info is meant to be less harsh than warn so people don't get confused and start thinking that the simulator is broken. Hack is a way for people to add runtime messages indicating that the simulator just executed a code "hack" that should probably be fixed. The benefit of knowing about these code hacks is that it will let people know what sorts of inaccuracies or potential bugs might be entering their experiments. Finally, I've added some flags to turn on and off these message types so command line options can change them.
2008-10-10jobfile: Add support for dictionaries as jobfile options.Nathan Binkert
If the same dictionary option is seen in several options, those dictionaries are composed. If you define the same dictionary key in multiple options, the system flags an error. Also, clean up the jobfile code so that it is more debuggable.
2008-10-10python: Add a utility for nested attribute dicts.Nathan Binkert
Change attrdict so that attributes that begin with an underscore don't go into the dict.
2008-10-09SimObjects: Clean up handling of C++ namespaces.Nathan Binkert
Make them easier to express by only having the cxx_type parameter which has the full namespace name, and drop the cxx_namespace thing. Add support for multiple levels of namespace.
2008-10-09eventq: convert all usage of events to use the new API.Nathan Binkert
For now, there is still a single global event queue, but this is necessary for making the steps towards a parallelized m5.
2008-10-09eventq: Major API change for the Event and EventQueue structures.Nathan Binkert
Since the early days of M5, an event needed to know which event queue it was on, and that data was required at the time of construction of the event object. In the future parallelized M5, this sort of requirement does not work well since the proper event queue will not always be known at the time of construction of an event. Now, events are created, and the EventQueue itself has the schedule function, e.g. eventq->schedule(event, when). To simplify the syntax, I created a class called EventManager which holds a pointer to an EventQueue and provides the schedule interface that is a proxy for the EventQueue. The intent is that objects that frequently schedule events can be derived from EventManager and then they have the schedule interface. SimObject and Port are examples of objects that will become EventManagers. The end result is that any SimObject can just call schedule(event, when) and it will just call that SimObject's eventq->schedule function. Of course, some objects may have more than one EventQueue, so this interface might not be perfect for those, but they should be relatively few.
2008-10-09pdb: Try to make pdb work better.Nathan Binkert
I've done a few things here. First, I invoke the script a little bit differently so that pdb doesn't get confused. Second, I've stored the actual filename in the module's __file__ so that pdb can find the source file on your machine.
2008-10-06python: cleanup options parsing stuff so that it properly deals with defaults.Nathan Binkert
While we're at it, make it possible to run main.py in a somewhat standalone mode again so that we can test things without compiling.
2008-09-29Make overriding port assignments in Python work,Steve Reinhardt
and print better error messages when it doesn't.
2008-09-10style: Remove non-leading tabs everywhere they shouldn't be. Developers ↵Ali Saidi
should configure their editors to not insert tabs
2008-08-04Make time format in 'started' line same as 'compiled'.Steve Reinhardt
Also make -B output consistent with normal header, and only include actual build options.
2008-08-04Get rid of outputStream... wasn't really being usedSteve Reinhardt
(except for warn()) and new -r/-e options make it not worth fixing.
2008-08-04Add -r/-e options to redirect stdout/stderr.Steve Reinhardt
Better than using shell since it automatically uses -d directory for output files (creating it as needed).
2008-08-03sockets: Add a function to disable all listening sockets.Nathan Binkert
When invoking several copies of m5 on the same machine at the same time, there can be a race for TCP ports for the terminal connections or remote gdb. Expose a function to disable those ports, and have the regression scripts disable them. There are some SimObjects that have no other function than to be used with ports (NativeTrace and EtherTap), so they will panic if the ports are disabled.
2008-08-03libm5: Create a libm5 static library for embedding m5.Nathan Binkert
This should allow m5 to be more easily embedded into other simulators. The m5 binary adds a simple main function which then calls into the m5 libarary to start the simulation. In order to make this work correctly, it was necessary embed python code directly into the library instead of the zipfile hack. This is because you can't just append the zipfile to the end of a library the way you can a binary. As a result, Python files that are part of the m5 simulator are now compile, marshalled, compressed, and then inserted into the library's data section with a certain symbol name. Additionally, a new Importer was needed to allow python to get at the embedded python code. Small additional changes include: - Get rid of the PYTHONHOME stuff since I don't think anyone ever used it, and it just confuses things. Easy enough to add back if I'm wrong. - Create a few new functions that are key to initializing and running the simulator: initSignals, initM5Python, m5Main. The original code for creating libm5 was inspired by a patch Michael Adler, though the code here was done by me.
2008-07-31scons: Get rid of generate.py in the build system.Nathan Binkert
I decided that separating some of the scons code into generate.py was just a bad idea because it caused the dependency system to get all messed up. If separation is the right way to go in the future, we should probably use the sconscript mechanism, not the mechanism that I just removed.
2008-07-23RemoteGDB: add an m5 command line option for setting or disabling remote gdb.Michael Adler
2008-06-24Automated merge with http://repo.m5sim.org/m5-stableAli Saidi
2008-06-24Checkpoinging/SWIG: Undo part of changeset 5464 since it broke checkpointing.Ali Saidi
2008-06-18imported patch sim_object_params.diffNathan Binkert
2008-06-15params: Prevent people from setting attributes on vector params.Nathan Binkert
2008-06-15add compile flags to m5Nathan Binkert
2008-06-14Command line option to print out List of SimObjects and their parametersNathan Binkert
2008-06-14main: add .m5/options.py processing. This file is processed beforeNathan Binkert
arguments are parsed so that they can change the default options for various config parameters.
2008-06-14Add .m5 configuration directoryNathan Binkert
2008-06-14python: Separate the options parsing stuff. Remove options parsing stuff fromNathan Binkert
main.py so things are a bit more obvious.
2008-06-14params: Fix the memory bandwidth parameterNathan Binkert
2008-06-14params: Fix floating point parametersNathan Binkert
2008-06-14python: Move various utility classes into a new m5.util package soNathan Binkert
they're all in the same place. This also involves having just one jobfile.py and moving it into the utils directory to avoid duplication. Lots of improvements to the utility as well. --HG-- rename : src/python/m5/attrdict.py => src/python/m5/util/attrdict.py rename : util/pbs/jobfile.py => src/python/m5/util/jobfile.py rename : src/python/m5/util.py => src/python/m5/util/misc.py rename : src/python/m5/multidict.py => src/python/m5/util/multidict.py rename : util/stats/orderdict.py => src/python/m5/util/orderdict.py
2008-06-14Fix various SWIG warningsNathan Binkert
2008-06-14scons: proper fix for hg version stuffNathan Binkert
2008-06-13scons: fix program_info.cc generationNathan Binkert
2008-06-13HG: Add compiled hg revision and date to the standard M5 output.Ali Saidi
2008-06-12Params: Allow nested namespaces in cxx_namespaceGabe Black
2008-06-12Params: Remove an unnecessary include.Gabe Black
2008-02-11Update copyright datesAli Saidi
--HG-- extra : convert_revision : 547e7ddff6b8005a9eaad60970bc51984e84fcd1
2007-11-12Params: Fix check for cycles in the configuration and clarify the ↵Gabe Black
comments/error message. --HG-- extra : convert_revision : 8f35dde408fae874bcba1a248d32a22222d98c35
2007-11-08Python: Allow a range to be a python tuple/list.Ali Saidi
--HG-- extra : convert_revision : 81cf805055e2f4d62e56a02ac82a0b230251f40b
2007-11-04TraceFlags: Fix off-by-one error with number of traceflags.Ali Saidi
--HG-- extra : convert_revision : 668299fc0a9083be858fe2f6e8fde512ddac9e32
2007-10-31String constant const-ness changes to placate g++ 4.2.Steve Reinhardt
Also some bug fixes in MIPS ISA uncovered by g++ warnings (Python string compares don't work in C++!). --HG-- extra : convert_revision : b347cc0108f23890e9b73b3ee96059f0cea96cf6
2007-10-31Traceflags: Add SCons function to created a traceflag instead of having one ↵Ali Saidi
file with them all. --HG-- extra : convert_revision : 427f6bd8f050861ace3bc0d354a1afa5fc8319e6
2007-09-04Serialization: Fix unserialization of object pointersAli Saidi
--HG-- extra : convert_revision : a5aed880b2fc05841067e8597a58a9484e30b84a
2007-09-04Config: Remove some ini file code that no longer worksAli Saidi
--HG-- extra : convert_revision : cb01dc0abeabc97b03d7af10959d92ceb62ea936
2007-08-30python: Write configuration file without reassigning sys.stdout.Miles Kaufmann
Using print >>ini_file syntax instead of reassigning sys.stdout allows the python debugger to be used. --HG-- extra : convert_revision : 63fc268f2e80f338ad1a7abe54b9e979e2239609