Commit graph

11764 commits

Author SHA1 Message Date
Steve Reinhardt
e4b52476bc Automerge
--HG--
extra : convert_revision : 2ca18ecbf04a1de72391073d0a5309fdbbdfefda
2003-11-03 20:35:05 -08:00
Steve Reinhardt
02795babaf Fix bugs in and expand syscall emulation code.
arch/alpha/fake_syscall.cc:
    Fix a couple of bugs:
    - error return codes weren't making it through due to inadvertent cast to unsigned
    - sigreturn broken in not one but two ways
    - make all file descriptors look like plain files (not ttys)
    Added implementations of setuid, getgid, fcntl, and getdirentries from Dave Oehmke

--HG--
extra : convert_revision : 53d3f13e1b05e3bde9e68ada3774ca39fa4c0d4c
2003-11-03 20:31:15 -08:00
Steve Reinhardt
40b9a3878a Minor changes to instruction trace output.
arch/alpha/isa_desc:
    A few disassembly changes to make it easier to compare with old machine.def traces:
    - Make lds prefetches print f31 instead of r31 as dest.
    - Don't print mode suffixes on FP if SS_COMPATIBLE_DISASSEMBLY
cpu/exetrace.cc:
    Left-justify instruction in field, and increase width by 1.

--HG--
extra : convert_revision : 9ffd56728f1bb772aa3ccda5f027b93d4c3a4135
2003-11-03 20:26:51 -08:00
Andrew Schultz
29474bdf02 Fix unserialize issues with etherdev (used to leave junk as callbacks which
would segfault)

--HG--
extra : convert_revision : 3b99b507c2df576622b9304215010bbfecedf8f1
2003-11-03 18:40:09 -05:00
Nathan Binkert
959f0b228b Merge zizzer.eecs.umich.edu:/bk/m5
into zans.eecs.umich.edu:/z/binkertn/research/m5/latest

--HG--
extra : convert_revision : 2029fb26a8c971a791161c9e24dfdc1135f3aaf8
2003-11-03 16:47:53 -05:00
Nathan Binkert
c55e6b495e Make it so the quiesce instruction is conditionally enabled
arch/alpha/isa_desc:
    move the quiesce instruction out of here so I can conditionally
    enable it.
arch/alpha/pseudo_inst.cc:
    conditionally enable quiesce
arch/alpha/pseudo_inst.hh:
    add quiesce

--HG--
extra : convert_revision : e1c474c4bf8761ff58073785d82b2bec9f632885
2003-11-03 16:47:08 -05:00
Ron Dreslinski
ea233ee2aa Fix sampling cpu switchover of suspended contexts, and make some changes
to sampling config files to allow for different periods of the server and client
systems.

--HG--
extra : convert_revision : ac4b6679266884d9bc3c20abb2a817f69873cc39
2003-11-03 16:43:59 -05:00
Andrew Schultz
ad8c0da4a4 Fix etherdev so it serializes txPacket and rxPacket and fixes up the DmaRequest
correctly and remove previous serialization of DmaPhys

--HG--
extra : convert_revision : 65e919ceb573a7554c07947951a74ae321f0f4c0
2003-11-03 16:29:32 -05:00
Andrew Schultz
c23eb836d5 Added serialization for DmaPhys structs and serialize DmaRequest::phys
--HG--
extra : convert_revision : 04f36fc5e6636c08ccb04d244a44017c7d0969ac
2003-11-03 14:33:02 -05:00
Ron Dreslinski
2d265afed2 Fix unserialize so that it still gos through the entire tree,
but warns if it doesn't find a section.  Used to stop if a section
didn't exist, but it's children might still exist.

--HG--
extra : convert_revision : d3f511b69bec26a80cb004d83c385df3de13f004
2003-11-03 12:17:55 -05:00
Ron Dreslinski
7eb9683cc1 Fix segfault from unserialization, add system_sample as a configuration
--HG--
extra : convert_revision : 41604400cb4b334dcffded44b77fa63658d8b096
2003-11-03 11:03:13 -05:00
Steve Reinhardt
2ac054386d Print a warning rather than failing if we're unserializing and there's an
object in the config that was not in the checkpointed config.
This code compiles, but I haven't tested it... I'm committing it so Ron
can have it.  Should not effect anything that currently works.

