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

SRSRA (vector, 4H)

Test 1: uops

Code:

  srsra v0.4h, v1.4h, #3
  movi v0.16b, 1
  movi v1.16b, 2

(no loop instructions)

1000 unrolls and 1 iteration

Retires: 1.000

Issues: 1.000

Integer unit issues: 0.000

Load/store unit issues: 0.000

SIMD/FP unit issues: 1.000

retire uop (01)cycle (02)030f1e3f4e51schedule uop (52)schedule simd uop (54)dispatch simd uop (57)ldst uops in schedulers (5b)696d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map simd uop (7e)map simd uop inputs (81)8283flush restart other nonspec (84)85inst all (8c)inst simd alu (9a)l1d cache writeback (a8)accfd5map dispatch bubble (d6)ddfetch restart (de)e0? simd retires (ee)f5f6f7f8fd
100430372320612548251000100010003983133018303730372415328951000100020003037303711100110000073216112630100030383038303830383038
100430372300822548251000100010003983133018303730372415328951000100020003037303711100110000073116112630100030383038303830383038
100430372300612548251000100010003983133018303730372415328951000100020003037303711100110000073116112630100030383038303830383038
100430372200612548251000100010003983133018303730372415328951000100020003037303711100110000073116112630100030383038303830383038
100430372200612548251000100010003983133018303730372415328951000100020003037303711100110000073116112630100030383038303830383038
100430372300612548251000100010003983133018303730372415328951000100020003037303711100110000073116112630100030383038303830383038
100430372300612548251000100010003983133018303730372415328951000100020003037303711100110000073116112630100030383038303830383038
100430372300612548251000100010003983133018303730372415328951000100020003037303711100110002073116112630100030383038303830383038
100430372200612548251000100010003983133018303730372415328951000100020003037303711100110000073116112630100030383038303830383038
100430372300612548251000100010003983133018303730372415328951000100020003037303711100110000073116112630100030383038303830383038

Test 2: Latency 1->1

Code:

  srsra v0.4h, v1.4h, #3
  movi v0.16b, 1
  movi v1.16b, 2

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

Result (median cycles for code): 3.0037

retire uop (01)cycle (02)03mmu table walk data (08)09191e3a3f4e51schedule uop (52)schedule int uop (53)schedule simd uop (54)dispatch int uop (56)dispatch simd uop (57)int uops in schedulers (59)ldst uops in schedulers (5b)60696b6d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map simd uop (7e)map int uop inputs (7f)map simd uop inputs (81)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)inst simd alu (9a)9fl1d tlb access (a0)l1d tlb miss (a1)l1d cache writeback (a8)acc2branch cond mispred nonspec (c5)cfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? simd retires (ee)? int retires (ef)f5f6f7f8fd
10204301202261120064129548251012510010000100100005004277313130018030037300372826532874510125200100002002000030037300371110201100991001001000010000200071011611296340100001003003830038300383003830038
102043003722400000114329548251010010010000100100005004277313030018030037300372826532874510100204100002002000030037300371110201100991001001000010000000071011611296340100001003003830038300383003830038
1020430037224000006129548251010010010000100100005004277313030018030037300372826532874510125200100002002000030037300371110201100991001001000010000000071011611296340100001003003830038300383003830038
1020430037225000006129548251010010010000100100005004277313030018030037300372826532874510100200100002002000030037300371110201100991001001000010000000071011611296340100001003003830038300383003830038
10204300372250000019329548251010010010000100100005004277313030018030037300372826532874510100200100002002000030037300371110201100991001001000010000000071011611296340100001003003830085300383003830038
1020430037224000006129548251010010010000100101485004277313030018030037300372826532874510100200100002002000030037300371110201100991001001000010000000071011611296340100001003003830038300383003830038
10204300372250000014929548251010010010000100100005004277313030018030037300372826532874510100200100002002000030037300371110201100991001001000010000000071011622296340100001003003830038300383003830038
10204300372250000010529548251010010010000100100005004277313130018030037300372826532874510100200100002002000030037300371110201100991001001000010000000071011611296340100001003003830038300383003830038
1020430037225000008229548251010010010000100100005004277313130018030037300372826532874510100200100002002000030037300371110201100991001001000010000000071011611296340100001003003830038300383003830038
10204300372250000116529548251010010010000100100005004277313030018030037300372826532874510100200100002002000030037300371110201100991001001000010000000071011611296340100001003003830038300383003830038

1000 unrolls and 10 iterations

