gem5.git
15 years agostats: Move flags into info.hh and use base/flags.hh to manage the flags
Nathan Binkert [Wed, 22 Apr 2009 20:38:01 +0000 (13:38 -0700)]
stats: Move flags into info.hh and use base/flags.hh to manage the flags

15 years agostats: Shuffle around info stuff so it can be accessed separately
Nathan Binkert [Wed, 22 Apr 2009 20:38:00 +0000 (13:38 -0700)]
stats: Shuffle around info stuff so it can be accessed separately

15 years agostats: Rename the info classes to hopefully make things a bit clearer
Nathan Binkert [Wed, 22 Apr 2009 20:38:00 +0000 (13:38 -0700)]
stats: Rename the info classes to hopefully make things a bit clearer
FooInfoBase became FooInfo
FooInfo became FooInfoProxy

15 years agostats: update reference outputs now that compatibility is gone
Nathan Binkert [Wed, 22 Apr 2009 17:25:17 +0000 (10:25 -0700)]
stats: update reference outputs now that compatibility is gone
Because of the initialization bug, it wasn't consistent anyway.

15 years agostats: remove simplescalar compatibility for printing
Nathan Binkert [Wed, 22 Apr 2009 17:25:14 +0000 (10:25 -0700)]
stats: remove simplescalar compatibility for printing

15 years agostats: fix initialization bug in distribution text output
Nathan Binkert [Wed, 22 Apr 2009 13:44:29 +0000 (06:44 -0700)]
stats: fix initialization bug in distribution text output

15 years agoi8254xGBe: major style overhaul.
Steve Reinhardt [Wed, 22 Apr 2009 05:58:53 +0000 (01:58 -0400)]
i8254xGBe: major style overhaul.
Moved DescCache template functions from .hh to .cc file.
Also fixed lots of line-wrapping problems, and some irregular indentation.

15 years agoUpdate stats for new single bad-address responder.
Steve Reinhardt [Wed, 22 Apr 2009 05:55:52 +0000 (01:55 -0400)]
Update stats for new single bad-address responder.
Mostly just config.ini updates, though the different response
latency for bad addresses caused very minor timing changes
in the O3 Linux boot tests.

16 years agomem: use single BadAddr responder per system.
Steve Reinhardt [Wed, 16 Jul 2008 18:10:33 +0000 (11:10 -0700)]
mem: use single BadAddr responder per system.
Previously there was one per bus, which caused some coherence problems
when more than one decided to respond.  Now there is just one on
the main memory bus.  The default bus responder on all other buses
is now the downstream cache's cpu_side port.  Caches no longer need
to do address range filtering; instead, we just have a simple flag
to prevent snoops from propagating to the I/O bus.

15 years agoscons: Rename the basic environment from env -> main.
Nathan Binkert [Wed, 22 Apr 2009 00:17:16 +0000 (17:17 -0700)]
scons:  Rename the basic environment from env -> main.
env is used as a local variable all over the place and sometimes it is
easy to get confused as to whether the global env or local env is being
used.  This will become especially important when I change the way we
support our variants.

15 years agoscons: Fix two problems with the way that the library path is generated.
Nathan Binkert [Wed, 22 Apr 2009 00:17:15 +0000 (17:17 -0700)]
scons: Fix two problems with the way that the library path is generated.
1) -L is automatically added, so don't do it ourselves
2) prepend the paths for gzstream and libelf so they are certain to
come first. The problem is that python might add /usr/lib to the path
and the user might have a locally installed version of libelf installed.

15 years agoAutomated merge with ssh://m5sim.org//repo/m5
Nathan Binkert [Tue, 21 Apr 2009 23:04:55 +0000 (16:04 -0700)]
Automated merge with ssh://m5sim.org//repo/m5

15 years agopseudo: only include kernel stats if FULL_SYSTEM.
Nathan Binkert [Tue, 21 Apr 2009 22:40:26 +0000 (15:40 -0700)]
pseudo: only include kernel stats if FULL_SYSTEM.

15 years agoarm: include missing file for arm
Nathan Binkert [Tue, 21 Apr 2009 22:40:26 +0000 (15:40 -0700)]
arm: include missing file for arm

