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

ST1 (multiple, post-index, 3 regs, 4S)

Test 1: uops

Code:

  st1 { v0.4s, v1.4s, v2.4s }, [x6], x8
  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
  mov x8, 0

(no loop instructions)

1000 unrolls and 1 iteration

Retires (minus 60 nops): 3.000

Issues: 4.000

Integer unit issues: 1.000

Load/store unit issues: 3.000

SIMD/FP unit issues: 0.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)18191e1f2223243a3f464951schedule uop (52)schedule int uop (53)schedule ldst uop (55)dispatch int uop (56)dispatch ldst uop (58)int uops in schedulers (59)simd uops in schedulers (5a)5f6061696b6d6emap rewind (75)map stall (76)dispatch uop (78)map ldst uop (7d)map ldst uop inputs (80)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)e0? int output thing (e9)eaebec? ldst retires (ed)? int retires (ef)f5f6f7f8fd
63005291002324140121000400046942885600230024000100030001000300050001590716001701802841429077310400030037000287222871411610011000100030096933003193300039380131929223701831400612016732273816235255283491000156671243713885300010002873128828289412880828727
6300428781231011000203041004519286030022789401710053012100330125020160561400170260282792877281040003006701428967289804161001100010003012690300010943300336330130039161681331470532039432723821275660284391002156901279414523300010002902029199291762929629089
63004289652330102202001840004651288170023105400010003000100030005000159084081702802864829145310400030007000290012922831610011000100030044613003016300036310133379371688131860622045631083821205455284131000154881263813809300010002888329064289932911328967
6300428899233012100100040004719288050022990400010003000100030005000159101209170450282742888031040003000700028890287781161001100010003004460300300330003633223130739162685831910582049430913812555356286761007156131261914091300010002939929495292442917129491
6300429320236210000077924444000470029036002297140201006301510083033504516711200176030287852942272340404430007000288612892311610011000100030033623003113300036320130669355701231901562008932183830215562282441000155331272213856300010002879628830288552870728765
63004288442334100120009340014870285610022600400010003000100030005000159087101705902828728776310400030007000285132859511610011000100030045613003003300006310132869435706932621622008031333822305658281271000154871270313386300010002873528654286892864628719
6300428822223010001100040014854285470022690400010003000100030005000158998081704302809228706310400030007000287342857611610011000100030055003003013300036310131859309697531960512007031653820245960282071000153421237313557300010002854728749286692872128709
63004288242241111111000300047222853100226554000100030001000300050001590912001705702811628734310400030007000287362859511610011000100030044613003013300030300129039397693131220612015131533821265459282001000153431260313741300010002868528713287872874728729
63004287052230111100001240014708287671022681400010003000100030005000159006101704102824528954310400430007000289362878711610011000100030033613003003300030310132179399689032010562019631423809315654282301000154541227414124300010002885028976288292892528760
6300428964224011111100040004680287823022788400010003000100030005000159070091702902827228870310400030007000288812868711610011000100030045023003013300036310131159299696731980642022032013813175859281721000154821243013784300010002881328958287982879828977

Test 2: throughput

Count: 8

Code:

  st1 { v0.4s, v1.4s, v2.4s }, [x6], x8
  st1 { v0.4s, v1.4s, v2.4s }, [x6], x8
  st1 { v0.4s, v1.4s, v2.4s }, [x6], x8
  st1 { v0.4s, v1.4s, v2.4s }, [x6], x8
  st1 { v0.4s, v1.4s, v2.4s }, [x6], x8
  st1 { v0.4s, v1.4s, v2.4s }, [x6], x8
  st1 { v0.4s, v1.4s, v2.4s }, [x6], x8
  st1 { v0.4s, v1.4s, v2.4s }, [x6], x8
  mov x7, x6
  mov x8, x6
  mov x9, x6
  mov x10, x6
  mov x11, x6
  mov x12, x6
  mov x13, x6
  mov x8, 0

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

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

