File tree 1 file changed +7
-7
lines changed
1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change 27
27
28
28
#include "assert.h"
29
29
#include "stdint.h"
30
- #include "stdlib.h"
31
30
#include "stdbool.h"
31
+ #include "qemu/compiler.h"
32
32
33
33
// Returns the S3_6_c15_c1_5 register's value
34
34
// Taken from
@@ -53,7 +53,7 @@ static inline uint64_t read_sprr_perm(void)
53
53
54
54
#if defined(__APPLE__ ) && defined(HAVE_PTHREAD_JIT_PROTECT ) && (defined(__arm__ ) || defined(__aarch64__ ))
55
55
56
- __attribute__(( unused )) static inline uint8_t thread_mask ()
56
+ QEMU_UNUSED_FUNC static inline uint8_t thread_mask ()
57
57
{
58
58
uint64_t v = read_sprr_perm ();
59
59
@@ -64,12 +64,12 @@ __attribute__((unused)) static inline uint8_t thread_mask()
64
64
}
65
65
}
66
66
67
- __attribute__(( unused )) static inline bool thread_writeable ()
67
+ QEMU_UNUSED_FUNC static inline bool thread_writeable ()
68
68
{
69
69
return thread_mask () == 3 ;
70
70
}
71
71
72
- __attribute__(( unused )) static inline bool thread_executable ()
72
+ QEMU_UNUSED_FUNC static inline bool thread_executable ()
73
73
{
74
74
return thread_mask () == 1 ;
75
75
}
@@ -84,17 +84,17 @@ static inline void assert_executable(bool executable) {
84
84
85
85
#else
86
86
87
- __attribute__(( unused )) static inline uint8_t thread_mask ()
87
+ QEMU_UNUSED_FUNC static inline uint8_t thread_mask ()
88
88
{
89
89
return 0 ;
90
90
}
91
91
92
- __attribute__(( unused )) static inline bool thread_writeable ()
92
+ QEMU_UNUSED_FUNC static inline bool thread_writeable ()
93
93
{
94
94
return false;
95
95
}
96
96
97
- __attribute__(( unused )) static inline bool thread_executable ()
97
+ QEMU_UNUSED_FUNC static inline bool thread_executable ()
98
98
{
99
99
return false;
100
100
}
You can’t perform that action at this time.
0 commit comments