Apple M1 Microarchitecture Research by Dougall Johnson

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

FRECPE (vector, 2D)

Test 1: uops

Code:

  frecpe v0.2d, v0.2d
  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)03080b1e3f4e51inst 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)a8accfd5d6ddinst fetch restart (de)e0? fp/simd (ee)f5f6f7f8fd
10043037230006119002510001000100010445113018303730372738328951000100010003037303711100110000073116112919100030383038303830383038
10043037230006119002510001000100010445103018303730372738328951000100010003037303711100110000073116112919100030383038303830383038
10043037230006119002510001000100010445113018303730372738328951000100010003037303711100110000073116112919100030383038303830383038
10043037230006119002510001000100010445113018303730372738328951000100010003037303711100110000073116112919100030383038303830383038
10043037220006119002510001000100010445113018303730372738328951000100010003037303711100110001073116112919100030383038303830383038
10043037230006119002510001000100010445103018303730372738328951000100010003037303711100110000073116112919100030383038303830383038
10043037220006119002510001000100010445113018303730372738328951000100010003037303711100110000073116112919100030383038303830383038
10043037230006119002510001000100010445103018303730372738328951000100010003037303711100110000073116112919100030383038303830383038
10043037230006119002510001000100010445103018303730372738328951000100010003037303711100110000073116112919100030383038303830383038
1004303723000611900251000100010001044510301830373037273832895100010001000303730371110011000010873116112919100030383038303830383038

Test 2: Latency 1->2

Code:

  frecpe v0.2d, v0.2d
  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)0318191e3f4e51inst 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)696d6edispatch 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)9fa8accfd5d6ddinst fetch restart (de)e0? fp/simd (ee)gpr retires (ef)f5f6f7f8fd
10204300372250012611990025101001001000010010000500106745130018300373003728588328745101002001000020010000300373003711102011009910010010000100007101161129919100001003003830038300383003830038
10204300372250006119900251010010010000100100005001067451300183003730037286231628745101002001000020010000300373003711102011009910010010000100107101161129919100001003003830038300383003830038
1020430037225000611990025101001001000010010000500106745130018300373003728588328745101002001000020010000300373003711102011009910010010000100007101161129919100001003003830038300383003830038
1020430037225000611990025101001001000010010000500106745130018300373003728588328745101002001000020010000300373003711102011009910010010000100007101161129919100001003013230038300383003830038
1020430037225000611990043101321001000010010000500106745130018300373003728588328745101002001000020010000300373003711102011009910010010000100007101161129919100001003003830038300383003830038
1020430037225000611990025101001001000010010000500106745130018300373003728588328745101002001000020010000300373003711102011009910010010000100007101161129919100001003003830038300383003830038
1020430037225000611990025101001001000010010000500106745130018300373003728588328745101002001000020010000300373003711102011009910010010000100037101161129919100001003003830038300383003830038
1020430037225000611990025101001001000010010000500106745130018300373003728588328745101002001000020010000300373003711102011009910010010000100007101161129919100001003003830038300383003830038
1020430037225000611990025101001001000010010000500106745130018300373003728588328745101002001000020010000300373003711102011009910010010000100007101161129919100001003013230038300853003830038
1020430037225000611990025101001001000010210000500106745130018300373003728588328745101002001000020010000300373003711102011009910010010000100007101161129919100001003003830038300383003830038

1000 unrolls and 10 iterations

Result (median cycles for code): 3.0037

retire (01)cycle (02)03080b18191e1f3f4e51inst 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)9fa0a1a6a8acc2cfd5d6ddinst fetch restart (de)e0? int output thing (e9)? fp/simd (ee)gpr retires (ef)f5f6f7f8fd
10024300372250004006119900251001010100001010000501067451030018300373003728610328767100102010000201000030037300371110021109101010000100000006403162229919010000103003830038300383003830038
10024300372250000006119900251001010100001010000501067451030018300373003728610328767100102010000201000030037300371110021109101010000100000006402162229919010000103003830038300383003830038
10024300372250000006119900251001010100001010000501067451030018300373003728610328767100102010000201000030037300371110021109101010000100000006402162229919010000103003830038300383003830038
10024300372250000006119900251001010100001010000501067451030018300373003728610328767100102010000201000030037300371110021109101010000100000006402162229919010000103003830038300383003830038
10024300372240100006119900251001010100001010000501067451130018300373003728610328895100102010000201000030037300371110021109101010000100000006402162229919010000103003830231300383003830038
10024300372250100006119900251001010100001010000551067451130018300373003728610328767100102010000201000030037300371110021109101010000100000306402162229919010000103003830038300383003830038
100243003722500000061199001351006912100561210294661068368130270303673036728734328767100962010000201000030367303688110021109101010000100003006402162229919010000103003830038300383003830038
10024300372250000006119900251001010100001010000501067451030018300373003728610328767100102010000201000030037300371110021109101010000100000006402162229919010000103003830038300383003830038
10024300372250000006119900251001010100001010000501067451130018300373003728610328767100102010000201000030037300371110021109101010000100000006402162229919010000103003830038300383003830038
10024300372250000006119900251001010100001010000501067451130018300373003728610328767100102010000201000030037300371110021109101010000100000006402162229919010000103003830038300383003830038