base/inifile.cc:
base/inifile.hh:
    Add sectionExists() method so you can query whether a section exists
    without knowing any of the entry names that would be in it.
sim/serialize.cc:
sim/serialize.hh:
    Add Checkpoint::sectionExists() (pass through to IniFile).

--HG--
extra : convert_revision : 905db122afdfe55946ab8493ccac0b1e715bc7c6
2003-11-02 21:49:15 -08:00
Ron Dreslinski
34c8821970 Merge zizzer:/m5/Bitkeeper/m5
into zamp.eecs.umich.edu:/amd/brio/y/rdreslin/m5bk/unclean

--HG--
extra : convert_revision : e142f9ad3528027accf9e03366357c006a9a1857
2003-11-02 23:20:50 -05:00
Nathan Binkert
491fb95919 ok, let's get this right
arch/alpha/pseudo_inst.cc:
    yes is not a real value, use true

--HG--
extra : convert_revision : 30b998ae6f13641d70c9158777a12b00df8742fe
2003-11-02 22:12:20 -05:00
Nathan Binkert
c307c22257 Fix a bug in the pseudo instruction context
arch/alpha/pseudo_inst.cc:
    Don't forget the descriptions

--HG--
extra : convert_revision : f208ea24d5b34283e962916cb4c7dff976406285
2003-11-02 21:58:23 -05:00
Ron Dreslinski
34c1ae0e5d Merge zizzer:/m5/Bitkeeper/m5
into zamp.eecs.umich.edu:/amd/brio/y/rdreslin/m5bk/unclean

--HG--
extra : convert_revision : e388676c83f75c5f19d58b5ed42d41942ff5e2cb
2003-11-02 20:56:41 -05:00
Nathan Binkert
136ee73a58 Add the option to ignore some of the pseudo instructions
--HG--
extra : convert_revision : 2010782749ca9c5dd029f71480956b8a1fa96394
2003-11-02 20:52:40 -05:00
Nathan Binkert
d76445f9f3 Move the m5 pseudo instructions into their own file
arch/alpha/isa_desc:
    Move the pseudo instructions out of the isa_desc, into their own
    file and call out to them when they're to be accessed
sim/sim_events.cc:
sim/sim_events.hh:
sim/sim_exit.hh:
    move SimExit to sim_exit.cc

--HG--
extra : convert_revision : 1c393adb1c18bd0fef065057d7f4e9cf60ac4197
2003-11-02 20:43:39 -05:00
Ron Dreslinski
d666d02b0b Merge zizzer:/m5/Bitkeeper/m5
into zamp.eecs.umich.edu:/amd/brio/y/rdreslin/m5bk/unclean

--HG--
extra : convert_revision : 40b955025db858628804bca3d0a155813ea81bf7
2003-11-02 19:38:51 -05:00
Ron Dreslinski
34620649de General fixes for Sampling CPU in full system mode, and serialization of sampling CPU
cpu/intr_control.cc:
    Fix the reference to the cpu, to look up which cpu is being used
    In sampling mode can't use an absolute pointer to the cpu, use the
    exeContexts vector
cpu/intr_control.hh:
    Add two new functions to simplify MP interrupts, fix it for sampling CPU model

--HG--
extra : convert_revision : a69cdbb81e6aefa3fd5385416713c689300bbea8
2003-11-02 19:38:22 -05:00
Steve Raasch
f0e2c80829 Merge zizzer.eecs.umich.edu:/m5/Bitkeeper/m5
into zizzer.eecs.umich.edu:/y/sraasch/head

--HG--
extra : convert_revision : f63c01cd6e002028879925e4c2c051de038f5e44
2003-11-02 19:29:28 -05:00
Steve Raasch
c6ffba9fa2 Add binning support
--HG--
extra : convert_revision : edb922d3a4422cedc5c0c7efbac7124b5184165f
2003-11-02 19:29:14 -05:00
Nathan Binkert
667cbb6690 Implement more m5 pseduo opcodes:
resetstats
dumpstats
dumpresetstats
m5checkpoint

Lots of cleanup of serialization and stats dumping/resetting to
work with these new instructions

