qemu-e2k/tests/tcg/hexagon/test_vcmpb.S
Niccolò Izzo 585a86b104 target/hexagon: import additional tests
Signed-off-by: Alessandro Di Federico <ale@rev.ng>
Signed-off-by: Niccolò Izzo <nizzo@rev.ng>
Signed-off-by: Anton Johansson <anjo@rev.ng>
Signed-off-by: Taylor Simpson <tsimpson@quicinc.com>
Reviewed-by: Taylor Simpson <tsimpson@quicinc.com>
Message-Id: <20220923173831.227551-12-anjo@rev.ng>
2022-12-16 12:30:28 -08:00

31 lines
555 B
ArmAsm

/*
* Purpose: test example, verify the soundness of the vector compare bytes
* operation.
*
* Vector byte comparison between 0x1234567887654321 and 0x1234567800000000
* should result in 0b11110000 in binary, or 0xf0 in hex.
*/
.text
.globl _start
_start:
{
r0 = #0x87654321
r1 = #0x12345678
}
{
r2 = #0x00000000
r3 = #0x12345678
}
{
p2 = vcmpb.eq(r1:0, r3:2)
}
{
r4 = p2
}
{
p0 = cmp.eq(r4, #0xf0); if (p0.new) jump:t pass
jump fail
}