Wormhole branch prediction using multi-dimensional histories Jorge - - PowerPoint PPT Presentation

wormhole branch prediction using multi dimensional
SMART_READER_LITE
LIVE PREVIEW

Wormhole branch prediction using multi-dimensional histories Jorge - - PowerPoint PPT Presentation

Wormhole branch prediction using multi-dimensional histories Jorge Albericio, Joshua San Miguel , Natalie Enright Jerger, and Andreas Moshovos 2 Motivation foreach frame: foreach object: if distance( object , p ) < threshold: { /* do


slide-1
SLIDE 1

Wormhole branch prediction using multi-dimensional histories

Jorge Albericio, Joshua San Miguel, 
 Natalie Enright Jerger, and Andreas Moshovos

slide-2
SLIDE 2

2

slide-3
SLIDE 3

3

foreach frame: foreach object: if distance(object, p) < threshold: { /* do something */ }

Motivation

slide-4
SLIDE 4

3

foreach frame: foreach object: if distance(object, p) < threshold: { /* do something */ }

Motivation

slide-5
SLIDE 5

3

foreach frame: foreach object: if distance(object, p) < threshold: { /* do something */ }

Motivation

slide-6
SLIDE 6

3

foreach frame: foreach object: if distance(object, p) < threshold: { /* do something */ }

Motivation

slide-7
SLIDE 7

1 1 1 1 1 1

Multidimensional histories

4

foreach frame: foreach object: if distance(object, p) < threshold: { /* do something */ }

slide-8
SLIDE 8

1 1 1 1 1 1

Multidimensional histories

4

foreach frame: foreach object: if distance(object, p) < threshold: { /* do something */ }

O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3 O b j e c t 4 O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3 O b j e c t 4 O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3

slide-9
SLIDE 9

1 1 1 1 1 1

Multidimensional histories

4

Frame 0

foreach frame: foreach object: if distance(object, p) < threshold: { /* do something */ }

Frame 1 Frame 2 O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3 O b j e c t 4 O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3 O b j e c t 4 O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3

slide-10
SLIDE 10

1 1 1 1 1 1

Multidimensional histories

4

Frame 0

foreach frame: foreach object: if distance(object, p) < threshold: { /* do something */ }

Frame 1 Frame 2

?

O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3 O b j e c t 4 O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3 O b j e c t 4 O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3

slide-11
SLIDE 11

1 1 1 1 1 1

Multidimensional histories

4

Frame 0

foreach frame: foreach object: if distance(object, p) < threshold: { /* do something */ }

Frame 1 Frame 2

?

O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3 O b j e c t 4 O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3 O b j e c t 4 O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3

slide-12
SLIDE 12

1 1 1 1 1 1

Multidimensional histories

4

Frame 0

foreach frame: foreach object: if distance(object, p) < threshold: { /* do something */ }

Frame 1 Frame 2 O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3 O b j e c t 4 O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3 O b j e c t 4 O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3

slide-13
SLIDE 13

1 1 1 1 1 1

Multidimensional histories

4

Frames

foreach frame: foreach object: if distance(object, p) < threshold: { /* do something */ }

O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3 O b j e c t 4

slide-14
SLIDE 14

1 1 1 1 1 1

Multidimensional histories

4

Frames

foreach frame: foreach object: if distance(object, p) < threshold: { /* do something */ }

O b j e c t O b j e c t 1 O b j e c t 2 O b j e c t 3 O b j e c t 4

slide-15
SLIDE 15

Summary

  • Wormhole predictor: 


Side-predictor on top of ISL-TAGE

  • Able to capture columns,

diagonals, and other patterns

  • 3.995, 2.498, and 2.014

MPKI in the 4KB, 32KB, and unlimited competition tracks

5

Wormhole pred. ISL-TAGE

predictions

slide-16
SLIDE 16

6

for j in N: for k in N: if j != k: /*Calculation*/

Detecting diagonals

slide-17
SLIDE 17

6