arch/alpha/isa_desc:
    Implement more m5 pseduo opcodes:
    resetstats
    dumpstats
    dumpresetstats
    m5checkpoint

    All of these functions take two optional parameters, the first is a delay,
    and the second is a period.  The delay tells the simulator to wait the
    specified number of nanoseconds before triggering the event, the period
    tells the simulator to repeat the event with a specified frequency
base/statistics.cc:
base/statistics.hh:
    regReset RegResetCallback
dev/disk_image.cc:
    serializeFilename -> CheckpointFile()
sim/debug.cc:
    Move this debugging statement to sim_stats.cc
sim/eventq.cc:
    Don't AutoDelete an event if it is scheduled since the process()
    function could potentially schedule the event again.
sim/main.cc:
    DumpStatsEvent is now Statistics::SetupEvent(Dump, curTick)
sim/serialize.cc:
    Change the serialize event so that it's possible to cause the
    event to repeat.  Also make the priority such that the event
    happens just before the simulator would exit if both events
    were scheduled for the same cycle.

    get rid of the serializeFilename variable and provide a CheckpointFile()
    function.  This function takes a basename that is set in the
    configuration, and appends the current cycle to the name so that
    multiple checkpoints can be dumped from the same simulation.

    Also, don't exit the simulation when a checkpoint file is dumped.
sim/serialize.hh:
    serializeFilename -> CheckpointFile()
    SetupCheckpoint function to tell the simulator to prepare
    to checkpoint at a certain time with a certain period
sim/sim_events.cc:
    DumpStatsEvent stuff gets move to sim_stats.(cc|hh)
    The context stuff gets moved into the already existing
    stats context in stat_context.cc
sim/sim_events.hh:
    DumpStatsEvent stuff gets move to sim_stats.(cc|hh)
sim/universe.cc:
    Provide some simple functions for converting times into
    ticks.  These use floating point math to get as close as
    possible to the real values.  Multipliers are set up ahead
    of time

--HG--
extra : convert_revision : d06ef26a9237529a1e5060cb1ac2dcc04d4ec252
2003-11-02 18:02:58 -05:00
Nathan Binkert
3e87070209 Prevent make from being smart about sccs
--HG--
extra : convert_revision : d9fdb32c87c8511aace91850867fc00d00855fe6
2003-11-02 13:05:14 -05:00
Nathan Binkert
780b3b4bcd SimExit takes a time now
arch/alpha/isa_desc:
    regen

--HG--
extra : convert_revision : a9da9d2a5fc8a0414491e437747cde48dfb61a20
2003-11-02 13:01:08 -05:00
Nathan Binkert
03ef1a0c09 If a filter isn't specified, don't try to do any filtering
If pcap_lookupnet fails, just assume the netmask is 0xffffff00
that's all we really wanted from it anyway.

--HG--
extra : convert_revision : ac0a390ddb7a6b0a4e4c6d2885bfa7bd059faf36
2003-11-02 02:13:04 -05:00
Nathan Binkert
c7d6745b07 deprecate the m5exit instruction and rename it to m5exit_old
Implement a new m5exit instruction with an optional delay

arch/alpha/isa_desc:
    move m5exit to m5exit old.  The old version of the
    instruction is now deprecated

    Implement the new exit instruction with the optional delay
sim/sim_events.cc:
sim/sim_events.hh:
    Make SimExit take a cycle
sim/universe.cc:
    provide ticksPerMS, ticksPerUS, and ticksPerNS so we don't
    have to do math during the cycle

--HG--
extra : convert_revision : e2ed47a2e5cfcd57c82086c6fcb4a28bf801c214
2003-11-02 02:07:31 -05:00
Nathan Binkert
7c6fa585ca Merge zizzer.eecs.umich.edu:/bk/m5
into zans.eecs.umich.edu:/z/binkertn/research/m5/latest

