Commit graph

2060 commits

Author SHA1 Message Date
Steve Reinhardt
00264ff1b8 Rename port methods:
sendBlockSizeQuery() -> peerBlockSize()
recvBlockSizeQuery() -> deviceBlockSize()
After seeing how this gets used in practice, the
send/recv*Query names just don't make a lot of sense.

dev/io_device.cc:
mem/port.cc:
    sendBlockSizeQuery() -> peerBlockSize()
mem/port.hh:
    sendBlockSizeQuery() -> peerBlockSize()
    recvBlockSizeQuery() -> deviceBlockSize()

--HG--
extra : convert_revision : e96349fb443979b85899a5248bd7cd8665e23ef0
2006-02-21 12:20:02 -05:00
Steve Reinhardt
8a753f6ae2 Move read/writeBlob functions to Port class;
clean up implementation a little.

SConscript:
    Add mem/port.cc
cpu/simple/cpu.cc:
cpu/simple/cpu.hh:
    Move read/writeBlob functions to base Port class.
mem/port.hh:
    Implement read/writeBlob functions.
    No need for them to be virtual since the proxy
    object (now called TranslatingPort) is not a
    subclass of Port.
mem/port.cc:
    Implement read/writeBlob functions.

--HG--
extra : convert_revision : a3660eaa43a7c286aca962f17fa32fbd42bf1fa6
2006-02-21 11:27:53 -05:00
Ron Dreslinski
00be4e8510 Thanks to Ali, I was able to add chunk generation code in to handle a few cases. Still have some duplicated code we may want to revisit.
cpu/simple/cpu.cc:
    Thanks to Ali I found the chunk generator, although I still seem to be duplicating some code becuase the only difference between readBlob and writeBlob is the command in the packet.  Perhaps an access function with the command as a param would help with the duplication (sendBlob that takes a cmd (maybe).
mem/translating_port.cc:
    Using the chunck generator to break it up to be in page size chunks

--HG--
extra : convert_revision : cc2e4e60c76098655e469f81c89d2c7438350fdb
2006-02-21 03:32:42 -05:00
Ron Dreslinski
562efe214c Adding some definitons for read/write blob/string. I need to locate te code stever wrote to break up address ranges into blk/page size chunks.
cpu/simple/cpu.cc:
cpu/simple/cpu.hh:
    Add read/write blob definitions, still need to break it up into blk size chunks (where was the code stever wrote for that?)
mem/physical.hh:
    Remove un-needed function (I think)
mem/port.hh:
    Default these virtual functions to panic unimplented
mem/translating_port.cc:
    Again handling read/write string properly.

    Need the stever code to break things into page size chunks yet
mem/translating_port.hh:
    Having trouble with the const declerator.  I will need to read how it works, for now it compiles if I remove it.

--HG--
extra : convert_revision : f174e06700daa9967958d18e01798270c90d6dac
2006-02-21 02:15:02 -05:00
Ron Dreslinski
75152fcaf7 Get simple cpu to compile.
Now I need to fix linking errors, probably due to missing function details in new memory objects.

cpu/exec_context.cc:
cpu/exec_context.hh:
    Fix constructor for SE mode
cpu/simple/cpu.cc:
cpu/simple/cpu.hh:
    Fix compilation errors

--HG--
extra : convert_revision : 6a58c0906340e10b654369c36f528fc17e3f19be
2006-02-21 01:01:16 -05:00
Ron Dreslinski
3391354285 Make loaders use translation port instead of proxy memory.
Also start compiling Simple CPU again.

SConscript:
    Start Compiling Simple CPU as well
base/loader/aout_object.cc:
base/loader/aout_object.hh:
base/loader/ecoff_object.cc:
base/loader/ecoff_object.hh:
base/loader/elf_object.cc:
base/loader/elf_object.hh:
base/loader/object_file.hh:
sim/process.cc:
sim/process.hh:
    Convert loaders to used translation port instead of proxy memory

--HG--
extra : convert_revision : 63275071f6a0e0d71935641205b203d94381ee44
2006-02-20 23:56:10 -05:00
Ron Dreslinski
d96de69abc Add in a new translating port that allows syscalls to translate addresses via the page table before accessing the memory port.
Other compile issues cleaned up.

SConscript:
    Changes to compile the new Translating Port.
    Split out memtester and eio support, will rework them back in after first getting a simpleCPU to work
arch/alpha/alpha_linux_process.cc:
arch/alpha/alpha_tru64_process.cc:
sim/syscall_emul.cc:
sim/syscall_emul.hh:
    Changes to use the new translating Port.
cpu/exec_context.cc:
cpu/exec_context.hh:
    Create a translating port in each execution context.
sim/process.cc:
    Fix the way we do proxy memory

--HG--
extra : convert_revision : 3d33218fe8b425a5d9ce24757f1112b4aa6001fd
2006-02-20 23:26:39 -05:00
Steve Reinhardt
b74f1b829d Revert PageTable code back to non-asid version.
mem/page_table.cc:
mem/page_table.hh:
    Revert back to non-asid version.

--HG--
extra : convert_revision : c8e8810584d4cf12eb86da43ab77ddf8551a9e6b
2006-02-20 20:53:38 -05:00
Ron Dreslinski
d142788172 More compilation fixes.
Should we add a proxy_port that does the v->p address translation?
Should the proxy port return a fault on translation errors, if we add one?

arch/alpha/alpha_linux_process.cc:
    Syscalls use a memPort through the CPU now instead of a xc functional memory.
cpu/base.hh:
    Add a pointer to the memPort syscalls will use.  Should this be a proxy_port that does address translation?
cpu/exec_context.cc:
cpu/exec_context.hh:
    Remove functional memory from the exec context
cpu/simple/cpu.cc:
    Set the memPort to be used as the syscall port as the dcache port
sim/syscall_emul.cc:
sim/syscall_emul.hh:
    Syscalls use a memPort through the CPU now instead of a xc functional memory.
    Also, fix the fact that readStringFunctional doesn't return a fault... should proxy_port handle this because it is doing the translation?

--HG--
extra : convert_revision : 1f65318c6594301a75dc4dc0c99fdd436b094a7f
2006-02-15 22:05:23 -05:00
Steve Reinhardt
b8a2d1e5c7 More progress toward compiling... partly by
fixing things, partly by ignoring CPU models
that don't currently compile.

SConscript:
    Split sources for fast, simple, and o3 CPU models into
    separate source lists.  For now none of these are included
    in the base source list, so you won't get any CPU models
    at all... but we still can't compile the other stuff so
    it's not an issue.

    Also get rid of obsolete encumbered/mem file.
base/loader/aout_object.cc:
base/loader/aout_object.hh:
base/loader/ecoff_object.cc:
base/loader/ecoff_object.hh:
base/loader/elf_object.cc:
base/loader/elf_object.hh:
base/loader/object_file.hh:
cpu/exec_context.cc:
sim/process.cc:
sim/system.cc:
sim/system.hh:
    FunctionalMemory -> Memory
cpu/pc_event.hh:
    Get rid of unused badpc.
cpu/simple/cpu.cc:
cpu/simple/cpu.hh:
    Move Port functions into .cc file.
mem/port.hh:
    Make recvAddressRangesQuery panic by default instead
    of being abstract... do CPUs need to implement this?
mem/request.hh:
    Add prefetch flags.
sim/syscall_emul.hh:
    Start to fix...

--HG--
extra : convert_revision : ece53b3855f20916caaa381598ac37e8c7adfba7
2006-02-15 17:52:49 -05:00
Kevin Lim
091e6b72cf Slightly fix compiling. Now decoder.cc fails on trying to set some flags that no longer exist (PF_EXCLUSIVE, EVICT_NEXT).
--HG--
extra : convert_revision : f7fb9c73034e3ce647681c1097ae0f627f96c0dc
2006-02-15 16:40:02 -05:00
Ron Dreslinski
90def9ea9e Changes to start making the tree use the new memory system. Trying to compile decoder.cc but fails still.
SConscript:
    Place the memory objects back in the right place
arch/alpha/isa_desc:
    Fix includes to point to the new memory requests
cpu/exec_context.hh:
    Exec context now points to memory object, fix the include paths.
    Convert to prot_read/prot_write functions instead of read and write.
    Convert to new CpuRequestPtr instead of MemReqPtr.
mem/request.hh:
    Add back in support for Request Flags (needed by decoder to tag request) Removed the flags that were associated with packets/coherence.
sim/process.hh:
    Converted to point to new memory objects

--HG--
extra : convert_revision : a0b95380915d63b53194e2a26336d6adb1a0086b
2006-02-15 14:53:02 -05:00
Ron Dreslinski
7f114ca419 Many changes that make the new mem system compile. Now to convert the rest of the tree to use the new mem system.
mem/mem_object.hh:
    Create constrtor so it compiles
mem/packet.hh:
    Fix typedefs so they compile, add in a few more headers for compilation
mem/page_table.cc:
    convert to new mem system so it compiles
mem/page_table.hh:
    fix it to the version that had asid support.  Make it compile in the new system
mem/physical.cc:
    Fix some compilation bugs
mem/physical.hh:
    Add a type that made compile fail
mem/port.hh:
    Fix a spelling error that messed up compilation
mem/request.hh:
    fix typedefs and forward declerations so it compiles

--HG--
extra : convert_revision : 580fb1ba31ada799ff0122601b8b5a8d994bb8af
2006-02-15 14:21:09 -05:00
Ron Dreslinski
3298e937d3 Merge zizzer:/z/m5/Bitkeeper/newmem
into  zazzer.eecs.umich.edu:/z/rdreslin/m5bk/newmem2

--HG--
extra : convert_revision : fd6e39398ac2461caadee6f68d168006ce3ab16f
2006-02-07 17:33:14 -05:00
Ron Dreslinski
eabb0cfc78 Pushing current state. Need to fix compilation problems, have moved the SCONS script to build memory objects first.
Some places I could have been using a forward decleration and that should be cleaned up as well.

SConscript:
    Changed to move new memory object compilation to the top.  See the errors right away.
    Will also need to update all other objects that included the old memory system to use the new one.  But not until we at least get the mem system compiling first.
mem/packet.hh:
    Adding includes and typedefs to fix compilation errors
mem/request.hh:
    Add definition for compilation issues

--HG--
extra : convert_revision : 34d9ae534a7a625445b981e81c7a1f856517cb04
2006-02-07 17:33:03 -05:00
Kevin Lim
989292a0fa Update for new memory system. Uses the ports to access memory now. Also supports the response path of the new memory system, as well as retrying accesses.
cpu/simple/cpu.cc:
    Update for new memory system.  Supports using ports to access the memory system.  The IcacheMissStall/DcacheMissStall statuses have been changed to reflect the cache returning a response after a variable latency (due to hit/miss).  They are now DcacheWaitResponse/IcacheWaitResponse.  Also supports retrying accesses.

    For now the body of the copy functions are commented out.
cpu/simple/cpu.hh:
    Update for new memory system.

--HG--
extra : convert_revision : 5a80247537d98ed690f7b6119094d9f59b4c7d73
2006-02-03 15:21:06 -05:00
Ron Dreslinski
4e36678028 Adding some more things toward having cpu->mem test in place. Still need to work on compilation issues.
mem/physical.cc:
mem/physical.hh:
    Added a stripped down version of the physical memory object

--HG--
extra : convert_revision : 26826fb316f4cac900ec648fa268f1d95bc960f1
2006-02-03 14:54:37 -05:00
Ron Dreslinski
4c40848dcc Remove non-needed functions, fix return values of completion handler.
--HG--
extra : convert_revision : 7c0cb6b13ba68650d54cdc35779517e8c4b5e3ff
2006-01-31 15:03:04 -05:00
Ron Dreslinski
0d74f27313 More changes toward making simpleCpu use new port interface.
cpu/simple/cpu.cc:
    Initialize the ports, also add Request and Packet instead of MemReq.  Initial work at ICache read in place.
cpu/simple/cpu.hh:
    Need to call the completion handler when we see a recieve.

--HG--
extra : convert_revision : a52caee6f0ceb5d9ee1e5acca63a202f5ea71359
2006-01-31 15:00:09 -05:00
Ron Dreslinski
6c7fdb1be7 More include files, removing definition of SendResult whioch isn't needed anymore
cpu/simple/cpu.hh:
    Some needed includes
mem/port.hh:
    Now we removed the sendResult and replaced with void,tick,bool don't need it defined anymore

--HG--
extra : convert_revision : aea08ec299c41b9f9a5b0da7649cef0459315139
2006-01-31 14:42:42 -05:00
Ron Dreslinski
2f644efafa Fixed some void functions with returns, first stab at cpu ports.
cpu/simple/cpu.hh:
    Adding port definitions to simple cpu, still needs work.
mem/bus.hh:
    no return for void functions

--HG--
extra : convert_revision : 42e5bc16af187d3a46eb25a15b600a8a11b88cc5
2006-01-31 14:39:41 -05:00
Ali Saidi
fccd113e2f Merge zizzer:/bk/newmem
into  zeep.eecs.umich.edu:/z/saidi/work/m5.newmem

--HG--
extra : convert_revision : 3eb1a665cb813df974aa2815a794b459473c0a77
2006-01-31 14:20:48 -05:00
Ali Saidi
4875b33467 changed sendresult -> bool,tick,void as appropriate
first crack at io devices code
made CpuRequest that derives from Request

dev/io_device.cc:
dev/io_device.hh:
    first crack at the classes for Pio and Dma devices
dev/platform.hh:
    We are going to a system pointer to get info about the memory system
mem/bus.hh:
    changed sendresult -> bool,tick,void as appropriate
mem/port.hh:
    changed sendresult -> bool,tick,void as appropriate;
    removed the sendTiming(pkt,t) call since it is not really
    implementable in a generic fashion
mem/request.hh:
    pulled items from Request into CpuRequest

--HG--
extra : convert_revision : 6213cf2b66417fa023b80884d9e623e78f5aa891
2006-01-31 14:20:39 -05:00
Ron Dreslinski
95088d141f Add proper includes
--HG--
extra : convert_revision : c5f909d00b6025cd8f14544f7e2c9c50610c0cd3
2006-01-31 14:15:33 -05:00
Ron Dreslinski
c0f012d13d Listing some of the enum structures
--HG--
extra : convert_revision : d6ba1873826ee017bf2e4975a44eb2494a323132
2006-01-31 14:09:43 -05:00
Ron Dreslinski
a1033448ea Inital split up of the header files for the new memory system. Still need to fill in some of the include files, and other data types. But this will be the starting point.
mem/bus.hh:
    Inital crack at a bus object that has ports.  Still need to clean up the include file issues.
mem/mem_object.hh:
    Decleration of a base memory object.  Derives from simobject and adds a function to get the port associated with the object.
mem/packet.hh:
    Inital crack at the packet decleration.  Still need to clean up the include file issues.
mem/port.hh:
    Inital crack at the port decleration.  Still need to clean up the include file issues.
mem/request.hh:
    Inital crack at the request decleration.  Still need to clean up the include file issues.

--HG--
extra : convert_revision : f17967d430458f91866a4639ab0cab45d835bb55
2006-01-31 12:12:49 -05:00
Steve Reinhardt
0e79d188e1 Hacks to avoid compiling in old FullCPU model.
Needed in the interim until we port the old model over
to the new interface.  Long term we should have a cleaner
solution for controlling which models get compiled in.

SConscript:
    Move old FullCPU source file list to separate full_cpu_sources
    list so we can choose to not include it in compile.
arch/isa_parser.py:
    Hack to avoid generating FullCPU execute files.
    Need a better way to control this.
cpu/exetrace.cc:
    Don't include old FullCPU-specific headers (apparently
    unnecessary anyway--or if not they should be).