for j in N: for k in N: if j != k: /*Calculation*/

Detecting diagonals

slide-18
SLIDE 18

6

for j in N: for k in N: if j != k: /*Calculation*/

Detecting diagonals

1 1 1

slide-19
SLIDE 19

6

for j in N: for k in N: if j != k: /*Calculation*/

Detecting diagonals

1 1 1

j=0 j=1 j=2

slide-20
SLIDE 20

Detecting diagonals

7

1 1 1

for j in N: //Loop 1 for k in N: //Loop 2 if j != k: /*Calculation*/

j=0 j=1 j=2

slide-21
SLIDE 21

Detecting diagonals

7

1 1 1

Outer loop (j) Iterations Inner loop (k) Iterations

for j in N: //Loop 1 for k in N: //Loop 2 if j != k: /*Calculation*/

slide-22
SLIDE 22

Multidimensional histories

8

1 1

Outer loop (j) Iterations Inner loop (k) Iterations

for j in N: for k in N: if j != k: /*Calculation*/

slide-23
SLIDE 23

Multidimensional histories

8

1 1

?

Outer loop (j) Iterations Inner loop (k) Iterations

for j in N: for k in N: if j != k: /*Calculation*/

slide-24
SLIDE 24

Multidimensional histories

8

1 1

? Saturating counters

Outer loop (j) Iterations Inner loop (k) Iterations

for j in N: for k in N: if j != k: /*Calculation*/

slide-25
SLIDE 25

Multidimensional histories

8

1 1

?

1

Saturating counters

Outer loop (j) Iterations Inner loop (k) Iterations

for j in N: for k in N: if j != k: /*Calculation*/

slide-26
SLIDE 26

Multidimensional histories

8

1 1

?

1

0100 Saturating counters x

Outer loop (j) Iterations Inner loop (k) Iterations

for j in N: for k in N: if j != k: /*Calculation*/

slide-27
SLIDE 27

Multidimensional histories

8

1 1

?

1

0100 Saturating counters x 1

Outer loop (j) Iterations Inner loop (k) Iterations

for j in N: for k in N: if j != k: /*Calculation*/

slide-28
SLIDE 28

Multidimensional histories

8

1 1

?

1

0100 Saturating counters x 1

1

Outer loop (j) Iterations Inner loop (k) Iterations

for j in N: for k in N: if j != k: /*Calculation*/

slide-29
SLIDE 29

Multidimensional histories

9

1 1 1

Saturating counters x

1

for j in N: for k in N: if j != k: /*Calculation*/

Outer loop (j) Iterations Inner loop (k) Iterations

slide-30
SLIDE 30

Multidimensional histories

9

1 1 1

? Saturating counters x

1

for j in N: for k in N: if j != k: /*Calculation*/

Outer loop (j) Iterations Inner loop (k) Iterations

slide-31
SLIDE 31

Multidimensional histories

9

1 1 1

?

1

Saturating counters x

1

for j in N: for k in N: if j != k: /*Calculation*/

Outer loop (j) Iterations Inner loop (k) Iterations

slide-32
SLIDE 32

Multidimensional histories

9

1 1 1

?

1

0100 Saturating counters x

1

for j in N: for k in N: if j != k: /*Calculation*/

Outer loop (j) Iterations Inner loop (k) Iterations

slide-33
SLIDE 33

Multidimensional histories

9

1 1 1

?

1

0100 Saturating counters x

1

Prediction: 1

for j in N: for k in N: if j != k: /*Calculation*/

Outer loop (j) Iterations Inner loop (k) Iterations

slide-34
SLIDE 34

Multidimensional histories

9

1 1 1

?

1

0100 Saturating counters x 1

1

Prediction: 1

for j in N: for k in N: if j != k: /*Calculation*/

Outer loop (j) Iterations Inner loop (k) Iterations

slide-35
SLIDE 35

Multidimensional histories

9

1 1 1

?

1

0100 Saturating counters x 1

1

Prediction: 1