--HG--
extra : convert_revision : 7fd03e2b9f776bf035ad8c758aaf349c35cee47f
2003-11-02 01:09:10 -05:00
Nathan Binkert
1cd3757db9 add several new functions that can be called from the guest
to tell the simulator to do something.
exit -> exit_old (deprecated
exit now takes an optional parameter that tells it to execute at a
specified time in the future

The next four functions have two optional parameters.  The first
specifies a delay for how long to wait to issue the instruction.
The second will tell the simulator to repeat that command
at the specified interval.

checkpoint will trigger a checkpoint
dumpstats will cause the simulator to dump stats
resetstats will cause all stats to be reset
dumpreset will dump and reset stats


all times are in nanoseconds

util/m5/Makefile:
    Clean up to make it a bit easier to muck with
util/m5/m5.c:
    Add a bunch of new commands and clean up the command parsing path
    Convert atoi to strtoul so that we can use 64bit numbers and even
    hex if we want to.  (this runs on alpha, so a long is 64bit)
util/m5/m5op.h:
    add prototypes for new m5 instructions
    use uint64_t since it's nicer

--HG--
extra : convert_revision : 664ff00f0f0dfc5263c4e873d82fd9996a4521e9
2003-11-02 01:08:59 -05:00
Lisa Hsu
949a0634a4 iqueue.cc:
don't clear stat fullCount in the constructor for iq.
it comes cleared.

--HG--
extra : convert_revision : 80e09cfbdebd67615892cd1178bb0f8cfb5fc04f
2003-11-02 01:07:43 -05:00
Nathan Binkert
a800d6abf7 Merge zizzer.eecs.umich.edu:/bk/m5
into zans.eecs.umich.edu:/z/binkertn/research/m5/latest

--HG--
extra : convert_revision : 8f2ced105b0a14bd4b0c0b52ed9c7b1c2ddc6e18
2003-11-02 00:35:40 -05:00
Nathan Binkert
f74dac9d96 Add basic.ini which is a barebones system that has nothing
disk1.ini provides #defines that can be set to configure a second disk

--HG--
extra : convert_revision : 0997063cd97dd66aea36402712998f65e23714b3
2003-11-02 00:35:31 -05:00
Ron Dreslinski
394d34beb3 Merge zamp.eecs.umich.edu:/amd/brio/y/rdreslin/m5bk/clean
into zamp.eecs.umich.edu:/amd/brio/y/rdreslin/m5bk/unclean

--HG--
extra : convert_revision : 89cecb54210ad4ec1b5062f091d7355b18b324e6
2003-11-01 23:03:17 -05:00
Ron Dreslinski
095962c914 Fix overwritting and ordering issues with serialization routines
dev/disk_image.cc:
    seperate serialization output files for different cow images

--HG--
extra : convert_revision : b62551f8e3f6315bb92ae3cb44e077d8084cbfe7
2003-11-01 23:00:40 -05:00
Lisa Hsu
249aaff329 statistics.hh:
add enum to Bin::VectorBin

base/statistics.hh:
    add enum to Bin::VectorBin

--HG--
extra : convert_revision : a05aef30ca85bf5c0d1f5155e1dff3fb34fd7777
2003-11-01 18:17:46 -05:00
Nathan Binkert
a6a5df529e Factor out the client/server network part into its own
.ini file that we #include and add a DUMPFILE option
for dumping a ethertrace

--HG--
extra : convert_revision : 96fec0710a6f788890f3764e4ef078d53723c6dd
2003-11-01 17:53:39 -05:00
Nathan Binkert
2fd2ed16f7 gah! how did this ever work? time uses Tick, not unsigned!
--HG--
extra : convert_revision : caf246d12be97988573d4775325a41ff94c9afe1
2003-11-01 16:26:19 -05:00
Nathan Binkert
c4dd30662b Licenses
--HG--
extra : convert_revision : ce47fdfaa5c59480a1fb38d86eed7d16ab7b5fc1
2003-11-01 14:11:29 -05:00
Steve Reinhardt
dc8370852f Make error messages more informative on a non-full-system fault.
base/misc.cc:
    Add curTick to panic and warn messages.
    Reformat fatal message a bit for consistency.

--HG--
extra : convert_revision : 171da2fe6ca5e25982058ee1af67473292659103
2003-11-01 10:59:06 -08:00
Nathan Binkert
9ce1edeb0c Merge zizzer.eecs.umich.edu:/bk/m5
into zans.eecs.umich.edu:/z/binkertn/research/m5/latest

--HG--
extra : convert_revision : 3536754864ead5d7c95a2a8a1b6edd2fb70f5a88
2003-11-01 13:53:23 -05:00
Nathan Binkert
6cc2783217 .cvsignore files don't really do anything for us anymore, so
let's make bitkeeper ignore the stuff.

--HG--
extra : convert_revision : 8ea2a403c7ba2a3c9bd44269a2c0ede9294c92d4
2003-11-01 13:53:08 -05:00
Steve Reinhardt
64198ba6ff Get rid of obsolete backtrace code.
--HG--
extra : convert_revision : 3f5b938e0f64fac5e1c060d82d7f6906521b2174
2003-11-01 10:45:23 -08:00
Nathan Binkert
15613161c2 Commit a command for use inside a simulated system for communicating
with the simulator.  This program is generally compiled as the name
m5 and installed in /usr/local/bin

This command uses opcodes that are invalid on a normal system, so
don't expect it to do anything on a real system.

--HG--
extra : convert_revision : fcbae99d4b0d38ff4a9950f1ab53923baa1f667a
2003-11-01 13:20:44 -05:00
Andrew Schultz
59eeb1bb52 eventq.cc, eventq.hh:
Cleaned up serialization

sim/eventq.hh:
sim/eventq.cc:
    Cleaned up serialization

--HG--
extra : convert_revision : b75696d75f1aee16ebca2076fdd3cd4913593762
2003-10-31 22:09:18 -05:00
Andrew Schultz
518654dce4 Fix mistake, used readRequest.name twice
--HG--
extra : convert_revision : 0f8fa5f5487223c78402af79b42cf18f7b5022c0
2003-10-31 18:38:52 -05:00
Nathan Binkert
166def1f56 Merge zizzer.eecs.umich.edu:/m5/Bitkeeper/m5
into zizzer.eecs.umich.edu:/.automount/zans/z/binkertn/research/m5/latest

--HG--
extra : convert_revision : 3134761fa4c572a672558dfb6f9252aaef7b7062
2003-10-31 18:28:05 -05:00
Nathan Binkert
5341e1aa9e Make the to_number function work better.
base/str.cc:
    Make some fixes for the to_number function.
    Fix overflow calculation for maximum decimal value.
    (Note: minimum decimal value for signed numbers does not
    work correctly, e.g. it will overflow on -128 for a signed char
    though -127 will work)
    Fix overflow calculation for hex values being converted into
    signed types
    Fix up the debugging stuff a little to make sure the values are
    always printed as numbers.
test/strnumtest.cc:
    using namespace std for g++ 3

--HG--
extra : convert_revision : b00bb1296c85c3d64d8864283c9374e1563bfa31
2003-10-31 18:27:17 -05:00
Andrew Schultz
60da271e1d Merge zizzer:/bk/m5
into ascender.eecs.umich.edu:/.automount/zizzer/z/alschult/sandbox/m5-change

--HG--
extra : convert_revision : 1ce2a98c531502cbf0c8eb4b365f14a893dc0f5d
2003-10-31 18:05:12 -05:00
Andrew Schultz
e8b9537d11 Serialization support for serializing between DmaHolder simobjects and DmaEngine
--HG--
extra : convert_revision : 85de62b4066595a3139029a6ccc1c1e84526a0be
2003-10-31 18:05:00 -05:00
Andrew Schultz
2ab51fbcdb Changed the naming of Serializeable derived objects. Serializeable no longer has
objName as a member, instead it has the pure virtual function name().  SimObject
now has a objName member, and all classes derived directly from Serializeable
have to implement a name() function (which now makes them unique by pointer value)

cpu/simple_cpu/simple_cpu.cc:
    Change initialization of Event to get rid of Serializeable naming
dev/etherlink.cc:
dev/etherlink.hh:
    Seralizeable derived naming changes
sim/eventq.cc:
    Serializeable derived naming changes, also changed serialization process so it
    doesn't need to use nameChildren
sim/eventq.hh:
    Serializeable derived naming changes, remove constructor for specifying event name
sim/serialize.cc:
    Serializeable derived naming changes, remove setName function and the child naming
    pass for serialization
sim/serialize.hh:
    Serializeable derived naming changes, removed nameChildren, setName
sim/sim_object.cc:
sim/sim_object.hh:
    Serializeable derived naming changes

--HG--
extra : convert_revision : 67bcc275b6c210f7049f98a1ad0d22e8f5596a63
2003-10-31 17:32:04 -05:00