Debian Codegraph @

gcc/config/aarch64/constraints.md

raw
1 ;; Machine description for AArch64 architecture.
2 ;; Copyright (C) 2009-2025 Free Software Foundation, Inc.
3 ;; Contributed by ARM Ltd.
4 ;;
5 ;; This file is part of GCC.
6 ;;
7 ;; GCC is free software; you can redistribute it and/or modify it
8 ;; under the terms of the GNU General Public License as published by
9 ;; the Free Software Foundation; either version 3, or (at your option)
10 ;; any later version.
11 ;;
12 ;; GCC is distributed in the hope that it will be useful, but
13 ;; WITHOUT ANY WARRANTY; without even the implied warranty of
14 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 ;; General Public License for more details.
16 ;;
17 ;; You should have received a copy of the GNU General Public License
18 ;; along with GCC; see the file COPYING3. If not see
19 ;; <http://www.gnu.org/licenses/>.
20
21 (define_register_constraint "k" "STACK_REG"
22 "@internal The stack register.")
23
24 (define_register_constraint "Uci" "W8_W11_REGS"
25 "@internal r8-r11, which can be used to index ZA.")
26
27 (define_register_constraint "Ucj" "W12_W15_REGS"
28 "@internal r12-r15, which can be used to index ZA.")
29
30 (define_register_constraint "Ucs" "TAILCALL_ADDR_REGS"
31 "@internal Registers suitable for an indirect tail call")
32
33 (define_register_constraint "Ucr"
34 "aarch64_harden_sls_blr_p () ? STUB_REGS : GENERAL_REGS"
35 "@internal Registers to be used for an indirect call.
36 This is usually the general registers, but when we are hardening against
37 Straight Line Speculation we disallow x16, x17, and x30 so we can use
38 indirection stubs. These indirection stubs cannot use the above registers
39 since they will be reached by a BL that may have to go through a linker
40 veneer.")
41
42 (define_register_constraint "w" "FP_REGS"
43 "Floating point and SIMD vector registers.")
44
45 (define_register_constraint "x" "FP_LO_REGS"
46 "Floating point and SIMD vector registers V0 - V15.")
47
48 (define_register_constraint "y" "FP_LO8_REGS"
49 "Floating point and SIMD vector registers V0 - V7.")
50
51 (define_register_constraint "Uw2" "FP_REGS"
52 "Even floating point and SIMD vector registers."
53 "regno % 2 == 0")
54
55 (define_register_constraint "Uw4" "FP_REGS"
56 "4-tuple-aligned floating point and SIMD vector registers."
57 "regno % 4 == 0")
58
59 (define_register_constraint "Uwd" "FP_REGS"
60 "@internal The first register in a tuple of 2 strided FPRs."
61 "(regno & 0x8) == 0")
62
63 (define_register_constraint "Uwt" "FP_REGS"
64 "@internal The first register in a tuple of 4 strided FPRs."
65 "(regno & 0xc) == 0")
66
67 (define_register_constraint "Upa" "PR_REGS"
68 "SVE predicate registers p0 - p15.")
69
70 (define_register_constraint "Up2" "PR_REGS"
71 "An even SVE predicate register, p0 - p14."
72 "regno % 2 == 0")
73
74 (define_register_constraint "Upl" "PR_LO_REGS"
75 "SVE predicate registers p0 - p7.")
76
77 (define_register_constraint "Uph" "PR_HI_REGS"
78 "SVE predicate registers p8 - p15.")
79
80 (define_register_constraint "Umv" "MOVEABLE_SYSREGS"
81 "@internal System Registers suitable for moving rather than requiring an unspec msr")
82
83 (define_constraint "c"
84 "@internal The condition code register."
85 (match_operand 0 "cc_register"))
86
87 (define_constraint "I"
88 "A constant that can be used with an ADD operation."
89 (and (match_code "const_int")
90 (match_test "aarch64_uimm12_shift (ival)")))
91
92 (define_constraint "Uaa"
93 "@internal A constant that matches two uses of add instructions."
94 (and (match_code "const_int")
95 (match_test "aarch64_pluslong_strict_immedate (op, VOIDmode)")))
96
97 (define_constraint "Uai"
98 "@internal
99 A constraint that matches a VG-based constant that can be added by
100 a single INC or DEC."
101 (match_operand 0 "aarch64_sve_scalar_inc_dec_immediate"))
102
103 (define_constraint "Uav"
104 "@internal
105 A constraint that matches a VG-based constant that can be added by
106 a single ADDVL or ADDPL."
107 (match_operand 0 "aarch64_sve_addvl_addpl_immediate"))
108
109 (define_constraint "UaV"
110 "@internal
111 A constraint that matches a VG-based constant that can be added by
112 a single ADDSVL or ADDSPL."
113 (match_operand 0 "aarch64_addsvl_addspl_immediate"))
114
115 (define_constraint "Uat"
116 "@internal
117 A constraint that matches a VG-based constant that can be added by
118 using multiple instructions, with one temporary register."
119 (match_operand 0 "aarch64_split_add_offset_immediate"))
120
121 (define_constraint "J"
122 "A constant that can be used with a SUB operation (once negated)."
123 (and (match_code "const_int")
124 (match_test "aarch64_uimm12_shift (- (unsigned HOST_WIDE_INT) ival)")))
125
126 ;; We can't use the mode of a CONST_INT to determine the context in
127 ;; which it is being used, so we must have a separate constraint for
128 ;; each context.
129
130 (define_constraint "K"
131 "A constant that can be used with a 32-bit logical operation."
132 (and (match_code "const_int")
133 (match_test "aarch64_bitmask_imm (ival, SImode)")))
134
135 (define_constraint "L"
136 "A constant that can be used with a 64-bit logical operation."
137 (and (match_code "const_int")
138 (match_test "aarch64_bitmask_imm (ival, DImode)")))
139
140 (define_constraint "M"
141 "A constant that can be used with a 32-bit MOV immediate operation."
142 (and (match_code "const_int")
143 (match_test "aarch64_move_imm (ival, SImode)")))
144
145 (define_constraint "N"
146 "A constant that can be used with a 64-bit MOV immediate operation."
147 (and (match_code "const_int")
148 (match_test "aarch64_is_mov_xn_imm (ival)")))
149
150 (define_constraint "O"
151 "A constant that can be used with a 32 or 64-bit MOV immediate operation."
152 (and (match_code "const_int")
153 (match_test "aarch64_move_imm (ival, DImode)")))
154
155 (define_constraint "Uti"
156 "A constant that can be used with a 128-bit MOV immediate operation."
157 (and (ior (match_code "const_int")
158 (match_code "const_wide_int"))
159 (match_test "aarch64_mov128_immediate (op)")))
160
161 (define_constraint "UsO"
162 "A constant that can be used with a 32-bit and operation."
163 (and (match_code "const_int")
164 (match_test "aarch64_and_bitmask_imm (ival, SImode)")))
165
166 (define_constraint "UsP"
167 "A constant that can be used with a 64-bit and operation."
168 (and (match_code "const_int")
169 (match_test "aarch64_and_bitmask_imm (ival, DImode)")))
170
171 (define_constraint "S"
172 "A constraint that matches an absolute symbolic address."
173 (and (match_code "const,symbol_ref,label_ref")
174 (match_test "aarch64_symbolic_address_p (op)")))
175
176 (define_constraint "Y"
177 "Floating point constant zero."
178 (and (match_code "const_double")
179 (match_test "aarch64_float_const_zero_rtx_p (op)")))
180
181 (define_constraint "Z"
182 "Integer or floating-point constant zero."
183 (match_test "op == CONST0_RTX (GET_MODE (op))"))
184
185 (define_constraint "Ush"
186 "A constraint that matches an absolute symbolic address high part."
187 (and (match_code "high")
188 (match_test "aarch64_valid_symref (XEXP (op, 0), GET_MODE (XEXP (op, 0)))")))
189
190 (define_constraint "Usa"
191 "@internal
192 A constraint that matches an absolute symbolic address that can be
193 loaded by a single ADR."
194 (and (match_code "const,symbol_ref,label_ref")
195 (match_test "aarch64_symbolic_address_p (op)")
196 (match_test "aarch64_mov_operand_p (op, GET_MODE (op))")))
197
198 (define_constraint "Usm"
199 "A constant that can be used with the S[MIN/MAX] CSSC instructions."
200 (and (match_code "const_int")
201 (match_test "aarch64_sminmax_immediate (op, VOIDmode)")))
202
203 ;; const is needed here to support UNSPEC_SALT_ADDR.
204 (define_constraint "Usw"
205 "@internal
206 A constraint that matches a small GOT access."
207 (and (match_code "const,symbol_ref")
208 (match_test "aarch64_classify_symbolic_expression (op)
209 == SYMBOL_SMALL_GOT_4G")))
210
211 (define_constraint "Uss"
212 "@internal
213 A constraint that matches an immediate shift constant in SImode."
214 (and (match_code "const_int")
215 (match_test "(unsigned HOST_WIDE_INT) ival < 32")))
216
217 (define_constraint "Usn"
218 "A constant that can be used with a CCMN operation (once negated)."
219 (and (match_code "const_int")
220 (match_test "IN_RANGE (ival, -31, 0)")))
221
222 (define_constraint "Usd"
223 "@internal
224 A constraint that matches an immediate shift constant in DImode."
225 (and (match_code "const_int")
226 (match_test "(unsigned HOST_WIDE_INT) ival < 64")))
227
228 (define_constraint "Usf"
229 "@internal Usf is a symbol reference under the context where plt stub allowed."
230 (and (match_code "symbol_ref")
231 (match_test "!(aarch64_is_noplt_call_p (op)
232 || aarch64_is_long_call_p (op))")))
233
234 (define_constraint "Usg"
235 "@internal
236 A constraint that matches an immediate right shift constant in SImode
237 suitable for a SISD instruction."
238 (and (match_code "const_int")
239 (match_test "IN_RANGE (ival, 1, 31)")))
240
241 (define_constraint "Usj"
242 "@internal
243 A constraint that matches an immediate right shift constant in DImode
244 suitable for a SISD instruction."
245 (and (match_code "const_int")
246 (match_test "IN_RANGE (ival, 1, 63)")))
247
248 (define_constraint "UsM"
249 "@internal
250 A constraint that matches the immediate constant -1."
251 (match_test "op == constm1_rtx"))
252
253 (define_constraint "Ulc"
254 "@internal
255 A constraint that matches a constant integer whose bits are consecutive ones
256 from the MSB."
257 (and (match_code "const_int")
258 (match_test "aarch64_high_bits_all_ones_p (ival)")))
259
260 (define_constraint "Usr"
261 "@internal
262 A constraint that matches a value produced by RDVL."
263 (and (match_code "const_poly_int")
264 (match_test "aarch64_sve_rdvl_immediate_p (op)")))
265
266 (define_constraint "UsR"
267 "@internal
268 A constraint that matches a value produced by RDSVL."
269 (and (match_code "const")
270 (match_test "aarch64_rdsvl_immediate_p (op)")))
271
272 (define_constraint "Usv"
273 "@internal
274 A constraint that matches a VG-based constant that can be loaded by
275 a single CNT[BHWD]."
276 (match_operand 0 "aarch64_sve_cnt_immediate"))
277
278 (define_constraint "Usi"
279 "@internal
280 A constraint that matches an immediate operand valid for
281 the SVE INDEX instruction."
282 (match_operand 0 "aarch64_sve_index_immediate"))
283
284 (define_constraint "Ui1"
285 "@internal
286 A constraint that matches the immediate constant +1."
287 (match_test "op == const1_rtx"))
288
289 (define_constraint "Ui2"
290 "@internal
291 A constraint that matches the integers 0...3."
292 (and (match_code "const_int")
293 (match_test "(unsigned HOST_WIDE_INT) ival <= 3")))
294
295 (define_constraint "Ui3"
296 "@internal
297 A constraint that matches the integers 0...4."
298 (and (match_code "const_int")
299 (match_test "(unsigned HOST_WIDE_INT) ival <= 4")))
300
301 (define_constraint "Ui7"
302 "@internal
303 A constraint that matches the integers 0...7."
304 (and (match_code "const_int")
305 (match_test "(unsigned HOST_WIDE_INT) ival <= 7")))
306
307 (define_constraint "Up3"
308 "@internal
309 A constraint that matches the integers 2^(0...4)."
310 (and (match_code "const_int")
311 (match_test "(unsigned) exact_log2 (ival) <= 4")))
312
313 (define_constraint "Uih"
314 "@internal
315 A constraint that matches HImode integers zero extendable to
316 SImode plus_operand."
317 (and (match_code "const_int")
318 (match_test "aarch64_plushi_immediate (op, VOIDmode)")))
319
320 (define_memory_constraint "Q"
321 "A memory address which uses a single base register with no offset."
322 (and (match_code "mem")
323 (match_test "REG_P (XEXP (op, 0))")))
324
325 (define_memory_constraint "Ust"
326 "@internal
327 A memory address with 9bit unscaled offset."
328 (match_operand 0 "aarch64_9bit_offset_memory_operand"))
329
330 (define_memory_constraint "Ump"
331 "@internal
332 A memory address suitable for a load/store pair operation."
333 (and (match_code "mem")
334 (match_test "aarch64_legitimate_address_p (GET_MODE (op), XEXP (op, 0),
335 true, ADDR_QUERY_LDP_STP)")))
336
337 ;; Used for storing or loading pairs in an AdvSIMD register using an STP/LDP
338 ;; as a vector-concat. The address mode uses the same constraints as if it
339 ;; were for a single value.
340 (define_relaxed_memory_constraint "Umn"
341 "@internal
342 A memory address suitable for a load/store pair operation."
343 (and (match_code "mem")
344 (match_test "aarch64_legitimate_address_p (GET_MODE (op), XEXP (op, 0),
345 true,
346 ADDR_QUERY_LDP_STP_N)")))
347
348 (define_address_constraint "UPb"
349 "@internal
350 An address valid for SVE PRFB instructions."
351 (match_test "aarch64_sve_prefetch_operand_p (op, VNx16QImode)"))
352
353 (define_address_constraint "UPd"
354 "@internal
355 An address valid for SVE PRFD instructions."
356 (match_test "aarch64_sve_prefetch_operand_p (op, VNx2DImode)"))
357
358 (define_address_constraint "UPh"
359 "@internal
360 An address valid for SVE PRFH instructions."
361 (match_test "aarch64_sve_prefetch_operand_p (op, VNx8HImode)"))
362
363 (define_address_constraint "UPw"
364 "@internal
365 An address valid for SVE PRFW instructions."
366 (match_test "aarch64_sve_prefetch_operand_p (op, VNx4SImode)"))
367
368 (define_memory_constraint "Utf"
369 "@internal
370 An address valid for SVE LDFF1 instructions."
371 (and (match_code "mem")
372 (match_test "aarch64_sve_ldff1_operand_p (op)")))
373
374 (define_memory_constraint "Utn"
375 "@internal
376 An address valid for SVE LDNF1 instructions."
377 (and (match_code "mem")
378 (match_test "aarch64_sve_ldnf1_operand_p (op)")))
379
380 (define_memory_constraint "Utr"
381 "@internal
382 An address valid for SVE LDR and STR instructions (as distinct from
383 LD[1234] and ST[1234] patterns)."
384 (and (match_code "mem")
385 (match_test "aarch64_sve_ldr_operand_p (op)")))
386
387 (define_memory_constraint "Utv"
388 "@internal
389 An address valid for loading/storing opaque structure
390 types wider than TImode."
391 (and (match_code "mem")
392 (match_test "aarch64_simd_mem_operand_p (op)")))
393
394 (define_relaxed_memory_constraint "Utq"
395 "@internal
396 An address valid for loading or storing a 128-bit AdvSIMD register"
397 (and (match_code "mem")
398 (match_test "aarch64_legitimate_address_p (GET_MODE (op),
399 XEXP (op, 0), 1)")
400 (match_test "aarch64_legitimate_address_p (V2DImode,
401 XEXP (op, 0), 1)")))
402
403 (define_relaxed_memory_constraint "UtQ"
404 "@internal
405 An address valid for SVE LD1RQs."
406 (and (match_code "mem")
407 (match_test "aarch64_sve_ld1rq_operand_p (op)")))
408
409 (define_relaxed_memory_constraint "UOb"
410 "@internal
411 An address valid for SVE LD1ROH."
412 (and (match_code "mem")
413 (match_test "aarch64_sve_ld1ro_operand_p (op, QImode)")))
414
415 (define_relaxed_memory_constraint "UOh"
416 "@internal
417 An address valid for SVE LD1ROH."
418 (and (match_code "mem")
419 (match_test "aarch64_sve_ld1ro_operand_p (op, HImode)")))
420
421
422 (define_relaxed_memory_constraint "UOw"
423 "@internal
424 An address valid for SVE LD1ROW."
425 (and (match_code "mem")
426 (match_test "aarch64_sve_ld1ro_operand_p (op, SImode)")))
427
428 (define_relaxed_memory_constraint "UOd"
429 "@internal
430 An address valid for SVE LD1ROD."
431 (and (match_code "mem")
432 (match_test "aarch64_sve_ld1ro_operand_p (op, DImode)")))
433
434 (define_relaxed_memory_constraint "Uty"
435 "@internal
436 An address valid for SVE LD1Rs."
437 (and (match_code "mem")
438 (match_test "aarch64_sve_ld1r_operand_p (op)")))
439
440 (define_memory_constraint "Utx"
441 "@internal
442 An address valid for SVE structure mov patterns (as distinct from
443 LD[234] and ST[234] patterns)."
444 (match_operand 0 "aarch64_sve_struct_memory_operand"))
445
446 (define_constraint "Ufc"
447 "A floating point constant which can be used with an\
448 FMOV immediate operation."
449 (and (match_code "const_double,const_vector")
450 (match_test "aarch64_float_const_representable_p (op)")))
451
452 (define_constraint "Uum"
453 "A constant that can be used with the U[MIN/MAX] CSSC instructions."
454 (and (match_code "const_int")
455 (match_test "aarch64_uminmax_immediate (op, VOIDmode)")))
456
457 (define_constraint "Uvi"
458 "A floating point constant which can be used with a\
459 MOVI immediate operation."
460 (and (match_code "const_double")
461 (match_test "aarch64_can_const_movi_rtx_p (op, GET_MODE (op))")))
462
463 (define_constraint "Do"
464 "@internal
465 A constraint that matches vector of immediates for orr."
466 (and (match_code "const_vector")
467 (match_test "aarch64_simd_valid_orr_imm (op)")))
468
469 (define_constraint "Db"
470 "@internal
471 A constraint that matches vector of immediates for and/bic."
472 (and (match_code "const_vector")
473 (match_test "aarch64_simd_valid_and_imm (op)")))
474
475 (define_constraint "De"
476 "@internal
477 A constraint that matches vector of immediates for xor."
478 (and (match_code "const_vector")
479 (match_test "aarch64_simd_valid_xor_imm (op)")))
480
481 (define_constraint "Dn"
482 "@internal
483 A constraint that matches vector of immediates."
484 (and (match_code "const,const_vector")
485 (match_test "aarch64_simd_valid_mov_imm (op)")))
486
487 (define_constraint "Dh"
488 "@internal
489 A constraint that matches an immediate operand valid for\
490 AdvSIMD scalar move in HImode."
491 (and (match_code "const_int")
492 (match_test "aarch64_simd_scalar_immediate_valid_for_move (op,
493 HImode)")))
494
495 (define_constraint "Dq"
496 "@internal
497 A constraint that matches an immediate operand valid for\
498 AdvSIMD scalar move in QImode."
499 (and (match_code "const_int")
500 (match_test "aarch64_simd_scalar_immediate_valid_for_move (op,
501 QImode)")))
502
503 (define_constraint "Dt"
504 "@internal
505 A const_double which is the reciprocal of an exact power of two, can be
506 used in an scvtf with fract bits operation"
507 (and (match_code "const_double")
508 (match_test "aarch64_fpconst_pow2_recip (op) > 0")))
509
510 (define_constraint "Dl"
511 "@internal
512 A constraint that matches vector of immediates for left shifts."
513 (and (match_code "const,const_vector")
514 (match_test "aarch64_simd_shift_imm_p (op, GET_MODE (op),
515 true)")))
516
517 (define_constraint "D1"
518 "@internal
519 A constraint that matches vector of immediates that is bits(mode)-1."
520 (and (match_code "const,const_vector")
521 (match_test "aarch64_const_vec_all_same_in_range_p (op,
522 GET_MODE_UNIT_BITSIZE (mode) - 1,
523 GET_MODE_UNIT_BITSIZE (mode) - 1)")))
524
525 (define_constraint "D2"
526 "@internal
527 A constraint that matches vector of immediates that is bits(mode)/2."
528 (and (match_code "const,const_vector")
529 (match_test "aarch64_simd_shift_imm_vec_exact_top (op, mode)")))
530
531 (define_constraint "DL"
532 "@internal
533 A constraint that matches vector of immediates for left shift long.
534 That is immediates between 0 to (bits(mode)/2)-1."
535 (and (match_code "const,const_vector")
536 (match_test "aarch64_const_vec_all_same_in_range_p (op, 0,
537 (GET_MODE_UNIT_BITSIZE (mode) / 2) - 1)")))
538
539 (define_constraint "Dr"
540 "@internal
541 A constraint that matches vector of immediates for right shifts."
542 (and (match_code "const,const_vector")
543 (match_test "aarch64_simd_shift_imm_p (op, GET_MODE (op),
544 false)")))
545
546 (define_constraint "Dx"
547 "@internal
548 A constraint that matches a vector of 64-bit immediates which we don't have a
549 single instruction to create but that we can create in creative ways."
550 (and (match_code "const_int,const,const_vector")
551 (match_test "aarch64_simd_special_constant_p (op, DImode)")))
552
553 (define_constraint "Dz"
554 "@internal
555 A constraint that matches a vector of immediate zero."
556 (and (match_code "const,const_vector")
557 (match_test "op == CONST0_RTX (GET_MODE (op))")))
558
559 (define_constraint "Dm"
560 "@internal
561 A constraint that matches a vector of immediate minus one."
562 (and (match_code "const,const_vector")
563 (match_test "op == CONSTM1_RTX (GET_MODE (op))")))
564
565 (define_constraint "Dd"
566 "@internal
567 A constraint that matches an integer immediate operand valid\
568 for AdvSIMD scalar operations in DImode."
569 (and (match_code "const_int")
570 (match_test "aarch64_can_const_movi_rtx_p (op, DImode)")))
571
572 (define_constraint "Ds"
573 "@internal
574 A constraint that matches an integer immediate operand valid\
575 for AdvSIMD scalar operations in SImode."
576 (and (match_code "const_int")
577 (match_test "aarch64_can_const_movi_rtx_p (op, SImode)")))
578
579 (define_address_constraint "Dp"
580 "@internal
581 An address valid for a prefetch instruction."
582 (match_test "aarch64_address_valid_for_prefetch_p (op, true)"))
583
584 (define_constraint "vgb"
585 "@internal
586 A constraint that matches an immediate offset valid for SVE LD1B
587 gather instructions."
588 (match_operand 0 "aarch64_sve_gather_immediate_b"))
589
590 (define_constraint "vgd"
591 "@internal
592 A constraint that matches an immediate offset valid for SVE LD1D
593 gather instructions."
594 (match_operand 0 "aarch64_sve_gather_immediate_d"))
595
596 (define_constraint "vgh"
597 "@internal
598 A constraint that matches an immediate offset valid for SVE LD1H
599 gather instructions."
600 (match_operand 0 "aarch64_sve_gather_immediate_h"))
601
602 (define_constraint "vgw"
603 "@internal
604 A constraint that matches an immediate offset valid for SVE LD1W
605 gather instructions."
606 (match_operand 0 "aarch64_sve_gather_immediate_w"))
607
608 (define_constraint "vsa"
609 "@internal
610 A constraint that matches an immediate operand valid for SVE
611 arithmetic instructions."
612 (match_operand 0 "aarch64_sve_arith_immediate"))
613
614 (define_constraint "vsb"
615 "@internal
616 A constraint that matches an immediate operand valid for SVE UMAX
617 and UMIN operations."
618 (match_operand 0 "aarch64_sve_vsb_immediate"))
619
620 (define_constraint "vsc"
621 "@internal
622 A constraint that matches a signed immediate operand valid for SVE
623 CMP instructions."
624 (match_operand 0 "aarch64_sve_cmp_vsc_immediate"))
625
626 (define_constraint "vss"
627 "@internal
628 A constraint that matches a signed immediate operand valid for SVE
629 DUP instructions."
630 (match_test "aarch64_sve_dup_immediate_p (op)"))
631
632 (define_constraint "vsd"
633 "@internal
634 A constraint that matches an unsigned immediate operand valid for SVE
635 CMP instructions."
636 (match_operand 0 "aarch64_sve_cmp_vsd_immediate"))
637
638 (define_constraint "vsi"
639 "@internal
640 A constraint that matches a vector count operand valid for SVE INC and
641 DEC instructions."
642 (match_operand 0 "aarch64_sve_vector_inc_dec_immediate"))
643
644 (define_constraint "vsn"
645 "@internal
646 A constraint that matches an immediate operand whose negative
647 is valid for SVE SUB instructions."
648 (match_operand 0 "aarch64_sve_sub_arith_immediate"))
649
650 (define_constraint "vsQ"
651 "@internal
652 Like vsa, but additionally check that the immediate is nonnegative
653 when interpreted as a signed value."
654 (match_operand 0 "aarch64_sve_qadd_immediate"))
655
656 (define_constraint "vsS"
657 "@internal
658 Like vsn, but additionally check that the immediate is negative
659 when interpreted as a signed value."
660 (match_operand 0 "aarch64_sve_qsub_immediate"))
661
662 (define_constraint "vsl"
663 "@internal
664 A constraint that matches an immediate operand valid for SVE logical
665 operations."
666 (match_operand 0 "aarch64_sve_logical_immediate"))
667
668 (define_constraint "vsm"
669 "@internal
670 A constraint that matches an immediate operand valid for SVE MUL,
671 SMAX and SMIN operations."
672 (match_operand 0 "aarch64_sve_vsm_immediate"))
673
674 (define_constraint "vs1"
675 "@internal
676 A constraint that matches a vector of immediate one."
677 (and (match_code "const,const_vector")
678 (match_test "op == CONST1_RTX (GET_MODE (op))")))
679
680 (define_constraint "vsA"
681 "@internal
682 A constraint that matches an immediate operand valid for SVE FADD
683 and FSUB operations."
684 (match_operand 0 "aarch64_sve_float_arith_immediate"))
685
686 ;; "B" for "bound".
687 (define_constraint "vsB"
688 "@internal
689 A constraint that matches an immediate operand valid for SVE FMAX
690 and FMIN operations."
691 (match_operand 0 "aarch64_sve_float_maxmin_immediate"))
692
693 (define_constraint "vsM"
694 "@internal
695 A constraint that matches an immediate operand valid for SVE FMUL
696 operations."
697 (match_operand 0 "aarch64_sve_float_mul_immediate"))
698
699 (define_constraint "vsN"
700 "@internal
701 A constraint that matches the negative of vsA"
702 (match_operand 0 "aarch64_sve_float_negated_arith_immediate"))