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

LDR (register, lsl, D)

Test 1: uops

Code:

  ldr d0, [x6, x7, lsl #3]
  mov x7, #4
  mov x8, 0

(no loop instructions)

1000 unrolls and 1 iteration

Retires: 1.000

Issues: 1.000

Integer unit issues: 0.001

Load/store unit issues: 1.000

SIMD/FP unit issues: 0.000

retire uop (01)cycle (02)schedule uop (52)schedule int uop (53)schedule ldst uop (55)dispatch ldst uop (58)simd uops in schedulers (5a)dispatch uop (78)map ldst uop (7d)map ldst uop inputs (80)? int output thing (e9)? ldst retires (ed)
10056781031110301000798610001000200011000
10045441001110001000798610001000200011000
10045441001110001000798610001000200011000
10045441001110001000798610001000200011000
10045441001110001000807610001000200011000
10045441001110001000798610001000200011000
10045441001110001000798610001000200011000
10045471001110001000798610001000200011000
10045441001110001000798610001000200011000
10045441001110001000798610001000200011000

Test 2: Latency 1->2 roundtrip

Chain cycles: 3

Code:

  ldr d0, [x6, x7, lsl #3]
  fmov x0, d0
  eor x8, x8, x0
  eor x8, x8, x0
  add x6, x6, x8
  mov x7, #4
  mov x8, 0

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

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

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)? int retires (ef)
502051001476010840101100061000130130100151000326691511045481107066150109302101000410004602202000810004400011000040100
502041000486010340101100021000030103100031000426692391045629107080350110302121000410004602242000810004400011000040100
502041000486010340101100021000030103100031000426692391045629107080350110302121000410004602242000810004400011000040100
502041000486010340101100021000030103100031000426692391045629107080350110302121000410004602242000810004400011000040100
502041000596010340101100021000030103100031000426693201045662107083650110302121000410004602242000810004400011000040100
502041000486010340101100021000030103100031000426692391045629107080350110302121000410004602242000810004400011000040100
502041000486010340101100021000030103100031000426692391045629107080350110302121000410004602242000810004400011000040100
502041000486010340101100021000030103100031001626695501045740107102050164302501001710017602242000810004400011000040100
502041000486010340101100021000030103100031000426692391045629107080350110302121000410004602242000810004400011000040100
502041000486010340101100021000030103100031000426692391045629107080350110302121000410004602242000810004400011000040100

1000 unrolls and 10 iterations

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

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)? int retires (ef)
500251001566001840011100061000130040100151000026692651046853107189850010300201000010000600202000010000400011000040010
500241000486001340011100021000030010100001000026693091046924107196150010300201000010000600202000010000400011000040010
500241000486001340011100021000030010100001000026693091046924107196150010300201000010000600202000010000400011000040010
500241000486001340011100021000030010100001000026693091046924107196150010300201000010000600202000010000400011000040010
500241000486001340011100021000030010100001000026693091046924107196150010300201000010000600202000010000400011000040010
500241000486001340011100021000030010100001000026693091046924107196150010300201000010000601222003210017400071000040010
500241000536001240011100011000030010100001000026691201046847107188450010300201000010000600202000010000400011000040010
500241000416001240011100011000030010100001000026694171046968107200550010300201000010000600202000010000400011000040010
500241000416001240011100011000030010100001000026691201046847107188450010300201000010000600202000010000400011000040010
500241000416001240011100011000030010100001001626709331047645107269050074300671001710016600202000010000400011000040010

Test 3: Latency 1->3 roundtrip

Chain cycles: 3

