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

ST2 (multiple, 16B)

Test 1: uops

Code:

  st2 { v0.16b, v1.16b }, [x6]
  nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop ; nop
  mov x0, 0

(no loop instructions)

1000 unrolls and 1 iteration

Retires (minus 60 nops): 4.000

Issues: 4.000

Integer unit issues: 0.000

Load/store unit issues: 2.000

SIMD/FP unit issues: 2.000

retire uop (01)cycle (02)03l1i tlb fill (04)l1d tlb fill (05)mmu table walk instruction (07)mmu table walk data (08)09l2 tlb miss instruction (0a)l2 tlb miss data (0b)18191e1f22243a3f464951schedule uop (52)schedule simd uop (54)schedule ldst uop (55)dispatch simd uop (57)dispatch ldst uop (58)simd uops in schedulers (5a)ldst uops in schedulers (5b)5f696b6d6emap rewind (75)map stall (76)dispatch uop (78)map ldst uop (7d)map simd uop (7e)map ldst uop inputs (80)map simd uop inputs (81)8283flush restart other nonspec (84)85inst all (8c)inst simd store (99)inst ldst (9b)l1d tlb access (a0)l1d tlb miss (a1)l1d cache miss st (a2)ld unit uop (a6)st unit uop (a7)l1d cache writeback (a8)a9acafbcl1d cache miss st nonspec (c0)l1d tlb miss nonspec (c1)c2c9cfd0d2l1i cache miss demand (d3)l1i tlb miss demand (d4)d5map dispatch bubble (d6)d9dadbddfetch restart (de)e0eaebec? ldst retires (ed)? simd retires (ee)f5f6f7f8fd
640072941023611101200002104695291750018381400020002000200020002160816000321809029125293613104000200020004000400029395294831161001100010002002461200200220002422013153930270053189052204273134382014495328671159661327314841200020002944529541294252944029261
640042938523601311000003104767292220018208400020002000200020002162216000521819029068294263104000200020004000400029398294061161001100010002002241200201220002422013130924768883201253204393296381611555228753160481304914878200020002941629361294202935229319
640042947623601111110002004620292202018294400020002000200020002161616000221876029129293743104000200020004000400029277294181161001100010002003341200201220002420013125936269563119159204083344382217525228709164611330515043200020002952329401294882930829422
640042941923601010100033004667292462018218400020002000200020002161516000121845029101294593104000200020004000400029254292961161001100010002002201200210220002421013284937769013188159203743198382116535328773162711320014894200020002950429436293092947629353
640042941523601111210003004633292140018343400020002000200020002161816000421856028961292983104000200020004000400029344293081161001100010002003341200201220002620013036950769403180058205173364381711505028530161641312414974200020002940929316295322949629458
640042940623601111110003004657292022018300400020002000200020002161716000121887029058293663104000200020004000400029309294031161001100010002004261200201220002420013216924470053178047204893331382211505128714161531319214880200020002944129509293322929529345
640042933023501111100003004621291942018366400020002000200020002160816000321863029080294613104000200020004000400029350292921161001100010002003260200201220002621013187925769943147050205123143381915555528703161531335614797200020002937129439294212953129464
640042940323701111310003004592292320018304400020002000200020002162316000421769029083293873104000200020004000400029374293931161001100010002002201200201220002421013227931169723150157203973320381613534728729160011327215258200020002933029577294782940729341
64004294242370111121000200460129134201835440002000200020002000216171600042186402906429542310400020002000400040002942329283116100110001000200226020021152000242101317593266977322504820363317538188495328737161081334514955200020002930829480294382928129511
64004294662370121121000300458629331001834340002000200020002000216131600032180502905429449310400020002000400040002922829426116100110001000200324120020122000242201319092486947323905620359340038218575328759159611303815008200020002924229469294672954429403

Test 2: throughput

Count: 8

Code:

  st2 { v0.16b, v1.16b }, [x6]
  st2 { v0.16b, v1.16b }, [x6]
  st2 { v0.16b, v1.16b }, [x6]
  st2 { v0.16b, v1.16b }, [x6]
  st2 { v0.16b, v1.16b }, [x6]
  st2 { v0.16b, v1.16b }, [x6]
  st2 { v0.16b, v1.16b }, [x6]
  st2 { v0.16b, v1.16b }, [x6]
  mov x7, x6
  mov x8, x6
  mov x9, x6
  mov x10, x6
  mov x11, x6
  mov x12, x6
  mov x13, x6

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

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

