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

UADALP (vector, 4H)

Test 1: uops

Code:

  uadalp v0.4h, v1.8b
  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)031e3f4e51schedule 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 tlb miss (a1)l1d cache writeback (a8)accfd5map dispatch bubble (d6)ddfetch restart (de)e0? simd retires (ee)f5f6f7f8fd
1004303722061254825100010001000398313130183037303724153289510001000200030373037111001100000073116112630100030383038303830383038
1004303723061254825100010001000398313130183037303724153289510001000200030373037111001100001073116112630100030383038303830383038
1004303723061254825100010001000398313130183037303724153289510001000200030373037111001100000073116112630100030383038303830383038
10043037231861254825100010001000398313130183037303724153289510001000200030373037111001100000073116112630100030383038303830383038
1004303723061254825100010001000398313130183037303724153289510001000200030373037111001100020073116112630100030383038303830383038
1004303723061254825100010001000398313130183037303724153289510001000200030373037111001100000073116112630100030383038303830383038
1004303723061254825100010001000398313130183037303724153289510001000200030373037111001100000073116112630100030383038303830383038
1004303723061254825100010001000398313130183037303724153289510001000200030373037111001100000073116112630100030383038303830383038
1004303723061254825100010001000398313130183037303724153289510001000200030373037111001100000073116112630100030383038303830383038
1004303723082254825100010001000398313130183037303724153289510001000200030373037111001100000073116112630100030383038303830383038

Test 2: Latency 1->1

Code:

  uadalp v0.4h, v1.8b
  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)03181e3f4e51schedule 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)9fa9accfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? simd retires (ee)? int retires (ef)f5f6f7f8fd
1020430037225002332954825101001001000010010000500427731303001830037300372826503287451010020010000200200003003730037111020110099100100100001000071021622296340100001003003830038300383003830038
102043003722500612954825101001001000010010000500427731303001830037300372826503287451010020010000200200003003730037111020110099100100100001000071021622296340100001003003830085300383008530038
1020430037225001702954825101001001000010010000500427731303001830037300372826503287451010020010000200200003003730037111020110099100100100001000071021622296340100001003003830038300383003830038
1020430037224001242954825101001001000010010000500427731313001830037300372826503287451010020010000200200003003730037111020110099100100100001000071021622296340100001003003830038300383003830038
1020430037225001242954825101001001000010010000500427731303001830037300372826503287451010020010000200200003003730037111020110099100100100001000071021622296340100001003003830038300383003830038
1020430037225001242954825101001001000010010000500427731303001830037300372826503287451010020010000200200003003730037111020110099100100100001000071021622296340100001003003830038300383003830038
1020430037225003602954825101001001000010010000500427731303001830037300372826503287451010020010000200200003003730037111020110099100100100001000071021622296340100001003003830038300383003830038
1020430037225005362954825101001001000010010000500427731303001830037300372826503287451010020010000200200003003730037111020110099100100100001000071021622296340100001003003830038300383003830038
1020430037225007892954825101001001000010010000500427731303001830037300372826503288001057320010000200200003003730037111020110099100100100001000071021622296340100001003003830038300383003830038
102043003722500612954825101001001000010010000500427731303001830037300372826503287451010020010000200200003003730037111020110099100100100001000071021622296340100001003003830038300383003830038

1000 unrolls and 10 iterations

Result (median cycles for code): 3.0037

retire uop (01)cycle (02)03181e3f4e51schedule 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)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)acc2cfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? simd retires (ee)? int retires (ef)f5f6f7f8fd
100243003722500279295482510010101000010100005042773133001830037300372828703287671001020100002020000300373003711100211091010100001011206403162229630010000103003830038300383003830038
1002430037225006129548251001010100001010000504277313300183003730037282870328767100102010000202000030037300371110021109101010000100006402162229630010000103003830038300383003830038
10024300372250025429548251001010100001010000504277313300183013230085282870328767101612010000202000030037300371110021109101010000100006402162229630010000103003830038300383003830038
1002430037224006129548251001010100001010000504277313300183003730037282870328767100102010000202000030037300371110023109101010000100006402162229630010000103003830038300383003830038
10024300372250010329548251001010100001010000504277313300183003730037282870328767100102010000202000030037300371110021109101010000100006402162229630210000103003830038300383003830038
1002430037225008229548251001010100001010000504277313300183003730037282870328767100102010000202000030037300371110021109101010000100006402162229630010000103003830038300383003830038
1002430037225006129548251001010100001010000504277313300183003730037282870328767100102010000202000030037300371110021109101010000100006402162229630010000103003830038300383003830038
10024300372240014729548251001010100001010000504277313300183003730037282870328767100102010000202000030037300371110021109101010000100006402162229630010000103003830038300383003830038
1002430037225006129548251001010100001010000504277313300183003730037282870328767100102010000202000030037300371110021109101010000100006402162229630010000103003830038300383003830038
1002430037225006129548251001010100001010000504277313300183003730037282870328767100102010000202000030037300371110021109101010000100306402162229630010000103003830038300383003830038

