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

ORR (register, lsr, 64-bit)

Test 1: uops

Code:

  orr x0, x0, x1, lsr #17
  mov x0, 1
  mov x1, 2

(no loop instructions)

1000 unrolls and 1 iteration

Retires: 1.000

Issues: 2.000

Integer unit issues: 2.000

Load/store unit issues: 0.000

SIMD/FP unit issues: 0.000

retire uop (01)cycle (02)03181e3f4c4d51schedule uop (52)schedule int uop (53)dispatch int uop (56)int uops in schedulers (59)606d6emap 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
10042035150061100017352520002000100032570120352035157531842100010002000203542111001100000732671117812000100020362036203620362036
10042035150061100017352520002000100032570020352035157531842100010002000203542111001100000731671117812000100020362036203620362036
10042035150061100017352520002000100032570120352035157531842100010002000203542111001100000731671117812000100020362036203620362036
10042035150061100017352520002000100032570020352035157531842100010002000203542111001100000731671117812000100020362036203620362036
10042035150061100017352520002000100032570120352035157531842100010002000203542111001100000731671117812000100020362036203620362036
10042035150061100017352520002000100032570120352035157531842100010002000203542111001100000731671117812000100020362036203620362036
10042035160061100017352520002000100032570120352035157531842100010002000203542111001100000731671117812000100020362036203620362036
10042035150061100017352520002000100032570020352035157531842100010002000203542111001100000731671117812000100020362036203620362036
10042035150061100017352520002000100032570120352035157531842100010002000203542111001100000731671117812000100020362036203620362036
10042035150061100017352520002000100032570120352035157531842100010002000203542111001100000731671117812000100020362036203620362036

Test 2: Latency 1->2

Code:

  orr x0, x0, x1, lsr #17
  mov x0, 1
  mov x1, 2

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

Result (median cycles for code): 2.0035

retire uop (01)cycle (02)03mmu table walk data (08)18191e3f4c4d51schedule 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)9fld unit uop (a6)l1d cache writeback (a8)a9accdcfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? int retires (ef)f5f6f7f8fd
102042003515000006110000198032520100201001010018534214916955020035200351842931870010100102002020020035421110201100991001010010000000710159111979120000101002003620036200362003620036
102042003515000006110000198032520100201001010018534214916955020035200351842931870010100102002020020035421110201100991001010010000000710159111979120000101002003620036200362003620036
102042003515000008410000198032520100201001010018534214916955020035200351842931870010100102002020020035421110201100991001010010000000710159111979120000101002003620036200362003620036
102042003515000006110000198032520100201001010018534214916955020035200351842931870010100102002020020035421110201100991001010010000000710159111979120000101002003620036200362003620036
102042003515000006110000198032520100201001010018534214916955020068200351842931870010100102002020020035421110201100991001010010000000710159111979120000101002003620036200362003620036
102042003514900006110000198032520100201001010018534214916955020035200351842931870010100102002020020035421110201100991001010010000000710159111979120000101002003620036200362003620036
10204200351500000102210000198032520100201001010018534214916955020035200351842931870010100102002020020035421110201100991001010010000000710159111979120000101002003620036200362003620036
102042003515000006110000198032520100201001010018534214916955020035200351842931870010100102002020020035421110201100991001010010000000710159111979120000101002003620036200362003620036
1020420035150000012410000198032520100201001010018534214916955020035200351842931870010100102002020020035421110201100991001010010010000710159111979120000101002003620036200362003620036
102042003515010008210000198032520100201001010018534214916955020035200351842931870010100102002020020035421110201100991001010010000000710159111979120000101002003620036200362003620036

1000 unrolls and 10 iterations

Result (median cycles for code): 2.0035