Code:

  ldr d0, [x6, x7, lsl #3]
  fmov x0, d0
  eor x8, x8, x0
  eor x8, x8, x0
  add x7, x7, x8
  mov x7, #4
  mov x8, 0

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

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

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)
5020510015660108401011000610001301301001510003266923210454601070647501093021010004100046022420008100044000110000040100
5020410005360103401011000210000301031000310004266929310456511070825501103021210004100046022420008100044000110000040100
5020410005260103401011000210000301031000310004266929310456511070825501103021210004100046022420008100044000110000040100
5020410005060103401011000210000301031000310004266929310456511070825501103021210004100046022420008100044000110000040100
5020410005060103401011000210000301031000310004266929310456511070825501103021210004100046029420034100164000510000040100
5020410005060103401011000210000301031000310004266929310456511070825501103021210004100046022420008100044000110000040100
5020410005060103401011000210000301031000310004266929310456511070825501103021210004100046022420008100044000110000040100
5020410005060103401011000210000301031000310004266929310456511070825501103021210004100046022420008100044000110000040100
5020410005060103401011000210000301031000310004266929310456511070825501103021210004100046022420008100044000110000040100
5020410005060103401011000210000301031000310004266929310456511070825501103021210004100046030020034100174000710000040100

1000 unrolls and 10 iterations

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

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)? int retires (ef)
500251002206001840011100061000130040100151000326694741046983107202450019300301000410004600202000010000400011000040010
500241000486001340011100021000030010100001000026691201046847107188450010300201000010000600202000010000400011000040010
500241000416001240011100011000030010100001002626721021048094107313450127301071002910030600202000010000400011000040010
500241000416001240011100011000030010100001000026691201046847107188450010300201000010000600202000010000400011000040010
500241000416001240011100011000030010100001000026691201046847107188450010300201000010000600202000010000400011000040010
500241000416001240011100011000030010100001000026691201046847107188450010300201000010000600202000010000400011000040010
500241000416001240011100011000030010100001000026691201046847107188450010300201000010000600202000010000400011000040010
500241000416001240011100011000030010100001000026691201046847107188450010300201000010000600202000010000400011000040010
500241000416001240011100011000030010100001000026691201046847107188450010300201000010000600202000010000400011000040010
500241000416001240011100011000030010100001000026691201046847107188450010300201000010000600202000010000400011000040010

Test 4: throughput

Count: 8

Code:

  ldr d0, [x6, x7, lsl #3]
  ldr d0, [x6, x7, lsl #3]
  ldr d0, [x6, x7, lsl #3]
  ldr d0, [x6, x7, lsl #3]
  ldr d0, [x6, x7, lsl #3]
  ldr d0, [x6, x7, lsl #3]
  ldr d0, [x6, x7, lsl #3]
  ldr d0, [x6, x7, lsl #3]
  mov x7, 8

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

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

retire uop (01)cycle (02)schedule uop (52)schedule int uop (53)schedule ldst uop (55)dispatch int uop (56)dispatch ldst uop (58)int uops in schedulers (59)simd uops in schedulers (5a)dispatch uop (78)map int uop (7c)map ldst uop (7d)map int uop inputs (7f)map ldst uop inputs (80)? int output thing (e9)? ldst retires (ed)? int retires (ef)
80204400758010510180004100800083004722428010820080012200160028180000100
80204400578010110180000100800083006402488010820080012200160024180000100
80204400568010110180000100800083006402488010820080012200160024180000100
80204400568010110180000100800083006402488010820080012200160024180000100
80204400568010110180000100800083006402488010820080012200160024180000100
80204400568010110180000100800083006402488010820080012200160024180000100
80204400568010110180000100800083006402488010820080012200160024180000100
80204400568010110180000100800083006402488010820080012200160028180000100
80204400568010110180000100800083006402488010820080012200160024180000100
80204400568010110180000100800083006402488010820080012200160024180000100

1000 unrolls and 10 iterations

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

retire uop (01)cycle (02)schedule uop (52)schedule int uop (53)schedule ldst uop (55)dispatch int uop (56)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)? int output thing (e9)? ldst retires (ed)? int retires (ef)
8002540268800451180034108000830440490080018208001202016002818000010
8002440124800111180000108001030641394080020208001402016000018000010
8002440113800111180000108000030641262080010208000002016000018000010
8002440379800151180004108000030575186080010208000002016000018000010
8002440062800111180000108000030640164080010208000002016000018000010
8002440051800111180000108000030640164080010208000002016000018000010
8002440051800111180000108000030640164080010208000002016000018000010
8002440051800111180000108000030641226080010208000002016000018000010
8002440051800111180000108000030640272080010208000002016000018000010
8002440121800111180000108000030640164080010208000002016000018000010