for j in N: for k in N: if j != k: /*Calculation*/

Outer loop (j) Iterations Inner loop (k) Iterations

slide-36
SLIDE 36

Wormhole predictor and ISL-TAGE

  • On top of ISL-TAGE 


(Best performer from last CBP)

  • TAGE: bimodal + tagged
  • Statistical corrector
  • Loop predictor

10

Wormhole pred. bimodal pred. tagged comp. Loop pred. Stat. corr. ISL-TAGE

predictions

slide-37
SLIDE 37

Wormhole predictor and ISL-TAGE

  • On top of ISL-TAGE 


(Best performer from last CBP)

  • TAGE: bimodal + tagged
  • Statistical corrector
  • Loop predictor

10

Wormhole pred. bimodal pred. tagged comp. Loop pred. Stat. corr. ISL-TAGE

predictions

Detect difficult branches

slide-38
SLIDE 38

Wormhole predictor and ISL-TAGE

  • On top of ISL-TAGE 


(Best performer from last CBP)

  • TAGE: bimodal + tagged
  • Statistical corrector
  • Loop predictor

10

Wormhole pred. bimodal pred. tagged comp. Loop pred. Stat. corr. ISL-TAGE

predictions

Detect difficult branches Loop dimensionality

slide-39
SLIDE 39

ISL-TAGE

  • Difficult branches!
  • Statistical corrector calculates accuracy for

TAGE

  • Wormhole allocates when low accuracy
  • Loop dimensionality!
  • Stored at LP_iters
  • u field (4KB)!
  • 3 bits
  • Updated when “as in the original TAGE”
  • Not reset: Incremented and decremented

11

Wormhole pred. bimodal pred. tagged comp. Loop pred. Stat. corr. ISL-TAGE

predictions

slide-40
SLIDE 40

Wormhole predictor’s configurations

12

1 1 1

?

slide-41
SLIDE 41

Wormhole predictor’s configurations

12

1 1 1

?

1

4KB

slide-42
SLIDE 42

Wormhole predictor’s configurations

12

1 1 1

?

1

4KB 32KB & Unlim.

1 1 1

?

1

slide-43
SLIDE 43

Wormhole predictor’s configurations

12

1 PC Conf 1 1 ???

Local history bits

... ...

Saturating counters

... ...

1 1 1

?

1

4KB 32KB & Unlim.

1 1 1

?

1

slide-44
SLIDE 44

Wormhole predictor’s configurations

12

18 4 101 301 16 x 5 256 x 5 4KB: 18 4 32KB & Unlim.: (bits)

1 PC Conf 1 1 ???

Local history bits

... ...

Saturating counters

... ...

1 1 1

?

1

4KB 32KB & Unlim.

1 1 1

?

1

slide-45
SLIDE 45

Wormhole predictor’s configurations

12

18 4 101 301 16 x 5 256 x 5 4KB: 18 4 32KB & Unlim.: (bits) = 197 = 1615

1 PC Conf 1 1 ???

Local history bits

... ...

Saturating counters

... ...

1 1 1

?

1

4KB 32KB & Unlim.

1 1 1

?

1

slide-46
SLIDE 46

13

Results: 32KB

0" 2" 4" 6" 8" 10" 12" 14" 16" 18" 20" LONG,00" LONG,01" LONG,02" LONG,03" LONG,04" LONG,05" LONG,06" LONG,07" LONG,08" LONG,09" LONG,10" LONG,11" LONG,12" LONG,13" LONG,14" LONG,15" LONG,16" LONG,17" LONG,18" LONG,19" FP,1" FP,2" FP,3" FP,4" FP,5" INT,1" INT,2" INT,3" INT,4" INT,5" MM,1" MM,2" MM,3" MM,4" MM,5" SERV,1" SERV,2" SERV,3" SERV,4" SERV,5" AMEAN" MPKI%% ISL,TAGE,32KB" WH,32KB"

b e t t e r b e t t e r

slide-47
SLIDE 47

13

Results: 32KB

