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

MSUB (32-bit)

Test 1: uops

Code:

  msub w0, w0, w1, w2
  mov x0, 1
  mov x1, 2

(no loop instructions)

1000 unrolls and 1 iteration

Retires: 1.000

Issues: 1.000

Integer unit issues: 1.000

Load/store unit issues: 0.000

SIMD/FP unit issues: 0.000

retire uop (01)cycle (02)031e1f3f4d51schedule uop (52)schedule int uop (53)dispatch int uop (56)int uops in schedulers (59)60696d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map int uop inputs (7f)8283flush restart other nonspec (84)85inst all (8c)inst int alu (97)l1d cache writeback (a8)accfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? int retires (ef)f5f6f7f8fd
1004303323006119222510001000100081440140303330332760328911000100030003033380111001100000731161129391000100030343034303430343034
10043033239906119222510001000100081440140303330332760328911000100030003033380111001100000731161129391000100030343034303430343034
1004303323006119222510001000100081440140303330332760328911000100030003033380111001100000731161129391000100030343034303430343034
1004303323006119222510001000100081440140303330332760328911000100030003033380111001100000731161129391000100030343034303430343034
1004303322006119222510001000100081440040303330332760328911000100030003033380111001100000731161129391000100030343034303430343034
10043033230025119222510001000100081440040303330332760328911000100030003033380111001100000731161129391000100030343034303430343034
1004303323006119222510001000100081440040303330332760328911000100030003033380111001100000731161129391000100030343034303430343034
1004303322006119222510001000100081440040303330332760328911000100030003033380111001100000731161129391000100030343034303430343034
10043033220084192225100010001000814401403033303327603289110001000300030333801110011000051731161129391000100030343034303430343034
1004303323006119222510001000100081440140303330332760328911000100030003033380111001100000731161129391000100030343034303430343034

Test 2: Latency 1->2

Code:

  msub w0, w0, w1, w2
  mov x0, 1
  mov x1, 2

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

Result (median cycles for code): 3.0033

retire uop (01)cycle (02)031e3a3f4d51schedule uop (52)schedule int uop (53)dispatch int uop (56)int uops in schedulers (59)60696a6d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map int uop inputs (7f)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)9fl1d cache writeback (a8)acbranch mispred nonspec (cb)cfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? int retires (ef)f5f6f7f8fd
102043003322500611992225101001010010100828940049269533003330033286103287401010010200302003003339511102011009910010100100000710217112993910000101003003430034300343003430034
102043003322500611992225101001010010100828940049269533003330033286103287411010010200302003003337411102011009910010100100000710116112993910000101003003430034300343003430034
102043003322500611992225101001010010100828940149269533003330033286103287411010010200302003003337411102011009910010100100100710116112993910000101003003430034300343003430034
102043003322500841992225101001010010100828940049269533003330033286103287411010010200302003003337411102011009910010100100000710116112993910000101003003430034300343003430034
102043003322500611992225101251013410100828940149269533003330033286103287411010010200302003003337411102011009910010100100000710116112993910000101003003430034300343003430034
1020430033225602321992225101001010010100829066149269533003330033286103287401010010200302003003337411102011009910010100100000710116112993910000101003003430034300343003430034
1020430033225011561992225101001010010100828940049269533003330033286103287411010010200302003003337411102011009910010100100000710116112993910000101003003430034300343003430034
1020430033225002511992225101001010010100828940149269533003330033286103287411010010200302003003337411102011009910010100100000710116112993910000101003003430034300343003430034
102043003322500611992225101001010010100828940049269533003330033286103287411010010200302003003337411102011009910010100100000710116112993910000101003003430034300343003430034
102043003322400611992225101001010010100828940149269533003330033286103287411010010200302003003337411102011009910010100100000710116112993910000101003003430034300343003430034

1000 unrolls and 10 iterations

Result (median cycles for code): 3.0033