15 years agoarm: Unify the ARM tlb. We forgot about this when we did the rest.
Nathan Binkert [Tue, 21 Apr 2009 22:40:25 +0000 (15:40 -0700)]
arm: Unify the ARM tlb.  We forgot about this when we did the rest.
This code compiles, but there are no tests still

15 years agorundiff: flush stdout after each diff
Steve Reinhardt [Tue, 21 Apr 2009 18:34:26 +0000 (11:34 -0700)]
rundiff: flush stdout after each diff

15 years agoscons: make default target work again
Nathan Binkert [Tue, 21 Apr 2009 17:49:06 +0000 (10:49 -0700)]
scons: make default target work again

15 years agoSet up m5threads tests on classic (non-ruby) memory system.
Steve Reinhardt [Tue, 21 Apr 2009 15:37:50 +0000 (08:37 -0700)]
Set up m5threads tests on classic (non-ruby) memory system.
Just one test (40.m5threads-test-atomic) is set up for now.
These tests require that the m5threads SPARC binaries are present
in /dist or in test-progs.

15 years agosyscall_emul: style fixes (mostly wrapping overly long lines)
Steve Reinhardt [Tue, 21 Apr 2009 15:17:36 +0000 (08:17 -0700)]
syscall_emul: style fixes (mostly wrapping overly long lines)

15 years agosyscall: Resolve conflicts between m5threads and Gabe's recent SE changes.
Steve Reinhardt [Tue, 21 Apr 2009 15:17:36 +0000 (08:17 -0700)]
syscall: Resolve conflicts between m5threads and Gabe's recent SE changes.

15 years agoCommit m5threads package.
Daniel Sanchez [Tue, 21 Apr 2009 15:17:36 +0000 (08:17 -0700)]
Commit m5threads package.

This patch adds limited multithreading support in syscall-emulation
mode, by using the clone system call.  The clone system call works
for Alpha, SPARC and x86, and multithreaded applications run
correctly in Alpha and SPARC.

15 years agoSCons: Export export_vars so SConsopts files can add to them
Nathan Binkert [Tue, 21 Apr 2009 15:17:36 +0000 (08:17 -0700)]
SCons: Export export_vars so SConsopts files can add to them

15 years agoMinor tweaks for future Ruby compatibility.
Steve Reinhardt [Tue, 21 Apr 2009 15:17:36 +0000 (08:17 -0700)]
Minor tweaks for future Ruby compatibility.

15 years agorequest: add PREFETCH flag.
Steve Reinhardt [Tue, 21 Apr 2009 15:17:10 +0000 (08:17 -0700)]
request: add PREFETCH flag.

15 years agorequest: rename INST_READ to INST_FETCH.
Steve Reinhardt [Tue, 21 Apr 2009 01:54:02 +0000 (18:54 -0700)]
request: rename INST_READ to INST_FETCH.

15 years agorequest: split public and private flags into separate fields.
Steve Reinhardt [Tue, 21 Apr 2009 01:40:00 +0000 (18:40 -0700)]
request: split public and private flags into separate fields.
This frees up needed space for more public flags.  Also:
- remove unused Request accessor methods
- make Packet use public Request accessors, so it need not be a friend

15 years agoMem: Fill out the comment that describes the LOCKED request flag.
Gabe Black [Mon, 20 Apr 2009 05:00:24 +0000 (22:00 -0700)]
Mem: Fill out the comment that describes the LOCKED request flag.

15 years agoMem: Change isLlsc to isLLSC.
Gabe Black [Mon, 20 Apr 2009 04:44:15 +0000 (21:44 -0700)]
Mem: Change isLlsc to isLLSC.

15 years agoX86: Fix the functions that manipulate large bit arrays in the local APIC.
Gabe Black [Sun, 19 Apr 2009 20:47:15 +0000 (13:47 -0700)]
X86: Fix the functions that manipulate large bit arrays in the local APIC.

15 years agoX86: Fix up a copyright.
Gabe Black [Sun, 19 Apr 2009 20:17:35 +0000 (13:17 -0700)]
X86: Fix up a copyright.

15 years agoX86: Fix how the TLB handles the storecheck flag.
Gabe Black [Sun, 19 Apr 2009 11:57:51 +0000 (04:57 -0700)]
X86: Fix how the TLB handles the storecheck flag.