--HG--
extra : convert_revision : 00d5a91a9e4d71507404b8c7f4c6e7c7b7ba3853
2006-01-29 17:35:53 -05:00
Steve Reinhardt
07948528fc Add PageTable code and SConscript fixes for new syscall emulation
memory model.  These changes really should have been part of the
previous changeset.

SConscript:
    Move System and PhysicalMemory sources from being full_system_sources
    to base_sources, since they are now used in syscall emulation also.
    Also add source files for PageTable and ProxyMemory objects.
    Actual source files for PhysicalMemory and ProxyMemory are not committed
    yet since they still need to be ported from old interface.

--HG--
extra : convert_revision : cb39e3b13d71429b7ee6082794dc09428cde989f
2006-01-29 17:28:04 -05:00
Steve Reinhardt
03a2aca9a9 Changes for Process object initialization in merged-memory environment.
System object now exists for both fullsys and syscall emulation, as the
latter needs it so that Process objects can find the shared PhysicalMemory
for initialization.
Changes are incomplete: still need to fix up Process (& EioProcess) memory
initialization and syscall emulation code for new mem interface.

arch/alpha/alpha_linux_process.cc:
arch/alpha/alpha_linux_process.hh:
arch/alpha/alpha_tru64_process.cc:
arch/alpha/alpha_tru64_process.hh:
cpu/base.cc:
cpu/base.hh:
    Take System argument in constructor.