Result (median cycles for code): 3.0037

retire uop (01)cycle (02)03mmu table walk data (08)09l2 tlb miss data (0b)18191e1f3a3f4e51schedule uop (52)schedule int uop (53)schedule simd uop (54)dispatch int uop (56)dispatch simd uop (57)int uops in schedulers (59)ldst uops in schedulers (5b)60696d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map simd uop (7e)map int uop inputs (7f)map simd uop inputs (81)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)inst simd alu (9a)9fl1d tlb access (a0)ld unit uop (a6)l1d cache writeback (a8)acc2branch cond mispred nonspec (c5)cfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? simd retires (ee)? int retires (ef)f5f6f7f8fd
100243003722500000000612954825100181210000101000050427731313001830037300372828732876710010201000020200003003730037111002110910101000010004712006402162229630010000103003830038300383003830038
1002430037225000000006129548251001010100001010000504277313130018300373003728287328767100102010000202000030037300371110021109101010000100000006402162229630010000103003830038300383003830038
1002430037225000000006129548251001010100001010000504277313130018300373003728287328767100102010000202000030037300371110021109101010000100000006402162229630010000103003830038300383003830038
1002430037225000000006129548251001010100001010000504277313130018300373003728287328767100102010000202000030037300371110021109101010000100000006402162229630010000103003830038300383003830038
10024300372250000000061295482510010101000010100005042773131300183003730037282873287671001020100002020000300373003711100211091010100001000310006402162229630010000103003830038300383003830038
1002430037224000000006129548251001010100001010000504277313130018300373003728287328767100102010000202000030037300371110021109101010000100010006402162229630010000103003830038300383003830038
10024300372250000012008229548251001010100001010000504278670130018300373003728287328767100102010000202000030037300371110021109101010000100033006402162229630010000103003830038300383003830038
10024300372250000000071229548251001010100001010000504277313130018300373003728287328767100102010000202000030037300371110021109101010000100000016402162229630010000103003830038300383003830038
1002430037242000000006129548251001010100001010000504277313130018300373003728287328767100102010000202000030037300371110021109101010000100000006402162229630010000103003830038300383003830038
1002430037225000000008029548251001010100001010000504277313030018300373003728287328767100102010000202000030037300371110021109101010000100000006402162229630010000103003830038300383003830038

Test 3: Latency 1->2

Code:

  srsra v0.4h, v0.4h, #3
  movi v0.16b, 1

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

Result (median cycles for code): 3.0037

retire uop (01)cycle (02)03mmu table walk data (08)09l2 tlb miss data (0b)18191e1f3f4e51schedule uop (52)schedule int uop (53)schedule simd uop (54)dispatch int uop (56)dispatch simd uop (57)int uops in schedulers (59)ldst uops in schedulers (5b)60696d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map simd uop (7e)map int uop inputs (7f)map simd uop inputs (81)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)inst simd alu (9a)9fl1d tlb access (a0)l1d tlb miss (a1)ld unit uop (a6)l1d cache writeback (a8)a9acc2branch cond mispred nonspec (c5)branch mispred nonspec (cb)cdcfd5map dispatch bubble (d6)dde0? simd retires (ee)? int retires (ef)f5f6f7f8fd
1020430037225000000061295472510100100100001001000050042771601300183003730037282716287401010020010000200200003003730037111020110099100100100001000000000111718016029645100001003003830038300383003830038
1020430037225000000061295472510100100100001001000050042771600300183003730037282716287401010020010008200200163003730037111020110099100100100001000000000111718024029799100001003003830038300383003830038
1020430037225000000061295472510100100100001001000050042771600300183003730037282716287411010020010008200200163003730037111020110099100100100001000000000111718016029646100001003003830038300383003830038
1020430037225000000061295472510100100100001001000050042771600300183003730037282717287571025320010008200200163003730037111020110099100100100001000000000111717016029645100001003003830038300383003830038
1020430037224000000061295472510100100100001001000050042771600300183003730037282716287401010020010008200200163003730037111020110099100100100001000000000111717016029646100001003003830038300383003830038
1020430037225000000061295472510100100100001001000050042771600300183003730037282716287411010020010008200200163003730037111020110099100100100001000000000111717016029646100001003003830038300383003830038
1020430037224000000061295472510100100100001001000050042771600300183003730037282716287401010020010008200200163003730037111020110099100100100001000021282780111717016029646100001003003830038300383003830038
1020430037225000000061295472510100100100001001000050042771600300183003730037282717287411010020010008200200163003730037111020110099100100100001000000000111718016029645100001003003830038300383003830038
1020430037225000000061295472510100100100001001000050042771600300183003730037282716287401010020010008200200163003730037111020110099100100100001000000000111717016029645100001003003830038300383003830038
1020430037225000000061295472510100100100001001000050042771600300183003730037282717287401010020010008200200163003730037111020110099100100100001000000000111718016029645100001003003830038300383003830038