Test 3: Latency 1->2

Code:

  uadalp v0.4h, v0.8b
  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)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)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)acbranch cond mispred nonspec (c5)branch mispred nonspec (cb)cdcfd5map dispatch bubble (d6)ddfetch restart (de)e0? simd retires (ee)? int retires (ef)f5f6f7f8fd
1020430037225006312954725101001001000010010000500427716030018300373003728271728741101002001000820020000300373003711102011009910010010000100001117222242229629100001003003830038300383003830038
102043003722501972954725101001001000010010000500427716030018300373003728252628733101002001000020020000300373003711102011009910010010000100001117222242229629100001003003830038300383003830038
102043003722501972954725101001001000010010000500427716030018300373003728252628733101002001000020020000300373003711102011009910010010000100001117222242229629100001003003830038300383003830038
102043003722501972954725101001001000010010000500427716030018300373003728252628740101002001000820020016300373003751102011009910010010000100001117170160029645100001003003830038300383003830038
102043003722500612954725101001001000010010000500427716030018300373003728271728741101002001000820020016300373003711102011009910010010000100001117170160029646100001003003830038300383003830038
102043003722500612954725101001001000010010000500427716030018300373003728271728741101002001000820020016300373003711102011009910010010000100001117180160029645100001003003830038300383003830038
102043003722500612954725101001001000010010000500427716030018300373003728271728741101002001000820020016300373003711102011009910010010000100001117180160029646100001003003830038300383003830038
102043003722500612954725101001001000010010000500427716030018300373003728271628741101002001000820020016300373003711102011009910010010000100001117180160029645100001003003830038300383003830038
102043003722500612954725101001001000010010000500427716030018300373003728271628740101002001000820020016300373003751102011009910010010000100001117170160029645100001003003830038300383003830038
102043003722500612954725101001001000010010000500427716030018300373003728271628741101002001000820020016300373003711102011009910010010000100001117180160029646100001003003830038300383003830038

1000 unrolls and 10 iterations

Result (median cycles for code): 3.0037

retire uop (01)cycle (02)031e3f4e51schedule 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 cache writeback (a8)accfd5map dispatch bubble (d6)ddfetch restart (de)e0? simd retires (ee)? int retires (ef)f5f6f7f8fd
1002430037225015252954725100101010000101000050427716013001830037300372828632876710010201000020200003003730037111002110910101000010000640216222962910000103003830038300383003830038
10024300372250612954725100101010000101000050427716003001830037300372828632876710010201000020200003003730037111002110910101000010000640216222962910000103003830038300383003830038
10024300372250612954725100101010000101000050427716003001830037300372828632876710010201000020200003003730037111002110910101000010000640216222962910000103003830038300383003830038
10024300372250612954725100101010000101000050427716003001830037300372828632876710010201000020200003003730037111002110910101000010000640216222962910000103003830038300383003830038
10024300372250612954725100101010000101000050427716003001830037300372828632876710010201065820203243003730037111002110910101000010000640216222962910000103003830038300383003830038
10024300372250612954725100101010000101000050427716013001830037300372828632876710010201000020200003003730037111002110910101000010000640216222962910000103003830038300383003830038
10024300372250612954725100101010000101000050427716013001830037300372828632876710010201000020200003003730037111002110910101000010000640216222962910000103003830038300383003830038
10024300372250612954725100101010000101000050427716003001830037300372828632876710010201000020200003003730037111002110910101000010000640216222962910000103003830038300383003830038
10024300372250612954725100101010000101000050427716003001830037300372828632876710010201000020200003003730037111002110910101000010000640216222962910000103003830038300383003830038
10024300372250612954725100101010000101000050427716003001830037300372828632876710010201000020200003003730037111002110910101000010000640216212962910000103003830038300383003830038