retire uop (01)cycle (02)03l2 tlb miss instruction (0a)l2 tlb miss data (0b)1e3f4d51schedule uop (52)schedule int uop (53)dispatch int uop (56)int uops in schedulers (59)696a6d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map int uop inputs (7f)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)9fl1d cache writeback (a8)acbranch cond mispred nonspec (c5)cfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? int retires (ef)f5f6f7f8fd
1002430033225000611992225100101001010010828490492695330033300332863232876310010100203002030033380111002110910100101001590640516662993910000100103003430034300343003430034
10024300332250006119922251001010010100108284904926953300333003328632328763100101002030020300333801110021109101001010000640516662993910000100103003430034300343003430034
1002430033225100611992225100101001010010828490492699730076300332863232876310010100203002030033380111002110910100101001290640616562993910000100103003430034300343003430034
1002430033225000611992225100101001010010828490492695330033300332863232876310010100203002030033380111002110910100101001320640516662993910000100103003430034300343003430034
10024300562250006119922251001010010100108284904926953300333003328632328763100101002030020300333801110021109101001010000640616562993910000100103003430034300343003430034
100243003322500025319922251001010010100108284904926953300333003328632328763100101002030020300333801110021109101001010000640516562993910000100103003430034300343003430034
10024300332250006119922251001010010100108284904926953300333003328632328763100101002030020300333801110021109101001010000640516652993910000100103003430034300343003430034
10024300332250006119922251001010010100108284904926953300333003328632328763100101002030020300333801110021109101001010000640616662993910000100103003430034300343003430034
10024300332250006119922251001010010100108284904926953300333003328632328763100101002030020300333801110021109101001010001640616652993910000100103003430034300343003430034
10024300332250006119922251001010010100108284904926953300333003328632328763100101002030020300333801110021109101001010100640416562993910000100103003430034300343003430034

Test 3: Latency 1->3

Code:

  msub w0, w1, w0, w2
  mov x0, 1
  mov x1, 2

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

Result (median cycles for code): 3.0033

retire uop (01)cycle (02)031e3f4d51schedule uop (52)schedule int uop (53)dispatch int uop (56)int uops in schedulers (59)696a6d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map int uop inputs (7f)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)9fl1d cache writeback (a8)accfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? int retires (ef)f5f6f7f8fd
102043003322506119922251010010100101008289404926953300333003328610328741101001020030200300333741110201100991001010010000710116112993910000101003003430034300343003430034
102043003322596119922251010010100101008289404926953300333003328610328741101001020030200300333741110201100991001010010000710116112993910000101003003430034300343003430034
102043003322506119922251010010100101008289404926953300333007728610328741101001020030200300333744110201100991001010010000710116112993910000101003003430034300343003430034
102043003322506119922251010010100101008289404926953300333003328610328741101001020030200300333741110201100991001010010000710116112993910000101003003430034300343003430034
102043003322506119922251010010100101008289404926953300333003328610328741101001020030200300333741110201100991001010010000710116112993910000101003003430034300343003430034
102043003322506119922251010010100101008289404926953300333003328610328741101001020030200300333741110201100991001010010000710116112993910000101003003430034300343003430034
102043003322506119922251010010100101008289404926953300333003328610328741101001020030200300333741110201100991001010010010710116112993910000101003003430034300343003430034
102043003322406119922251010010100101008289404926953300333003328610328741101001020030200300333741110201100991001010010000710116112993910000101003003430034300343003430034
102043003322506119922251010010100101008289404926953300333003328610328741101001020030200300333741110201100991001010010000710116112993910000101003003430034300343003430034
102043003322506119922251010010100101008289404926953300333003328610328741101001020030200300333741110201100991001010010000710116112993910000101003003430034300343003430034

1000 unrolls and 10 iterations

Result (median cycles for code): 3.0033

retire uop (01)cycle (02)03l2 tlb miss data (0b)18191e3f4d51schedule uop (52)schedule int uop (53)dispatch int uop (56)int uops in schedulers (59)60696a6d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map int uop inputs (7f)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)9fl1d cache writeback (a8)accfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? int retires (ef)f5f6f7f8fd
1002430033225000061199222510010100101001082849004926953300333003328632328763100101002030020300333801110021109101001010318640216222993910000100103003430034300343003430034
1002430033225000061199222510010100101001082849004926953300333003328632328763100101002030020300333801110021109101001010060640216222993910000100103003430034300343003430034
100243003322500006119922251001010010100108284900492695330033300332863232876310010100203002030033380111002110910100101009640216222993910000100103003430034300343003430034
1002430033225000061199222510010100101001082849004926996300783003328632328763100101002030020300333801110021109101001010066640216222993910000100103003430034300343003430034
1002430033225000061199222510010100101001082849004926953300333003328632328763100101002030020300333801110021109101001010069640216222993910000100103003430034300343003430034
100243003322500006119922251001010010100108284900492695330033300332863232876310010100203002030033380111002110910100101003640216222993910000100103003430034300343003430034
100243003322500006119922251001010010100108284900492695330033300332863232876310010100203002030033380111002110910100101000640216222993910000100103003430034300343003430034
1002430033225000061199222510010100101001082849004926953300333003328632328763100101002030020300333801110021109101001010069640216222993910000100103003430034300343003430034
1002430033224000061199222510010100101001082849004926953300333003328632328763100101002030020300333801110021109101001010075640216222993910000100103003430034300343003430034
10024300332240000726199222510010100101001082849004926953300333003328632328763100101002030020300333801110021109101001010075640216222993910000100103003430034300343003430034