1000 unrolls and 10 iterations

Result (median cycles for code): 3.0037

retire uop (01)cycle (02)03mmu table walk data (08)1e3f4e51schedule uop (52)schedule int uop (53)schedule simd uop (54)dispatch int uop (56)dispatch simd uop (57)int uops in schedulers (59)ldst uops in schedulers (5b)696d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map simd uop (7e)map int uop inputs (7f)map simd uop inputs (81)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)inst simd alu (9a)9fld unit uop (a6)l1d cache writeback (a8)accfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? simd retires (ee)? int retires (ef)f5f6f7f8fd
100243003722500822954725100101010000101000050427716030018300373003728286328767100102010000202000030037300371110021109101010000100006402162229629010000103003830038300383003830038
100243003722500612954725100101010000101000050427716030018300373003728286328767100102010000202000030037300371110021109101010000100006402162229629010000103003830038300383003830038
100243003722500612954725100101010000101000050427716030018300373003728286328767100102010000202000030037300371110021109101010000100006402162229629010000103003830038300383003830038
100243003722500612954725100101010000101000050427716030018300373003728286328767100102010000202000030037300371110021109101010000100006402162229629010000103003830038300383003830038
100243003722500612954725100101010000101000050427716030018300373003728286328767100102010000202000030037300371110021109101010000100006402162229629010000103003830038300383003830038
100243003722500612954725100101010000101000050427716030018300373003728286328767100102010000202000030037300371110021109101010000100006402162229629010000103003830038300383003830038
100243003722500612954725100101010000101000050427716030018300373003728286328767100102010000202000030037300371110021109101010000100006403162229629010000103003830038300383003830038
100243003722500612954725100101010000101000050427851230018300373003728286328767100102010000202000030037300371110021109101010000100066403162229629010000103003830038300383003830038
100243003722410612954725100101010000101000050427716030018300373003728286328767103102010000202032230037300371110021109101010000100006402162229629010000103003830038300383003830038
100243003722400612954725100101010000101000050427716030018300373003728286328787100102010000202000030037300371110021109101010000100006402162229629010000103003830038300383003830038

Test 4: throughput

Count: 8

Code:

  movi v0.16b, 0
  srsra v0.4h, v8.4h, #3
  movi v1.16b, 0
  srsra v1.4h, v8.4h, #3
  movi v2.16b, 0
  srsra v2.4h, v8.4h, #3
  movi v3.16b, 0
  srsra v3.4h, v8.4h, #3
  movi v4.16b, 0
  srsra v4.4h, v8.4h, #3
  movi v5.16b, 0
  srsra v5.4h, v8.4h, #3
  movi v6.16b, 0
  srsra v6.4h, v8.4h, #3
  movi v7.16b, 0
  srsra v7.4h, v8.4h, #3
  movi v8.16b, 9

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

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

retire uop (01)cycle (02)03191e1f3f51schedule uop (52)schedule int uop (53)schedule simd uop (54)dispatch int uop (56)dispatch simd uop (57)int uops in schedulers (59)ldst uops in schedulers (5b)60696d6emap rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map simd uop (7e)map int uop inputs (7f)map simd uop inputs (81)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)inst simd alu (9a)9fl1d cache writeback (a8)acbranch cond mispred nonspec (c5)branch mispred nonspec (cb)cdcfd0d5map dispatch bubble (d6)ddfetch restart (de)e0? simd retires (ee)? int retires (ef)f5f6f7f8fd
160204200881500001632580116100800161008002850064019602004520065200656128012820080028200160056200652006511160201100991001001600001000011110122081688200621600001002006620066200662006620066
16020420065150000292580116100800161008002850064019612004520065200656128012820080028200160056200652006511160201100991001001600001000011110127381688200621600001002006620066200662006620066
16020420065150000292580116100800161008002850064019602004520065200656128012820080028200160056200652006511160201100991001001600001000011110128081683200621600001002006620066200662006620066
16020420065151000292580116100800161008002850064019602004520065200656128012820080028200160056200652006511160201100991001001600001000011110127071673200621600001002006620066200662006620066
16020420065151000522580116100800161008002850064019602004520065200656128012820080028200160056200652006511160201100991001001600001000011110127081688200621600001002006620066200662006620066
16020420065151000292580116100800161008002850064019602004520065200656128012820080028200160056200652006511160201100991001001600001000011110127031688200621600001002006620066200662006620066
16020420065150000292580116100800161008002850064019612004520065200656128012820080028200160056200652006511160201100991001001600001000011110128371688200621600001002006620066200662006620066
160204200651500004132580116100800161008002850064019602004520065201436128012820080028200160056200652006511160201100991001001600001000011110150081683200621600001002006620066200662006620066
16020420065150000292580200100800161008002850064019612004520065200656128012820080028200160056200652006511160201100991001001600001000011110127081689200621600001002006620066200662006620066
16020420065150000292580116100800161008002850064019602004520065200656128012820080028200160056200652006511160201100991001001600001000011110127071687200621600001002006620066200662006620066