retire uop (01)cycle (02)03mmu table walk instruction (07)09l2 tlb miss instruction (0a)18191e3a3f4c4d51schedule 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 cache writeback (a8)a9accfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? int retires (ef)f5f6f7f8fd
1002420035150201000371100001974325200102001010010185310149169550200352003518451318718100101002020020200354211100211091010010100000646116310111979220000100102003620036200362003620036
10024200351501010003201100001974325200102001010010185310149169550200352003518451318718100101002020020200354211100211091010010100000646106310111979220000100102003620036200362003620036
100242003515010100037110000197432520010200101001018531004916955020035200351845131871810010100202002020035421110021109101001010000064686310101979220000100102003620036200362003620036
1002420035150101000371100001974325200102001010010185310049169550200352003518451318718100101002020020200354211100211091010010100000646106311101979220000100102003620036200362003620036
1002420035150101000371100001974325200102001010010185310049169550200352003518451318718100101002020020200354211100211091010010100000646106311101979220000100102008220081200362003620036
100242003515010100037110000197432520010200101001018531004916955020035200351845131871810010100202002020035421110021109101001010000111646106310101979220000100102003620036200362003620036
100242003514910100037110000197932520010200561001018531014916955020035200351845581873510302101832035820035422110021109101001010000064610751051979220024100102003620081200362003620081
10024200351501010003711000019743252001020010100101853100491695502003520035184513187181001010020200202003542111002110910100101000013864666311101979220000100102003620036200362003620036
10024200351501010012371100001974325200102001010010185310149169550200352003518451318718100101002020020200354211100211091010010100000646106310101979220000100102003620036200362003620036
10024200351501010003113100001974325200102001010010185310149169550200352003518451318718100101002020020200354211100211091010010100025764656310101979220000100102003620036200362003620036

Test 3: Latency 1->3

Code:

  orr x0, x1, x0, lsr #17
  mov x0, 1
  mov x1, 2

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

Result (median cycles for code): 2.0035

retire uop (01)cycle (02)03mmu table walk instruction (07)l2 tlb miss instruction (0a)3f4c4d51schedule uop (52)schedule int uop (53)dispatch int uop (56)int uops in schedulers (59)6061696a6d6emap 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)branch mispred nonspec (cb)cdcfd0d5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? int retires (ef)f5f6f7f8fd
102042003515011449100001980325201002010010111184985034916955200352003518477718735101111023220264200354211102011009910010100100001117200116111984820000101002003620036200362003620036
102042003515011199100001980325201002010010111184985004916955200352003518477718735101111023220264200354211102011009910010100100001117200116111984820000101002003620036200362003620036
10204200351501161100001980325201002010010111184985004916955200352003518477718736101111023220264200354211102011009910010100100001117200116111984820000101002003620036200362003620036
10204200351501161100001980325201002010010111184985004916955200352003518477718735101111023220264200354211102011009910010100100001117200116111984820000101002003620036200362003620036
10204200351501161100001980325201002010010111184985004916955200352003518477618735101111023220264200354211102011009910010100100001117200116111984720000101002003620036200362003620036
10204200351501161100001980325201002010010111184985004916955200352003518477718736101111023220264200354211102011009910010100100001117190116111984820000101002003620036200362003620036
10204200351501161100001980325201002010010111184985004916955200352003518477718735101111023220264200354211102011009910010100100001117200116111984820000101002003620036200362003620036
102042003515011337100001980325201002010010111184985104916955200352003518477718735101111023220264200354211102011009910010100100001117203116111984820000101002003620036200362003620036
10204200351501161100001980325201002010010111184985004916955200352003518477718735101111023220264200354211102011009910010100100001117200116111984820000101002003620036200362003620036
10204200351501161100001980325201002010010111184985034916955200352003518477718735101111023220264200354211102011009910010100100001117200116111984820000101002003620036200362003620036

1000 unrolls and 10 iterations

Result (median cycles for code): 2.0035

retire uop (01)cycle (02)031e3f4c4d51schedule 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
1002420035150061100001974325200102001010010185310149169552003520035184513187181001010020200202003542111002110910100101000640363221979220000100102003620036200362003620036
10024200351490611000019743252001020010100101853100491695520035200351845131871810010100202002020035421110021109101001010021640263221979220000100102003620036200362003620036
100242003515006110000197432520010200101001018531004916955200352003518451318718100101002020020200354211100211091010010100108640263221979220000100102003620036200362003620036
10024200351503661100001974325200102001010010185310149169552003520035184513187181001010020200202003542111002110910100101000640263221979220000100102003620036200362003620036
1002420035150061100001974325200102001010010185310149169552003520035184513187181001010020200202003542111002110910100101000640263221979220000100102003620036200362003620036
10024200351503961100001974325200102001010010185310049169552003520035184523187181001010020200202003542111002110910100101000640263221979220000100102003620081200362003620036
1002420035150061100001974325200102001010010185310049169552003520035184513187181001010020200202003542111002110910100101000640263221979220000100102003620036200362003620036
1002420035150061100001974325200102001010010185310149169552003520035184513187181001010020200202003542111002110910100101000640263221979220000100102003620036200362003620036
1002420035150061100001974325200102001010010185310049169552003520035184513187181001010020200202003542111002110910100101000640263221979220000100102003620036200362003620036
10024200351500611000019743252001020010100101853101491695520035200351845131871810010100202002020035421110021109101001010012640263221979220000100102003620036200362003620036

