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

SQDMULH (scalar, S)

Test 1: uops

Code:

  sqdmulh s0, s0, s1
  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)03181e3f4e51schedule uop (52)schedule simd uop (54)dispatch simd uop (57)ldst uops in schedulers (5b)60696d6emap 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
1004303722006125482510001000100039831303018303730372415328951000100020003037303711100110000073116112630100030383038303830383038
10043037230010325482510001000100039831303018303730372415328951000100020003037303711100110000073116112630100030383038303830383038
1004303723006125482510001000100039831313018303730372415328951000100020003037303711100110000073116112630100030383038303830383038
1004303722006125482510001000100039831313018303730372415328951000100020003037303711100110000073116112630100030383038303830383038
1004303723006125482510001000100039831313018303730372415328951000100020003037303711100110000073116112630100030383038303830383038
1004303722036125482510001000100039831313018303730372415328951000100020003037303711100110000073116112630100030383038303830383038
1004303723006125482510001000100039831313018303730372415328951000100020003037303711100110007073116112630100030383038303830383038
1004303722006125482510001000100039831303018303730372415328951000100020003037303711100110000073116112630100030383038303830383038
1004303723006125482510001000100039831303018303730372415328951000100020003037303711100110003373116112630100030383038303830383038
1004303722006125482510001000100039831303018303730372415328951000100020003037303711100110000073116112630100030383038303830383038

Test 2: Latency 1->2

Code:

  sqdmulh s0, s0, s1
  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)03l2 tlb miss data (0b)191e3f4e51schedule 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)simd prf full (72)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 cache writeback (a8)a9accfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? simd retires (ee)? int retires (ef)f5f6f7f8fd
102043003722400917029548251010010010000100100005004277313030018300373003728265032874510100200100002002000030037300371110201100991001001000010000071011611296340100001003003830038300383003830038
1020430037225001595729548251010010010000100100005004277313130018300373003728265032874510100200100002002000030037300371110201100991001001000010000071011611296340100001003003830038300383003830038
1020430037225000105429548251010010010000100100005004277313130018300373003728265032874510100200100002002000030037300371110201100991001001000010000071011611296340100001003003830038300383003830038
102043003722500098029548251010010010000100100005004277313130018300373003728265032874510100200100002002000030037300371110201100991001001000010000071011611296340100001003003830038300383003830038
10204300372250006129548251010010010008100100005004277313130018300373003728265032874510100200100002002000030037300371110201100991001001000010000071011611296340100001003003830038300383003830038
1020430037225000107129548251010010010000100100005004277313130018300373003728265032874510100200100002002000030037300371110201100991001001000010000671011611296340100001003003830038300383003830038
10204300372250006129548251010010010000100100005004277313130018300373003728265032874510100200100002002000030037300371110201100991001001000010000071011611296340100001003003830038300383003830038
10204300372330006129548251010010010000100100005004277313130018300373003728265032874510100200100002002000030037300371110201100991001001000010000071011611296340100001003003830038300383003830038
1020430037225000101529548251010010010000100100005004277313130018300373003728265032874510100200100002002000030037300371110201100991001001000010000071011611296340100001003003830038300383003830038
10204300372250006129548251010010010000100100005004277313030018300373003728265032874510100200100002002000030037300371110201100991001001000010000071011611296340100001003003830038300383003830038

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 instruction (0a)l2 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)6061696d6emap 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)st unit uop (a7)l1d cache writeback (a8)acc2branch mispred nonspec (cb)cfd0l1i cache miss demand (d3)d5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? simd retires (ee)? int retires (ef)f5f6f7f8fd
100243003724100000000612953025100101010000101000050427731310300183003730037282873287671001020100002020000300373003711100211091010100001000001000640002172229630010000103003830038300853003830038
1002430037241000000604352954825100101010000101000050427731300300183003730037283053287671001020100002020000300373003711100211091010100001000002300640002162229630010000103008530038300383003830038
1002430037241000000006129548251001010100001010000504277797003001830037300372828732876710010201000020200003008330037111002110910101000010000035300640002162329668010000103003830038300383003830038
1002430037243000000120612954825100101010000101044750427731310300183003730037282873287671001020100002020000300373003711100211091010100001000001900640002162229630010000103003830038300383003830038
100243003723300000000612954825100101010000101000050427731300300183003730037282873287671001020100002020000300373003711100211091010100001000007000640002162229630010000103003830038300383003830038
100243003722500000000612954825100101010000101000050427731300300183003730037282873287671001020100002020000300373003711100211091010100001000006000640002162229699010000103003830038300383003830038
1002430037225000000006129548251001010100001010000504277313003001830037300372828732876710010201000020200003003730037111002110910101000010000009600640002162229630010000103003830038300383003830038
1002430228228011199132088071652944918010091121008812115477642922400030270304133041228312362891211057201119820226063036830366811002110910101000010400012151220787002992729917210000103036930419303673036830275
10024304192270000001320612954825100101510040101000050427731300300183041530415283184028920113592011470202231030463304621011002110910101000010040103050440787002893529899210000103036830370303733040430369
1002430369228011178111363246632948516110069151005617105967142868941030018300373003728287328767100102010000202000030037300371110021109101010000100000247200640002162229630010000103003830086300383003830038

