-
Notifications
You must be signed in to change notification settings - Fork 436
Expand file tree
/
Copy pathtest.sh
More file actions
executable file
·44 lines (37 loc) · 1.77 KB
/
Copy pathtest.sh
File metadata and controls
executable file
·44 lines (37 loc) · 1.77 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
#!/usr/bin/env bash
set -e
echo "=== Test 1: naive_f32() returns a non-zero instruction count ==="
result=$(icp canister call --query backend naive_f32 '()') && \
echo "$result" && \
echo "$result" | grep -qv '(0 : nat64)' && \
echo "PASS" || (echo "FAIL" && exit 1)
echo "=== Test 2: optimized_f32() returns a non-zero instruction count ==="
result=$(icp canister call --query backend optimized_f32 '()') && \
echo "$result" && \
echo "$result" | grep -qv '(0 : nat64)' && \
echo "PASS" || (echo "FAIL" && exit 1)
echo "=== Test 3: auto_vectorized_f32() returns a non-zero instruction count ==="
result=$(icp canister call --query backend auto_vectorized_f32 '()') && \
echo "$result" && \
echo "$result" | grep -qv '(0 : nat64)' && \
echo "PASS" || (echo "FAIL" && exit 1)
echo "=== Test 4: simd_f32() returns a non-zero instruction count ==="
result=$(icp canister call --query backend simd_f32 '()') && \
echo "$result" && \
echo "$result" | grep -qv '(0 : nat64)' && \
echo "PASS" || (echo "FAIL" && exit 1)
echo "=== Test 5: naive_u32() returns a non-zero instruction count ==="
result=$(icp canister call --query backend naive_u32 '()') && \
echo "$result" && \
echo "$result" | grep -qv '(0 : nat64)' && \
echo "PASS" || (echo "FAIL" && exit 1)
echo "=== Test 6: optimized_u32() returns a non-zero instruction count ==="
result=$(icp canister call --query backend optimized_u32 '()') && \
echo "$result" && \
echo "$result" | grep -qv '(0 : nat64)' && \
echo "PASS" || (echo "FAIL" && exit 1)
echo "=== Test 7: auto_vectorized_u32() returns a non-zero instruction count ==="
result=$(icp canister call --query backend auto_vectorized_u32 '()') && \
echo "$result" && \
echo "$result" | grep -qv '(0 : nat64)' && \
echo "PASS" || (echo "FAIL" && exit 1)