mem: Comment removal and adding constexpr to is_secure bools

This commit removes some comments and adds constexpr in front
of "bool is_secure..." in pif.cc, signature_path.cc, and
signature_path_v2.cc

Change-Id: Icafe1d7c97d1d3fbf6abc12ba87ebb596255b96f
This commit is contained in:
Erin Le
2024-08-02 21:11:02 +00:00
committed by Erin (Jianghua) Le
parent 9adf44ed1f
commit 2db021b27b
4 changed files with 3 additions and 6 deletions

View File

@@ -90,8 +90,6 @@ class AssociativeSet : public AssociativeCache<Entry>
using AssociativeCache<Entry>::accessEntryByAddr;
using AssociativeCache<Entry>::findEntry;
using AssociativeCache<Entry>::insertEntry;
// using AssociativeCache<Entry>::getPossibleEntries;
using AssociativeCache<Entry>::replPolicy;
using AssociativeCache<Entry>::indexingPolicy;
};

View File

@@ -176,7 +176,7 @@ PIF::notifyRetiredInst(const Addr pc)
// Insert the spatial entry into the history buffer and update
// the 'iterator' table to point to the new entry
historyBuffer.push_back(spatialCompactor);
bool is_secure = false;
constexpr bool is_secure = false;
auto idx_entry = index.findEntry(spatialCompactor.trigger,
is_secure);
if (idx_entry != nullptr) {

View File

@@ -192,7 +192,7 @@ SignaturePath::getSignatureEntry(Addr ppn, bool is_secure,
SignaturePath::PatternEntry &
SignaturePath::getPatternEntry(Addr signature)
{
bool is_secure = false;
constexpr bool is_secure = false;
PatternEntry* pattern_entry = patternTable.findEntry(signature, is_secure);
if (pattern_entry != nullptr) {
// Signature found

View File

@@ -124,8 +124,7 @@ SignaturePathV2::handlePageCrossingLookahead(signature_t signature,
// of them are unique, there are never "hits" in the GHR
GlobalHistoryEntry *gh_entry = globalHistoryRegister.findVictim(0);
assert(gh_entry != nullptr);
// Any address value works, as it is never used
bool is_secure = false;
constexpr bool is_secure = false;
globalHistoryRegister.insertEntry(0, is_secure, gh_entry); // false,
gh_entry->signature = signature;