X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=src%2Fcpu%2Fo3%2Fcpu.hh;h=04472752ce2428432bfdabe5af26d6181ddd7d3a;hb=6df6f9aa98022457cff470118c88b5b8f1a6ba21;hp=ac917dba901cd74b46e2028fbe41dbfb747885ec;hpb=7584c390ebbb890642468a7cfd40aaa52699684e;p=gem5.git diff --git a/src/cpu/o3/cpu.hh b/src/cpu/o3/cpu.hh index ac917dba9..04472752c 100644 --- a/src/cpu/o3/cpu.hh +++ b/src/cpu/o3/cpu.hh @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2013, 2016-2019 ARM Limited + * Copyright (c) 2011-2013, 2016-2020 ARM Limited * Copyright (c) 2013 Advanced Micro Devices, Inc. * All rights reserved * @@ -38,10 +38,6 @@ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * Authors: Kevin Lim - * Korey Sewell - * Rick Strong */ #ifndef __CPU_O3_CPU_HH__ @@ -65,7 +61,6 @@ #include "cpu/base.hh" #include "cpu/simple_thread.hh" #include "cpu/timebuf.hh" -//#include "cpu/o3/thread_context.hh" #include "params/DerivO3CPU.hh" #include "sim/process.hh" @@ -284,7 +279,7 @@ class FullO3CPU : public BaseO3CPU /** Executes a syscall. * @todo: Determine if this needs to be virtual. */ - void syscall(int64_t callnum, ThreadID tid, Fault *fault); + void syscall(ThreadID tid); /** Starts draining the CPU's pipeline of all instructions in * order to stop all memory accesses. */ @@ -317,6 +312,12 @@ class FullO3CPU : public BaseO3CPU /** Traps to handle given fault. */ void trap(const Fault &fault, ThreadID tid, const StaticInstPtr &inst); + /** + * Mark vector fields in scoreboard as ready right after switching + * vector mode, since software may read vectors at this time. + */ + void setVectorsAsReady(ThreadID tid); + /** Check if a change in renaming is needed for vector registers. * The vecMode variable is updated and propagated to rename maps. * @@ -713,13 +714,13 @@ class FullO3CPU : public BaseO3CPU /** CPU pushRequest function, forwards request to LSQ. */ Fault pushRequest(const DynInstPtr& inst, bool isLoad, uint8_t *data, unsigned int size, Addr addr, Request::Flags flags, - uint64_t *res, AtomicOpFunctor *amo_op = nullptr, - const std::vector& byteEnable = + uint64_t *res, AtomicOpFunctorPtr amo_op = nullptr, + const std::vector& byte_enable = std::vector()) { return iew.ldstQueue.pushRequest(inst, isLoad, data, size, addr, - flags, res, amo_op, byteEnable); + flags, res, std::move(amo_op), byte_enable); } /** CPU read function, forwards read to LSQ. */ @@ -786,6 +787,11 @@ class FullO3CPU : public BaseO3CPU //number of misc Stats::Scalar miscRegfileReads; Stats::Scalar miscRegfileWrites; + + public: + // hardware transactional memory + void htmSendAbortSignal(ThreadID tid, uint64_t htm_uid, + HtmFailureFaultCause cause); }; #endif // __CPU_O3_CPU_HH__