From ee9a360c601011d9694352b0f87a2bbcd48764bf Mon Sep 17 00:00:00 2001 From: Gabe Black Date: Wed, 4 Mar 2020 16:00:02 -0800 Subject: [PATCH] mem: Change some default values in the Request class. These values are more abnormal than the 0s they replace, and so it would be more obvious when something is accidentally left uninitialized. Change-Id: Ie7f14abe9e22f9df1ff238f29d4a783c890f4a20 Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/26237 Tested-by: kokoro Reviewed-by: Nikos Nikoleris Maintainer: Nikos Nikoleris --- src/mem/request.hh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/mem/request.hh b/src/mem/request.hh index 823e6bb7c..01252bf66 100644 --- a/src/mem/request.hh +++ b/src/mem/request.hh @@ -316,7 +316,7 @@ class Request * latencies. This field is set to curTick() any time paddr or vaddr * is written. */ - Tick _time = 0; + Tick _time = MaxTick; /** * The task id associated with this request @@ -339,7 +339,7 @@ class Request uint32_t _substreamId = 0; /** The virtual address of the request. */ - Addr _vaddr = 0; + Addr _vaddr = MaxAddr; /** * Extra data for the request, such as the return value of @@ -347,10 +347,10 @@ class Request uint64_t _extraData = 0; /** The context ID (for statistics, locks, and wakeups). */ - ContextID _contextId = 0; + ContextID _contextId = InvalidContextID; /** program counter of initiating access; for tracing/debugging */ - Addr _pc = 0; + Addr _pc = MaxAddr; /** Sequence number of the instruction that creates the request */ InstSeqNum _reqInstSeqNum = 0; -- 2.30.2