15 years agoX86: Recognize and handle the lock legacy prefix.
Gabe Black [Sun, 19 Apr 2009 11:57:28 +0000 (04:57 -0700)]
X86: Recognize and handle the lock legacy prefix.

15 years agoX86: Implement a locking version of XADD.
Gabe Black [Sun, 19 Apr 2009 11:56:49 +0000 (04:56 -0700)]
X86: Implement a locking version of XADD.

15 years agoX86: Implement a locking version of BTC.
Gabe Black [Sun, 19 Apr 2009 11:56:45 +0000 (04:56 -0700)]
X86: Implement a locking version of BTC.

15 years agoX86: Implement a locking version of BTR.
Gabe Black [Sun, 19 Apr 2009 11:56:43 +0000 (04:56 -0700)]
X86: Implement a locking version of BTR.

15 years agoX86: Implement a locking version of CMPXCHG.
Gabe Black [Sun, 19 Apr 2009 11:56:40 +0000 (04:56 -0700)]
X86: Implement a locking version of CMPXCHG.

15 years agoX86: Implement a locking version of BTS.
Gabe Black [Sun, 19 Apr 2009 11:56:36 +0000 (04:56 -0700)]
X86: Implement a locking version of BTS.

15 years agoX86: Implement a locking version of DEC.
Gabe Black [Sun, 19 Apr 2009 11:56:34 +0000 (04:56 -0700)]
X86: Implement a locking version of DEC.

15 years agoX86: Implement a locking version of INC.
Gabe Black [Sun, 19 Apr 2009 11:56:31 +0000 (04:56 -0700)]
X86: Implement a locking version of INC.

15 years agoX86: Implement a locking version of NEG.
Gabe Black [Sun, 19 Apr 2009 11:56:28 +0000 (04:56 -0700)]
X86: Implement a locking version of NEG.

15 years agoX86: Implement a locking version of NOT.
Gabe Black [Sun, 19 Apr 2009 11:56:25 +0000 (04:56 -0700)]
X86: Implement a locking version of NOT.

15 years agoX86: Implement a locking version of XCHG.
Gabe Black [Sun, 19 Apr 2009 11:56:22 +0000 (04:56 -0700)]
X86: Implement a locking version of XCHG.

15 years agoX86: Implement a locking version of XOR.
Gabe Black [Sun, 19 Apr 2009 11:56:20 +0000 (04:56 -0700)]
X86: Implement a locking version of XOR.

15 years agoX86: Implement a locking version of SUB.
Gabe Black [Sun, 19 Apr 2009 11:56:16 +0000 (04:56 -0700)]
X86: Implement a locking version of SUB.

15 years agoX86: Implement a locking version of AND.
Gabe Black [Sun, 19 Apr 2009 11:56:14 +0000 (04:56 -0700)]
X86: Implement a locking version of AND.

15 years agoX86: Implement a locking version of SBB.
Gabe Black [Sun, 19 Apr 2009 11:56:11 +0000 (04:56 -0700)]
X86: Implement a locking version of SBB.

15 years agoX86: Implement a locking version of ADC.
Gabe Black [Sun, 19 Apr 2009 11:56:08 +0000 (04:56 -0700)]
X86: Implement a locking version of ADC.

15 years agoX86: Implement a locking version of OR.
Gabe Black [Sun, 19 Apr 2009 11:56:06 +0000 (04:56 -0700)]
X86: Implement a locking version of OR.

15 years agoX86: Implement a locking version of ADD.
Gabe Black [Sun, 19 Apr 2009 11:56:02 +0000 (04:56 -0700)]
X86: Implement a locking version of ADD.

15 years agoX86: Implement the stul microop.
Gabe Black [Sun, 19 Apr 2009 11:55:58 +0000 (04:55 -0700)]
X86: Implement the stul microop.
This microop does a store and unlocks the requested address. The RISC86
microop ISA doesn't seem to have an equivalent to this, so I'm guessing that
the store following an ldstl is automatically unlocking. We don't do it this
way for performance reasons since the behavior is the same.

15 years agoX86: Implement the ldstl microop.
Gabe Black [Sun, 19 Apr 2009 11:55:43 +0000 (04:55 -0700)]
X86: Implement the ldstl microop.
This microop does a load, checks that a store would succeed, and locks the
requested address.

