Apple M1 Microarchitecture Research by Dougall Johnson

Firestorm: Overview | Base Instructions | SIMD and FP Instructions
Icestorm:  Overview | Base Instructions | SIMD and FP Instructions

ABS (vector, 16B)

Test 1: uops

Code:

  abs v0.16b, v0.16b
  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 (01)cycle (02)031e3f4e51inst issue (52)~issue fp/simd (54)~dispatch fp/simd (57)huge thing fp/simd (5b)60696d6edispatch stall (70)scheduler rewind (75)scheduler stall (76)~dispatch op (78)~map op fp/simd (7e)~map lookup fp/simd (81)8283pipeline redirect (84)85inst all (8c)inst neon or fp (9a)a8c2cfd5d6ddinst fetch restart (de)e0? fp/simd (ee)f5f6f7f8fd
100430372306125472510001000100039816013018303730372414328951000100010003037303711100110000073116112629100030383038303830383038
100430372208225472510001000100039816013018303730372414328951000100010003037303711100110000073116112629100030383038303830383038
100430372306125472510001000100039816013018303730372414328951000100010003037303711100110000073116112629100030383038303830383038
100430372206125472510001000100039816013018303730372414328951000100010003037303711100110000273116112629100030383038303830383038
100430372306125472510001000100039816013018303730372414328951000100010003037303711100110000073116112629100030383038303830383038
100430372306125472510001000100039816013018303730372414328951000100010003037303711100110000073116112629100030383038303830383038
100430372306125472510001000100039816013018303730372414328951000100010003037303711100110000073116112629100030383038303830383038
1004303723010325472510001000100039816013018303730372414328951000100010003037303711100110000073116112629100030383038303830383038
100430372306125472510001000100039816013018303730372414328951000100010003037303711100110000073116112629100030383038303830383038
1004303723010825472510001000100039816013018303730372414328951000100010003037303711100110000073116112629100030383038303830383038

Test 2: Latency 1->2

