Refs/heads/tage size align repeat index fill align#824
Conversation
Change-Id: I7c0b359c8241119f090b2092766e56fa0174464c
Change-Id: Ia804999a72ffff1fbc3a63033b9a60e8930e69d1
Change-Id: Iec5a3df1c270a440c14eea93b4fe0612c08daede
Change-Id: I655f44c30877c1ad5e9de12ebed9573f3a5f2649
Change-Id: I73adc140730b5d692d3973eb103f2d719d5724b5
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
✅ Files skipped from review due to trivial changes (1)
📝 WalkthroughWalkthroughChanged BTBTAGE tableSizes syntax, updated getTageIndex to repeat short folded-history chunks across the index width, and added a unit test verifying repeated-bit indexing behavior for short folded histories. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested Labels
Suggested Reviewers
Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 inconclusive)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
[Generated by GEM5 Performance Robot] Align BTB PerformanceOverall Score
[Generated by GEM5 Performance Robot] Align BTB PerformanceOverall Score
|
There was a problem hiding this comment.
🧹 Nitpick comments (1)
src/cpu/pred/btb/test/btb_tage.test.cc (1)
409-426: Pin the test to an explicit predictor shape.These expectations only hold while the UNIT_TEST constructor keeps 10 index bits and
{4, 8, ...}history lengths. If those defaults move, this test will fail without any regression in the repetition logic. Instantiate a localBTBTAGEwith explicit constructor arguments here.♻️ Suggested tightening
TEST_F(BTBTAGETest, IndexRepeatsShortFoldedHistory) { + BTBTAGE local_tage(/*numPredictors=*/2, /*numWaysPerTable=*/1, + /*tableSize=*/1024, /*numBanks=*/1); const Addr pc = 0x0; @@ - EXPECT_EQ(tage->getTageIndex(pc, t0, t0FoldedHist), t0ExpectedFolded) + EXPECT_EQ(local_tage.getTageIndex(pc, t0, t0FoldedHist), t0ExpectedFolded) << "t0 index should repeat 4-bit history to cover all index bits"; @@ - EXPECT_EQ(tage->getTageIndex(pc, t1, t1FoldedHist), t1ExpectedFolded) + EXPECT_EQ(local_tage.getTageIndex(pc, t1, t1FoldedHist), t1ExpectedFolded) << "t1 index should repeat 8-bit history to cover all index bits"; }🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@src/cpu/pred/btb/test/btb_tage.test.cc` around lines 409 - 426, The test relies on implicit UNIT_TEST defaults (10 index bits and history lengths {4,8,...}); to make it robust, create a local BTBTAGE instance in the test with explicit constructor arguments that pin indexBits=10 and the matching per-table history lengths (e.g., 4 and 8 for tables 0 and 1), then call that instance's getTageIndex instead of the shared/implicit member (replace usages of `tage->getTageIndex` with the local `BTBTAGE` instance). Ensure the local constructor arguments exactly match the expected folded values used in the assertions so the test no longer depends on UNIT_TEST defaults.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In `@src/cpu/pred/btb/test/btb_tage.test.cc`:
- Around line 409-426: The test relies on implicit UNIT_TEST defaults (10 index
bits and history lengths {4,8,...}); to make it robust, create a local BTBTAGE
instance in the test with explicit constructor arguments that pin indexBits=10
and the matching per-table history lengths (e.g., 4 and 8 for tables 0 and 1),
then call that instance's getTageIndex instead of the shared/implicit member
(replace usages of `tage->getTageIndex` with the local `BTBTAGE` instance).
Ensure the local constructor arguments exactly match the expected folded values
used in the assertions so the test no longer depends on UNIT_TEST defaults.
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: 18045b4f-4051-481e-9a02-5d2cd4986224
📒 Files selected for processing (3)
src/cpu/pred/BranchPredictor.pysrc/cpu/pred/btb/btb_tage.ccsrc/cpu/pred/btb/test/btb_tage.test.cc
🚀 Coremark Smoke Test Results
✅ Difftest smoke test passed! |
Change-Id: I2b6c15b3bc81934470e3577d8628e0eea433eab1
🚀 Coremark Smoke Test Results
✅ Difftest smoke test passed! |
|
[Generated by GEM5 Performance Robot] Align BTB PerformanceOverall Score
[Generated by GEM5 Performance Robot] Align BTB PerformanceOverall Score
|
This reverts commit abd7008.
🚀 Coremark Smoke Test Results
✅ Difftest smoke test passed! |
|
[Generated by GEM5 Performance Robot] Align BTB PerformanceOverall Score
[Generated by GEM5 Performance Robot] Align BTB PerformanceOverall Score
|
Summary by CodeRabbit
Refactor
Bug Fixes
Tests