Test 4: throughput

Count: 8

Code:

  orr x0, x8, x9, lsr #17
  orr x1, x8, x9, lsr #17
  orr x2, x8, x9, lsr #17
  orr x3, x8, x9, lsr #17
  orr x4, x8, x9, lsr #17
  orr x5, x8, x9, lsr #17
  orr x6, x8, x9, lsr #17
  orr x7, x8, x9, lsr #17
  mov x8, 9
  mov x9, 10

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

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

retire uop (01)cycle (02)031e3f4c4d51schedule 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 cond mispred nonspec (c5)branch mispred nonspec (cb)cdcfd5map dispatch bubble (d6)ddfetch restart (de)e0? int output thing (e9)? int retires (ef)f5f6f7f8fd
80204267682000133800312614628160182160182802621619060492365226732267321665181666180262803761605522673239118020110099100801001000011151281160026729160082801002673326733267332673326733
8020426731200049800312614627160182160182802621619060492365226732267321665181666180262803761605522673239118020110099100801001000011151290160026729160082801002673326733267332673326733
8020426732200028800312614628160182160182802621619060492365226732267321665181666180262803761605522673239118020110099100801001000011151290160026729160082801002673326733267332673326732
8020426732200028800312614628160182160182802621619061492063426732267321665181666180262803761605522673239118020110099100801001000011151290161126717160000801002672626726267262672626726
8020426725200061800002609425160100160100801001643180492364526725267251661531667780100802001602002672539118020110099100801001000000051101221126717160000801002672626726267262672626726
80204267252010536800002609425160100160100801001643180492364526725267251661531667780100802001602002672539118020110099100801001000000051101221126717160000801002672626726267262672626726
8020426725200061800002609425160100160100801001643181492364526725267251661531667780100802001602002672539118020110099100801001000000051101221126717160000801002672626726267262672626726
8020426725200061800002609425160100160100801001643181492364526725267251661531667780100802001602002672539118020110099100801001000000051101221126717160000801002672626726267262672626726
8020426725201061800002609425160100160100801001643181492364526725267251661531667780100802001602002672539118020110099100801001000000051101221126717160000801002672626726267262672626726
8020426725200061800002609425160100160100801001643181492364526725267251661531667780100802001602002672539118020110099100801001000000051101221126717160000801002672626726267262672626726

1000 unrolls and 10 iterations

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

retire uop (01)cycle (02)031e3f4c4d51schedule uop (52)schedule int uop (53)dispatch int uop (56)int uops in schedulers (59)5f60696a6b6d6emap 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)cfd2d5map dispatch bubble (d6)dbddfetch restart (de)e0? int output thing (e9)ec? int retires (ef)f5f6f7f8fd
800242673420006180000212802516001016001080010163142014923631026711267111662331668580010800201600202671139118002110910800101003050200222011267041600000800102671226712267122671226712
8002426711200061800002128025160010160010800101631420049236310267112671116623316685800108002016002026711391180021109108001010000502001220112670416000016800102671226712267122671226712
800242671120006180000212802516001016001080010163142004923631026711267111662331668580010800201600202671139118002110910800101003050200122011267041600000800102671226712267122671226712
800242671120006180000212802516001016001080010163142004923631026711267111662331668580010800201600202671139118002110910800101003050200122011267041600000800102671226712267122671226712
8002426711200016680000212802516001016001080010163142004923631026711267111662331668580010800201600202671139118002110910800101003050200122022267041600000800102671226712267122671226712
8002426711200061800002128025160010160010800101631420049236310267112671116623316685800108002016002026711391180021109108001010012050200122011267041600000800102671226712267122671226712
800242671120006180000212802516001016001080010175939004923631026711267111662331668580010800201600202671139118002110910800101000050200122022267041600000800102671226712267122671226712
8002426711200010380000212802516001016001080010163142004923631026711267111662331668580010800201600202671139118002110910800101000050200122011267041600000800102671226712267122671226712
8002426711200126180000212802516001016001080010163142014923631026711267111662331668580010800201600202671139118002110910800101003050200222022267041600000800102671226712267122671226712
800242671120006180000221002516001016001080010163142004923631026711267111662331668580010800201600202671139118002110910800101000150200122011267041600000800102671226712267122671226712