Test 4: Latency 1->4

Code:

  msub w0, w1, w2, w0
  mov x0, 1
  mov x1, 2

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

Result (median cycles for code): 1.0037

retire uop (01)cycle (02)03mmu table walk data (08)191e3f51schedule uop (52)schedule int uop (53)dispatch int uop (56)int uops in schedulers (59)60696a6d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map int uop inputs (7f)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)9fl1d cache writeback (a8)accfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? int retires (ef)f5f6f7f8fd
10204100377500048251010010100101007049804969571003710037871438745101001020030200100371621110201100991001010010000710116111003310000101001003810038100381003810038
10204100377500048251010010100101007049804969571003710037871438745101001020030200100371621110201100991001010010000710116111003310000101001003810038100381003810038
10204100377600048251010010100101007049814969571003710037871438745101001020030200100371621110201100991001010010000710116111003310000101001003810038100381003810038
10204100377500048251010010100101007049814969571003710037871438745101001020030200100371621110201100991001010010000710116111003310000101001003810038100381003810038
10204100377500048251010010100101007049804969571003710037871438745101001020030200100371621110201100991001010010000710116111003310000101001003810038100381003810038
10204100377500048251010010100101007049804969571003710037871438745101001020030200100371621110201100991001010010000710116111003310000101001003810038100381003810038
10204100377500048251010010100101007049814969571003710037871438745101001020030200100371621110201100991001010010000710116111003310000101001003810038100381003810038
10204100377500048251010010100101007049804969571003710037871438745101001020030200100371621110201100991001010010000710116111003310000101001003810038100381003810038
10204100377500048251010010100101007049804969571003710037871438745101001020030200100371621110201100991001010010000710116111003310000101001003810038100381003810038
10204100377500048251010010100101007049814969571003710037871438745101001020030200100371621110201100991001010010000710116111003310000101001003810038100381003810038

1000 unrolls and 10 iterations

Result (median cycles for code): 1.0037

retire uop (01)cycle (02)031e1f3f51schedule uop (52)schedule int uop (53)dispatch int uop (56)int uops in schedulers (59)60696a6d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map int uop inputs (7f)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)9fl1d tlb access (a0)st unit uop (a7)l1d cache writeback (a8)accfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? int retires (ef)f5f6f7f8fd
10024100377500482510010100101001070048149695710037100378736387671001010020300201003716411100211091010010100000640216221003310000100101003810038100381003810038
10024100377500482510010100101001070048049695710037100378736387671001010020300201003716411100211091010010100000640216221003310000100101003810038100381003810038
100241003775004825100101001010010700481496957100371003787363883510010100203002010037164111002110910100101000012640216221003310000100101003810038100381003810038
10024100377500482510010100101001070048049695710037100378736387671001010020300201008016411100211091010010100000640216221003310000100101003810038100381003810038
100241003775210482510010100101001070048149695710037100378736387671001010020300201003716411100211091010010100000640216221003310000100101003810038100861003810038
10024100377500482510010100101001070048049695710037100378736387671001010020300201003716411100211091010010100010640216221003310000100101003810038100381003810038
10024100377500482510010100101001070048149695710037100378736387671001010020300201003716411100211091010010100000640216221003310000100101003810038100381003810038
10024100377500482510010100101001070048049695710037100378736387671001010020300201003716411100211091010010100000640216221003310000100101003810038100381003810038
10024100377500482510010100101001070048049695710037100378736387671001010020300201003716411100211091010010100000640216221003310000100101003810038100381003810038
10024100377530482510010100101001070048049695710037100378736387671001010020300201003716411100211091010010100000640216221003310000100101003810038100381003810038