cpu/exec_context.cc:
    Take System argument in constructor.
    Merge two constructors into a single one.
cpu/exec_context.hh:
    Take System argument in constructor.
    Merge two constructors into a single one.
    Replace dummy translation with lookup in Process object's page table.
python/m5/objects/Process.py:
    Add System parameter to Process object (& subobjects).
python/m5/objects/System.py:
    Segregate full-system only Process parameters (most of them!).
sim/process.cc:
    Take System argument in constructor.
    Move initialization to startup() callback to occur after system & cpus
    are initialized.
    Generate ProxyMemory object to pass to loader for transparent
    virtual page allocation.
sim/process.hh:
    Take System argument in constructor.
    Move initialization to startup() callback to occur after system & cpus
    are initialized.
sim/system.cc:
sim/system.hh:
    Enable System object for non-full-system too.
    Basically involved putting most of the existing code
    inside '#ifdef FULL_SYSTEM'.
    Key thing needed for syscall emulation at this point is
    the PhysicalMemory object (for Process initialization).

--HG--
extra : convert_revision : f0f34b47bd4f77b502191affd3d03b4d6d9bcdd8
2006-01-28 00:08:22 -05:00
Ali Saidi
9df80550d4 added Request struct and updated Packet as per meeting 24/01/2006
--HG--
extra : convert_revision : 61cc36306412be178cc63d78b5274e6779af0f78
2006-01-24 20:09:51 -05:00
Steve Reinhardt
f383936348 Update interface from 1/17 meeting.
--HG--
extra : convert_revision : 6d3e52e609fde1acd08f7a79c6015fc177068dec
2006-01-17 17:47:53 -05:00
Steve Reinhardt
c4b2b2927d Couple more interface additions.
--HG--
extra : convert_revision : d51a67282e28e8a4e205e237b31efbfa5ab40ef3
2006-01-16 13:19:10 -05:00
Steve Reinhardt
0ecb25898d More evolution of the new interface.
--HG--
extra : convert_revision : 22212ba23f6684f38aa810b53d48bbe0bf07a0f1
2005-12-23 16:31:01 -05:00
Steve Reinhardt
dce0c77ca2 Add ChunkGenerator object for breaking arbitrary regions
into block- or page-sized chunks.