1000 unrolls and 10 iterations

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

retire uop (01)cycle (02)03l1i tlb fill (04)1e3a3f51schedule uop (52)schedule int uop (53)schedule simd uop (54)dispatch int uop (56)dispatch simd uop (57)int uops in schedulers (59)ldst uops in schedulers (5b)5f60696d6emap rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map simd uop (7e)map int uop inputs (7f)map simd uop inputs (81)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)inst simd alu (9a)9faccfd0d2l1i cache miss demand (d3)d5map dispatch bubble (d6)d9dadbddfetch restart (de)e0eaeb? simd retires (ee)? int retires (ef)f5f6f7f8fd
160024200761501004525800101080000108000050640000112002920048200483228001020800002016000020048200481116002110910101600001001004084113022111292220045160160000102004920049200492004920049
160024200481501007425800101080000108000050640000112002920048200483228001020800002016000020048200481116002110910101600001001004760112626111252520045310160000102004920053200492004920049
160024200481500019725800101080000108000050640000112002920048200483228001020800002016000020048200481116002110910101600001001004966111522111261620045160160000102004920049200492004920049
160024200481501014525800101080000108000050640000112002920048200483228001020800002016000020048200481116002110910101600001001004966112622111162520045160160000102004920049200492004920049
160024200481501014525800101080000108000050640000112002920048200483228001020800002016000020048200481116002110910101600001001004863112522111152520045160160000102004920049200492004920049
1600242004815010011025800101080000108000050640000112002920052200483228001020800002016000020048200481116002110910101600001001004957112722111262620045160160000102004920049200492004920049
160024200481501004525800101080000108000050640000012002920048200483228001020800002016000020048200481116002110910101600001001004960112822111202520045160160000102004920049200492004920049
160024200481501017425800101080000108000050640000112002920048200483228001020800002016000020048200481116002110910101600001001004957112522121262620045160160000102004920049200492004920049
160024200521501017425800101080000108000050640000112002920048200483228001020800002016000020048200481116002110910101600001001004360112722111261620045160160000102004920053200492004920049
160024200481501017425800101080000108000050640000112002920048200483228001020800002016000020052200481116002110910101600001001004957112626111152520045160160000102004920049200492004920049

Test 5: throughput

Count: 16

Code:

  srsra v0.4h, v16.4h, #3
  srsra v1.4h, v16.4h, #3
  srsra v2.4h, v16.4h, #3
  srsra v3.4h, v16.4h, #3
  srsra v4.4h, v16.4h, #3
  srsra v5.4h, v16.4h, #3
  srsra v6.4h, v16.4h, #3
  srsra v7.4h, v16.4h, #3
  srsra v8.4h, v16.4h, #3
  srsra v9.4h, v16.4h, #3
  srsra v10.4h, v16.4h, #3
  srsra v11.4h, v16.4h, #3
  srsra v12.4h, v16.4h, #3
  srsra v13.4h, v16.4h, #3
  srsra v14.4h, v16.4h, #3
  srsra v15.4h, v16.4h, #3
  movi v16.16b, 17

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

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