Test 3: throughput

Count: 8

Code:

  frecpe v0.2d, v8.2d
  frecpe v1.2d, v8.2d
  frecpe v2.2d, v8.2d
  frecpe v3.2d, v8.2d
  frecpe v4.2d, v8.2d
  frecpe v5.2d, v8.2d
  frecpe v6.2d, v8.2d
  frecpe v7.2d, v8.2d
  movi v8.16b, 9

(fused SUBS/B.cc loop)

100 unrolls and 100 iterations

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

retire (01)cycle (02)03080b1e1f3f51inst 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)9fa0a8acc2c5branch mispredict (cb)cdcfd0d5d6ddinst fetch restart (de)e0? fp/simd (ee)gpr retires (ef)f5f6f7f8fd
80204800416000100392580100100800001008000050064000000800208003980039699716699938010020080008200800088003980039118020110099100100800001000000111511700160080036800001008004080040800408004080040
802048003959900088602580100100800001008000050064000010800208008880039699716699938010020080008200800088003980039118020110099100100800001000000111516800160080036800001008004080040800408004080040
80204800396000000392580100100800001008000050064000000800208003980039699716699938010020080008200800088003980039118020110099100100800001000000111511700160080036800001008004080040800408004080040
80204800396000000392580100100800001008000050064000000800208003980089699716699938010020080008200800088003980039118020110099100100800001000000111511700160080036800001008004080040800408004080040
80204800395990000392580100100800001008000050064000000800208003980039699716699938010020080008200800088003980039118020110099100100800001000000111511700160080036800001008004080040800408004080040
80204800396000000392580100100800001008000050064000000800208003980039699716699938010020080008200800088003980039118020110099100100800001000000111511700160080036800001008004080040800408004080040
80204800395990000392580100100800001008000050064021510800208003980039699716699938010020080008200800088003980039118020110099100100800001000000111511700160080112800001008004080040800408004080040
80204800395990000392580100100800001008000050064000000800208003980039699716699938010020080008200800088003980039118020110099100100800001000000111511700160080036800001008004080040800408004080040
80204801375990000392580100100800001008000050064000000800208003980039699716699938010020080008200800088003980039118020110099100100800001000000111511700160080036800001008004080040800408004080040
80204800395990012027362580100100800001008000050064000000800208003980039699716699938010020080008200800088003980039118020110099100100800001000000111511700160080036800001008004080040800408004080088

1000 unrolls and 10 iterations

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

retire (01)cycle (02)0318191e3f51inst 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)9fa1a8accfd5d6ddinst fetch restart (de)e0? fp/simd (ee)gpr retires (ef)f5f6f7f8fd
80024800406000005025800101080000108000050640000080020800398003969986370019800102080000208000080039800391180021109101080000100005020516428003480000108004080040800408004080040
80024800395990005025800101080000108000050640000080020800398003969986370019800102080000208000080039800391180021109101080000102005020216548003480000108004080040800408004080040
800248003960000050258001010800001080000506400000800208003980039699863700198001020800002080000800398003911800211091010800001000395020216448003480000108004080040800408004080040
80024800396000005025800101080000108000050640000080020800398003969986370019800102080000208000080039800391180021109101080000100005020216428003480000108004080040800408004080040
80024800395990005025800101080000108000050640000180020800398003969986370019800102080000208000080039800391180021109101080000100005020416248003480000108004080040800408004080040
80024800396000065025800101080000108000050640000180058800398003969986370019800102080000208000080039800391180021109101080000100005020316348003480000108004080040800408004080040
80024800395993005080800341080000108000050640000080120800398003969986370019800102080000208000080039800391180021109101080000100035020416248003480000108018980189800908004080040
80024800395992205025800581080000108000050640000080020800398003970018370019800102080000208000080039800391180021109101080000100005020416248003480000108004080040802608004080040
800248003959900015525800101080000108000050640000080020800398003969986370019800102080000208000080039800391180021109101080000100005020316448003480000108004080040800408004080040
80024800395990005025800101080000108000050640000080020800398003969986370019800102080000208000080039800391180021109101080000100005020416628003480000108004080040800408004080040