[gem5-dev] Change in gem5/gem5[master]: cpu: Added 8KB and 64KB TAGE-SC-L branch predictor
Pau Cabre has submitted this change and it was merged. ( https://gem5-review.googlesource.com/c/public/gem5/+/14855 ) Change subject: cpu: Added 8KB and 64KB TAGE-SC-L branch predictor .. cpu: Added 8KB and 64KB TAGE-SC-L branch predictor The original paper of the branch predictor can be found here: http://www.jilp.org/cbp2016/paper/AndreSeznecLimited.pdf Change-Id: I684863752407685adaacedebb699205c3559c528 Reviewed-on: https://gem5-review.googlesource.com/c/14855 Reviewed-by: Sudhanshu Jha Reviewed-by: Andreas Sandberg Maintainer: Andreas Sandberg --- M src/cpu/pred/BranchPredictor.py M src/cpu/pred/SConscript M src/cpu/pred/loop_predictor.cc M src/cpu/pred/loop_predictor.hh M src/cpu/pred/ltage.cc M src/cpu/pred/ltage.hh A src/cpu/pred/statistical_corrector.cc A src/cpu/pred/statistical_corrector.hh M src/cpu/pred/tage.cc M src/cpu/pred/tage.hh M src/cpu/pred/tage_base.cc M src/cpu/pred/tage_base.hh A src/cpu/pred/tage_sc_l.cc A src/cpu/pred/tage_sc_l.hh A src/cpu/pred/tage_sc_l_64KB.cc A src/cpu/pred/tage_sc_l_64KB.hh A src/cpu/pred/tage_sc_l_8KB.cc A src/cpu/pred/tage_sc_l_8KB.hh 18 files changed, 2,541 insertions(+), 56 deletions(-) Approvals: Andreas Sandberg: Looks good to me, approved; Looks good to me, approved Sudhanshu Jha: Looks good to me, approved diff --git a/src/cpu/pred/BranchPredictor.py b/src/cpu/pred/BranchPredictor.py index 1d5fd5e..85b225c 100644 --- a/src/cpu/pred/BranchPredictor.py +++ b/src/cpu/pred/BranchPredictor.py @@ -118,7 +118,7 @@ logUResetPeriod = Param.Unsigned(18, "Log period in number of branches to reset TAGE useful counters") numUseAltOnNa = Param.Unsigned(1, "Number of USE_ALT_ON_NA counters") -useAltOnNaBits = Param.Unsigned(4, "Size of the USE_ALT_ON_NA counter") +useAltOnNaBits = Param.Unsigned(4, "Size of the USE_ALT_ON_NA counter(s)") maxNumAlloc = Param.Unsigned(1, "Max number of TAGE entries allocted on mispredict") @@ -185,6 +185,96 @@ optionalAgeReset = Param.Bool(True, "Reset age bits optionally in some cases") +class TAGE_SC_L_TAGE(TAGEBase): +type = 'TAGE_SC_L_TAGE' +cxx_class = 'TAGE_SC_L_TAGE' +cxx_header = "cpu/pred/tage_sc_l.hh" +abstract = True +tagTableTagWidths = [0] +numUseAltOnNa = 16 +pathHistBits = 27 +maxNumAlloc = 2 +logUResetPeriod = 10 +useAltOnNaBits = 5 +# TODO No speculation implemented as of now +speculativeHistUpdate = False + +# This size does not set the final sizes of the tables (it is just used +# for some calculations) +# Instead, the number of TAGE entries comes from shortTagsTageEntries and +# longTagsTageEntries +logTagTableSize = Param.Unsigned("Log size of each tag table") + +shortTagsTageFactor = Param.Unsigned( +"Factor for calculating the total number of short tags TAGE entries") + +longTagsTageFactor = Param.Unsigned( +"Factor for calculating the total number of long tags TAGE entries") + +shortTagsSize = Param.Unsigned(8, "Size of the short tags") + +longTagsSize = Param.Unsigned("Size of the long tags") + +firstLongTagTable = Param.Unsigned("First table with long tags") + +truncatePathHist = Param.Bool(True, +"Truncate the path history to its configured size") + + +class TAGE_SC_L_TAGE_64KB(TAGE_SC_L_TAGE): +type = 'TAGE_SC_L_TAGE_64KB' +cxx_class = 'TAGE_SC_L_TAGE_64KB' +cxx_header = "cpu/pred/tage_sc_l_64KB.hh" +nHistoryTables = 36 + +minHist = 6 +maxHist = 3000 + +tagTableUBits = 1 + +logTagTableSizes = [13] + +# This is used to handle the 2-way associativity +# (all odd entries are set to one, and if the corresponding even entry +# is set to one, then there is a 2-way associativity for this pair) +# Entry 0 is for the bimodal and it is ignored +# Note: For this implementation, some odd entries are also set to 0 to save +# some bits +noSkip = [0,0,1,0,0,0,1,0,0,1,1,1,1,1,1,1,1,1,1, +1,1,1,1,0,1,0,1,0,1,0,0,0,1,0,0,0,1] + +logTagTableSize = 10 +shortTagsTageFactor = 10 +longTagsTageFactor = 20 + +longTagsSize = 12 + +firstLongTagTable = 13 + +class TAGE_SC_L_TAGE_8KB(TAGE_SC_L_TAGE): +type = 'TAGE_SC_L_TAGE_8KB' +cxx_class = 'TAGE_SC_L_TAGE_8KB' +cxx_header = "cpu/pred/tage_sc_l_8KB.hh" + +nHistoryTables = 30 + +minHist = 4 +maxHist = 1000 + +logTagTableSize = 7 +shortTagsTageFactor = 9 +longTagsTageFactor = 17 +longTagsSize = 12 + +logTagTableSizes = [12] + +firstLongTagTable = 11 + +truncatePathHist = False + +noSkip = [0,0,1,0,1,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,1,0,1,0,1,0,1,0,1] + +tagTableUBits = 2 # LTAGE branch predictor as described in # https://www.irisa.fr/caps/people/seznec/L-TAGE.pdf @@ -196,4 +286,177 @@ cxx_header = "cpu/pred/ltage.hh" tage = LTAGE_TAGE() +
[gem5-dev] Change in gem5/gem5[master]: cpu: Added 8KB and 64KB TAGE-SC-L branch predictor
Hello Javier Bueno Hedo, Sudhanshu Jha, Andreas Sandberg, I'd like you to reexamine a change. Please visit https://gem5-review.googlesource.com/c/public/gem5/+/14855 to look at the new patch set (#16). Change subject: cpu: Added 8KB and 64KB TAGE-SC-L branch predictor .. cpu: Added 8KB and 64KB TAGE-SC-L branch predictor The original paper of the branch predictor can be found here: http://www.jilp.org/cbp2016/paper/AndreSeznecLimited.pdf Change-Id: I684863752407685adaacedebb699205c3559c528 --- M src/cpu/pred/BranchPredictor.py M src/cpu/pred/SConscript M src/cpu/pred/loop_predictor.cc M src/cpu/pred/loop_predictor.hh M src/cpu/pred/ltage.cc M src/cpu/pred/ltage.hh A src/cpu/pred/statistical_corrector.cc A src/cpu/pred/statistical_corrector.hh M src/cpu/pred/tage.cc M src/cpu/pred/tage.hh M src/cpu/pred/tage_base.cc M src/cpu/pred/tage_base.hh A src/cpu/pred/tage_sc_l.cc A src/cpu/pred/tage_sc_l.hh A src/cpu/pred/tage_sc_l_64KB.cc A src/cpu/pred/tage_sc_l_64KB.hh A src/cpu/pred/tage_sc_l_8KB.cc A src/cpu/pred/tage_sc_l_8KB.hh 18 files changed, 2,541 insertions(+), 56 deletions(-) -- To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/14855 To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings Gerrit-Project: public/gem5 Gerrit-Branch: master Gerrit-Change-Id: I684863752407685adaacedebb699205c3559c528 Gerrit-Change-Number: 14855 Gerrit-PatchSet: 16 Gerrit-Owner: Pau Cabre Gerrit-Assignee: Ilias Vougioukas Gerrit-Reviewer: Andreas Sandberg Gerrit-Reviewer: Javier Bueno Hedo Gerrit-Reviewer: Pau Cabre Gerrit-Reviewer: Sudhanshu Jha Gerrit-CC: Ilias Vougioukas Gerrit-MessageType: newpatchset ___ gem5-dev mailing list gem5-dev@gem5.org http://m5sim.org/mailman/listinfo/gem5-dev
[gem5-dev] Change in gem5/gem5[master]: cpu: Added 8KB and 64KB TAGE-SC-L branch predictor
Hello Javier Bueno Hedo, Sudhanshu Jha, I'd like you to reexamine a change. Please visit https://gem5-review.googlesource.com/c/public/gem5/+/14855 to look at the new patch set (#15). Change subject: cpu: Added 8KB and 64KB TAGE-SC-L branch predictor .. cpu: Added 8KB and 64KB TAGE-SC-L branch predictor The original paper of the branch predictor can be found here: http://www.jilp.org/cbp2016/paper/AndreSeznecLimited.pdf Change-Id: I684863752407685adaacedebb699205c3559c528 --- M src/cpu/pred/BranchPredictor.py M src/cpu/pred/SConscript M src/cpu/pred/loop_predictor.cc M src/cpu/pred/loop_predictor.hh M src/cpu/pred/ltage.cc M src/cpu/pred/ltage.hh A src/cpu/pred/statistical_corrector.cc A src/cpu/pred/statistical_corrector.hh M src/cpu/pred/tage.cc M src/cpu/pred/tage.hh M src/cpu/pred/tage_base.cc M src/cpu/pred/tage_base.hh A src/cpu/pred/tage_sc_l.cc A src/cpu/pred/tage_sc_l.hh A src/cpu/pred/tage_sc_l_64KB.cc A src/cpu/pred/tage_sc_l_64KB.hh A src/cpu/pred/tage_sc_l_8KB.cc A src/cpu/pred/tage_sc_l_8KB.hh 18 files changed, 2,544 insertions(+), 56 deletions(-) -- To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/14855 To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings Gerrit-Project: public/gem5 Gerrit-Branch: master Gerrit-Change-Id: I684863752407685adaacedebb699205c3559c528 Gerrit-Change-Number: 14855 Gerrit-PatchSet: 15 Gerrit-Owner: Pau Cabre Gerrit-Assignee: Ilias Vougioukas Gerrit-Reviewer: Javier Bueno Hedo Gerrit-Reviewer: Pau Cabre Gerrit-Reviewer: Sudhanshu Jha Gerrit-CC: Andreas Sandberg Gerrit-CC: Ilias Vougioukas Gerrit-MessageType: newpatchset ___ gem5-dev mailing list gem5-dev@gem5.org http://m5sim.org/mailman/listinfo/gem5-dev
[gem5-dev] Change in gem5/gem5[master]: cpu: Added 8KB and 64KB TAGE-SC-L branch predictor
Pau Cabre has uploaded a new patch set (#9). ( https://gem5-review.googlesource.com/c/public/gem5/+/14855 ) Change subject: cpu: Added 8KB and 64KB TAGE-SC-L branch predictor .. cpu: Added 8KB and 64KB TAGE-SC-L branch predictor The original paper of the branch predictor can be found here: http://www.jilp.org/cbp2016/paper/AndreSeznecLimited.pdf And this is the original implementation: http://www.jilp.org/cbp2016/code/AndreSeznecLimited.tar.gz Change-Id: I684863752407685adaacedebb699205c3559c528 Signed-off-by: Pau Cabre --- M src/cpu/pred/2bit_local.cc M src/cpu/pred/2bit_local.hh M src/cpu/pred/BranchPredictor.py M src/cpu/pred/SConscript M src/cpu/pred/bi_mode.cc M src/cpu/pred/bi_mode.hh M src/cpu/pred/bpred_unit.cc M src/cpu/pred/bpred_unit.hh M src/cpu/pred/ltage.cc M src/cpu/pred/ltage.hh M src/cpu/pred/tage.cc M src/cpu/pred/tage.hh A src/cpu/pred/tage_sc_l.cc A src/cpu/pred/tage_sc_l.hh A src/cpu/pred/tage_sc_l_64KB.cc A src/cpu/pred/tage_sc_l_64KB.hh A src/cpu/pred/tage_sc_l_8KB.cc A src/cpu/pred/tage_sc_l_8KB.hh M src/cpu/pred/tournament.cc M src/cpu/pred/tournament.hh 20 files changed, 2,605 insertions(+), 186 deletions(-) -- To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/14855 To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings Gerrit-Project: public/gem5 Gerrit-Branch: master Gerrit-Change-Id: I684863752407685adaacedebb699205c3559c528 Gerrit-Change-Number: 14855 Gerrit-PatchSet: 9 Gerrit-Owner: Pau Cabre Gerrit-Assignee: Ilias Vougioukas Gerrit-Reviewer: Pau Cabre Gerrit-CC: Ilias Vougioukas Gerrit-MessageType: newpatchset ___ gem5-dev mailing list gem5-dev@gem5.org http://m5sim.org/mailman/listinfo/gem5-dev