PPC: Fix missing TRACE exception
[qemu/agraf.git] / tests / tcg / openrisc / test_addic.c
blob4ba7432521c721fe9dafa07f8d33beda77395e45
1 #include <stdio.h>
3 int main(void)
5 int a, b, c;
6 int result;
8 a = 1;
9 result = 0x1;
10 __asm
11 ("l.addic %0, %0, 0xffff\n\t"
12 : "+r"(a)
14 if (a != result) {
15 printf("first addic error\n");
16 return -1;
19 a = 0x1;
20 result = 0x201;
21 __asm
22 ("l.addic %0, %0, 0xffff\n\t"
23 "l.ori %0, r0, 0x100\n\t"
24 "l.addic %0, %0, 0x100\n\t"
25 : "+r"(a)
27 if (a != result) {
28 printf("second addic error\n");
29 return -1;
32 return 0;