Test 3: Latency 1->3

Code:

  sqdmulh s0, s1, s0
  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)0309l2 tlb miss data (0b)181e3a3f4e51schedule 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 miss (a1)ld 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
10204300372250000057729548251010010010000100100005004277313030018300373003728265328745101002001000020020000300373003711102011009910010010000100000071011611296340100001003003830038300383003830038
10204300372250000010529548251010010010000100100005004277313030018300373003728265328745101002001000020020000300373003711102011009910010010000100000071011611296340100001003003830038300383003830038
1020430037224000006129548251010010010000100100005004277313030018300373003728265328745101002001000020020000300373003711102011009910010010000100000071011611296340100001003003830038300383003830038
1020430037224000008429548251010010010000100100005004277313030018300373003728265328745101002001000020020000300373003711102011009910010010000100000071011611296340100001003003830038300383003830038
102043003722500000167329548251010010010000100100005004277313030018300373003728265328745101002001000020020000300373003711102011009910010010000100000071011611296340100001003003830038300383003830038
10204300372250000095029548251010010010000100100005004277313030018300373003728265328745101002001000020020000300373003711102011009910010010000100000071011611296340100001003003830038300383003830038
10204300372250001206129548251010010010000100100005004277313030018300373003728265328745101002001000020020000300373003711102011009910010010000100000071011611296340100001003003830038300383003830038
10204300372250000017029548251010010010000100100005004277313030018300373003728265328745101002001000020020000300373003711102011009910010010000100000071011611296340100001003003830038300383003830038
10204300372250000025529548251010010010000100100005004277313030018300373003728265328745101002001000020020000300373003711102011009910010010000100000071011611296320100001003003830038300383003830038
10204300372250000014929548251010010010000100100005004277313030018300373003728265328745101002001000020020000300373003711102011009910010010000100000071011611296340100001003003830038300383003830038

1000 unrolls and 10 iterations

Result (median cycles for code): 3.0037

retire uop (01)cycle (02)031e3a3f4e51schedule 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 miss (a1)l1d cache writeback (a8)acc2cfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? simd retires (ee)? int retires (ef)f5f6f7f8fd
100243003722500212295482510010101000010100005042773130300183003730037282873287671001020100002020000300373003711100211091010100001000006403163329630010000103003830038300383003830038
10024300372250084295482510010101000010100005042773130300183003730037282873287671001020100002020000300373003711100211091010100001000006403163329630010000103003830038300383003830038
100243003722500212295482510010101000010100005042773130300183003730037282873287671001020100002020000300373003711100211091010100001000006403163329650010000103003830038300383003830038
10024300372240061295482510010101000010100005042773130300183003730037282873287671001020100002020000300373003711100211091010100001000006403163329630010000103003830038300383003830038
100243003722590191295482510010101000010100005042773130300183003730037282873287671001020100002020000300373003711100211091010100001000006403163329630010000103003830038300383003830038
100243003722500316295482510010101000010100005042773130300183003730037282873287671001020100002020000300373003711100211091010100001000006403163329683010000103003830038300383003830038
10024300372250061295482510010101000010100005042773130300183003730037282873287671001020100002020000300373003711100211091010100001000006403163329630010000103003830038300383003830038
100243003722500505295482510010101000010100005042773130300183003730037282873287671001020100002020000300373003711100211091010100001000006403163329630010000103003830038300383003830038
100243003722500170295482510010101000010100005042773130300183003730037282873287671001020100002020000300373003711100211091010100001000006403163329630010000103003830038300383003830038
10024300372250082295482510010101000010100005042773130300183003730037282873287671001020100002020000300373003711100211091010100001000006403163329630010000103003830038300383003830038