15 years agoCPUs: Make the atomic CPU support locked memory accesses.
Gabe Black [Sun, 19 Apr 2009 11:50:07 +0000 (04:50 -0700)]
CPUs: Make the atomic CPU support locked memory accesses.

15 years agoMemory: Add a LOCKED flag back in for x86 style locking.
Gabe Black [Sun, 19 Apr 2009 11:39:25 +0000 (04:39 -0700)]
Memory: Add a LOCKED flag back in for x86 style locking.

15 years agoMemory: Rename LOCKED for load locked store conditional to LLSC.
Gabe Black [Sun, 19 Apr 2009 11:25:01 +0000 (04:25 -0700)]
Memory: Rename LOCKED for load locked store conditional to LLSC.

15 years agoSE mode: Make keeping track of the number of syscalls less hacky.
Gabe Black [Sun, 19 Apr 2009 11:15:32 +0000 (04:15 -0700)]
SE mode: Make keeping track of the number of syscalls less hacky.

15 years agoX86: Actually put the PCI INTA entry into the MP tables.
Gabe Black [Sun, 19 Apr 2009 11:15:18 +0000 (04:15 -0700)]
X86: Actually put the PCI INTA entry into the MP tables.

15 years agoX86: Mask the PIC at startup to avoid a glitch which causes an NMI.
Gabe Black [Sun, 19 Apr 2009 11:15:06 +0000 (04:15 -0700)]
X86: Mask the PIC at startup to avoid a glitch which causes an NMI.

15 years agoX86: Make E820 report nice, round (and correct) numbers.
Gabe Black [Sun, 19 Apr 2009 11:14:48 +0000 (04:14 -0700)]
X86: Make E820 report nice, round (and correct) numbers.

15 years agoX86: Actually handle 16 bit mode modrm.
Gabe Black [Sun, 19 Apr 2009 11:14:31 +0000 (04:14 -0700)]
X86: Actually handle 16 bit mode modrm.

15 years agoX86: Make the TEST instruction set all the flags it's supposed to.
Gabe Black [Sun, 19 Apr 2009 11:14:16 +0000 (04:14 -0700)]
X86: Make the TEST instruction set all the flags it's supposed to.

15 years agoX86: Implement broadcast IPIs.
Gabe Black [Sun, 19 Apr 2009 11:14:01 +0000 (04:14 -0700)]
X86: Implement broadcast IPIs.

15 years agoX86: Fix the ordering of the vendor string reported by CPUID.
Gabe Black [Sun, 19 Apr 2009 11:13:45 +0000 (04:13 -0700)]
X86: Fix the ordering of the vendor string reported by CPUID.

15 years agoX86: Keep track of what the initial count value was in the LAPIC timer.
Gabe Black [Sun, 19 Apr 2009 10:56:57 +0000 (03:56 -0700)]
X86: Keep track of what the initial count value was in the LAPIC timer.

15 years agoX86: Only recognize the first startup IPI after INIT or reset.
Gabe Black [Sun, 19 Apr 2009 10:56:36 +0000 (03:56 -0700)]
X86: Only recognize the first startup IPI after INIT or reset.

15 years agoX86: Use recvResponse to implement the idle bit in the Local APIC ICR.
Gabe Black [Sun, 19 Apr 2009 10:56:24 +0000 (03:56 -0700)]
X86: Use recvResponse to implement the idle bit in the Local APIC ICR.

15 years agoX86: Add a function which gets called when an interrupt message has been delivered.
Gabe Black [Sun, 19 Apr 2009 10:54:11 +0000 (03:54 -0700)]
X86: Add a function which gets called when an interrupt message has been delivered.

15 years agoX86: Fix the flags for interrupt response messages.
Gabe Black [Sun, 19 Apr 2009 10:53:29 +0000 (03:53 -0700)]
X86: Fix the flags for interrupt response messages.

15 years agoX86: Explicitly use the right width in a few places that need a 64 bit value.
Gabe Black [Sun, 19 Apr 2009 10:47:59 +0000 (03:47 -0700)]
X86: Explicitly use the right width in a few places that need a 64 bit value.

15 years agoX86: Keep track of the pioAddr for the local APIC.
Gabe Black [Sun, 19 Apr 2009 10:47:12 +0000 (03:47 -0700)]
X86: Keep track of the pioAddr for the local APIC.