Test 5: throughput

Count: 8

Code:

  msub w0, w8, w9, w9
  msub w1, w8, w9, w9
  msub w2, w8, w9, w9
  msub w3, w8, w9, w9
  msub w4, w8, w9, w9
  msub w5, w8, w9, w9
  msub w6, w8, w9, w9
  msub w7, w8, w9, w9
  mov x8, 9
  mov x9, 10
  mov x10, 11

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

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

retire uop (01)cycle (02)03mmu table walk data (08)l2 tlb miss data (0b)18191e1f3a3f51schedule uop (52)schedule int uop (53)dispatch int uop (56)int uops in schedulers (59)60696a6d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map int uop inputs (7f)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)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)cfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? int retires (ef)f5f6f7f8fd
80204800355990000000462580100801008010040050004976955800358003569964369993801008020024020080035164118020110099100801001000000000015110516118003180000801008003680036800368003680036
80204800355990000000462580100801008010040050004976955800358003569964369993801008020024020080035164118020110099100801001000000000005110116118003180000801008003680036800368003680036
802048003559900000001302580100801008010040050004976955800358003569964369993801008020024020080035164118020110099100801001000000000005110116118003180000801008031080126800368003680036
80204800355990000000462580100801008010040050004976955800358003569964369993801008020024020080035164118020110099100801001000000000005110316118003180000801008003680036800368003680036
80204800355990000000462580100801008010040050004976955800358003569964369993801008020024020080035164118020110099100801001000000000005110116118003180000801008003680036800368003680036
80204800355990000000462580100801008010040050004976955800358003569964369993801008020024020080035164118020110099100801001000000000005110116118003180000801008003680036800368003680036
80204800355990000000462580100801008010040050004976955800358003569964369993801008020024020080035164118020110099100801001000000000005110116118003180000801008003680036800368003680036
80204800356010000000462580100801008010040050004976955800358003569964369993801008020024020080035164118020110099100801001000000000005110116118003180000801008003680036800368003680036
80204800355990000000462580100801008010040050004976955800358003569964369993801008020024020080035164118020210099100801001000000000005110116118003180000801008003680036800368003680036
80204800355990000000462580100801008010040050004976955800358003569964369993801008020024020080035164118020110099100801001000000000005110116118003180000801008003680036800368003680036

1000 unrolls and 10 iterations

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

retire uop (01)cycle (02)03mmu table walk data (08)191e3f51schedule uop (52)schedule int uop (53)dispatch int uop (56)int uops in schedulers (59)60696a6b6d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map int uop inputs (7f)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst branch cond (94)inst int alu (97)9fl1d tlb access (a0)l1d tlb miss (a1)ld unit uop (a6)l1d cache writeback (a8)accfd5map dispatch bubble (d6)daddfetch restart (de)e0? int output thing (e9)eb? int retires (ef)f5f6f7f8fd
800248003559900052125800108001080010400050149769550800358003569986370015800108002024002080035164118002110910800101000000502021602280032800000800108003680036800368003680036
800248003559900071125800108001080032400050149769550800358003569986370015800108002024002080035164118002110910800101000000502021602280032800000800108003680036800368003680036
800248003559900071125800108001080010400050149769550800358003569986370015800108002024002080035164118002110910800101000000502021602280032800000800108003680036800368003680036
800248003560000071125800108001080010400050149769550800358003569986370015800108002024002080035164118002110910800101000000502021602280032800000800108003680036800368003680036
8002480035599009971125800108001080010400050149769550800358003569986370015800108002024002080035164118002110910800101000000502021602280032800000800108003680036800368003680036
80024800355990004625800108001080010400050149769550800358003569986370015800108002024002080035164118002110910800101000000502021602280032800000800108003680217800368003680036
80024800355990004625800108001080010400050149769550800358003569986370015800108002024002080035164118002110910800101000000502021602280032800000800108003680036800368003680036
80024800355990004625800108001080010400050049769550800358003569986370015800108002024002080035164118002110910800101000000502021602280032800000800108003680036800368003680036
80024800355990004625800108001080010400050049769550800358003569986370015800108002024002080035164118002110910800101000000502021602280032800000800108003680036800368003680036
800248003559900125125800108001080010400050049769550800358003569986370015800108002024002080035164118002110910800101000000502021602280032800000800108003680036800778003680036