Apple Microarchitecture Research by Dougall Johnson

M1/A14 P-core (Firestorm): Overview | Base Instructions | SIMD and FP Instructions
M1/A14 E-core (Icestorm):  Overview | Base Instructions | SIMD and FP Instructions

LD2R (1D)

Test 1: uops

Code:

  ld2r { v0.1d, v1.1d }, [x6]
  nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop
  mov x0, 1
  mov x1, 2
  mov x8, 0

(no loop instructions)

1000 unrolls and 1 iteration

Retires (minus 60 nops): 3.000

Issues: 3.004

Integer unit issues: 0.001

Load/store unit issues: 1.000

SIMD/FP unit issues: 2.004

retire uop (01)cycle (02)schedule uop (52)schedule int uop (53)schedule simd uop (54)schedule ldst uop (55)dispatch int uop (56)dispatch simd uop (57)dispatch ldst uop (58)simd uops in schedulers (5a)ldst uops in schedulers (5b)dispatch uop (78)map ldst uop (7d)map simd uop (7e)map ldst uop inputs (80)map simd uop inputs (81)? int output thing (e9)? ldst retires (ed)? simd retires (ee)
6300531667303312030100202004100030031529630001000200010002000110002000
6300429315300512004100002000100030001529030001000200010002000110002000
6300429303300512004100002000100030001529030001000200010002000110002000
6300429303300512004100002000100030001529030001000200010002000110002000
6300429308300512004100002000100030001529030001000200010002000110002000
6300429313300512004100002000100030001529030001000200010002000110002000
6300429308300512004100002000100030001529030001000200010002000110002000
6300429305300512004100002000100030001529030001000200010002000110002000
6300429309300512004100002000100030051530030001000200010002000110002000
6300430186300512004100002000100030001529030001000200010002000110002000

Test 2: Latency 1->3 roundtrip

Chain cycles: 3

Code:

  ld2r { v0.1d, v1.1d }, [x6]
  fmov x0, d0
  eor x8, x8, x0
  eor x8, x8, x0
  add x6, x6, x8
  mov x0, 1
  mov x1, 2
  mov x8, 0

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

Result (median cycles for code, minus 3 chain cycles): 9.0047

retire uop (01)cycle (02)schedule uop (52)schedule int uop (53)schedule simd uop (54)schedule ldst uop (55)dispatch int uop (56)dispatch simd uop (57)dispatch ldst uop (58)int uops in schedulers (59)simd uops in schedulers (5a)ldst uops in schedulers (5b)dispatch uop (78)map int uop (7c)map ldst uop (7d)map simd uop (7e)map int uop inputs (7f)map ldst uop inputs (80)map simd uop inputs (81)? int output thing (e9)? ldst retires (ed)? simd retires (ee)? int retires (ef)
70206120185801304010630022100023016030057100033209242120902230848647010830208100033000960216100033000940001100002000040100
70204120047801074010130006100003010330002100033208876120886830845127010830208100033000960284100153004640006100002000040100
70204120047801074010130006100003010330002100033209114120902130847517010830208100033000960216100033000940001100002000040100
70204120047801074010130006100003010330002100033208952120895830845957010830208100033000960216100033000940001100002000040100
70204120047801074010130006100003010330002100033208925120894730845697010830208100033000960216100033000940001100002000040100
70204120047801074010130006100003010330002100033208925120894730845697010830208100033000960216100033000940001100002000040100
70204120047801074010130006100003010330002100033208925120894730845697010830208100033000960288100153004540006100002000040100
70204120050801074010130006100003010330002100033208925120894730845697010830208100033000960216100033000940001100002000040100
70204120047801074010130006100003010330002100033208979120896930846217010830208100033000960216100033000940001100002000040100
70204120047801074010130006100003010330002100033208925120894730845697010830208100033000960216100033000940001100002000040100

1000 unrolls and 10 iterations

Result (median cycles for code, minus 3 chain cycles): 9.0049