Code:

  abs v0.16b, v0.16b
  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 (01)cycle (02)030b1e1f3a3f4e51inst issue (52)~issue int (53)~issue fp/simd (54)~dispatch int (56)~dispatch fp/simd (57)huge thing int (59)huge thing fp/simd (5b)60696d6edispatch stall (70)scheduler rewind (75)scheduler stall (76)~dispatch op (78)~map op int (7c)~map op fp/simd (7e)~map lookup int (7f)~map lookup fp/simd (81)8283pipeline redirect (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst b.cc (94)inst integer (97)inst neon or fp (9a)9fa1a8acc9cfd5d6ddinst fetch restart (de)e0? fp/simd (ee)gpr retires (ef)f5f6f7f8fd
10204300372250000612954725101001001000010010000500427716003001830037300372826432874510100200100002001000030037300371110201100991001001000010000007101161129633100001003003830038300383003830038
10204300372250000612954725101001001000010010000500427716013001830037300372826432874510100200100002001000030037300371110201100991001001000010001607101161129633100001003003830228300383003830038
10204300372251000612954725101001001000010010000500427716003001830037300372826432874510100200100002001000030037300371110201100991001001000010001007101161129633100001003003830038300383003830038
102043003722503900612954725101001001000010010000500427716013001830037300372826432874510100200100002001000030037300371110201100991001001000010000008041161129633100001003003830038300383003830038
10204300372250000612954725101001001000010010000500427716003001830037300372826432874510100200100002001000030037300371110201100991001001000010001007101161129633100001003003830038300383003830038
102043003722400005202954725101001001000010010000616427716013005430037300372826432874510100200100002001000030037300371110201100991001001000010000007101161129633100001003003830228300383003830038
10204300372250000612954725101001001000010010000681427716003005430037300372826432874510100200100002001000030037300371110201100991001001000010000007101161129633100001003003830038300383003830038
10204300372250000612954725101001001000010010000500428256813001830037300372826432874510100200100002001000030037300371110201100991001001000010000007101251129633100001003003830038300383003830038
10204300372250000612954725101001001000010010000500427716003001830037300372826432874510100200100002001000030037300371110201100991001001000010000007101161129633100001003003830038301823003830038
10204300372250000612954725101001001000010010000500427716013001830037300372826432874510100200100002001000030037301781110201100991001001000010000007101161129633100001003003830038300383003830038

1000 unrolls and 10 iterations

Result (median cycles for code): 3.0037

retire (01)cycle (02)0308181e1f3f4e51inst issue (52)~issue int (53)~issue fp/simd (54)~dispatch int (56)~dispatch fp/simd (57)huge thing int (59)huge thing fp/simd (5b)6061696d6edispatch stall (70)scheduler rewind (75)scheduler stall (76)~dispatch op (78)~map op int (7c)~map op fp/simd (7e)~map lookup int (7f)~map lookup fp/simd (81)8283pipeline redirect (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst b.cc (94)inst integer (97)inst neon or fp (9a)9fa8a9accfd0d5d6ddinst fetch restart (de)e0? fp/simd (ee)gpr retires (ef)f5f6f7f8fd
1002430037225000061295472510010101000010100005042771601030018300373003728286328767100102010000201000030037300371110021109101010000100006400216222962910000103003830038300383003830038
1002430037225000061295472510010101000010100005042771601030018300703003728286328767100102010000201000030037300371110021109101010000100006400216222962910000103003830038300383003830038
1002430037225000061295472510010101000010100005042771601030018300373003728286328767100102010000201000030037300371110021109101010000100006400216222962910000103003830038300383003830038
1002430037225000061295472510010101000010100005042771601030018300373003728286328767100102010000201000030037300371110021109101010000100006400216222962910000103003830038300383003830038
1002430037225000061295472510010101000010100005042771601030018300373003728286328767100102010000201000030037300371110021109101010000100006400216222962910000103003830038300383003830038
1002430037225000061295472510010101000010100005042771601030018300373003728286328767100102010000201000030037300371110021109101010000100006400216222962910000103003830038300383003830038
1002430037224000061295472510010101000010100005042771601030018300373003728286328767100102010000201000030037300371110021109101010000100006400216222962910000103003830038300383003830038
1002430037225000061295472510010101000010100005042771601030018300373003728286328767100102010000201000030037300371110021109101010000100006400216222962910000103003830038300383003830038
1002430037225000061295472510010101000010100005042771601030018300373003728286328767100102010000201000030037300371110021109101010000100006400216222962910000103003830038300383003830038
1002430037224000061295472510010101000010100005042771601030018300853003728286328767100102010000201000030037300371110021109101010000100006400216222962910000103003830038300383003830038

Test 3: throughput

Count: 8

Code:

  abs v0.16b, v8.16b
  abs v1.16b, v8.16b
  abs v2.16b, v8.16b
  abs v3.16b, v8.16b
  abs v4.16b, v8.16b
  abs v5.16b, v8.16b
  abs v6.16b, v8.16b
  abs v7.16b, v8.16b
  movi v8.16b, 9

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

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

retire (01)cycle (02)031e3f51inst issue (52)~issue int (53)~issue fp/simd (54)~dispatch int (56)~dispatch fp/simd (57)huge thing int (59)huge thing fp/simd (5b)60696d6edispatch stall (70)scheduler rewind (75)scheduler stall (76)~dispatch op (78)~map op int (7c)~map op fp/simd (7e)~map lookup int (7f)~map lookup fp/simd (81)8283pipeline redirect (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst b.cc (94)inst integer (97)inst neon or fp (9a)9fa8acc5branch mispredict (cb)cdcfd5d6ddinst fetch restart (de)e0? fp/simd (ee)gpr retires (ef)f5f6f7f8fd
80204200581500302580108100800081008002050064013202002020039200399977699908012020080032200804582013920039118020110099100100800001000011151181160020036800001002004020040200402004020040
80204200391500302580108100800081008002050064013202002020039200399977699908012020080032200800322003920039118020110099100100800001000011151180160020036800001002004020040200402004020040
80204200391500302580108100800081008002050064013202002020039200399977699908012020080032200800322003920039118020110099100100800001000011151180160020036800001002004020040200402004020040
80204200391500532580108100800081008002050064013202002020039200399977699908012020080032200800322003920039118020110099100100800001000011151180160020036800001002004020040200402004020040
80204200391500302580108100800081198002050064013202002020039200399977699908012020080032200800322003920039118020110099100100800001000011151180160020036800001002004020040200402004020040
802042003915001142580108100800081008002050064013212002020039200399977699908012020080032200800322003920039118020110099100100800001000011151180160020036800001002004020040200402004020040
80204200391500512580108100800081008002050064013202002020039200399977699908012020080032200800322003920039118020110099100100800001000311151180160020036800001002004020040200402004020040
80204200391500302580108100800081008002050064013202002020039200399977699908012020080032200800322003920039118020110099100100800001000011151180160020036800001002004020040200402004020040
80204200391500952580108100800081008002050064013202002020039200399977699908012020080032200800322003920039118020110099100100800001000011151180160020036800001002004020040200402004020040
80204200391500752580108100800081008002050064013202002020039200399977699908012020080032200800322003920039118020110099100100800001000011151180160020036800001002004020040200402004020040

1000 unrolls and 10 iterations

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

retire (01)cycle (02)03081e3f51inst issue (52)~issue int (53)~issue fp/simd (54)~dispatch int (56)~dispatch fp/simd (57)huge thing int (59)huge thing fp/simd (5b)60696b6d6edispatch stall (70)scheduler rewind (75)scheduler stall (76)~dispatch op (78)~map op int (7c)~map op fp/simd (7e)~map lookup int (7f)~map lookup fp/simd (81)8283pipeline redirect (84)85inst all (8c)inst branch (8d)inst branch taken (90)inst b.cc (94)inst integer (97)inst neon or fp (9a)9fa1a8acbranch mispredict (cb)cfd5d6ddinst fetch restart (de)e0? fp/simd (ee)gpr retires (ef)f5f6f7f8fd
80024200391500040258001010800001080000506400001200200200392003999963100198001020800002080000200392003911800211091010800001000005020716352003680000102004020040200402004020040
80024200391500040258001010800001080000506400001200200200392003999963100198001020800002080000200392003911800211091010800001000005020416422003680000102004020040200402004020100
80024200391500040258001010800001080000506400001200200200392003999963100198001020800002080000200392003911800211091010800001000005020216242003680000102004020040200402004020040
80024200391500040258001010800001080000506400001200200200392003999963100198001020800002080000200392003911800211091010800001000005047216422003680000102004020040200402004020040
80024200391500040258001010800001080000506400001200200200392003999963100198001020800002080000200392003911800211091010800001000005020216342003680000102004020040200402004020040
80024200391500040258001010800001080000506400001200200200392003999963100198001020800002080000200392003911800211091010800001000005020216462003680000102004020040200402004020040
80024200391500040258001010800001080000506400001200200200392003999963100198001020800002080000200392003911800211091010800001000005020416442003680000102004020099200402004020040
80024200391500040258001010800001080000506400001200200200392003999963100198001020800002080000200392003911800211091010800001000005020416422003680000102004020040200402004020040
80024200391500082258001010800001080000506400001200200200392003999963100198001020800002080000200392003911800211091010800001000005020416242003680000102004020040200402004020040
80024200391500040258001010800001080000506400001200200200392003999963100198001020800002080000200392003911800211091010800001000005045416422003680000102004020040200402004020040