riscv: fix more sign/zero-extension problems
[tinycc.git] / tests / asm-c-connect-2.c
blob3440b40bca6ebb975cd7963919e671b3e78d55c5
1 #include <stdio.h>
3 #if defined _WIN32 && !defined __TINYC__
4 # define _ "_"
5 #else
6 # define _
7 #endif
9 int x3(void)
11 printf(" x3");
12 return 3;
15 /* That callx4 is defined globally (as if ".globl callx4")
16 is a TCC extension. GCC doesn't behave like this. */
17 void callx4(void);
18 __asm__(_"callx4: call "_"x4; ret;"
19 #ifndef __TINYC__
20 " .global "_"callx4"
21 #endif
24 extern void x5(void);
26 void callx5_again(void);
27 void callx5_again(void)
29 x5();
30 asm("call "_"x6");
33 static void x6()
35 printf(" x6-2");