retire uop (01)cycle (02)03mmu table walk instruction (07)mmu table walk data (08)09l2 tlb miss instruction (0a)l2 tlb miss data (0b)0e18191e1f24373f46494f51schedule 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)696d6emap stall dispatch (70)map rewind (75)map stall (76)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)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 store (99)inst ldst (9b)9fl1d tlb access (a0)l1d tlb miss (a1)l1d cache miss st (a2)a4ld unit uop (a6)st unit uop (a7)l1d cache writeback (a8)a9acafbcl1d cache miss st nonspec (c0)c2branch cond mispred nonspec (c5)branch mispred nonspec (cb)cdcfd5map dispatch bubble (d6)d9ddfetch restart (de)e0? ldst retires (ed)? simd retires (ee)? int retires (ef)f5f6f7f8fd
320207800586200000000003056548003016169025324159100166480160004100160016160016500229726213086058002480045800440617320132200160016160016200320272320032800448004411802011009910010080000800001001600000420016000210216000224201115116111601012800421600001600001008004680045800458004680046
3202048004462000000000030455680030161602532542810016434816000510016001616001650021407111304534800248004580044011153201322001600161600162003200323200328004580045118020110099100100800008000010016000004463016000300216000220011151161216098800411600001600001008004580046800458004680046
3202048004562100000000132304199800301616025324438100165589160000100160000160000500215883112990918002480044800450327320100200160000160000200320000320000800448004411802011009910010080000800001001600000420016000200516000224200005109131701110800501600001600001008004680045800468004580045
320204800446200000001004040848019616160253239911001644431600001001600001600005002078785130727280024800448004503263201002001600001600002003200003200008004480044118020110099100100800008000010016000004200160002102160002000000510912170109800501600001600001008004780045800458004681692
32020482350620000000000304008800291616025327365100166292160000100160000160000500213137712962668002380045800440327320100200160000160000200320000320000800458004411802011009910010080000800001001600000420016000200216000224200005109121701612800411600001600001008004680046800458021080046
320204800466200000000003060458002916160253269531001670231600001001600001600005002079089130638780024800468004403273201002001600001600002003200003200008004480045118020110099100100800008000010016000004262016000000516006524200005109121701310800411600001600001008004680045800458004680047
320204800446210000001056130501780028161602532327810016707316000010016000016000050020909641297363800238004580046092632010020016000016000020032000032000080044800451180201100991001008000080000100160000042001600021021600020000005109131701411800411600001600001008004680046802138004680047
320204800446210000000003041078003001602532657010016586216000010016000016000050020795721304080800238004580044032732010020016000016000020032000032000080044800441180201100991001008000080000100160000042001600020001600022000005109151701414800421600001600001008004580045800468004680045
3202048004764300000000030455680365161602532635110016547716000010016000016000050022367901299656800248004580045032632010020016000016000020032000032000080046800451180201100991001008000080000100160000042001600021021600022420000510912170913800421600001600001008004580045800468004680046
32020480045620000000001230564780030161602532414310016436316000010016000016000050020784371306387800228004580045032732010020016012016000020032000032000080045800451180201100991001008000080000100160000042001600020092716000224200005109141701613800421600001600001008004780046800468004580047

1000 unrolls and 10 iterations

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

retire uop (01)cycle (02)03l1d tlb fill (05)mmu table walk data (08)09l2 tlb miss instruction (0a)l2 tlb miss data (0b)18191e1f222324373a3f46494f51schedule 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)696b6d6emap stall dispatch (70)map rewind (75)map stall (76)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)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 store (99)inst ldst (9b)9fl1d tlb access (a0)l1d tlb miss (a1)l1d cache miss st (a2)a4ld unit uop (a6)st unit uop (a7)l1d cache writeback (a8)a9acafbcl1d cache miss st nonspec (c0)l1d tlb miss nonspec (c1)c2cfd5map dispatch bubble (d6)ddfetch restart (de)e0ea? ldst retires (ed)? simd retires (ee)? int retires (ef)f5f6f7f8fd
32002780051620110000012300070121800371616025324453101600041600001016000016000050255983513014678002608004480050032632001020160000160000203200003200008004580045118002110910108000080000101600151400016001601161600021644141501981799800470160000160000108006380053800528005380051
320024800506211100100121900024291800351616025322444101636361600001016000016000050239983113003988002808004580051032732001020160000160000203200003200008004580051118002110910108000080000101600001442001600160021600021601405019817109800490160000160000108005380045800458005180046
32002480052621100000001800042481800351616025325847101636371600001016000016000050207952912917698002508004480051032732001020160000160000203200003200008004580052118002110910108000080000101600141443410160016102016000016441415019817108800480160000160000108005380051800458004580054
3200248005062001000000180004198080047016025325163101663371600001016000016000050271978613065338002808004580051032732001020160000160000203200003200008004580051118002110910108000080000101600001442001600161051600021642005019101796800590160000160000108005180045800468005280051
320024800516201100000014000419418003701622532534010165614160000101600001600005027197861296436800270800438005003273200102016000016000020320000320000800458005011800211091010800008000010160014144401160016002160002244005019917810800410160000160000108005380046800468005380045
320024800526201000000123000570408003116002532588110166131160000101600001600005021590081304927800243800448005103263200102016000016000020320000320000800458005011800211091010800008000010160015154400160016021916000216441415019101788800480160000160000108005280052800538005280063
320024800516211100100019000647018004716160253249191016414216000010160000160000503679454129176980026080045800520325320010201600001600002032000032000080045800511180021109101080000800001016001414540016001600516000216441405019101798800480160000160000108005180051800528005380052
320024800536211000000018000378218003716160253244401016584316000010160000160000502399920129654980026080044800620327320010201600001600002032000032000080045800521180021109101080000800001016001414440016001620171600021644140501991788800490160000160000108005280046800468005280046
3200248005162111000000210000595018004716160253234081016428216000010160000160000503679454129722280026080045800520326320010201600001600002032000032000080045800511180021109101080000800001016000014420016001600216000214420050197171010800480160000160000108005380045800458005180045
32002480050621000000001700034630800291616025325131101643771600001016000016000050255984912963878002608004480050032632001020160000160000203200003200008005180050118002110910108000080000101600141444011600160016160002164414050191017610800602160000160000108005280053800518005380053