diff options
author | Ron Dreslinski <rdreslin@umich.edu> | 2005-03-10 11:56:07 -0500 |
---|---|---|
committer | Ron Dreslinski <rdreslin@umich.edu> | 2005-03-10 11:56:07 -0500 |
commit | e51850f1d2c7c754ee11612c9b663d8af0a54400 (patch) | |
tree | 8f10dcfce3669f37801d39b47c48070ab964de65 /arch/alpha/isa_traits.hh | |
parent | ffaba200d1078f19a1d56af803420a79a96f7fe2 (diff) | |
parent | 331460dfe88af6b026c30277d2904cf87ce37743 (diff) | |
download | gem5-e51850f1d2c7c754ee11612c9b663d8af0a54400.tar.xz |
Merge zizzer:/z/m5/Bitkeeper/m5
into zizzer.eecs.umich.edu:/.automount/zazzer/z/rdreslin/m5bk/timing_L1
--HG--
extra : convert_revision : a5ee8e5187503203058da35ca44918f1ff7ae1eb
Diffstat (limited to 'arch/alpha/isa_traits.hh')
-rw-r--r-- | arch/alpha/isa_traits.hh | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/arch/alpha/isa_traits.hh b/arch/alpha/isa_traits.hh index 8db8c6994..d9c1a506e 100644 --- a/arch/alpha/isa_traits.hh +++ b/arch/alpha/isa_traits.hh @@ -286,6 +286,43 @@ const int ArgumentReg1 = TheISA::ArgumentReg1; const int BranchPredAddrShiftAmt = TheISA::BranchPredAddrShiftAmt; const int MaxAddr = (Addr)-1; +#ifndef FULL_SYSTEM +class SyscallReturn { + public: + template <class T> + SyscallReturn(T v, bool s) + { + retval = (uint64_t)v; + success = s; + } + + template <class T> + SyscallReturn(T v) + { + success = (v >= 0); + retval = (uint64_t)v; + } + + ~SyscallReturn() {} + + SyscallReturn& operator=(const SyscallReturn& s) { + retval = s.retval; + success = s.success; + return *this; + } + + bool successful() { return success; } + uint64_t value() { return retval; } + + + private: + uint64_t retval; + bool success; +}; + +#endif + + #ifdef FULL_SYSTEM typedef TheISA::InternalProcReg InternalProcReg; const int NumInternalProcRegs = TheISA::NumInternalProcRegs; |