retire uop (01)cycle (02)03091e1f3f51schedule uop (52)schedule int uop (53)schedule simd uop (54)dispatch int uop (56)dispatch simd uop (57)int uops in schedulers (59)ldst uops in schedulers (5b)60696d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map simd uop (7e)map int uop inputs (7f)map simd uop inputs (81)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)inst simd alu (9a)9fst unit uop (a7)l1d cache writeback (a8)a9acbranch cond mispred nonspec (c5)branch mispred nonspec (cb)cdcfmap dispatch bubble (d6)e0? simd retires (ee)? int retires (ef)f5f6f7f8fd
16020440059300000302516010810016000810016002050012801321400204003940039199776199901601202001600322003200644003940112111602011009910010016000010000001111011816400361600001004004040040400404004040040
16020440039300000302516010810016000810016002050012801321400204003940039199776199901601202001600322003200644003940039111602011009910010016000010000001111011816400361600001004004040040400404004040040
16020440039300000302516010810016000810016002050012801320400204003940039199776199901601202001600322003200644003940039111602011009910010016000010000001111011816400361600001004004040040400404004040040
16020440039300090302516010810016000810016002050012801320400204003940039199776199901601202001600322003200644003940039111602011009910010016000010000001111011816400361600001004004040040400404004040040
16020440039299000302516010810016000810016002050012801320400204003940039199776199901601202001600322003200644003940039111602011009910010016000010000001111011816400361600001004004040040400404004040040
16020440039299000302516010810016000810016002050012801321400204003940039199776199901601202001600322003200644003940039111602011009910010016000010000001111011816400361600001004004040040400404004040040
16020440039300000302516010810016000810016002050012801321400204003940039199776199901601202001600322003200644003940039111602011009910010016000010000001111011816400361600001004004040040400404004040040
16020440039300090302516010810016000810016002050012801321400204003940039199776199901601202001600322003200644003940039111602011009910010016000010000001111011816400361600001004004040040400404004040040
16020440039300000302516010810016000810016002050012801321400204003940039199776199901601202001600322003200644003940039111602011009910010016000010000001111011816400361600001004004040040400404004040040
160204400393000006952516010810016000810016002050012801321400204003940039199776199901601202001600322003200644003940039111602011009910010016000010000001111011816400361600001004004040040400404004040040

1000 unrolls and 10 iterations

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

retire uop (01)cycle (02)03mmu table walk data (08)09l2 tlb miss data (0b)18191e3a3f51schedule uop (52)schedule int uop (53)schedule simd uop (54)dispatch int uop (56)dispatch simd uop (57)int uops in schedulers (59)ldst uops in schedulers (5b)5f60696d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map simd uop (7e)map int uop inputs (7f)map simd uop inputs (81)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)inst simd alu (9a)9fl1d tlb access (a0)ld unit uop (a6)l1d cache writeback (a8)acc2cfd0d2l1i cache miss demand (d3)d5map dispatch bubble (d6)d9dadbddfetch restart (de)e0eaeb? simd retires (ee)? int retires (ef)f5f6f7f8fd
160024400512990000000462516001010160000101600005012800001040020400394003919996320019160010201600002032000040039400391116002110910101600001000000100223112516211252540036155160000104004040040400404004040040
160024400392990000000462516001010160000101600005012800001140020400394003919996320047160116201600002032000040039400391116002110910101600001000000100223112516211242640036155160000104004040040400404004040040
160024400393000000000462516001010160000101600005012800001140020400394003919996320019160010201600002032000040039400391116002110910101600001000000100223112416211262540036155160000104004040040400404004040040
16002440039300000005640882516001010160000101600005012800001140020400394003919996320019160010201600002032000040039400391116002110910101600001000030100229112416211242440086155160000104004040040400404004040040
160024400393000000000462516001010160000101600005012800001140020400394003919996320019160010201600002032000040039400391116002110910101600001000000100223232616211242440036155160000104004040040400404004040040
160024400392990000000672516001010160000101600005012800001140020400394003919996320019160010201600002032000040039400391116002110910101600001003500100223112416211272340036155160000104004040040400404004040040
160024400392990000000462516001010160000101600005012800001040020400394003919996320019160010201600002032000040039400901116002110910101600001000000100223112616211242340036155160000104004040040400404004040040
160024400393010000000462516001010160000101600005012800001140020400394003919996320019160010201600002032000040039400391116002110910101600001000100100223112416211242440036155160000104004040040400404004040040
160024400393000000000462516001010160000101601075012800001040020400394003919996320019160010201600002032000040039400391116002110910101600001000300100223112516211252340036155160000104004040040400404004040040
160024400393000000000462516001010160000101600005012800001140020400394003919996320019160010201600002032000040039400391116002110910101600001000000100223112616411262740036155160000104004040040400404004040040