15 years agoX86: Implement far jmp.
Gabe Black [Sun, 19 Apr 2009 10:42:41 +0000 (03:42 -0700)]
X86: Implement far jmp.

15 years agoX86: Some segment selectors can be used when "NULL".
Gabe Black [Sun, 19 Apr 2009 10:41:10 +0000 (03:41 -0700)]
X86: Some segment selectors can be used when "NULL".

15 years agoX86: Fix a bug in the chks microop where it ignored that it found a fault.
Gabe Black [Sun, 19 Apr 2009 10:40:08 +0000 (03:40 -0700)]
X86: Fix a bug in the chks microop where it ignored that it found a fault.

15 years agoX86: Make the interrupt entering microcode record the value to use, not actually...
Gabe Black [Sun, 19 Apr 2009 10:36:57 +0000 (03:36 -0700)]
X86: Make the interrupt entering microcode record the value to use, not actually use it.

15 years agoX86: LEA calculates an address before segmentation.
Gabe Black [Sun, 19 Apr 2009 10:24:51 +0000 (03:24 -0700)]
X86: LEA calculates an address before segmentation.

15 years agoX86: Implement the save machine status word instruction (SMSW).
Gabe Black [Sun, 19 Apr 2009 10:22:38 +0000 (03:22 -0700)]
X86: Implement the save machine status word instruction (SMSW).

15 years agoX86: Implement the load machine status word instruction (LMSW).
Gabe Black [Sun, 19 Apr 2009 10:17:14 +0000 (03:17 -0700)]
X86: Implement the load machine status word instruction (LMSW).

15 years agoX86: Update the stats for the fix for CPUID.
Gabe Black [Sun, 19 Apr 2009 10:14:33 +0000 (03:14 -0700)]
X86: Update the stats for the fix for CPUID.

15 years agoX86: Only use %eax to select a function and look like we support sse2.
Gabe Black [Sun, 19 Apr 2009 10:11:24 +0000 (03:11 -0700)]
X86: Only use %eax to select a function and look like we support sse2.

15 years agoX86: Fix the mov to segment selector in real mode instruction microcode.
Gabe Black [Sun, 19 Apr 2009 10:08:40 +0000 (03:08 -0700)]
X86: Fix the mov to segment selector in real mode instruction microcode.

15 years agoX86: The startup IPI delivery mode is not reserved.
Gabe Black [Sun, 19 Apr 2009 10:01:46 +0000 (03:01 -0700)]
X86: The startup IPI delivery mode is not reserved.

15 years agoX86: Implement the STARTUP IPI.
Gabe Black [Sun, 19 Apr 2009 09:56:03 +0000 (02:56 -0700)]
X86: Implement the STARTUP IPI.

15 years agoX86: Implement the INIT IPI.
Gabe Black [Sun, 19 Apr 2009 09:53:00 +0000 (02:53 -0700)]
X86: Implement the INIT IPI.

15 years agoX86: Fix the halt microop.
Gabe Black [Sun, 19 Apr 2009 09:51:09 +0000 (02:51 -0700)]
X86: Fix the halt microop.

15 years agoX86: Start implementing the interrupt command register in the local APIC.
Gabe Black [Sun, 19 Apr 2009 09:43:22 +0000 (02:43 -0700)]
X86: Start implementing the interrupt command register in the local APIC.

15 years agoX86: Make code that sends an interrupt from the IO APIC available for IPIs.
Gabe Black [Sun, 19 Apr 2009 09:42:19 +0000 (02:42 -0700)]
X86: Make code that sends an interrupt from the IO APIC available for IPIs.

15 years agoX86: Automatically make the IO APIC in an N CPU system have id N+1.
Gabe Black [Sun, 19 Apr 2009 09:39:19 +0000 (02:39 -0700)]
X86: Automatically make the IO APIC in an N CPU system have id N+1.

15 years agoCPU: If the simple CPU is already idle, just return from suspendContext, don't assert.
Gabe Black [Sun, 19 Apr 2009 09:23:29 +0000 (02:23 -0700)]
CPU: If the simple CPU is already idle, just return from suspendContext, don't assert.

15 years agoX86: Condense the startupCPU code.
Gabe Black [Sun, 19 Apr 2009 09:20:57 +0000 (02:20 -0700)]
X86: Condense the startupCPU code.

