We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d338534 commit d382106Copy full SHA for d382106
1 file changed
test/regtest/test_c.c
@@ -2,12 +2,17 @@
2
#include <stdio.h>
3
#include <stdlib.h>
4
#include <string.h>
5
+#include <sys/types.h>
6
7
#ifndef putchar
8
#undef putchar
9
#endif
10
-asm (
11
+#ifndef __GNUC__
12
+#define __asm__ asm
13
+#endif
14
+
15
+__asm__ (
16
".globl entry\n"
17
".set entry,0x0\n"
18
);
@@ -69,12 +74,12 @@ __attribute__((__noinline__)) void triforce(ssize_t n)
69
74
void data_func_2(void)
70
75
{
71
76
printf("invoked data_func()\n");
72
- asm volatile ("nop");
77
+ __asm__ volatile ("nop");
73
78
}
79
80
static void data_func(void)
81
- asm volatile (
82
+ __asm__ volatile (
83
"xchg %r15, %r15\n"
84
"callq data_func_2");
85
0 commit comments