• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1//===- IntrinsicsARM.td - Defines ARM intrinsics -----------*- tablegen -*-===//
2//
3//                     The LLVM Compiler Infrastructure
4//
5// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
9//
10// This file defines all of the ARM-specific intrinsics.
11//
12//===----------------------------------------------------------------------===//
13
14
15//===----------------------------------------------------------------------===//
16// TLS
17
18let TargetPrefix = "arm" in {  // All intrinsics start with "llvm.arm.".
19
20def int_arm_thread_pointer : GCCBuiltin<"__builtin_thread_pointer">,
21            Intrinsic<[llvm_ptr_ty], [], [IntrNoMem]>;
22
23//===----------------------------------------------------------------------===//
24// Saturating Arithmentic
25
26def int_arm_qadd : GCCBuiltin<"__builtin_arm_qadd">,
27    Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty],
28    [IntrNoMem, Commutative]>;
29def int_arm_qsub : GCCBuiltin<"__builtin_arm_qsub">,
30    Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], [IntrNoMem]>;
31def int_arm_ssat : GCCBuiltin<"__builtin_arm_ssat">,
32    Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], [IntrNoMem]>;
33def int_arm_usat : GCCBuiltin<"__builtin_arm_usat">,
34    Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty], [IntrNoMem]>;
35
36//===----------------------------------------------------------------------===//
37// Load, Store and Clear exclusive
38
39def int_arm_ldrex : Intrinsic<[llvm_i32_ty], [llvm_anyptr_ty]>;
40def int_arm_strex : Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_anyptr_ty]>;
41def int_arm_clrex : Intrinsic<[]>;
42
43def int_arm_strexd : Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty,
44    llvm_ptr_ty]>;
45def int_arm_ldrexd : Intrinsic<[llvm_i32_ty, llvm_i32_ty], [llvm_ptr_ty]>;
46
47//===----------------------------------------------------------------------===//
48// VFP
49
50def int_arm_get_fpscr : GCCBuiltin<"__builtin_arm_get_fpscr">,
51                       Intrinsic<[llvm_i32_ty], [], [IntrNoMem]>;
52def int_arm_set_fpscr : GCCBuiltin<"__builtin_arm_set_fpscr">,
53                       Intrinsic<[], [llvm_i32_ty], []>;
54def int_arm_vcvtr     : Intrinsic<[llvm_float_ty], [llvm_anyfloat_ty],
55                                  [IntrNoMem]>;
56def int_arm_vcvtru    : Intrinsic<[llvm_float_ty], [llvm_anyfloat_ty],
57                                  [IntrNoMem]>;
58
59//===----------------------------------------------------------------------===//
60// Coprocessor
61
62// Move to coprocessor
63def int_arm_mcr : GCCBuiltin<"__builtin_arm_mcr">,
64   Intrinsic<[], [llvm_i32_ty, llvm_i32_ty, llvm_i32_ty,
65                  llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], []>;
66def int_arm_mcr2 : GCCBuiltin<"__builtin_arm_mcr2">,
67   Intrinsic<[], [llvm_i32_ty, llvm_i32_ty, llvm_i32_ty,
68                  llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], []>;
69
70// Move from coprocessor
71def int_arm_mrc : GCCBuiltin<"__builtin_arm_mrc">,
72   Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty, llvm_i32_ty,
73                             llvm_i32_ty, llvm_i32_ty], []>;
74def int_arm_mrc2 : GCCBuiltin<"__builtin_arm_mrc2">,
75   Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_i32_ty, llvm_i32_ty,
76                             llvm_i32_ty, llvm_i32_ty], []>;
77
78// Coprocessor data processing
79def int_arm_cdp : GCCBuiltin<"__builtin_arm_cdp">,
80   Intrinsic<[], [llvm_i32_ty, llvm_i32_ty, llvm_i32_ty,
81                  llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], []>;
82def int_arm_cdp2 : GCCBuiltin<"__builtin_arm_cdp2">,
83   Intrinsic<[], [llvm_i32_ty, llvm_i32_ty, llvm_i32_ty,
84                  llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], []>;
85
86// Move from two registers to coprocessor
87def int_arm_mcrr : GCCBuiltin<"__builtin_arm_mcrr">,
88   Intrinsic<[], [llvm_i32_ty, llvm_i32_ty, llvm_i32_ty,
89                  llvm_i32_ty, llvm_i32_ty], []>;
90def int_arm_mcrr2 : GCCBuiltin<"__builtin_arm_mcrr2">,
91   Intrinsic<[], [llvm_i32_ty, llvm_i32_ty, llvm_i32_ty,
92                  llvm_i32_ty, llvm_i32_ty], []>;
93
94//===----------------------------------------------------------------------===//
95// Advanced SIMD (NEON)
96
97// The following classes do not correspond directly to GCC builtins.
98class Neon_1Arg_Intrinsic
99  : Intrinsic<[llvm_anyvector_ty], [LLVMMatchType<0>], [IntrNoMem]>;
100class Neon_1Arg_Narrow_Intrinsic
101  : Intrinsic<[llvm_anyvector_ty],
102              [LLVMExtendedElementVectorType<0>], [IntrNoMem]>;
103class Neon_2Arg_Intrinsic
104  : Intrinsic<[llvm_anyvector_ty], [LLVMMatchType<0>, LLVMMatchType<0>],
105              [IntrNoMem]>;
106class Neon_2Arg_Narrow_Intrinsic
107  : Intrinsic<[llvm_anyvector_ty],
108              [LLVMExtendedElementVectorType<0>,
109               LLVMExtendedElementVectorType<0>],
110              [IntrNoMem]>;
111class Neon_2Arg_Long_Intrinsic
112  : Intrinsic<[llvm_anyvector_ty],
113              [LLVMTruncatedElementVectorType<0>,
114               LLVMTruncatedElementVectorType<0>],
115              [IntrNoMem]>;
116class Neon_3Arg_Intrinsic
117  : Intrinsic<[llvm_anyvector_ty],
118              [LLVMMatchType<0>, LLVMMatchType<0>, LLVMMatchType<0>],
119              [IntrNoMem]>;
120class Neon_3Arg_Long_Intrinsic
121  : Intrinsic<[llvm_anyvector_ty],
122              [LLVMMatchType<0>,
123               LLVMTruncatedElementVectorType<0>,
124               LLVMTruncatedElementVectorType<0>],
125              [IntrNoMem]>;
126class Neon_CvtFxToFP_Intrinsic
127  : Intrinsic<[llvm_anyfloat_ty], [llvm_anyint_ty, llvm_i32_ty], [IntrNoMem]>;
128class Neon_CvtFPToFx_Intrinsic
129  : Intrinsic<[llvm_anyint_ty], [llvm_anyfloat_ty, llvm_i32_ty], [IntrNoMem]>;
130class Neon_CvtFPtoInt_1Arg_Intrinsic
131  : Intrinsic<[llvm_anyvector_ty], [llvm_anyvector_ty], [IntrNoMem]>;
132
133// The table operands for VTBL and VTBX consist of 1 to 4 v8i8 vectors.
134// Besides the table, VTBL has one other v8i8 argument and VTBX has two.
135// Overall, the classes range from 2 to 6 v8i8 arguments.
136class Neon_Tbl2Arg_Intrinsic
137  : Intrinsic<[llvm_v8i8_ty],
138              [llvm_v8i8_ty, llvm_v8i8_ty], [IntrNoMem]>;
139class Neon_Tbl3Arg_Intrinsic
140  : Intrinsic<[llvm_v8i8_ty],
141              [llvm_v8i8_ty, llvm_v8i8_ty, llvm_v8i8_ty], [IntrNoMem]>;
142class Neon_Tbl4Arg_Intrinsic
143  : Intrinsic<[llvm_v8i8_ty],
144              [llvm_v8i8_ty, llvm_v8i8_ty, llvm_v8i8_ty, llvm_v8i8_ty],
145              [IntrNoMem]>;
146class Neon_Tbl5Arg_Intrinsic
147  : Intrinsic<[llvm_v8i8_ty],
148              [llvm_v8i8_ty, llvm_v8i8_ty, llvm_v8i8_ty, llvm_v8i8_ty,
149               llvm_v8i8_ty], [IntrNoMem]>;
150class Neon_Tbl6Arg_Intrinsic
151  : Intrinsic<[llvm_v8i8_ty],
152              [llvm_v8i8_ty, llvm_v8i8_ty, llvm_v8i8_ty, llvm_v8i8_ty,
153               llvm_v8i8_ty, llvm_v8i8_ty], [IntrNoMem]>;
154
155// Arithmetic ops
156
157let Properties = [IntrNoMem, Commutative] in {
158
159  // Vector Add.
160  def int_arm_neon_vhadds : Neon_2Arg_Intrinsic;
161  def int_arm_neon_vhaddu : Neon_2Arg_Intrinsic;
162  def int_arm_neon_vrhadds : Neon_2Arg_Intrinsic;
163  def int_arm_neon_vrhaddu : Neon_2Arg_Intrinsic;
164  def int_arm_neon_vqadds : Neon_2Arg_Intrinsic;
165  def int_arm_neon_vqaddu : Neon_2Arg_Intrinsic;
166  def int_arm_neon_vaddhn : Neon_2Arg_Narrow_Intrinsic;
167  def int_arm_neon_vraddhn : Neon_2Arg_Narrow_Intrinsic;
168
169  // Vector Multiply.
170  def int_arm_neon_vmulp : Neon_2Arg_Intrinsic;
171  def int_arm_neon_vqdmulh : Neon_2Arg_Intrinsic;
172  def int_arm_neon_vqrdmulh : Neon_2Arg_Intrinsic;
173  def int_arm_neon_vmulls : Neon_2Arg_Long_Intrinsic;
174  def int_arm_neon_vmullu : Neon_2Arg_Long_Intrinsic;
175  def int_arm_neon_vmullp : Neon_2Arg_Long_Intrinsic;
176  def int_arm_neon_vqdmull : Neon_2Arg_Long_Intrinsic;
177
178  // Vector Multiply and Accumulate/Subtract.
179  def int_arm_neon_vqdmlal : Neon_3Arg_Long_Intrinsic;
180  def int_arm_neon_vqdmlsl : Neon_3Arg_Long_Intrinsic;
181
182  // Vector Maximum.
183  def int_arm_neon_vmaxs : Neon_2Arg_Intrinsic;
184  def int_arm_neon_vmaxu : Neon_2Arg_Intrinsic;
185  def int_arm_neon_vmaxnm : Neon_2Arg_Intrinsic;
186
187  // Vector Minimum.
188  def int_arm_neon_vmins : Neon_2Arg_Intrinsic;
189  def int_arm_neon_vminu : Neon_2Arg_Intrinsic;
190  def int_arm_neon_vminnm : Neon_2Arg_Intrinsic;
191
192  // Vector Reciprocal Step.
193  def int_arm_neon_vrecps : Neon_2Arg_Intrinsic;
194
195  // Vector Reciprocal Square Root Step.
196  def int_arm_neon_vrsqrts : Neon_2Arg_Intrinsic;
197}
198
199// Vector Subtract.
200def int_arm_neon_vhsubs : Neon_2Arg_Intrinsic;
201def int_arm_neon_vhsubu : Neon_2Arg_Intrinsic;
202def int_arm_neon_vqsubs : Neon_2Arg_Intrinsic;
203def int_arm_neon_vqsubu : Neon_2Arg_Intrinsic;
204def int_arm_neon_vsubhn : Neon_2Arg_Narrow_Intrinsic;
205def int_arm_neon_vrsubhn : Neon_2Arg_Narrow_Intrinsic;
206
207// Vector Absolute Compare.
208def int_arm_neon_vacged : Intrinsic<[llvm_v2i32_ty],
209                                    [llvm_v2f32_ty, llvm_v2f32_ty],
210                                    [IntrNoMem]>;
211def int_arm_neon_vacgeq : Intrinsic<[llvm_v4i32_ty],
212                                    [llvm_v4f32_ty, llvm_v4f32_ty],
213                                    [IntrNoMem]>;
214def int_arm_neon_vacgtd : Intrinsic<[llvm_v2i32_ty],
215                                    [llvm_v2f32_ty, llvm_v2f32_ty],
216                                    [IntrNoMem]>;
217def int_arm_neon_vacgtq : Intrinsic<[llvm_v4i32_ty],
218                                    [llvm_v4f32_ty, llvm_v4f32_ty],
219                                    [IntrNoMem]>;
220
221// Vector Absolute Differences.
222def int_arm_neon_vabds : Neon_2Arg_Intrinsic;
223def int_arm_neon_vabdu : Neon_2Arg_Intrinsic;
224
225// Vector Pairwise Add.
226def int_arm_neon_vpadd : Neon_2Arg_Intrinsic;
227
228// Vector Pairwise Add Long.
229// Note: This is different than the other "long" NEON intrinsics because
230// the result vector has half as many elements as the source vector.
231// The source and destination vector types must be specified separately.
232def int_arm_neon_vpaddls : Intrinsic<[llvm_anyvector_ty], [llvm_anyvector_ty],
233                                     [IntrNoMem]>;
234def int_arm_neon_vpaddlu : Intrinsic<[llvm_anyvector_ty], [llvm_anyvector_ty],
235                                     [IntrNoMem]>;
236
237// Vector Pairwise Add and Accumulate Long.
238// Note: This is similar to vpaddl but the destination vector also appears
239// as the first argument.
240def int_arm_neon_vpadals : Intrinsic<[llvm_anyvector_ty],
241                                     [LLVMMatchType<0>, llvm_anyvector_ty],
242                                     [IntrNoMem]>;
243def int_arm_neon_vpadalu : Intrinsic<[llvm_anyvector_ty],
244                                     [LLVMMatchType<0>, llvm_anyvector_ty],
245                                     [IntrNoMem]>;
246
247// Vector Pairwise Maximum and Minimum.
248def int_arm_neon_vpmaxs : Neon_2Arg_Intrinsic;
249def int_arm_neon_vpmaxu : Neon_2Arg_Intrinsic;
250def int_arm_neon_vpmins : Neon_2Arg_Intrinsic;
251def int_arm_neon_vpminu : Neon_2Arg_Intrinsic;
252
253// Vector Shifts:
254//
255// The various saturating and rounding vector shift operations need to be
256// represented by intrinsics in LLVM, and even the basic VSHL variable shift
257// operation cannot be safely translated to LLVM's shift operators.  VSHL can
258// be used for both left and right shifts, or even combinations of the two,
259// depending on the signs of the shift amounts.  It also has well-defined
260// behavior for shift amounts that LLVM leaves undefined.  Only basic shifts
261// by constants can be represented with LLVM's shift operators.
262//
263// The shift counts for these intrinsics are always vectors, even for constant
264// shifts, where the constant is replicated.  For consistency with VSHL (and
265// other variable shift instructions), left shifts have positive shift counts
266// and right shifts have negative shift counts.  This convention is also used
267// for constant right shift intrinsics, and to help preserve sanity, the
268// intrinsic names use "shift" instead of either "shl" or "shr".  Where
269// applicable, signed and unsigned versions of the intrinsics are
270// distinguished with "s" and "u" suffixes.  A few NEON shift instructions,
271// such as VQSHLU, take signed operands but produce unsigned results; these
272// use a "su" suffix.
273
274// Vector Shift.
275def int_arm_neon_vshifts : Neon_2Arg_Intrinsic;
276def int_arm_neon_vshiftu : Neon_2Arg_Intrinsic;
277def int_arm_neon_vshiftls : Neon_2Arg_Long_Intrinsic;
278def int_arm_neon_vshiftlu : Neon_2Arg_Long_Intrinsic;
279def int_arm_neon_vshiftn : Neon_2Arg_Narrow_Intrinsic;
280
281// Vector Rounding Shift.
282def int_arm_neon_vrshifts : Neon_2Arg_Intrinsic;
283def int_arm_neon_vrshiftu : Neon_2Arg_Intrinsic;
284def int_arm_neon_vrshiftn : Neon_2Arg_Narrow_Intrinsic;
285
286// Vector Saturating Shift.
287def int_arm_neon_vqshifts : Neon_2Arg_Intrinsic;
288def int_arm_neon_vqshiftu : Neon_2Arg_Intrinsic;
289def int_arm_neon_vqshiftsu : Neon_2Arg_Intrinsic;
290def int_arm_neon_vqshiftns : Neon_2Arg_Narrow_Intrinsic;
291def int_arm_neon_vqshiftnu : Neon_2Arg_Narrow_Intrinsic;
292def int_arm_neon_vqshiftnsu : Neon_2Arg_Narrow_Intrinsic;
293
294// Vector Saturating Rounding Shift.
295def int_arm_neon_vqrshifts : Neon_2Arg_Intrinsic;
296def int_arm_neon_vqrshiftu : Neon_2Arg_Intrinsic;
297def int_arm_neon_vqrshiftns : Neon_2Arg_Narrow_Intrinsic;
298def int_arm_neon_vqrshiftnu : Neon_2Arg_Narrow_Intrinsic;
299def int_arm_neon_vqrshiftnsu : Neon_2Arg_Narrow_Intrinsic;
300
301// Vector Shift and Insert.
302def int_arm_neon_vshiftins : Neon_3Arg_Intrinsic;
303
304// Vector Absolute Value and Saturating Absolute Value.
305def int_arm_neon_vabs : Neon_1Arg_Intrinsic;
306def int_arm_neon_vqabs : Neon_1Arg_Intrinsic;
307
308// Vector Saturating Negate.
309def int_arm_neon_vqneg : Neon_1Arg_Intrinsic;
310
311// Vector Count Leading Sign/Zero Bits.
312def int_arm_neon_vcls : Neon_1Arg_Intrinsic;
313def int_arm_neon_vclz : Neon_1Arg_Intrinsic;
314
315// Vector Count One Bits.
316def int_arm_neon_vcnt : Neon_1Arg_Intrinsic;
317
318// Vector Reciprocal Estimate.
319def int_arm_neon_vrecpe : Neon_1Arg_Intrinsic;
320
321// Vector Reciprocal Square Root Estimate.
322def int_arm_neon_vrsqrte : Neon_1Arg_Intrinsic;
323
324// Vector Conversions Between Floating-point and Integer
325def int_arm_neon_vcvtau : Neon_CvtFPtoInt_1Arg_Intrinsic;
326def int_arm_neon_vcvtas : Neon_CvtFPtoInt_1Arg_Intrinsic;
327def int_arm_neon_vcvtnu : Neon_CvtFPtoInt_1Arg_Intrinsic;
328def int_arm_neon_vcvtns : Neon_CvtFPtoInt_1Arg_Intrinsic;
329def int_arm_neon_vcvtpu : Neon_CvtFPtoInt_1Arg_Intrinsic;
330def int_arm_neon_vcvtps : Neon_CvtFPtoInt_1Arg_Intrinsic;
331def int_arm_neon_vcvtmu : Neon_CvtFPtoInt_1Arg_Intrinsic;
332def int_arm_neon_vcvtms : Neon_CvtFPtoInt_1Arg_Intrinsic;
333
334// Vector Conversions Between Floating-point and Fixed-point.
335def int_arm_neon_vcvtfp2fxs : Neon_CvtFPToFx_Intrinsic;
336def int_arm_neon_vcvtfp2fxu : Neon_CvtFPToFx_Intrinsic;
337def int_arm_neon_vcvtfxs2fp : Neon_CvtFxToFP_Intrinsic;
338def int_arm_neon_vcvtfxu2fp : Neon_CvtFxToFP_Intrinsic;
339
340// Vector Conversions Between Half-Precision and Single-Precision.
341def int_arm_neon_vcvtfp2hf
342    : Intrinsic<[llvm_v4i16_ty], [llvm_v4f32_ty], [IntrNoMem]>;
343def int_arm_neon_vcvthf2fp
344    : Intrinsic<[llvm_v4f32_ty], [llvm_v4i16_ty], [IntrNoMem]>;
345
346// Narrowing Saturating Vector Moves.
347def int_arm_neon_vqmovns : Neon_1Arg_Narrow_Intrinsic;
348def int_arm_neon_vqmovnu : Neon_1Arg_Narrow_Intrinsic;
349def int_arm_neon_vqmovnsu : Neon_1Arg_Narrow_Intrinsic;
350
351// Vector Table Lookup.
352// The first 1-4 arguments are the table.
353def int_arm_neon_vtbl1 : Neon_Tbl2Arg_Intrinsic;
354def int_arm_neon_vtbl2 : Neon_Tbl3Arg_Intrinsic;
355def int_arm_neon_vtbl3 : Neon_Tbl4Arg_Intrinsic;
356def int_arm_neon_vtbl4 : Neon_Tbl5Arg_Intrinsic;
357
358// Vector Table Extension.
359// Some elements of the destination vector may not be updated, so the original
360// value of that vector is passed as the first argument.  The next 1-4
361// arguments after that are the table.
362def int_arm_neon_vtbx1 : Neon_Tbl3Arg_Intrinsic;
363def int_arm_neon_vtbx2 : Neon_Tbl4Arg_Intrinsic;
364def int_arm_neon_vtbx3 : Neon_Tbl5Arg_Intrinsic;
365def int_arm_neon_vtbx4 : Neon_Tbl6Arg_Intrinsic;
366
367// Vector Rounding
368def int_arm_neon_vrintn : Neon_1Arg_Intrinsic;
369def int_arm_neon_vrintx : Neon_1Arg_Intrinsic;
370def int_arm_neon_vrinta : Neon_1Arg_Intrinsic;
371def int_arm_neon_vrintz : Neon_1Arg_Intrinsic;
372def int_arm_neon_vrintm : Neon_1Arg_Intrinsic;
373def int_arm_neon_vrintp : Neon_1Arg_Intrinsic;
374
375// De-interleaving vector loads from N-element structures.
376// Source operands are the address and alignment.
377def int_arm_neon_vld1 : Intrinsic<[llvm_anyvector_ty],
378                                  [llvm_ptr_ty, llvm_i32_ty],
379                                  [IntrReadArgMem]>;
380def int_arm_neon_vld2 : Intrinsic<[llvm_anyvector_ty, LLVMMatchType<0>],
381                                  [llvm_ptr_ty, llvm_i32_ty],
382                                  [IntrReadArgMem]>;
383def int_arm_neon_vld3 : Intrinsic<[llvm_anyvector_ty, LLVMMatchType<0>,
384                                   LLVMMatchType<0>],
385                                  [llvm_ptr_ty, llvm_i32_ty],
386                                  [IntrReadArgMem]>;
387def int_arm_neon_vld4 : Intrinsic<[llvm_anyvector_ty, LLVMMatchType<0>,
388                                   LLVMMatchType<0>, LLVMMatchType<0>],
389                                  [llvm_ptr_ty, llvm_i32_ty],
390                                  [IntrReadArgMem]>;
391
392// Vector load N-element structure to one lane.
393// Source operands are: the address, the N input vectors (since only one
394// lane is assigned), the lane number, and the alignment.
395def int_arm_neon_vld2lane : Intrinsic<[llvm_anyvector_ty, LLVMMatchType<0>],
396                                      [llvm_ptr_ty, LLVMMatchType<0>,
397                                       LLVMMatchType<0>, llvm_i32_ty,
398                                       llvm_i32_ty], [IntrReadArgMem]>;
399def int_arm_neon_vld3lane : Intrinsic<[llvm_anyvector_ty, LLVMMatchType<0>,
400                                       LLVMMatchType<0>],
401                                      [llvm_ptr_ty, LLVMMatchType<0>,
402                                       LLVMMatchType<0>, LLVMMatchType<0>,
403                                       llvm_i32_ty, llvm_i32_ty],
404                                      [IntrReadArgMem]>;
405def int_arm_neon_vld4lane : Intrinsic<[llvm_anyvector_ty, LLVMMatchType<0>,
406                                       LLVMMatchType<0>, LLVMMatchType<0>],
407                                      [llvm_ptr_ty, LLVMMatchType<0>,
408                                       LLVMMatchType<0>, LLVMMatchType<0>,
409                                       LLVMMatchType<0>, llvm_i32_ty,
410                                       llvm_i32_ty], [IntrReadArgMem]>;
411
412// Interleaving vector stores from N-element structures.
413// Source operands are: the address, the N vectors, and the alignment.
414def int_arm_neon_vst1 : Intrinsic<[],
415                                  [llvm_ptr_ty, llvm_anyvector_ty,
416                                   llvm_i32_ty], [IntrReadWriteArgMem]>;
417def int_arm_neon_vst2 : Intrinsic<[],
418                                  [llvm_ptr_ty, llvm_anyvector_ty,
419                                   LLVMMatchType<0>, llvm_i32_ty],
420                                  [IntrReadWriteArgMem]>;
421def int_arm_neon_vst3 : Intrinsic<[],
422                                  [llvm_ptr_ty, llvm_anyvector_ty,
423                                   LLVMMatchType<0>, LLVMMatchType<0>,
424                                   llvm_i32_ty], [IntrReadWriteArgMem]>;
425def int_arm_neon_vst4 : Intrinsic<[],
426                                  [llvm_ptr_ty, llvm_anyvector_ty,
427                                   LLVMMatchType<0>, LLVMMatchType<0>,
428                                   LLVMMatchType<0>, llvm_i32_ty],
429                                  [IntrReadWriteArgMem]>;
430
431// Vector store N-element structure from one lane.
432// Source operands are: the address, the N vectors, the lane number, and
433// the alignment.
434def int_arm_neon_vst2lane : Intrinsic<[],
435                                      [llvm_ptr_ty, llvm_anyvector_ty,
436                                       LLVMMatchType<0>, llvm_i32_ty,
437                                       llvm_i32_ty], [IntrReadWriteArgMem]>;
438def int_arm_neon_vst3lane : Intrinsic<[],
439                                      [llvm_ptr_ty, llvm_anyvector_ty,
440                                       LLVMMatchType<0>, LLVMMatchType<0>,
441                                       llvm_i32_ty, llvm_i32_ty],
442                                      [IntrReadWriteArgMem]>;
443def int_arm_neon_vst4lane : Intrinsic<[],
444                                      [llvm_ptr_ty, llvm_anyvector_ty,
445                                       LLVMMatchType<0>, LLVMMatchType<0>,
446                                       LLVMMatchType<0>, llvm_i32_ty,
447                                       llvm_i32_ty], [IntrReadWriteArgMem]>;
448
449// Vector bitwise select.
450def int_arm_neon_vbsl : Intrinsic<[llvm_anyvector_ty],
451                        [LLVMMatchType<0>, LLVMMatchType<0>, LLVMMatchType<0>],
452                        [IntrNoMem]>;
453
454} // end TargetPrefix
455