summaryrefslogtreecommitdiff
path: root/src/sim
AgeCommit message (Collapse)Author
2009-01-30Errors: Use the correct panic/warn/fatal/info message in some places.Ali Saidi
2009-01-29Fix typoNathan Binkert
2009-01-24pseudo inst: Add new wake cpu instruction for sending a message to wake a cpu.Nathan Binkert
It's instantaneous and so it's somewhat bogus, but it's a first step.
2009-01-19python: Rework how things are importedNathan Binkert
2009-01-17Fix issue 326: glibc non-deterministic because it reads /procAli Saidi
2009-01-06Tracing: Make tracing aware of macro and micro ops.Gabe Black
2008-12-17Make Alpha pseudo-insts available from SE mode.Steve Reinhardt
2008-12-08eventq: Add some debugging code to the eventq.Nathan Binkert
2008-12-07imported patch aux-fix.patchLisa Hsu
2008-12-06eventq: use the flags data structureNathan Binkert
2008-12-06eventq: move virtual function definitiions to the .cc file.Nathan Binkert
2008-12-05This brings M5 closer to modernity - the kernel being advertised is newer so ↵Lisa Hsu
it won't die on binaries compiled with newer glibc's, and enables use of TLS-toolchain built binaries for ALPHA_SE by putting auxiliary vectors on the stack. There are some comments in the code to help. Finally, stats changes for ALPHA are from slight perturbations to the initial stack frame, all minimal diffs.
2008-12-04This patch pulls out the auxiliary vector struct from individual ISALisa Hsu
LiveProcesses to the base LiveProcess definition so anyone can use them.
2008-11-20Assume files w/o obvious OS are Linux (with warning)Steve Reinhardt
instead of giving a fatal error.
2008-11-15syscalls: fix latent brk/obreak bug.Steve Reinhardt
Bogus calls to ChunkGenerator with negative size were triggering a new assertion that was added there. Also did a little renaming and cleanup in the process.
2008-11-10pseudo inst: Add rpns (read processor nanoseconds) instruction.Nathan Binkert
This instruction basically returns the number of nanoseconds that the CPU has been running.
2008-11-10clean: Move some stuff from the hh file to the cc file.Nathan Binkert
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-11-05Right now a single thread cpu 1 could get assigned context Id != 1, dependingLisa Hsu
on the order in which it's registered with the system. To make them match, here is a little change.
2008-11-02Add in Context IDs to the simulator. From now on, cpuId is almost never used,Lisa Hsu
the primary identifier for a hardware context should be contextId(). The concept of threads within a CPU remains, in the form of threadId() because sometimes you need to know which context within a cpu to manipulate.
2008-11-02Make it so that all thread contexts are registered with the System, even inLisa Hsu
SE. Process still keeps track of the tc's it owns, but registration occurs with the System, this eases the way for system-wide context Ids based on registration.
2008-11-02make BaseCPU the provider of _cpuId, and cpuId() instead of being scatteredLisa Hsu
across the subclasses. generally make it so that member data is _cpuId and accessor functions are cpuId(). The ID val comes from the python (default -1 if none provided), and if it is -1, the index of cpuList will be given. this has passed util/regress quick and se.py -n4 and fs.py -n4 as well as standard switch.
2008-10-14eventq: revert code for unserializing events.Nathan Binkert
Since I never implemented a proper solution, put it back to something that at least works for now. Once I add more event queues, I'll have to really fix this though
2008-10-12CPU: Create a microcode ROM object in the CPU which is defined by the ISA.Gabe Black
2008-10-10TLB: Make all tlbs derive from a common base class in both python and C++.Gabe Black
2008-10-10Rename the info function to inform to avoid likely name conflictsNathan 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-10gdb: add a debugging function that enters the python interpreter.Nathan Binkert
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-09eventq: Don't use inline friend function when a static function will do.Nathan Binkert
Another good reason to avoid this is that swig will try to wrap the friend, but it won't try to wrap a private static function.
2008-10-09SCons: add code to provide a libm5 shared library.Nathan Binkert
Targets look like libm5_debug.so. This target can be dynamically linked into another C++ program and provide just about all of the M5 features. Additionally, this library is a standalone module that can be imported into python with an "import libm5_debug" type command line.
2008-10-09eventq: I'm sick of the warning about MaxTick being unused.Nathan Binkert
2008-10-02Output: Verify output files are open after opening them.Ali Saidi
2008-09-29Fix EVENTQ_DEBUG vs DEBUG_EVENTQ #define inconsistency.Steve Reinhardt
2008-09-19We're using the static keyword improperly in some cases.Nathan Binkert
2008-09-19Use the proper version of C++ headersNathan Binkert
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-11params: Get rid of the remnants of the old style parameter configuration stuff.Nathan Binkert
2008-08-11params: Convert the CPU objects to use the auto generated param structs.Nathan Binkert
A whole bunch of stuff has been converted to use the new params stuff, but the CPU wasn't one of them. While we're at it, make some things a bit more stylish. Most of the work was done by Gabe, I just cleaned stuff up a bit more at the end.
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-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-08-03syscall: Avoid a compiler warning which turns into a bug.Nathan Binkert
Simply cast the result to an int and life is good.
2008-07-24syscall: Fix TTY emulation in fstat() user-mode simulation for fd 1 (stdout).Michael Adler
The code didn't set S_IFCHR in the st_mode
2008-07-23process: separate stderr from stdoutMichael Adler
- Add the option of redirecting stderr to a file. With the old behaviour, stderr would follow stdout if stdout was to a file, but stderr went to the host stderr if stdout went to the host stdout. The new default maintains stdout and stderr going to the host. Now the two can specify different files, but they will share a file descriptor if the name of the files is the same. - Add --output and --errout options to se.py to go with --input.
2008-07-23syscalls: Add a bunch of missing system calls.Michael Adler
readlink, umask, truncate, ftruncate, mkdir, and getcwd.
2008-07-23RemoteGDB: add an m5 command line option for setting or disabling remote gdb.Michael Adler
2008-07-11m5ops: clean up the m5ops stuff.Nathan Binkert
- insert warnings for deprecated m5ops - reserve opcodes for Ali's stuff - remove code for stuff that has been deprecated forever - simplify m5op_alpha
2008-07-11style: fix indentation and formatting of the pseudo insts.Nathan Binkert