@@ -15,6 +15,7 @@ use crate::ops::{Deref, DerefMut};
15
15
not( target_arch = "aarch64" ) ,
16
16
not( target_arch = "powerpc" ) ,
17
17
not( target_arch = "s390x" ) ,
18
+ not( target_arch = "xtensa" ) ,
18
19
not( target_arch = "x86_64" )
19
20
) ,
20
21
all( target_arch = "aarch64" , target_vendor = "apple" ) ,
@@ -37,6 +38,7 @@ pub struct VaListImpl<'f> {
37
38
not( target_arch = "aarch64" ) ,
38
39
not( target_arch = "powerpc" ) ,
39
40
not( target_arch = "s390x" ) ,
41
+ not( target_arch = "xtensa" ) ,
40
42
not( target_arch = "x86_64" )
41
43
) ,
42
44
all( target_arch = "aarch64" , target_vendor = "apple" ) ,
@@ -113,6 +115,24 @@ pub struct VaListImpl<'f> {
113
115
_marker : PhantomData < & ' f mut & ' f c_void > ,
114
116
}
115
117
118
+ /// Xtensa ABI implementation of a `va_list`.
119
+ #[ cfg( target_arch = "xtensa" ) ]
120
+ #[ repr( C ) ]
121
+ #[ derive( Debug ) ]
122
+ #[ unstable(
123
+ feature = "c_variadic" ,
124
+ reason = "the `c_variadic` feature has not been properly tested on \
125
+ all supported platforms",
126
+ issue = "44930"
127
+ ) ]
128
+ #[ lang = "va_list" ]
129
+ pub struct VaListImpl < ' f > {
130
+ stk : * mut i32 ,
131
+ reg : * mut i32 ,
132
+ ndx : i32 ,
133
+ _marker : PhantomData < & ' f mut & ' f i32 > ,
134
+ }
135
+
116
136
/// A wrapper for a `va_list`
117
137
#[ repr( transparent) ]
118
138
#[ derive( Debug ) ]
@@ -124,6 +144,7 @@ pub struct VaList<'a, 'f: 'a> {
124
144
not( target_arch = "s390x" ) ,
125
145
not( target_arch = "x86_64" )
126
146
) ,
147
+ target_arch = "xtensa" ,
127
148
all( target_arch = "aarch64" , target_vendor = "apple" ) ,
128
149
target_family = "wasm" ,
129
150
target_os = "uefi" ,
@@ -138,6 +159,7 @@ pub struct VaList<'a, 'f: 'a> {
138
159
target_arch = "s390x" ,
139
160
target_arch = "x86_64"
140
161
) ,
162
+ not( target_arch = "xtensa" ) ,
141
163
any( not( target_arch = "aarch64" ) , not( target_vendor = "apple" ) ) ,
142
164
not( target_family = "wasm" ) ,
143
165
not( target_os = "uefi" ) ,
@@ -155,6 +177,7 @@ pub struct VaList<'a, 'f: 'a> {
155
177
not( target_arch = "s390x" ) ,
156
178
not( target_arch = "x86_64" )
157
179
) ,
180
+ target_arch = "xtensa" ,
158
181
all( target_arch = "aarch64" , target_vendor = "apple" ) ,
159
182
target_family = "wasm" ,
160
183
target_os = "uefi" ,
@@ -173,8 +196,10 @@ impl<'f> VaListImpl<'f> {
173
196
target_arch = "aarch64" ,
174
197
target_arch = "powerpc" ,
175
198
target_arch = "s390x" ,
199
+ target_arch = "xtensa" ,
176
200
target_arch = "x86_64"
177
201
) ,
202
+ not( target_arch = "xtensa" ) ,
178
203
any( not( target_arch = "aarch64" ) , not( target_vendor = "apple" ) ) ,
179
204
not( target_family = "wasm" ) ,
180
205
not( target_os = "uefi" ) ,
0 commit comments