xref: /openbmc/qemu/tests/tcg/hexagon/test_vspliceb.S (revision 7d87775f)
1/*
2 * Purpose: test example, verify the soundness of the vspliceb operation
3 * the operation is a binary splice of two 64bit operators.
4 *
5 *  vspliceb(0xffffffffffffffff,0x0000000000000000,5) = 0x000000ffffffffff.
6 */
7    .text
8    .globl _start
9
10_start:
11    {
12        r0 = #-1
13        r1 = #-1
14    }
15    {
16        r2 = #0
17        r3 = #0
18    }
19    {
20        r5:4 = vspliceb(r1:0, r3:2, #5)
21    }
22    {
23        p0 = cmp.eq(r4, #-1); if (p0.new) jump:t test2
24        jump fail
25    }
26
27test2:
28    {
29        p0 = cmp.eq(r5, #255); if (p0.new) jump:t pass
30        jump fail
31    }
32