--HG--
extra : convert_revision : 3ebdd496f9ffc6d1fcd1847c33e98ac23f1bfe66
2005-12-23 14:06:27 -05:00
Steve Reinhardt
91192dbe97 Merge zizzer.eecs.umich.edu:/z/m5/Bitkeeper/m5
into  zizzer.eecs.umich.edu:/z/stever/bk/newmem

--HG--
extra : convert_revision : 60b1d26505a7b17321840e2db4173c3e867a6a75
2005-12-23 13:51:12 -05:00
Steve Reinhardt
16bda9c03e Fix roundUp function template so explicit arg is not
needed in a few more cases.

base/intmath.hh:
    align arg to roundUp should be int, not template class
sim/process.cc:
sim/syscall_emul.hh:
    No need for explicit template arg now that roundUp is fixed.

--HG--
extra : convert_revision : f9f4639e022acb9f427e8d30d81c782504437c53
2005-12-23 13:50:35 -05:00
Steve Reinhardt
0cdcb08d90 Change base/intmath.{cc,hh} to follow m5 style.
arch/alpha/alpha_tru64_process.cc:
base/intmath.hh:
base/statistics.cc:
base/str.cc:
cpu/o3/btb.cc:
sim/process.cc:
sim/syscall_emul.hh:
    Rename intmath.hh functions to follow m5 style
    (RoundUp -> roundUp, etc.).