Test 4: throughput

Count: 8

Code:

  sqdmulh s0, s8, s9
  sqdmulh s1, s8, s9
  sqdmulh s2, s8, s9
  sqdmulh s3, s8, s9
  sqdmulh s4, s8, s9
  sqdmulh s5, s8, s9
  sqdmulh s6, s8, s9
  sqdmulh s7, s8, s9
  movi v8.16b, 9
  movi v9.16b, 10

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

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

retire uop (01)cycle (02)033f51schedule 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)9fl1d cache writeback (a8)accfd5map dispatch bubble (d6)ddfetch restart (de)e0? simd retires (ee)? int retires (ef)f5f6f7f8fd
8020420060150412580100100800001008000050064000020020200392003999733999780100200800002001600002003920039118020110099100100800001000051103161120036800001002004020040200402004020040
80204200391507942580100100800001008000050064000020020200392003999733999780100200800002001600002003920039118020110099100100800001000051101161120036800001002004020040200402004020040
8020420039150412580100100800001008000050064000020020200392003999733999780100200800002001600002003920039118020110099100100800001000051101161120036800001002004020040200402004020040
8020420039150412580100100800001008000050064000020020200392003999733999780100200800002001600002003920039118020110099100100800001000051101161220036800001002004020040200402004020040
8020420039150412580100100800001008000050064000020020200392003999733999780100200800002001600002003920039118020110099100100800001000051101161120036800001002004020040200402004020040
8020420039150412580100100800001008000050064000020020200392003999733999780100200800002001600002003920039118020110099100100800001000051101161120036800001002004020040200402004020040
8020420039150412580100100800001008000050064000020020200392003999733999780100200800002001600002003920039118020110099100100800001000051103161120036800001002004020040200402004020040
8020420039150412580100100800001008000050064000020020200392003999733999780100200800002001600002003920039118020110099100100800001000051101161120036800001002004020040200402004020040
8020420039150412580100100800001008000050064000020020200392003999733999780100200800002001600002003920039118020110099100100800001000051101161120036800001002004020040200402004020040
80204200391508822580100100800001008000050064000020020200392003999733999780100200800002001600002003920039118020110099100100800001000051101161120036800001002004020040200402004020040

1000 unrolls and 10 iterations

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

retire uop (01)cycle (02)0318191e1f3f51schedule 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)9fl1d cache writeback (a8)a9accfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? simd retires (ee)? int retires (ef)f5f6f7f8fd
800242004015000008225800101080000108000050640000200202003920039999631001980010208000020160000200392003911800211091010800001000050201168620036080000102004020040200402004020040
800242003915000004025800101080000108000050640000200202003920039999631001980010208000020160000200392003911800211091010800001000050203163320036080000102004020040200402004020040
800242003915000004025800101080000108000050640000200202003920039999631001980010208000020160000200392003911800211091010800001000050203166320036080000102004020040200402004020040
800242003915000004025800101080000108000050640000200202003920039999631001980010208000020160000200392003911800211091010800001000050203163320036080000102004020040200402004020040
800242003915000004025800101080000108000050640000200202003920039999631001980010208000020160000200392003911800211091010800001000050201164620036080000102004020040200402004020040
8002420039150000035325800101080000108000050640000200202003920039999631001980010208000020160000200392003911800211091010800001000050203165320036080000102004020040200402004020040
8002420039150000036425800101080000108000050640000200202003920039999631001980010208000020160000200392003911800211091010800001000050203165620036380000102004020040200402004020040
80024200391501101966325801071080192128000050640000203572004120098100058100478011020800002016000020039200391180021109101080000100451550203163320036080000102004020040200402004020040
800242003915000304025800101080000108000050640000200202003920039999631001980010208000020160000200392003911800211091010800001000050203163520036080000102004020040200402004020040
800242003915000004025800101080000108000050640000200202003920039999631001980010208000020160000200392003911800211091010800001000050202163320036080000102004020040200402004020040