repo.or.cz
/
qemu
/
ar7.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
hw/sd: sdhci: Simplify updating s->prnsts in sdhci_sdma_transfer_multi_blocks()
[qemu/ar7.git]
/
tests
/
tcg
/
xtensa
/
test_clamps.S
blob
d9b2c38ac1d6d9ffaf5695ff28d7c687649080ee
1
#include "macros.inc"
2
3
test_suite clamps
4
5
#if XCHAL_HAVE_CLAMPS
6
7
test clamps
8
movi a2, 0
9
movi a3, 0
10
clamps a4, a2, 7
11
assert eq, a3, a4
12
13
movi a2, 0x7f
14
movi a3, 0x7f
15
clamps a4, a2, 7
16
assert eq, a3, a4
17
18
movi a2, 0xffffff80
19
movi a3, 0xffffff80
20
clamps a4, a2, 7
21
assert eq, a3, a4
22
23
movi a2, 0x80
24
movi a3, 0x7f
25
clamps a2, a2, 7
26
assert eq, a3, a2
27
28
movi a2, 0xffffff7f
29
movi a3, 0xffffff80
30
clamps a2, a2, 7
31
assert eq, a3, a2
32
33
movi a2, 0x7fffffff
34
movi a3, 0x7f
35
clamps a2, a2, 7
36
assert eq, a3, a2
37
38
movi a2, 0x80000000
39
movi a3, 0xffffff80
40
clamps a2, a2, 7
41
assert eq, a3, a2
42
test_end
43
44
#endif
45
46
test_suite_end