retire uop (01)cycle (02)schedule uop (52)schedule int uop (53)schedule simd uop (54)schedule ldst uop (55)dispatch int uop (56)dispatch simd uop (57)dispatch ldst uop (58)int uops in schedulers (59)simd uops in schedulers (5a)ldst uops in schedulers (5b)dispatch uop (78)map int uop (7c)map ldst uop (7d)map simd uop (7e)map int uop inputs (7f)map ldst uop inputs (80)map simd uop inputs (81)? int output thing (e9)? ldst retires (ed)? simd retires (ee)? int retires (ef)
70025120146800304001130018100013004030027100033208978120937130845247001830028100033000960108100153004540006100002000040010
70024120047800174001130006100003001030000100003208998120939330845437001030020100003000060020100003000040001100002000040010
70024120047800174001130006100003001030000100003208998120939330845437001030020100003000060020100003000040001100002000040010
70024120047800174001130006100003001030000100003208998120939330845437001030020100003000060020100003000040001100002000040010
70024120047800174001130006100003001030000100003208998120939330845437001030020100003000060020100003000040001100002000040010
70024120047800174001130006100003001030000100003208998120939330845437001030020100003000060108100153004540006100002000040010
70024120047800174001130006100003001030000100003208998120939330845437001030020100003000060020100003000040001100002000040010
70024120047800174001130006100003001030000100003208998120939330845437001030020100003000060020100003000040001100002000040010
70024120047800174001130006100003001030000100003208998120939330845437001030020100003000060020100003000040001100002000040010
70024120047800174001130006100003001030000100003208998120939330845437001030020100003000060020100003000040001100002000040010

Test 3: Latency 2->3 roundtrip

Chain cycles: 3

Code:

  ld2r { v0.1d, v1.1d }, [x6]
  fmov x1, d1
  eor x8, x8, x1
  eor x8, x8, x1
  add x6, x6, x8
  mov x0, 1
  mov x1, 2
  mov x8, 0

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

Result (median cycles for code, minus 3 chain cycles): 9.0049

retire uop (01)cycle (02)schedule uop (52)schedule int uop (53)schedule simd uop (54)schedule ldst uop (55)dispatch int uop (56)dispatch simd uop (57)dispatch ldst uop (58)int uops in schedulers (59)simd uops in schedulers (5a)ldst uops in schedulers (5b)dispatch uop (78)map int uop (7c)map ldst uop (7d)map simd uop (7e)map int uop inputs (7f)map ldst uop inputs (80)map simd uop inputs (81)? int output thing (e9)? ldst retires (ed)? simd retires (ee)? int retires (ef)
70205120157801204010130018100013013030027100033208908120882830845297010830208100033000960284100153004540006100002000040100
70204120049801074010130006100003010330002100033208979120896730846197010830208100033000960216100033000940001100002000040100
70204120049801074010130006100003010330002100033209006120897830846457010830208100033000960216100033000940001100002000040100
70204120049801074010130006100003010330002100033208979120896730846197010830208100033000960216100033000940001100002000040100
70204120134801074010130006100003010330002100033209195120905030848227010830208100033000960216100033000940001100002000040100
70204120049801074010130006100003010330002100033208979120896730846197010830208100033000960288100153004340006100002000040100
70204120049801074010130006100003010330002100033208979120896730846197010830208100033000960216100033000940001100002000040100
70204120049801074010130006100003010330002100033208979120896730846197010830208100033000960216100033000940001100002000040100
70204120049801074010130006100003010330002100033208979120896730846197010830208100033000960216100033000940001100002000040100
70204120052801074010130006100003010330002100033209478120905830850747010830208100033000960216100033000940001100002000040100

1000 unrolls and 10 iterations

Result (median cycles for code, minus 3 chain cycles): 9.0049

retire uop (01)cycle (02)schedule uop (52)schedule int uop (53)schedule simd uop (54)schedule ldst uop (55)dispatch int uop (56)dispatch simd uop (57)dispatch ldst uop (58)int uops in schedulers (59)simd uops in schedulers (5a)ldst uops in schedulers (5b)dispatch uop (78)map int uop (7c)map ldst uop (7d)map simd uop (7e)map int uop inputs (7f)map ldst uop inputs (80)map simd uop inputs (81)? int output thing (e9)? ldst retires (ed)? simd retires (ee)? int retires (ef)
70025120154800304001130018100013004030027100033209032120939130845727001830028100033000960020100003000040001100002000040010
70024120049800174001130006100003001030000100003209052120941330845937001030020100003000060020100003000040001100002000040010
70024120049800174001130006100003001030000100003209052120941330845937001030020100003000060020100003000040001100002000040010
70024120049800174001130006100003001030000100003209052120941330845937001030020100003000060020100003000040001100002000040010
70025120082800274001630010100013004330032100003209052120941330845937001030020100003000060020100003000040001100002000040010
70024120049800174001130006100003001030000100003209052120941330845937001030020100003000060020100003000040001100002000040010
70025120163800274001630010100013004330032100003209160120945730846977001030020100003000060020100003000040001100002000040010
70024120047800174001130006100003001330002100003208998120939330845437001030020100003000060020100003000040001100002000040010
70024120047800174001130006100003001030000100003209187120947030847257001030020100003000060020100003000040001100002000040010
70025120147800294001530012100023004330031100263211883121052130872897016130100100273008160020100003000040001100002000040010

