arch-x86: Rename RomLabels namespace as rom_labels

As part of recent decisions regarding namespace
naming conventions, all namespaces will be changed
to snake case.

RomLabels became rom_labels.

Change-Id: I972409ab33c595baaf845bf11f2f450ab5938d54
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/45396
Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu>
Maintainer: Bobby R. Bruce <bbruce@ucdavis.edu>
Tested-by: kokoro <noreply+kokoro@google.com>
This commit is contained in:
Daniel R. Carvalho
2021-05-06 16:01:34 -03:00
committed by Daniel Carvalho
parent fd660886c7
commit 8bb0dd3ab9
4 changed files with 9 additions and 7 deletions

View File

@@ -64,7 +64,7 @@ X86FaultBase::invoke(ThreadContext *tc, const StaticInstPtr &inst)
PCState pcState = tc->pcState();
Addr pc = pcState.pc();
DPRINTF(Faults, "RIP %#x: vector %d: %s\n", pc, vector, describe());
using namespace X86ISAInst::RomLabels;
using namespace X86ISAInst::rom_labels;
HandyM5Reg m5reg = tc->readMiscRegNoEffect(MISCREG_M5_REG);
MicroPC entry;
if (m5reg.mode == LongMode) {
@@ -292,7 +292,7 @@ InitInterrupt::invoke(ThreadContext *tc, const StaticInstPtr &inst)
// Update the handy M5 Reg.
tc->setMiscReg(MISCREG_M5_REG, 0);
MicroPC entry = X86ISAInst::RomLabels::extern_label_initIntHalt;
MicroPC entry = X86ISAInst::rom_labels::extern_label_initIntHalt;
pc.upc(romMicroPC(entry));
pc.nupc(romMicroPC(entry) + 1);
tc->pcState(pc);

View File

@@ -216,12 +216,12 @@ let {{
assembler.symbols["label"] = labeler
def rom_labeler(labelStr):
return "romMicroPC(RomLabels::extern_label_%s)" % labelStr
return "romMicroPC(rom_labels::extern_label_%s)" % labelStr
assembler.symbols["rom_label"] = rom_labeler
def rom_local_labeler(labelStr):
return "romMicroPC(RomLabels::label_%s)" % labelStr
return "romMicroPC(rom_labels::label_%s)" % labelStr
assembler.symbols["rom_local_label"] = rom_local_labeler

View File

@@ -215,7 +215,7 @@ let {{
macroop ? macroop->getExtMachInst() : dummyExtMachInst;
GEM5_VAR_USED const EmulEnv &env =
macroop ? macroop->getEmulEnv() : dummyEmulEnv;
using namespace RomLabels;
using namespace rom_labels;
return %s;
}
'''

View File

@@ -31,7 +31,7 @@ def template MicroRomConstructor {{
X86ISA::MicrocodeRom::MicrocodeRom()
{
using namespace RomLabels;
using namespace rom_labels;
genFuncs = new GenFunc[numMicroops];
%(alloc_generators)s;
}
@@ -52,7 +52,9 @@ let {{
def getDeclaration(self):
declareLabels = "namespace RomLabels {\n"
declareLabels = \
"GEM5_DEPRECATED_NAMESPACE(RomLabels, rom_labels);\n"
declareLabels += "namespace rom_labels\n{\n"
for (label, microop) in self.labels.items():
declareLabels += "const static uint64_t label_%s = %d;\n" \
% (label, microop.micropc)