Test 4: throughput

Count: 8

Code:

  movi v0.16b, 0
  uadalp v0.4h, v8.8b
  movi v1.16b, 0
  uadalp v1.4h, v8.8b
  movi v2.16b, 0
  uadalp v2.4h, v8.8b
  movi v3.16b, 0
  uadalp v3.4h, v8.8b
  movi v4.16b, 0
  uadalp v4.4h, v8.8b
  movi v5.16b, 0
  uadalp v5.4h, v8.8b
  movi v6.16b, 0
  uadalp v6.4h, v8.8b
  movi v7.16b, 0
  uadalp v7.4h, v8.8b
  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)03mmu table walk data (08)l2 tlb miss data (0b)181e1f3f51schedule 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 tlb access (a0)ld unit uop (a6)acc2branch cond mispred nonspec (c5)branch mispred nonspec (cb)cdcfd5map dispatch bubble (d6)ddfetch restart (de)e0? simd retires (ee)? int retires (ef)f5f6f7f8fd
16020420088150000002925801161008001610080028500640196020045200652006561280128200800282001600562006520305111602011009910010016000010000001111011951600200621600001002006620066200662006620066
16020420065151010005025801161008001610080028500640196020045200652006561280128200800282001600562006520065111602011009910010016000010000001111011901600200621600001002006620066200662006620066
160204200651500000091325801161008001610080028500640196020045200652006561280128200800282001600562006520065111602011009910010016000010000001111011901600200621600001002006620066200662006620066
16020420065150000002925801161008001610080028500640196120045200652006561280128200800282001600562006520065111602011009910010016000010000001111011901600200621600001002006620066200662006620066
16020420065150000002925801161008001610080028500640196020045200652006561280128200800282001600562006520065111602011009910010016000010000001111011901600200621600001002006620066200662006620066
16020420065150000002925801161008001610080028500640196020045200652006561280128200800282001600562006520065111602011009910010016000010000001111011901600200621600001002006620066200662006620066
16020420065150000902925801161008001610080028500640196020045200652006561280128200800282001600562006520065111602011009910010016000010000001111011901600200621600001002006620066200662006620066
16020420065150000002925801161008001610080028500640196020045200652006561280128200800282001600562006520065111602011009910010016000010000001111011901600200621600001002006620066200662006620066
16020420065151000009625801161008001610080028500640196020045200652006561280128200800282001600562006520065111602011009910010016000010000001111011901600200621600001002006620066200662006620066
16020420065150000002925801161008001610080028500640196020045200652006561280128200800282001600562006520065111602011009910010016000010000001111011901600200621600001002006620066200662006620066

1000 unrolls and 10 iterations

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

retire uop (01)cycle (02)03l2 tlb miss data (0b)1e1f3f51schedule 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)5f6061696d6erob full (74)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)accfd0d2l1i cache miss demand (d3)d5map dispatch bubble (d6)d9dadbddfetch restart (de)e0ea? simd retires (ee)? int retires (ef)f5f6f7f8fd
1600242006315000045258001010800001080000506400001152002720046200460322800102080000201600002004620046111600211091010160000100000100267721820211532004315160000102004720047200472004720047
160024200461500004596258001010800001080000506400001152002720046200460322800102080000201600002004620233111600211091010160000100000100328931620211782004315160000102004720047200472004720047
1600242004615010089258001010800001080000506400001152002720046200460322800102080000201600002005020050111600211091010160000100000100356842324422452004730160000102005120051200512005120051
16002420050151000512580010108000010800005064000001520031200502005003228001020800002016000020050200501116002110910101600001000001003165424244221052004730160000102005120051200512005120051
1600242005015000051258001010800001080000506400000152003120050200500322800102080000201600002005020046111600211091010160000100000100325631420411532004330160000102004720047200472004720047
16002420046150000216258001010800001080000506400001152002720046200460322800102080000201600002004620047111600211091010160000100000100285331620211632004315160000102004720047200472004720047
16002420046150000452580010108000010800005064000011520027200462004603228001020800002016000020046200461116002110910101600001000001002856311020211992004315160000102004720047200472004720047
160024200461500004525800101080000108000050640000115200272004620046032280010208000020160000200462004611160021109101016000010000010032563110202111052004315160000102004720047200472004720047
1600242004615000045258001010800001080000506400001152002720046200460322800102080000201600002004620046111600211091010160000100000100285331420211352004315160000102004720047200472004720047
1600242004615000045258001010800001080000506400001152002720046200460322800102080000201600002004620046111600211091010160000100000100265331420211932004315160000102004720047200472004720047

