Skip to content

Commit 15a4547

Browse files
committed
fix typo and set more reasonable branch misprediction latency penalty
1 parent 358d162 commit 15a4547

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

CustomStages/MCADFetchDelayStage.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ llvm::Error MCADFetchDelayStage::execute(llvm::mca::InstRef &IR) {
5454
LLVM_DEBUG(dbgs() << "[MCAD FetchDelayStage] Previous branch at ");
5555
LLVM_DEBUG(dbgs().write_hex(instrAddr->addr));
5656
LLVM_DEBUG(dbgs() << " mispredicted, delaying next instruction by "
57-
<< delayCyclesLeft << "cycle(s).\n");
57+
<< delayCyclesLeft << " cycle(s).\n");
5858
} else {
5959
LLVM_DEBUG(dbgs() << "[MCAD FetchDelayStage] Previous branch at ");
6060
LLVM_DEBUG(dbgs().write_hex(instrAddr->addr));

MCAWorker.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ std::unique_ptr<mca::Pipeline> MCAWorker::createDefaultPipeline() {
182182
MCAPO.StoreQueueSize,
183183
MCAPO.AssumeNoAlias, &MDRegistry);
184184
auto HWS = std::make_unique<Scheduler>(SM, *LSU);
185-
auto BPU = std::make_unique<NaiveBranchPredictorUnit>(100);
185+
auto BPU = std::make_unique<NaiveBranchPredictorUnit>(20);
186186

187187
// Create the pipeline stages.
188188
auto Fetch = std::make_unique<EntryStage>(SrcMgr);
@@ -227,7 +227,7 @@ std::unique_ptr<mca::Pipeline> MCAWorker::createInOrderPipeline() {
227227
auto LSU = std::make_unique<MCADLSUnit>(SM, MCAPO.LoadQueueSize,
228228
MCAPO.StoreQueueSize,
229229
MCAPO.AssumeNoAlias, &MDRegistry);
230-
auto BPU = std::make_unique<NaiveBranchPredictorUnit>(100);
230+
auto BPU = std::make_unique<NaiveBranchPredictorUnit>(20);
231231

232232
// Create the pipeline stages.
233233
auto Entry = std::make_unique<EntryStage>(SrcMgr);

0 commit comments

Comments
 (0)