base/intmath.cc:
    Rename intmath.hh functions to follow m5 style
    (RoundUp -> roundUp, etc.).
    Also reindent code in m5 style.

--HG--
extra : convert_revision : 57b853002bc3c9911e122599d9062b41a06d8e6a
2005-12-23 13:32:31 -05:00
Nathan Binkert
86722d8406 tweak try1.cc
--HG--
extra : convert_revision : 7679e736db499ed7f174a97ea12851c83bc27d13
2005-12-23 01:48:58 -05:00
Nathan Binkert
facbcf88fd Merge zizzer.eecs.umich.edu:/bk/m5
into  ziff.eecs.umich.edu:/z/binkertn/research/m5/newmem

--HG--
extra : convert_revision : 87481b470fca0197474c0c08443997d7c992d836
2005-12-23 01:48:15 -05:00
Nathan Binkert
a32a66c065 Move the memory hierarchy to oldmem and leave an empty
mem directory

--HG--
extra : convert_revision : 658a8f5e915407a45d639edf4806dce159591a10
2005-12-23 01:44:06 -05:00
Nathan Binkert
627f540e31 Updates to Memory system changes document.
--HG--
extra : convert_revision : a35a76d18a6183a0aaa5dd40c330f1ec0ef2244a
2005-12-23 01:39:53 -05:00
Steve Reinhardt
89d3cc8c94 Add a more refined stab at some of the new interface.
--HG--
extra : convert_revision : 9c3de70d83e6a1515566a9b7226e798ee077466f
2005-12-22 22:00:24 -05:00
Steve Reinhardt
1a19923ead Add notes from latest memory system redesign meetings.
--HG--
extra : convert_revision : 53389e8e784e471b0fc6053ec970cd967bfe1598
2005-12-22 14:41:49 -05:00
Nathan Binkert
3b35c698ec Make ScsiController a PioDevice so it works again.
--HG--
extra : convert_revision : cd610221edc6926d120d9f3978dd9ee89f501824
2005-12-21 22:19:33 -05:00
Nathan Binkert
45ecb2b69e Create the ProxyError Exception. Raise it when an unproxy
operation fails because information is wrong or not available.