Test 5: throughput

Count: 16

Code:

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

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

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

retire uop (01)cycle (02)0309181e373f51schedule 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)a9acbranch cond mispred nonspec (c5)branch mispred nonspec (cb)cdcfd5map dispatch bubble (d6)ddfetch restart (de)e0? simd retires (ee)? int retires (ef)f5f6f7f8fd
160204400593000001302516010810016000810016002050012801320400294013140039199776199991601202001600322003200644004840039111602011009910010016000010000001111011801600400451600001004004040049400404004940040
1602044003929900017392516010810016000810016002050023991310400294004840039199776199991601202001600322003200644004840039111602011009910010016000010000001111011801600400361600001004004940040400404004940040
1602044004929900017302516010810016001710016002050012801320400294004840048199776199901601202001600322003200644004840039111602011009910010016000010000001111011801600400451600001004004940040400494004040049
160204400483000060302516011710016001710016002050023991310400304004840039199776199901601202001600322003200644004840039111602011009910010016000010000001111011801600400451600001004004940040400494004040040
1602044003930000007162516010810016001710016002050012801320400204003940048199776199901601202001600322003200644003940039111602011009910010016000010000001111011801600400361600001004004940040400494004040049
1602044003930000017392516018810016001710016002050012801320400294003940048199776199901601202001600322003200644004840039111602011009910010016000010000001111011801600400361600001004004040050400404004040049
1602044003930010017392516010810016000810016002050023991310400294004840039199776199991601202001600322003200644004840039111602011009910010016000010000001111011801600400361600001004004040049400404005040040
160204400393000000392516011710016001710016002050024389970400294004840039199776199901601202001600322003200644004840039111602011009910010016000010000001111011801600400371600001004004040049400404004040040
160204400393000000302516010810016000810016002050023991310400294004840039199776199901601202001600322003200644003940048111602011009910010016000010000001111011801600400451600001004004940049400404004940040
160204400492990001772927160133100160033100160028500238799504003040049400491997610199861601282001600382003200764004840048111602011009910010016000010000002221012812311400451600001004004940050400494004940049

1000 unrolls and 10 iterations

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

retire uop (01)cycle (02)031e1f373f51schedule 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)5f6061696d6emap 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)acbranch cond mispred nonspec (c5)cfd0d2l1i cache miss demand (d3)d5map dispatch bubble (d6)d9dadbddfetch restart (de)e0eaeb? simd retires (ee)? int retires (ef)f5f6f7f8fd
160024400513000018582516001110160001101600005012800000054003040040400391999673200191600102016000020320000400484003911160021109101016000010118010024162271622147400364018160000104004940040400494004040049
16002440040300000138251600101016000010160000501320000000400214004840039200110320019160010201600002032000040048400391116002110910101600001000010024132141641253400374014160000104004140040400414004040041
160024400393000005225160010101600001016000050239899901104002940048400511999603200311600102016000020320000400394004911160021109101016000010000100246214162125540045406160000104005240049400524004940040
160024400403000004725160010101600001016000050128000000040020400514004919996032002816001020160000203200004004940039111600211091010160000100001002264171621235400362012160000104004940041400414004940040
160024400513000006125160010101600001016000050239899910040029400484003919996032001916001020160000203200004004040039111600211091010160000100001002464171642153400374012160000104004940040400494004040049
160024400403000005225160010101600001016000050243892100040020400404003919996032001916001020160000203200004004840039111600211091010160000100001002261271642255400454012160000104004140040400414004040041
16002440039299001762251600101016000010160000501320000000400214004840039199960320019160010201600002032000040039400481116002110910101600001000010024163171641288400464012160000104005240041400404004940040
1600244005130000064251600101016000010160000502398999100400204004040048199960320028160010201600002032000040039400391116002110910101600001000010022163281622284400454018160000104004040049400404004940052
1600244003930000055251600111016000010160000501280000011040077400484003919996032003116001020160000203200004003940048111600211091010160000100001002416223164215540045406160000104004040041400404004940040
1600244005130000052251600101016000010160000501280000000400304004940039199960320019160010201600002032000040039400481116002110910101600001000010024162271642147400364012160000104004040050400494004140049