Test 4: throughput

Count: 8

Code:

  ld2r { v0.1d, v1.1d }, [x6]
  ld2r { v0.1d, v1.1d }, [x6]
  ld2r { v0.1d, v1.1d }, [x6]
  ld2r { v0.1d, v1.1d }, [x6]
  ld2r { v0.1d, v1.1d }, [x6]
  ld2r { v0.1d, v1.1d }, [x6]
  ld2r { v0.1d, v1.1d }, [x6]
  ld2r { v0.1d, v1.1d }, [x6]
  mov x7, x6
  mov x8, x6
  mov x9, x6
  mov x10, x6
  mov x11, x6
  mov x12, x6
  mov x13, x6

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

Result (median cycles for code divided by count): 1.0007

retire uop (01)cycle (02)schedule uop (52)schedule int uop (53)schedule simd uop (54)schedule ldst uop (55)dispatch int uop (56)dispatch simd uop (57)dispatch ldst uop (58)int uops in schedulers (59)simd uops in schedulers (5a)ldst uops in schedulers (5b)dispatch uop (78)map int uop (7c)map ldst uop (7d)map simd uop (7e)map int uop inputs (7f)map ldst uop inputs (80)map simd uop inputs (81)? int output thing (e9)? ldst retires (ed)? simd retires (ee)? int retires (ef)
2402058017424019310116007280020100160034800063002400359861102401142008000716001320080007160013180000160000100
24020480430240443101160222801201001602378000630024003516004902401142008000716001320080007160013180000160000100
24020480060240125101160020800041001600088000630024003516004902401142008000716001320080007160013180000160000100
24020480056240125101160020800041001600088000630024003516004902401142008000716001320080007160013180000160000100
2402048007324012510116002080004100160008800063002400411344522240114200800071600133056590182129999118117681412996615954
24020480056240125101160020800041001600088000630024004616005422401142008000716001320080034160066180000160000100
24020580107240184101160056800271001600568000630024009812223442401142008000716001320080033160063180000160000100
24020480428240445101160224801201001602378000630024017016004502401142008000716001320080007160013180000160000100
24020480054240125101160020800041001600088000630024005216004382401142008000716001320080123160241180000160000100
24020480054240125101160020800041001600088000630024003416004382401142008000716001320080007160013180000160000100

1000 unrolls and 10 iterations

Result (median cycles for code divided by count): 1.0006

retire uop (01)cycle (02)schedule uop (52)schedule int uop (53)schedule simd uop (54)schedule ldst uop (55)dispatch int uop (56)dispatch simd uop (57)dispatch ldst uop (58)int uops in schedulers (59)simd uops in schedulers (5a)ldst uops in schedulers (5b)dispatch uop (78)map int uop (7c)map ldst uop (7d)map simd uop (7e)map int uop inputs (7f)map ldst uop inputs (80)map simd uop inputs (81)? int output thing (e9)? ldst retires (ed)? simd retires (ee)? int retires (ef)
24002580150240101111600708002010160034800003024006716004442400102080000160000208000016000018000016000010
24002480056240031111600208000010160000800003024000716002362400102080000160000208000016000018000016000010
24002480048240027111600168000010160000800003024000716002362400102080000160000208003516006918000016000010
24002480048240027111600168000010160000800003024000716002362400102080000160000208000016000018000016000010
24002480048240027111600168000010160000800003024000716002362400102080000160000208000016000018000016000010
24002480048240027111600168000010160000800003024000716002362400102080000160000208000016000018000016000010
24002480048240027111600168000010160000800003024000716002362400102080000160000208000016000018000016000010
24002480048240027111600168000010160000800003024000716002362400102080000160000208000016000018000016000010
24002480048240027111600168000010160000800003024000716002362400102080000160000208000016000018000016000010
24002480048240027111600168000010160000800003024000716002362400102080000160000208003716007118000016000010