1#!/bin/sh 2# Copyright 2020 Google LLC 3# 4# This source code is licensed under the BSD-style license found in the 5# LICENSE file in the root directory of this source tree. 6 7#################################### Scalar ################################### 8### Generic C micro-kernels 9tools/xngen src/f32-vrnd/scalar-libm.c.in -D OP=RNDNE -D BATCH_TILE=1 -o src/f32-vrnd/gen/vrndne-scalar-libm-x1.c & 10tools/xngen src/f32-vrnd/scalar-libm.c.in -D OP=RNDNE -D BATCH_TILE=2 -o src/f32-vrnd/gen/vrndne-scalar-libm-x2.c & 11tools/xngen src/f32-vrnd/scalar-libm.c.in -D OP=RNDNE -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndne-scalar-libm-x4.c & 12tools/xngen src/f32-vrnd/scalar-libm.c.in -D OP=RNDZ -D BATCH_TILE=1 -o src/f32-vrnd/gen/vrndz-scalar-libm-x1.c & 13tools/xngen src/f32-vrnd/scalar-libm.c.in -D OP=RNDZ -D BATCH_TILE=2 -o src/f32-vrnd/gen/vrndz-scalar-libm-x2.c & 14tools/xngen src/f32-vrnd/scalar-libm.c.in -D OP=RNDZ -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndz-scalar-libm-x4.c & 15tools/xngen src/f32-vrnd/scalar-libm.c.in -D OP=RNDU -D BATCH_TILE=1 -o src/f32-vrnd/gen/vrndu-scalar-libm-x1.c & 16tools/xngen src/f32-vrnd/scalar-libm.c.in -D OP=RNDU -D BATCH_TILE=2 -o src/f32-vrnd/gen/vrndu-scalar-libm-x2.c & 17tools/xngen src/f32-vrnd/scalar-libm.c.in -D OP=RNDU -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndu-scalar-libm-x4.c & 18tools/xngen src/f32-vrnd/scalar-libm.c.in -D OP=RNDD -D BATCH_TILE=1 -o src/f32-vrnd/gen/vrndd-scalar-libm-x1.c & 19tools/xngen src/f32-vrnd/scalar-libm.c.in -D OP=RNDD -D BATCH_TILE=2 -o src/f32-vrnd/gen/vrndd-scalar-libm-x2.c & 20tools/xngen src/f32-vrnd/scalar-libm.c.in -D OP=RNDD -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndd-scalar-libm-x4.c & 21 22################################## WAsm SIMD ################################## 23tools/xngen src/f32-vrnd/wasmsimd.c.in -D BATCH_TILE=4 -D OP=RNDNE -o src/f32-vrnd/gen/vrndne-wasmsimd-x4.c & 24tools/xngen src/f32-vrnd/wasmsimd.c.in -D BATCH_TILE=8 -D OP=RNDNE -o src/f32-vrnd/gen/vrndne-wasmsimd-x8.c & 25tools/xngen src/f32-vrnd/wasmsimd.c.in -D BATCH_TILE=4 -D OP=RNDZ -o src/f32-vrnd/gen/vrndz-wasmsimd-x4.c & 26tools/xngen src/f32-vrnd/wasmsimd.c.in -D BATCH_TILE=8 -D OP=RNDZ -o src/f32-vrnd/gen/vrndz-wasmsimd-x8.c & 27tools/xngen src/f32-vrnd/wasmsimd.c.in -D BATCH_TILE=4 -D OP=RNDU -o src/f32-vrnd/gen/vrndu-wasmsimd-x4.c & 28tools/xngen src/f32-vrnd/wasmsimd.c.in -D BATCH_TILE=8 -D OP=RNDU -o src/f32-vrnd/gen/vrndu-wasmsimd-x8.c & 29tools/xngen src/f32-vrnd/wasmsimd.c.in -D BATCH_TILE=4 -D OP=RNDD -o src/f32-vrnd/gen/vrndd-wasmsimd-x4.c & 30tools/xngen src/f32-vrnd/wasmsimd.c.in -D BATCH_TILE=8 -D OP=RNDD -o src/f32-vrnd/gen/vrndd-wasmsimd-x8.c & 31 32################################### ARM NEON ################################## 33tools/xngen src/f32-vrnd/vrndne-neon.c.in -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndne-neon-x4.c & 34tools/xngen src/f32-vrnd/vrndne-neon.c.in -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndne-neon-x8.c & 35tools/xngen src/f32-vrnd/vrndz-neon.c.in -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndz-neon-x4.c & 36tools/xngen src/f32-vrnd/vrndz-neon.c.in -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndz-neon-x8.c & 37tools/xngen src/f32-vrnd/vrndu-neon.c.in -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndu-neon-x4.c & 38tools/xngen src/f32-vrnd/vrndu-neon.c.in -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndu-neon-x8.c & 39tools/xngen src/f32-vrnd/vrndd-neon.c.in -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndd-neon-x4.c & 40tools/xngen src/f32-vrnd/vrndd-neon.c.in -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndd-neon-x8.c & 41 42tools/xngen src/f32-vrnd/neonv8.c.in -D OP=RNDNE -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndne-neonv8-x4.c & 43tools/xngen src/f32-vrnd/neonv8.c.in -D OP=RNDNE -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndne-neonv8-x8.c & 44tools/xngen src/f32-vrnd/neonv8.c.in -D OP=RNDZ -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndz-neonv8-x4.c & 45tools/xngen src/f32-vrnd/neonv8.c.in -D OP=RNDZ -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndz-neonv8-x8.c & 46tools/xngen src/f32-vrnd/neonv8.c.in -D OP=RNDU -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndu-neonv8-x4.c & 47tools/xngen src/f32-vrnd/neonv8.c.in -D OP=RNDU -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndu-neonv8-x8.c & 48tools/xngen src/f32-vrnd/neonv8.c.in -D OP=RNDD -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndd-neonv8-x4.c & 49tools/xngen src/f32-vrnd/neonv8.c.in -D OP=RNDD -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndd-neonv8-x8.c & 50 51################################# x86 128-bit ################################# 52tools/xngen src/f32-vrnd/vrndne-sse2.c.in -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndne-sse2-x4.c & 53tools/xngen src/f32-vrnd/vrndne-sse2.c.in -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndne-sse2-x8.c & 54tools/xngen src/f32-vrnd/vrndz-sse2.c.in -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndz-sse2-x4.c & 55tools/xngen src/f32-vrnd/vrndz-sse2.c.in -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndz-sse2-x8.c & 56tools/xngen src/f32-vrnd/vrndu-sse2.c.in -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndu-sse2-x4.c & 57tools/xngen src/f32-vrnd/vrndu-sse2.c.in -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndu-sse2-x8.c & 58tools/xngen src/f32-vrnd/vrndd-sse2.c.in -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndd-sse2-x4.c & 59tools/xngen src/f32-vrnd/vrndd-sse2.c.in -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndd-sse2-x8.c & 60 61tools/xngen src/f32-vrnd/sse41.c.in -D OP=RNDNE -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndne-sse41-x4.c & 62tools/xngen src/f32-vrnd/sse41.c.in -D OP=RNDNE -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndne-sse41-x8.c & 63tools/xngen src/f32-vrnd/sse41.c.in -D OP=RNDZ -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndz-sse41-x4.c & 64tools/xngen src/f32-vrnd/sse41.c.in -D OP=RNDZ -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndz-sse41-x8.c & 65tools/xngen src/f32-vrnd/sse41.c.in -D OP=RNDU -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndu-sse41-x4.c & 66tools/xngen src/f32-vrnd/sse41.c.in -D OP=RNDU -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndu-sse41-x8.c & 67tools/xngen src/f32-vrnd/sse41.c.in -D OP=RNDD -D BATCH_TILE=4 -o src/f32-vrnd/gen/vrndd-sse41-x4.c & 68tools/xngen src/f32-vrnd/sse41.c.in -D OP=RNDD -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndd-sse41-x8.c & 69 70################################# x86 256-bit ################################# 71tools/xngen src/f32-vrnd/avx.c.in -D OP=RNDNE -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndne-avx-x8.c & 72tools/xngen src/f32-vrnd/avx.c.in -D OP=RNDNE -D BATCH_TILE=16 -o src/f32-vrnd/gen/vrndne-avx-x16.c & 73tools/xngen src/f32-vrnd/avx.c.in -D OP=RNDZ -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndz-avx-x8.c & 74tools/xngen src/f32-vrnd/avx.c.in -D OP=RNDZ -D BATCH_TILE=16 -o src/f32-vrnd/gen/vrndz-avx-x16.c & 75tools/xngen src/f32-vrnd/avx.c.in -D OP=RNDU -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndu-avx-x8.c & 76tools/xngen src/f32-vrnd/avx.c.in -D OP=RNDU -D BATCH_TILE=16 -o src/f32-vrnd/gen/vrndu-avx-x16.c & 77tools/xngen src/f32-vrnd/avx.c.in -D OP=RNDD -D BATCH_TILE=8 -o src/f32-vrnd/gen/vrndd-avx-x8.c & 78tools/xngen src/f32-vrnd/avx.c.in -D OP=RNDD -D BATCH_TILE=16 -o src/f32-vrnd/gen/vrndd-avx-x16.c & 79 80################################# x86 512-bit ################################# 81tools/xngen src/f32-vrnd/avx512f.c.in -D OP=RNDNE -D BATCH_TILE=16 -o src/f32-vrnd/gen/vrndne-avx512f-x16.c & 82tools/xngen src/f32-vrnd/avx512f.c.in -D OP=RNDNE -D BATCH_TILE=32 -o src/f32-vrnd/gen/vrndne-avx512f-x32.c & 83tools/xngen src/f32-vrnd/avx512f.c.in -D OP=RNDZ -D BATCH_TILE=16 -o src/f32-vrnd/gen/vrndz-avx512f-x16.c & 84tools/xngen src/f32-vrnd/avx512f.c.in -D OP=RNDZ -D BATCH_TILE=32 -o src/f32-vrnd/gen/vrndz-avx512f-x32.c & 85tools/xngen src/f32-vrnd/avx512f.c.in -D OP=RNDU -D BATCH_TILE=16 -o src/f32-vrnd/gen/vrndu-avx512f-x16.c & 86tools/xngen src/f32-vrnd/avx512f.c.in -D OP=RNDU -D BATCH_TILE=32 -o src/f32-vrnd/gen/vrndu-avx512f-x32.c & 87tools/xngen src/f32-vrnd/avx512f.c.in -D OP=RNDD -D BATCH_TILE=16 -o src/f32-vrnd/gen/vrndd-avx512f-x16.c & 88tools/xngen src/f32-vrnd/avx512f.c.in -D OP=RNDD -D BATCH_TILE=32 -o src/f32-vrnd/gen/vrndd-avx512f-x32.c & 89 90################################## Unit tests ################################# 91tools/generate-vunary-test.py --spec test/f32-vrndne.yaml --output test/f32-vrndne.cc & 92tools/generate-vunary-test.py --spec test/f32-vrndz.yaml --output test/f32-vrndz.cc & 93tools/generate-vunary-test.py --spec test/f32-vrndu.yaml --output test/f32-vrndu.cc & 94tools/generate-vunary-test.py --spec test/f32-vrndd.yaml --output test/f32-vrndd.cc & 95 96wait 97