--HG--
extra : convert_revision : 1fd90c1291618b09752179cfa6894f1df495fffd
2005-12-19 02:07:06 -05:00
Nathan Binkert
adf47c95b0 Add a little bit of support to grab info for making graphs
without using the jobfile.

util/stats/db.py:
util/stats/profile.py:
    Make it possible to send job as a string and to set the system
    separately from the job.

--HG--
extra : convert_revision : 08aaebd3f9a1643bd41953b43f3b80dc97e6592f
2005-12-19 02:02:58 -05:00
Steve Reinhardt
a95fcf7df0 Make simulation termination message less threatening... maybe
people won't think they're getting an error when they're not.

--HG--
extra : convert_revision : 7622360f4f88eed9edf44480dac551d153582d8b
2005-12-06 20:00:50 -05:00
Ron Dreslinski
ffc32970f6 Two small fixes for mem_req's and Probe path with MOSI/MOESI
cpu/simple/cpu.cc:
    Properly set the Instruction Read bit in the Memory Request

--HG--
extra : convert_revision : e1a4756f32718fd8ef3ac3db16625bd6d8f07cc5
2005-12-01 18:47:36 -05:00
Ali Saidi
481219caf6 Add support for multiple streams being configured with the INITPARAM
variable

--HG--
extra : convert_revision : 2cb20845cb7f32589882850156bdd42d9024db7a
2005-11-29 18:06:15 -05:00
Nathan Binkert
36373fa465 Virtualized SINIC fixes
dev/pktfifo.hh:
    we can't modify i because it's used further down to remove
    the packet from the fifo.  Instead, copy the iterator and
    modify that to get the previous packet.
dev/sinic.cc:
    - don't change the transmit state and kick the machine unless
    we're at the head of the txList.
    - add a couple of debugging statements to figure out how far
    along we've gotten in processing a packet.
    - assert that the current tx vnic has something to do when
    we start processing the state machine.

--HG--
extra : convert_revision : 588fe2c7d810be0e3d8d39c5cc0ec8a72119517e
2005-11-28 18:40:58 -05:00