0" 2" 4" 6" 8" 10" 12" 14" 16" 18" 20" LONG,00" LONG,01" LONG,02" LONG,03" LONG,04" LONG,05" LONG,06" LONG,07" LONG,08" LONG,09" LONG,10" LONG,11" LONG,12" LONG,13" LONG,14" LONG,15" LONG,16" LONG,17" LONG,18" LONG,19" FP,1" FP,2" FP,3" FP,4" FP,5" INT,1" INT,2" INT,3" INT,4" INT,5" MM,1" MM,2" MM,3" MM,4" MM,5" SERV,1" SERV,2" SERV,3" SERV,4" SERV,5" AMEAN" MPKI%% ISL,TAGE,32KB" WH,32KB"

b e t t e r b e t t e r

slide-48
SLIDE 48

13

Results: 32KB

0" 2" 4" 6" 8" 10" 12" 14" 16" 18" 20" LONG,00" LONG,01" LONG,02" LONG,03" LONG,04" LONG,05" LONG,06" LONG,07" LONG,08" LONG,09" LONG,10" LONG,11" LONG,12" LONG,13" LONG,14" LONG,15" LONG,16" LONG,17" LONG,18" LONG,19" FP,1" FP,2" FP,3" FP,4" FP,5" INT,1" INT,2" INT,3" INT,4" INT,5" MM,1" MM,2" MM,3" MM,4" MM,5" SERV,1" SERV,2" SERV,3" SERV,4" SERV,5" AMEAN" MPKI%% ISL,TAGE,32KB" WH,32KB"

b e t t e r

19% 42%

b e t t e r

slide-49
SLIDE 49

13

Results: 32KB

0" 2" 4" 6" 8" 10" 12" 14" 16" 18" 20" LONG,00" LONG,01" LONG,02" LONG,03" LONG,04" LONG,05" LONG,06" LONG,07" LONG,08" LONG,09" LONG,10" LONG,11" LONG,12" LONG,13" LONG,14" LONG,15" LONG,16" LONG,17" LONG,18" LONG,19" FP,1" FP,2" FP,3" FP,4" FP,5" INT,1" INT,2" INT,3" INT,4" INT,5" MM,1" MM,2" MM,3" MM,4" MM,5" SERV,1" SERV,2" SERV,3" SERV,4" SERV,5" AMEAN" MPKI%% ISL,TAGE,32KB" WH,32KB"

b e t t e r

19% 42% 2%

b e t t e r

slide-50
SLIDE 50

13

Results: 32KB

0" 2" 4" 6" 8" 10" 12" 14" 16" 18" 20" LONG,00" LONG,01" LONG,02" LONG,03" LONG,04" LONG,05" LONG,06" LONG,07" LONG,08" LONG,09" LONG,10" LONG,11" LONG,12" LONG,13" LONG,14" LONG,15" LONG,16" LONG,17" LONG,18" LONG,19" FP,1" FP,2" FP,3" FP,4" FP,5" INT,1" INT,2" INT,3" INT,4" INT,5" MM,1" MM,2" MM,3" MM,4" MM,5" SERV,1" SERV,2" SERV,3" SERV,4" SERV,5" AMEAN" MPKI%% ISL,TAGE,32KB" WH,32KB"

b e t t e r

19% 42% 2%

Big improvements on two traces! 32KB: Avg. MPKI = 2.498

b e t t e r

slide-51
SLIDE 51

14

Results: 4KB

0" 2" 4" 6" 8" 10" 12" 14" 16" 18" 20" LONG,00" LONG,01" LONG,02" LONG,03" LONG,04" LONG,05" LONG,06" LONG,07" LONG,08" LONG,09" LONG,10" LONG,11" LONG,12" LONG,13" LONG,14" LONG,15" LONG,16" LONG,17" LONG,18" LONG,19" FP,1" FP,2" FP,3" FP,4" FP,5" INT,1" INT,2" INT,3" INT,4" INT,5" MM,1" MM,2" MM,3" MM,4" MM,5" SERV,1" SERV,2" SERV,3" SERV,4" SERV,5" AMEAN" MPKI%% ISL,TAGE,4KB" WH,4KB"