15 years agoX86: Set the local APIC ID to something meaningful.
Gabe Black [Sun, 19 Apr 2009 09:16:49 +0000 (02:16 -0700)]
X86: Set the local APIC ID to something meaningful.

15 years agoX86: Don't pretend to be an AMD CPU any more. We're not good enough at it.
Gabe Black [Sun, 19 Apr 2009 09:06:51 +0000 (02:06 -0700)]
X86: Don't pretend to be an AMD CPU any more. We're not good enough at it.

15 years agoo3-mips-regress: add hello word regression.
Korey Sewell [Sat, 18 Apr 2009 14:42:29 +0000 (10:42 -0400)]
o3-mips-regress: add hello word regression.

15 years agomips-tlb-fix: check for alignment faults.\nMIPS was never updated to use TLBS correct...
Korey Sewell [Sat, 18 Apr 2009 14:42:29 +0000 (10:42 -0400)]
mips-tlb-fix: check for alignment faults.\nMIPS was never updated to use TLBS correcty in SE mode. The error was forwarding translations directly to pageTable. The TLB should check for alignment faults at bare minimum here but in the long run we should be using TLBs in SE mode for MIPS.

15 years agomips-syscall: mark with correct flag. \nMIPS was using wrong serialization flag on...
Korey Sewell [Sat, 18 Apr 2009 14:42:29 +0000 (10:42 -0400)]
mips-syscall: mark with correct flag. \nMIPS was using wrong serialization flag on syscall instructions allowing O3 to handle SE mode syscalls incorrectly and speculate on instructions after a syscall

15 years agoo3-delay-slot-bpred: fix decode stage handling of uncdtl. branches.\n decode stage...
Korey Sewell [Sat, 18 Apr 2009 14:42:29 +0000 (10:42 -0400)]
o3-delay-slot-bpred: fix decode stage handling of uncdtl. branches.\n decode stage was not setting the predicted PC correctly or passing that information back to fetch correctly

15 years agomips-shadowsets: fix calcuations. \n Remove Shadowsets from Int & Arch. Reg Calculations
Korey Sewell [Sat, 18 Apr 2009 14:42:28 +0000 (10:42 -0400)]
mips-shadowsets: fix calcuations. \n  Remove Shadowsets from Int & Arch. Reg Calculations

15 years agoo3, inorder: fix FS bug due to initializing ThreadState to Halted.
Steve Reinhardt [Fri, 17 Apr 2009 23:54:58 +0000 (16:54 -0700)]
o3, inorder: fix FS bug due to initializing ThreadState to Halted.
For some reason o3 FS init() only called initCPU if the thread state
was Suspended, which was no longer the case.  There's no apparent
reason to check, so I whacked the test completely rather than
changing the check to Halted.
The inorder init() was also updated to be symmetric, though the
previous code was just a fancy no-op.

15 years agoo3: handle fetch with no active threads correctly.
Steve Reinhardt [Thu, 16 Apr 2009 06:12:00 +0000 (23:12 -0700)]
o3: handle fetch with no active threads correctly.
This situation can arise now on the first fetch cycle after
the last active thread is halted.  It seems easy enough to
deal with when it happens rather than trying to avoid it.

15 years agoo3: fix {read,set}ArchFloatReg* functions.
Steve Reinhardt [Thu, 16 Apr 2009 06:10:43 +0000 (23:10 -0700)]
o3: fix {read,set}ArchFloatReg* functions.
Register indices were not being calculated properly.

15 years agoThreadState: initialize status to Halted in constructor.
Steve Reinhardt [Wed, 15 Apr 2009 20:18:24 +0000 (13:18 -0700)]
ThreadState: initialize status to Halted in constructor.
This provides a common initial status for all threads independent
of CPU model (unlike the prior situation where CPUs initialized
threads to inconsistent states).
This mostly matters for SE mode; in FS mode, ISA-specific startupCPU()
methods generally handle boot-time initialization of thread contexts
(since the right thing to do is ISA-dependent).

15 years agoUpdate stats after elimination of Unallocated state.
Steve Reinhardt [Wed, 15 Apr 2009 20:13:58 +0000 (13:13 -0700)]
Update stats after elimination of Unallocated state.
Somehow ending threads with halt() instead of deallocate()
reduces the squash count on o3 by 1 (and a few other
similarly trivial changes).