retire uop (01)cycle (02)03l1d tlb fill (05)mmu table walk data (08)09l2 tlb miss data (0b)0f18191e1f2223243a3f46494f51schedule uop (52)schedule int uop (53)schedule ldst uop (55)dispatch int uop (56)dispatch ldst uop (58)int uops in schedulers (59)simd uops in schedulers (5a)606167696d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map ldst uop (7d)map int uop inputs (7f)map ldst uop inputs (80)8283flush restart other nonspec (84)85inst all (8c)inst branch (8d)inst branch taken (90)91inst 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)c2cdcfd2l1i cache miss demand (d3)d5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? ldst retires (ed)? int retires (ef)f5f6f7f8fd
240205120053930100000001400011200451614808132020080151240000801852402164710265525200000120269120326120328902511890245320408200240119200560560120461120319318020110099010010080000800001002400141736002400760080024000223400051470014215841201758003724000080100120317120444120325120463120176
240204120440931111102226426700011200321616525320100801002400008010024000047066255199080001200221200471200478997239000532010020024000020056000012005912005311802011009901001008000080000100240015154201240016001424000216351410511000316231200398000024000080100120059120041120051120043120043
240204120061964000010006000012002516160253201008010024000080100240000470715552004800012001712005912005089955390000320100200240000200560000120058120052118020110099010010080000800001002400151400124001400162400022341400511000316231200398000024000080100120052120041120043120052120050
2402041200429640000000303000112002716160253201008010024000080100240000470710551942400012001712004212004289955390018320100200240000200560000120050120059118020110099010010080000800001002400141536012400161019240002034000511000416331200398000024000080100120051120043120043120052120051
2402041200429640000000030001120043016025320100801002400008010024000047066455201500001200331200591200638996339000532010020024000020056000012006212006811802011009901001008000080000100240015153600240016001924000216361410511000316421200398000024000080100120043120043120043120043120050
240204120050964000000000000012002716160253201008010024000080100240000470715551985600012001712004212005089955390000320100200240000200560000120058120050118020110099010010080000800001002400141400024001610142400021601410511000316331200488000024000080100120060120052120059120059120060
240204120047964100100012150000120025161632532010080100240000801002400004707125519424100120017120059120048899533900003201002002400002005600001200541200521180201100990100100800008000010024001414360024001600202400002341400511000316231200478000024000080100120043120043120050120043120060
2402041200429640000000123001112002715160253201008010024000080100240000470715551942400012001712004212004289962390010320100200240000200560000120052120047118020110099010010080000800001002400141536012400160021240000234000511000216231200398000024000080100120043120041120041120043120043
240204120042964000000001800001200271616025320100801002400008010024000047071355194240001200261200401200428995339000032010020024000020056000012006012005211802011009901001008000080000100240014143600240016111724000216361400511000316321200508000024000080100120060120060120052120048120060
2402041200609651000000021000012002716002532010080100240000801002400004706645519424000120017120042120042899731690217320392200240239200560842120456120314418020110099010010080000800001002401971434590240196001577240180252000515100635881204058008024000080100120333120321120456120322120327

1000 unrolls and 10 iterations

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

retire uop (01)cycle (02)03l1d tlb fill (05)mmu table walk data (08)l2 tlb miss data (0b)18191e1f233a3f46494f51schedule uop (52)schedule int uop (53)schedule ldst uop (55)dispatch int uop (56)dispatch ldst uop (58)int uops in schedulers (59)simd uops in schedulers (5a)60696d6emap stall dispatch (70)map rewind (75)map stall (76)dispatch uop (78)map int uop (7c)map ldst uop (7d)map int uop inputs (7f)map ldst uop inputs (80)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)c2branch cond mispred nonspec (c5)branch mispred nonspec (cb)cdcfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? ldst retires (ed)? int retires (ef)f5f6f7f8fd
2400251200429310000012300120036161602532001080010240000800102400004701985519424012002812004012004289977390020320010202400002056000012004212005111800211091010800008000010240000034002400020079424000223400000502010161081200398000024000080010120276120041120309120177120181
240024120174931001322641790012016616022175320205800852401208012324032447056455343400120308120319120436902571792113323348202427582056028012057312030941800211091010800008000010240060034282240182021560240122234000005044816691200478000024000080010120043120043120043120043120043
24002412004293000000030012003516160253200108001024000080010240000470203551942401200171200421200408997739002032001020240000205600001200421200491180021109101080000800001024000003400240002002240000234000005020816981200398000024000080010120043120043120043120043120041
2400251200409300000096300120025016025320010800102400008001024000047019855194240120017120042120040899853901323200102024000020560000120040120042118002110910108000080000102400000000240002102240002234000005020616871200478000024000080010120043120052120043120043120043
24002412004293100000630012002716160253200108001024000080010240000470198551976001200171200501200428997739002932001020240000205600001200401200421180021109101080000800001024000003400240002008240002034000005020916691200378000024000080010120043120043120043120043120043
240024120049930000000900120025161632532001080010240000800102400004701955519424012001712004212005189989390020320010202400002056000012004012005111800211091010800008000010240000000024000200112400022340000050208169101200398000024000080010120043120050120043120043120043
240024120042931000002190012002716160253200108001024000080010240000470198551942401200151200401200498997539002032001020240000205600001200401200421180021109101080000800001024000003400240002102240002234000105020416581200398000024000080010120043120041120041120118120052
240024120049930000000600120100161602532001080010240000800102400004701985519424112001712004012004989977390022320010202400002056000012004012004211800211091010800008000010240000034002400001011240002234001005020916881200398000024000080010120041120043120043120051120041
240024120042931000001260012003516160253200108001024000080010240000470193551942401200171200401200518997739002232001020240000205600001200401200501180021109101080000800001024000000002400022022400000340000050206161081200488000024000080010120043120052120041120041120043
24002412004293000000030012002516160253200108001024000080010240000470193551942401200151200421200428997739002232001020240000205600001200421200501180021109101080000800001024000000002400020082400022340000050209169101200398000024000080010120043120050120043120043120043