b e t t e r

slide-52
SLIDE 52

14

Results: 4KB

0" 2" 4" 6" 8" 10" 12" 14" 16" 18" 20" LONG,00" LONG,01" LONG,02" LONG,03" LONG,04" LONG,05" LONG,06" LONG,07" LONG,08" LONG,09" LONG,10" LONG,11" LONG,12" LONG,13" LONG,14" LONG,15" LONG,16" LONG,17" LONG,18" LONG,19" FP,1" FP,2" FP,3" FP,4" FP,5" INT,1" INT,2" INT,3" INT,4" INT,5" MM,1" MM,2" MM,3" MM,4" MM,5" SERV,1" SERV,2" SERV,3" SERV,4" SERV,5" AMEAN" MPKI%% ISL,TAGE,4KB" WH,4KB"

b e t t e r

slide-53
SLIDE 53

14

Results: 4KB

0" 2" 4" 6" 8" 10" 12" 14" 16" 18" 20" LONG,00" LONG,01" LONG,02" LONG,03" LONG,04" LONG,05" LONG,06" LONG,07" LONG,08" LONG,09" LONG,10" LONG,11" LONG,12" LONG,13" LONG,14" LONG,15" LONG,16" LONG,17" LONG,18" LONG,19" FP,1" FP,2" FP,3" FP,4" FP,5" INT,1" INT,2" INT,3" INT,4" INT,5" MM,1" MM,2" MM,3" MM,4" MM,5" SERV,1" SERV,2" SERV,3" SERV,4" SERV,5" AMEAN" MPKI%% ISL,TAGE,4KB" WH,4KB"

b e t t e r

slide-54
SLIDE 54

14

Results: 4KB

0" 2" 4" 6" 8" 10" 12" 14" 16" 18" 20" LONG,00" LONG,01" LONG,02" LONG,03" LONG,04" LONG,05" LONG,06" LONG,07" LONG,08" LONG,09" LONG,10" LONG,11" LONG,12" LONG,13" LONG,14" LONG,15" LONG,16" LONG,17" LONG,18" LONG,19" FP,1" FP,2" FP,3" FP,4" FP,5" INT,1" INT,2" INT,3" INT,4" INT,5" MM,1" MM,2" MM,3" MM,4" MM,5" SERV,1" SERV,2" SERV,3" SERV,4" SERV,5" AMEAN" MPKI%% ISL,TAGE,4KB" WH,4KB"

b e t t e r

Better than ISL-TAGE in 20 out of 40 traces (4.6% on avg.)! 4KB: Avg. MPKI = 3.995

slide-55
SLIDE 55

15

4KB 32KB Statistical corrector 96 384 Loop predictor 376 376 TAGE predictor 3589 30476 Wormhole predictor 134 1413 Total size (bytes) 4195 32649

Wormhole predictor’s storage

slide-56
SLIDE 56

Conclusion

  • Wormhole predictor: 


Side-predictor on top of ISL-TAGE

  • Able to consider the branch

history as multidimensional, capturing columns, diagonals and other patterns

  • 3.995, 2.498, and 2.014 MPKI in

the 4KB, 32KB, and unlimited competition tracks, respectively

16

1 1 1 1 1 1

slide-57
SLIDE 57

Conclusion

  • Wormhole predictor: 


Side-predictor on top of ISL-TAGE

  • Able to consider the branch

history as multidimensional, capturing columns, diagonals and other patterns

  • 3.995, 2.498, and 2.014 MPKI in

the 4KB, 32KB, and unlimited competition tracks, respectively

16

1 1 1 1 1 1

slide-58
SLIDE 58

Wormhole branch prediction using multi-dimensional histories

Jorge Albericio, Joshua San Miguel, 
 Natalie Enright Jerger, and Andreas Moshovos

Questions?