LLVM  15.0.0git
MachineValueType.h
Go to the documentation of this file.
1 //===- Support/MachineValueType.h - Machine-Level types ---------*- C++ -*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 //
9 // This file defines the set of machine-level target independent types which
10 // legal values in the code generator use.
11 //
12 //===----------------------------------------------------------------------===//
13 
14 #ifndef LLVM_SUPPORT_MACHINEVALUETYPE_H
15 #define LLVM_SUPPORT_MACHINEVALUETYPE_H
16 
17 #include "llvm/ADT/Sequence.h"
21 #include "llvm/Support/TypeSize.h"
22 #include <cassert>
23 
24 namespace llvm {
25 
26  class Type;
27 
28  /// Machine Value Type. Every type that is supported natively by some
29  /// processor targeted by LLVM occurs here. This means that any legal value
30  /// type can be represented by an MVT.
31  class MVT {
32  public:
33  enum SimpleValueType : uint8_t {
34  // clang-format off
35 
36  // Simple value types that aren't explicitly part of this enumeration
37  // are considered extended value types.
39 
40  // If you change this numbering, you must change the values in
41  // ValueTypes.td as well!
42  Other = 1, // This is a non-standard value
43  i1 = 2, // This is a 1 bit integer value
44  i2 = 3, // This is a 2 bit integer value
45  i4 = 4, // This is a 4 bit integer value
46  i8 = 5, // This is an 8 bit integer value
47  i16 = 6, // This is a 16 bit integer value
48  i32 = 7, // This is a 32 bit integer value
49  i64 = 8, // This is a 64 bit integer value
50  i128 = 9, // This is a 128 bit integer value
51 
54 
55  bf16 = 10, // This is a 16 bit brain floating point value
56  f16 = 11, // This is a 16 bit floating point value
57  f32 = 12, // This is a 32 bit floating point value
58  f64 = 13, // This is a 64 bit floating point value
59  f80 = 14, // This is a 80 bit floating point value
60  f128 = 15, // This is a 128 bit floating point value
61  ppcf128 = 16, // This is a PPC 128-bit floating point value
62 
65 
66  v1i1 = 17, // 1 x i1
67  v2i1 = 18, // 2 x i1
68  v4i1 = 19, // 4 x i1
69  v8i1 = 20, // 8 x i1
70  v16i1 = 21, // 16 x i1
71  v32i1 = 22, // 32 x i1
72  v64i1 = 23, // 64 x i1
73  v128i1 = 24, // 128 x i1
74  v256i1 = 25, // 256 x i1
75  v512i1 = 26, // 512 x i1
76  v1024i1 = 27, // 1024 x i1
77 
78  v128i2 = 28, // 128 x i2
79 
80  v64i4 = 29, // 64 x i4
81 
82  v1i8 = 30, // 1 x i8
83  v2i8 = 31, // 2 x i8
84  v4i8 = 32, // 4 x i8
85  v8i8 = 33, // 8 x i8
86  v16i8 = 34, // 16 x i8
87  v32i8 = 35, // 32 x i8
88  v64i8 = 36, // 64 x i8
89  v128i8 = 37, // 128 x i8
90  v256i8 = 38, // 256 x i8
91  v512i8 = 39, // 512 x i8
92  v1024i8 = 40, // 1024 x i8
93 
94  v1i16 = 41, // 1 x i16
95  v2i16 = 42, // 2 x i16
96  v3i16 = 43, // 3 x i16
97  v4i16 = 44, // 4 x i16
98  v8i16 = 45, // 8 x i16
99  v16i16 = 46, // 16 x i16
100  v32i16 = 47, // 32 x i16
101  v64i16 = 48, // 64 x i16
102  v128i16 = 49, // 128 x i16
103  v256i16 = 50, // 256 x i16
104  v512i16 = 51, // 512 x i16
105 
106  v1i32 = 52, // 1 x i32
107  v2i32 = 53, // 2 x i32
108  v3i32 = 54, // 3 x i32
109  v4i32 = 55, // 4 x i32
110  v5i32 = 56, // 5 x i32
111  v6i32 = 57, // 6 x i32
112  v7i32 = 58, // 7 x i32
113  v8i32 = 59, // 8 x i32
114  v16i32 = 60, // 16 x i32
115  v32i32 = 61, // 32 x i32
116  v64i32 = 62, // 64 x i32
117  v128i32 = 63, // 128 x i32
118  v256i32 = 64, // 256 x i32
119  v512i32 = 65, // 512 x i32
120  v1024i32 = 66, // 1024 x i32
121  v2048i32 = 67, // 2048 x i32
122 
123  v1i64 = 68, // 1 x i64
124  v2i64 = 69, // 2 x i64
125  v3i64 = 70, // 3 x i64
126  v4i64 = 71, // 4 x i64
127  v8i64 = 72, // 8 x i64
128  v16i64 = 73, // 16 x i64
129  v32i64 = 74, // 32 x i64
130  v64i64 = 75, // 64 x i64
131  v128i64 = 76, // 128 x i64
132  v256i64 = 77, // 256 x i64
133 
134  v1i128 = 78, // 1 x i128
135 
138 
139  v1f16 = 79, // 1 x f16
140  v2f16 = 80, // 2 x f16
141  v3f16 = 81, // 3 x f16
142  v4f16 = 82, // 4 x f16
143  v8f16 = 83, // 8 x f16
144  v16f16 = 84, // 16 x f16
145  v32f16 = 85, // 32 x f16
146  v64f16 = 86, // 64 x f16
147  v128f16 = 87, // 128 x f16
148  v256f16 = 88, // 256 x f16
149  v512f16 = 89, // 256 x f16
150 
151  v2bf16 = 90, // 2 x bf16
152  v3bf16 = 91, // 3 x bf16
153  v4bf16 = 92, // 4 x bf16
154  v8bf16 = 93, // 8 x bf16
155  v16bf16 = 94, // 16 x bf16
156  v32bf16 = 95, // 32 x bf16
157  v64bf16 = 96, // 64 x bf16
158  v128bf16 = 97, // 128 x bf16
159 
160  v1f32 = 98, // 1 x f32
161  v2f32 = 99, // 2 x f32
162  v3f32 = 100, // 3 x f32
163  v4f32 = 101, // 4 x f32
164  v5f32 = 102, // 5 x f32
165  v6f32 = 103, // 6 x f32
166  v7f32 = 104, // 7 x f32
167  v8f32 = 105, // 8 x f32
168  v16f32 = 106, // 16 x f32
169  v32f32 = 107, // 32 x f32
170  v64f32 = 108, // 64 x f32
171  v128f32 = 109, // 128 x f32
172  v256f32 = 110, // 256 x f32
173  v512f32 = 111, // 512 x f32
174  v1024f32 = 112, // 1024 x f32
175  v2048f32 = 113, // 2048 x f32
176 
177  v1f64 = 114, // 1 x f64
178  v2f64 = 115, // 2 x f64
179  v3f64 = 116, // 3 x f64
180  v4f64 = 117, // 4 x f64
181  v8f64 = 118, // 8 x f64
182  v16f64 = 119, // 16 x f64
183  v32f64 = 120, // 32 x f64
184  v64f64 = 121, // 64 x f64
185  v128f64 = 122, // 128 x f64
186  v256f64 = 123, // 256 x f64
187 
190 
193 
194  nxv1i1 = 124, // n x 1 x i1
195  nxv2i1 = 125, // n x 2 x i1
196  nxv4i1 = 126, // n x 4 x i1
197  nxv8i1 = 127, // n x 8 x i1
198  nxv16i1 = 128, // n x 16 x i1
199  nxv32i1 = 129, // n x 32 x i1
200  nxv64i1 = 130, // n x 64 x i1
201 
202  nxv1i8 = 131, // n x 1 x i8
203  nxv2i8 = 132, // n x 2 x i8
204  nxv4i8 = 133, // n x 4 x i8
205  nxv8i8 = 134, // n x 8 x i8
206  nxv16i8 = 135, // n x 16 x i8
207  nxv32i8 = 136, // n x 32 x i8
208  nxv64i8 = 137, // n x 64 x i8
209 
210  nxv1i16 = 138, // n x 1 x i16
211  nxv2i16 = 139, // n x 2 x i16
212  nxv4i16 = 140, // n x 4 x i16
213  nxv8i16 = 141, // n x 8 x i16
214  nxv16i16 = 142, // n x 16 x i16
215  nxv32i16 = 143, // n x 32 x i16
216 
217  nxv1i32 = 144, // n x 1 x i32
218  nxv2i32 = 145, // n x 2 x i32
219  nxv4i32 = 146, // n x 4 x i32
220  nxv8i32 = 147, // n x 8 x i32
221  nxv16i32 = 148, // n x 16 x i32
222  nxv32i32 = 149, // n x 32 x i32
223 
224  nxv1i64 = 150, // n x 1 x i64
225  nxv2i64 = 151, // n x 2 x i64
226  nxv4i64 = 152, // n x 4 x i64
227  nxv8i64 = 153, // n x 8 x i64
228  nxv16i64 = 154, // n x 16 x i64
229  nxv32i64 = 155, // n x 32 x i64
230 
233 
234  nxv1f16 = 156, // n x 1 x f16
235  nxv2f16 = 157, // n x 2 x f16
236  nxv4f16 = 158, // n x 4 x f16
237  nxv8f16 = 159, // n x 8 x f16
238  nxv16f16 = 160, // n x 16 x f16
239  nxv32f16 = 161, // n x 32 x f16
240 
241  nxv1bf16 = 162, // n x 1 x bf16
242  nxv2bf16 = 163, // n x 2 x bf16
243  nxv4bf16 = 164, // n x 4 x bf16
244  nxv8bf16 = 165, // n x 8 x bf16
245  nxv16bf16 = 166, // n x 16 x bf16
246  nxv32bf16 = 167, // n x 32 x bf16
247 
248  nxv1f32 = 168, // n x 1 x f32
249  nxv2f32 = 169, // n x 2 x f32
250  nxv4f32 = 170, // n x 4 x f32
251  nxv8f32 = 171, // n x 8 x f32
252  nxv16f32 = 172, // n x 16 x f32
253 
254  nxv1f64 = 173, // n x 1 x f64
255  nxv2f64 = 174, // n x 2 x f64
256  nxv4f64 = 175, // n x 4 x f64
257  nxv8f64 = 176, // n x 8 x f64
258 
261 
264 
267 
268  x86mmx = 177, // This is an X86 MMX value
269 
270  Glue = 178, // This glues nodes together during pre-RA sched
271 
272  isVoid = 179, // This has no value
273 
274  Untyped = 180, // This value takes a register, but has
275  // unspecified type. The register class
276  // will be determined by the opcode.
277 
278  funcref = 181, // WebAssembly's funcref type
279  externref = 182, // WebAssembly's externref type
280  x86amx = 183, // This is an X86 AMX value
281  i64x8 = 184, // 8 Consecutive GPRs (AArch64)
282 
283  FIRST_VALUETYPE = 1, // This is always the beginning of the list.
284  LAST_VALUETYPE = i64x8, // This always remains at the end of the list.
286 
287  // This is the current maximum for LAST_VALUETYPE.
288  // MVT::MAX_ALLOWED_VALUETYPE is used for asserts and to size bit vectors
289  // This value must be a multiple of 32.
291 
292  // A value of type llvm::TokenTy
293  token = 248,
294 
295  // This is MDNode or MDString.
296  Metadata = 249,
297 
298  // An int value the size of the pointer of the current
299  // target to any address space. This must only be used internal to
300  // tblgen. Other than for overloading, we treat iPTRAny the same as iPTR.
301  iPTRAny = 250,
302 
303  // A vector with any length and element size. This is used
304  // for intrinsics that have overloadings based on vector types.
305  // This is only for tblgen's consumption!
306  vAny = 251,
307 
308  // Any floating-point or vector floating-point value. This is used
309  // for intrinsics that have overloadings based on floating-point types.
310  // This is only for tblgen's consumption!
311  fAny = 252,
312 
313  // An integer or vector integer value of any bit width. This is
314  // used for intrinsics that have overloadings based on integer bit widths.
315  // This is only for tblgen's consumption!
316  iAny = 253,
317 
318  // An int value the size of the pointer of the current
319  // target. This should only be used internal to tblgen!
320  iPTR = 254,
321 
322  // Any type. This is used for intrinsics that have overloadings.
323  // This is only for tblgen's consumption!
324  Any = 255
325 
326  // clang-format on
327  };
328 
330 
331  constexpr MVT() = default;
332  constexpr MVT(SimpleValueType SVT) : SimpleTy(SVT) {}
333 
334  bool operator>(const MVT& S) const { return SimpleTy > S.SimpleTy; }
335  bool operator<(const MVT& S) const { return SimpleTy < S.SimpleTy; }
336  bool operator==(const MVT& S) const { return SimpleTy == S.SimpleTy; }
337  bool operator!=(const MVT& S) const { return SimpleTy != S.SimpleTy; }
338  bool operator>=(const MVT& S) const { return SimpleTy >= S.SimpleTy; }
339  bool operator<=(const MVT& S) const { return SimpleTy <= S.SimpleTy; }
340 
341  /// Return true if this is a valid simple valuetype.
342  bool isValid() const {
343  return (SimpleTy >= MVT::FIRST_VALUETYPE &&
345  }
346 
347  /// Return true if this is a FP or a vector FP type.
348  bool isFloatingPoint() const {
349  return ((SimpleTy >= MVT::FIRST_FP_VALUETYPE &&
355  }
356 
357  /// Return true if this is an integer or a vector integer type.
358  bool isInteger() const {
365  }
366 
367  /// Return true if this is an integer, not including vectors.
368  bool isScalarInteger() const {
371  }
372 
373  /// Return true if this is a vector value type.
374  bool isVector() const {
377  }
378 
379  /// Return true if this is a vector value type where the
380  /// runtime length is machine dependent
381  bool isScalableVector() const {
384  }
385 
386  bool isFixedLengthVector() const {
389  }
390 
391  /// Return true if this is a 16-bit vector type.
392  bool is16BitVector() const {
393  return (SimpleTy == MVT::v2i8 || SimpleTy == MVT::v1i16 ||
395  }
396 
397  /// Return true if this is a 32-bit vector type.
398  bool is32BitVector() const {
399  return (SimpleTy == MVT::v32i1 || SimpleTy == MVT::v4i8 ||
402  SimpleTy == MVT::v1f32);
403  }
404 
405  /// Return true if this is a 64-bit vector type.
406  bool is64BitVector() const {
407  return (SimpleTy == MVT::v64i1 || SimpleTy == MVT::v8i8 ||
411  SimpleTy == MVT::v1f64);
412  }
413 
414  /// Return true if this is a 128-bit vector type.
415  bool is128BitVector() const {
416  return (SimpleTy == MVT::v128i1 || SimpleTy == MVT::v16i8 ||
421  }
422 
423  /// Return true if this is a 256-bit vector type.
424  bool is256BitVector() const {
425  return (SimpleTy == MVT::v16f16 || SimpleTy == MVT::v16bf16 ||
430  SimpleTy == MVT::v64i4);
431  }
432 
433  /// Return true if this is a 512-bit vector type.
434  bool is512BitVector() const {
435  return (SimpleTy == MVT::v32f16 || SimpleTy == MVT::v32bf16 ||
439  SimpleTy == MVT::v8i64);
440  }
441 
442  /// Return true if this is a 1024-bit vector type.
443  bool is1024BitVector() const {
444  return (SimpleTy == MVT::v1024i1 || SimpleTy == MVT::v128i8 ||
449  }
450 
451  /// Return true if this is a 2048-bit vector type.
452  bool is2048BitVector() const {
453  return (SimpleTy == MVT::v256i8 || SimpleTy == MVT::v128i16 ||
457  }
458 
459  /// Return true if this is an overloaded type for TableGen.
460  bool isOverloaded() const {
461  return (SimpleTy == MVT::Any || SimpleTy == MVT::iAny ||
464  }
465 
466  /// Return a vector with the same number of elements as this vector, but
467  /// with the element type converted to an integer type with the same
468  /// bitwidth.
470  MVT EltTy = getVectorElementType();
471  MVT IntTy = MVT::getIntegerVT(EltTy.getSizeInBits());
472  MVT VecTy = MVT::getVectorVT(IntTy, getVectorElementCount());
474  "Simple vector VT not representable by simple integer vector VT!");
475  return VecTy;
476  }
477 
478  /// Return a VT for a vector type whose attributes match ourselves
479  /// with the exception of the element type that is chosen by the caller.
481  MVT VecTy = MVT::getVectorVT(EltVT, getVectorElementCount());
483  "Simple vector VT not representable by simple integer vector VT!");
484  return VecTy;
485  }
486 
487  /// Return the type converted to an equivalently sized integer or vector
488  /// with integer element type. Similar to changeVectorElementTypeToInteger,
489  /// but also handles scalars.
491  if (isVector())
494  }
495 
496  /// Return a VT for a vector type with the same element type but
497  /// half the number of elements.
499  MVT EltVT = getVectorElementType();
500  auto EltCnt = getVectorElementCount();
501  assert(EltCnt.isKnownEven() && "Splitting vector, but not in half!");
502  return getVectorVT(EltVT, EltCnt.divideCoefficientBy(2));
503  }
504 
505  /// Returns true if the given vector is a power of 2.
506  bool isPow2VectorType() const {
507  unsigned NElts = getVectorMinNumElements();
508  return !(NElts & (NElts - 1));
509  }
510 
511  /// Widens the length of the given vector MVT up to the nearest power of 2
512  /// and returns that type.
514  if (isPow2VectorType())
515  return *this;
516 
518  unsigned NewMinCount = 1 << Log2_32_Ceil(NElts.getKnownMinValue());
519  NElts = ElementCount::get(NewMinCount, NElts.isScalable());
520  return MVT::getVectorVT(getVectorElementType(), NElts);
521  }
522 
523  /// If this is a vector, return the element type, otherwise return this.
524  MVT getScalarType() const {
525  return isVector() ? getVectorElementType() : *this;
526  }
527 
529  // clang-format off
530  switch (SimpleTy) {
531  default:
532  llvm_unreachable("Not a vector MVT!");
533  case v1i1:
534  case v2i1:
535  case v4i1:
536  case v8i1:
537  case v16i1:
538  case v32i1:
539  case v64i1:
540  case v128i1:
541  case v256i1:
542  case v512i1:
543  case v1024i1:
544  case nxv1i1:
545  case nxv2i1:
546  case nxv4i1:
547  case nxv8i1:
548  case nxv16i1:
549  case nxv32i1:
550  case nxv64i1: return i1;
551  case v128i2: return i2;
552  case v64i4: return i4;
553  case v1i8:
554  case v2i8:
555  case v4i8:
556  case v8i8:
557  case v16i8:
558  case v32i8:
559  case v64i8:
560  case v128i8:
561  case v256i8:
562  case v512i8:
563  case v1024i8:
564  case nxv1i8:
565  case nxv2i8:
566  case nxv4i8:
567  case nxv8i8:
568  case nxv16i8:
569  case nxv32i8:
570  case nxv64i8: return i8;
571  case v1i16:
572  case v2i16:
573  case v3i16:
574  case v4i16:
575  case v8i16:
576  case v16i16:
577  case v32i16:
578  case v64i16:
579  case v128i16:
580  case v256i16:
581  case v512i16:
582  case nxv1i16:
583  case nxv2i16:
584  case nxv4i16:
585  case nxv8i16:
586  case nxv16i16:
587  case nxv32i16: return i16;
588  case v1i32:
589  case v2i32:
590  case v3i32:
591  case v4i32:
592  case v5i32:
593  case v6i32:
594  case v7i32:
595  case v8i32:
596  case v16i32:
597  case v32i32:
598  case v64i32:
599  case v128i32:
600  case v256i32:
601  case v512i32:
602  case v1024i32:
603  case v2048i32:
604  case nxv1i32:
605  case nxv2i32:
606  case nxv4i32:
607  case nxv8i32:
608  case nxv16i32:
609  case nxv32i32: return i32;
610  case v1i64:
611  case v2i64:
612  case v3i64:
613  case v4i64:
614  case v8i64:
615  case v16i64:
616  case v32i64:
617  case v64i64:
618  case v128i64:
619  case v256i64:
620  case nxv1i64:
621  case nxv2i64:
622  case nxv4i64:
623  case nxv8i64:
624  case nxv16i64:
625  case nxv32i64: return i64;
626  case v1i128: return i128;
627  case v1f16:
628  case v2f16:
629  case v3f16:
630  case v4f16:
631  case v8f16:
632  case v16f16:
633  case v32f16:
634  case v64f16:
635  case v128f16:
636  case v256f16:
637  case v512f16:
638  case nxv1f16:
639  case nxv2f16:
640  case nxv4f16:
641  case nxv8f16:
642  case nxv16f16:
643  case nxv32f16: return f16;
644  case v2bf16:
645  case v3bf16:
646  case v4bf16:
647  case v8bf16:
648  case v16bf16:
649  case v32bf16:
650  case v64bf16:
651  case v128bf16:
652  case nxv1bf16:
653  case nxv2bf16:
654  case nxv4bf16:
655  case nxv8bf16:
656  case nxv16bf16:
657  case nxv32bf16: return bf16;
658  case v1f32:
659  case v2f32:
660  case v3f32:
661  case v4f32:
662  case v5f32:
663  case v6f32:
664  case v7f32:
665  case v8f32:
666  case v16f32:
667  case v32f32:
668  case v64f32:
669  case v128f32:
670  case v256f32:
671  case v512f32:
672  case v1024f32:
673  case v2048f32:
674  case nxv1f32:
675  case nxv2f32:
676  case nxv4f32:
677  case nxv8f32:
678  case nxv16f32: return f32;
679  case v1f64:
680  case v2f64:
681  case v3f64:
682  case v4f64:
683  case v8f64:
684  case v16f64:
685  case v32f64:
686  case v64f64:
687  case v128f64:
688  case v256f64:
689  case nxv1f64:
690  case nxv2f64:
691  case nxv4f64:
692  case nxv8f64: return f64;
693  }
694  // clang-format on
695  }
696 
697  /// Given a vector type, return the minimum number of elements it contains.
698  unsigned getVectorMinNumElements() const {
699  switch (SimpleTy) {
700  default:
701  llvm_unreachable("Not a vector MVT!");
702  case v2048i32:
703  case v2048f32: return 2048;
704  case v1024i1:
705  case v1024i8:
706  case v1024i32:
707  case v1024f32: return 1024;
708  case v512i1:
709  case v512i8:
710  case v512i16:
711  case v512i32:
712  case v512f16:
713  case v512f32: return 512;
714  case v256i1:
715  case v256i8:
716  case v256i16:
717  case v256f16:
718  case v256i32:
719  case v256i64:
720  case v256f32:
721  case v256f64: return 256;
722  case v128i1:
723  case v128i2:
724  case v128i8:
725  case v128i16:
726  case v128i32:
727  case v128i64:
728  case v128f16:
729  case v128bf16:
730  case v128f32:
731  case v128f64: return 128;
732  case v64i1:
733  case v64i4:
734  case v64i8:
735  case v64i16:
736  case v64i32:
737  case v64i64:
738  case v64f16:
739  case v64bf16:
740  case v64f32:
741  case v64f64:
742  case nxv64i1:
743  case nxv64i8: return 64;
744  case v32i1:
745  case v32i8:
746  case v32i16:
747  case v32i32:
748  case v32i64:
749  case v32f16:
750  case v32bf16:
751  case v32f32:
752  case v32f64:
753  case nxv32i1:
754  case nxv32i8:
755  case nxv32i16:
756  case nxv32i32:
757  case nxv32i64:
758  case nxv32f16:
759  case nxv32bf16: return 32;
760  case v16i1:
761  case v16i8:
762  case v16i16:
763  case v16i32:
764  case v16i64:
765  case v16f16:
766  case v16bf16:
767  case v16f32:
768  case v16f64:
769  case nxv16i1:
770  case nxv16i8:
771  case nxv16i16:
772  case nxv16i32:
773  case nxv16i64:
774  case nxv16f16:
775  case nxv16bf16:
776  case nxv16f32: return 16;
777  case v8i1:
778  case v8i8:
779  case v8i16:
780  case v8i32:
781  case v8i64:
782  case v8f16:
783  case v8bf16:
784  case v8f32:
785  case v8f64:
786  case nxv8i1:
787  case nxv8i8:
788  case nxv8i16:
789  case nxv8i32:
790  case nxv8i64:
791  case nxv8f16:
792  case nxv8bf16:
793  case nxv8f32:
794  case nxv8f64: return 8;
795  case v7i32:
796  case v7f32: return 7;
797  case v6i32:
798  case v6f32: return 6;
799  case v5i32:
800  case v5f32: return 5;
801  case v4i1:
802  case v4i8:
803  case v4i16:
804  case v4i32:
805  case v4i64:
806  case v4f16:
807  case v4bf16:
808  case v4f32:
809  case v4f64:
810  case nxv4i1:
811  case nxv4i8:
812  case nxv4i16:
813  case nxv4i32:
814  case nxv4i64:
815  case nxv4f16:
816  case nxv4bf16:
817  case nxv4f32:
818  case nxv4f64: return 4;
819  case v3i16:
820  case v3i32:
821  case v3i64:
822  case v3f16:
823  case v3bf16:
824  case v3f32:
825  case v3f64: return 3;
826  case v2i1:
827  case v2i8:
828  case v2i16:
829  case v2i32:
830  case v2i64:
831  case v2f16:
832  case v2bf16:
833  case v2f32:
834  case v2f64:
835  case nxv2i1:
836  case nxv2i8:
837  case nxv2i16:
838  case nxv2i32:
839  case nxv2i64:
840  case nxv2f16:
841  case nxv2bf16:
842  case nxv2f32:
843  case nxv2f64: return 2;
844  case v1i1:
845  case v1i8:
846  case v1i16:
847  case v1i32:
848  case v1i64:
849  case v1i128:
850  case v1f16:
851  case v1f32:
852  case v1f64:
853  case nxv1i1:
854  case nxv1i8:
855  case nxv1i16:
856  case nxv1i32:
857  case nxv1i64:
858  case nxv1f16:
859  case nxv1bf16:
860  case nxv1f32:
861  case nxv1f64: return 1;
862  }
863  }
864 
867  }
868 
869  unsigned getVectorNumElements() const {
870  if (isScalableVector())
872  "Possible incorrect use of MVT::getVectorNumElements() for "
873  "scalable vector. Scalable flag may be dropped, use "
874  "MVT::getVectorElementCount() instead");
875  return getVectorMinNumElements();
876  }
877 
878  /// Returns the size of the specified MVT in bits.
879  ///
880  /// If the value type is a scalable vector type, the scalable property will
881  /// be set and the runtime size will be a positive integer multiple of the
882  /// base size.
884  switch (SimpleTy) {
885  default:
886  llvm_unreachable("getSizeInBits called on extended MVT.");
887  case Other:
888  llvm_unreachable("Value type is non-standard value, Other.");
889  case iPTR:
890  llvm_unreachable("Value type size is target-dependent. Ask TLI.");
891  case iPTRAny:
892  case iAny:
893  case fAny:
894  case vAny:
895  case Any:
896  llvm_unreachable("Value type is overloaded.");
897  case token:
898  llvm_unreachable("Token type is a sentinel that cannot be used "
899  "in codegen and has no size");
900  case Metadata:
901  llvm_unreachable("Value type is metadata.");
902  case i1:
903  case v1i1: return TypeSize::Fixed(1);
904  case nxv1i1: return TypeSize::Scalable(1);
905  case i2:
906  case v2i1: return TypeSize::Fixed(2);
907  case nxv2i1: return TypeSize::Scalable(2);
908  case i4:
909  case v4i1: return TypeSize::Fixed(4);
910  case nxv4i1: return TypeSize::Scalable(4);
911  case i8 :
912  case v1i8:
913  case v8i1: return TypeSize::Fixed(8);
914  case nxv1i8:
915  case nxv8i1: return TypeSize::Scalable(8);
916  case i16 :
917  case f16:
918  case bf16:
919  case v16i1:
920  case v2i8:
921  case v1i16:
922  case v1f16: return TypeSize::Fixed(16);
923  case nxv16i1:
924  case nxv2i8:
925  case nxv1i16:
926  case nxv1bf16:
927  case nxv1f16: return TypeSize::Scalable(16);
928  case f32 :
929  case i32 :
930  case v32i1:
931  case v4i8:
932  case v2i16:
933  case v2f16:
934  case v2bf16:
935  case v1f32:
936  case v1i32: return TypeSize::Fixed(32);
937  case nxv32i1:
938  case nxv4i8:
939  case nxv2i16:
940  case nxv1i32:
941  case nxv2f16:
942  case nxv2bf16:
943  case nxv1f32: return TypeSize::Scalable(32);
944  case v3i16:
945  case v3f16:
946  case v3bf16: return TypeSize::Fixed(48);
947  case x86mmx:
948  case f64 :
949  case i64 :
950  case v64i1:
951  case v8i8:
952  case v4i16:
953  case v2i32:
954  case v1i64:
955  case v4f16:
956  case v4bf16:
957  case v2f32:
958  case v1f64: return TypeSize::Fixed(64);
959  case nxv64i1:
960  case nxv8i8:
961  case nxv4i16:
962  case nxv2i32:
963  case nxv1i64:
964  case nxv4f16:
965  case nxv4bf16:
966  case nxv2f32:
967  case nxv1f64: return TypeSize::Scalable(64);
968  case f80 : return TypeSize::Fixed(80);
969  case v3i32:
970  case v3f32: return TypeSize::Fixed(96);
971  case f128:
972  case ppcf128:
973  case i128:
974  case v128i1:
975  case v16i8:
976  case v8i16:
977  case v4i32:
978  case v2i64:
979  case v1i128:
980  case v8f16:
981  case v8bf16:
982  case v4f32:
983  case v2f64: return TypeSize::Fixed(128);
984  case nxv16i8:
985  case nxv8i16:
986  case nxv4i32:
987  case nxv2i64:
988  case nxv8f16:
989  case nxv8bf16:
990  case nxv4f32:
991  case nxv2f64: return TypeSize::Scalable(128);
992  case v5i32:
993  case v5f32: return TypeSize::Fixed(160);
994  case v6i32:
995  case v3i64:
996  case v6f32:
997  case v3f64: return TypeSize::Fixed(192);
998  case v7i32:
999  case v7f32: return TypeSize::Fixed(224);
1000  case v256i1:
1001  case v128i2:
1002  case v64i4:
1003  case v32i8:
1004  case v16i16:
1005  case v8i32:
1006  case v4i64:
1007  case v16f16:
1008  case v16bf16:
1009  case v8f32:
1010  case v4f64: return TypeSize::Fixed(256);
1011  case nxv32i8:
1012  case nxv16i16:
1013  case nxv8i32:
1014  case nxv4i64:
1015  case nxv16f16:
1016  case nxv16bf16:
1017  case nxv8f32:
1018  case nxv4f64: return TypeSize::Scalable(256);
1019  case i64x8:
1020  case v512i1:
1021  case v64i8:
1022  case v32i16:
1023  case v16i32:
1024  case v8i64:
1025  case v32f16:
1026  case v32bf16:
1027  case v16f32:
1028  case v8f64: return TypeSize::Fixed(512);
1029  case nxv64i8:
1030  case nxv32i16:
1031  case nxv16i32:
1032  case nxv8i64:
1033  case nxv32f16:
1034  case nxv32bf16:
1035  case nxv16f32:
1036  case nxv8f64: return TypeSize::Scalable(512);
1037  case v1024i1:
1038  case v128i8:
1039  case v64i16:
1040  case v32i32:
1041  case v16i64:
1042  case v64f16:
1043  case v64bf16:
1044  case v32f32:
1045  case v16f64: return TypeSize::Fixed(1024);
1046  case nxv32i32:
1047  case nxv16i64: return TypeSize::Scalable(1024);
1048  case v256i8:
1049  case v128i16:
1050  case v64i32:
1051  case v32i64:
1052  case v128f16:
1053  case v128bf16:
1054  case v64f32:
1055  case v32f64: return TypeSize::Fixed(2048);
1056  case nxv32i64: return TypeSize::Scalable(2048);
1057  case v512i8:
1058  case v256i16:
1059  case v128i32:
1060  case v64i64:
1061  case v256f16:
1062  case v128f32:
1063  case v64f64: return TypeSize::Fixed(4096);
1064  case v1024i8:
1065  case v512i16:
1066  case v256i32:
1067  case v128i64:
1068  case v512f16:
1069  case v256f32:
1070  case x86amx:
1071  case v128f64: return TypeSize::Fixed(8192);
1072  case v512i32:
1073  case v256i64:
1074  case v512f32:
1075  case v256f64: return TypeSize::Fixed(16384);
1076  case v1024i32:
1077  case v1024f32: return TypeSize::Fixed(32768);
1078  case v2048i32:
1079  case v2048f32: return TypeSize::Fixed(65536);
1080  case funcref:
1081  case externref: return TypeSize::Fixed(0); // opaque type
1082  }
1083  }
1084 
1085  /// Return the size of the specified fixed width value type in bits. The
1086  /// function will assert if the type is scalable.
1088  return getSizeInBits().getFixedSize();
1089  }
1090 
1093  }
1094 
1095  /// Return the number of bytes overwritten by a store of the specified value
1096  /// type.
1097  ///
1098  /// If the value type is a scalable vector type, the scalable property will
1099  /// be set and the runtime size will be a positive integer multiple of the
1100  /// base size.
1102  TypeSize BaseSize = getSizeInBits();
1103  return {(BaseSize.getKnownMinSize() + 7) / 8, BaseSize.isScalable()};
1104  }
1105 
1106  // Return the number of bytes overwritten by a store of this value type or
1107  // this value type's element type in the case of a vector.
1110  }
1111 
1112  /// Return the number of bits overwritten by a store of the specified value
1113  /// type.
1114  ///
1115  /// If the value type is a scalable vector type, the scalable property will
1116  /// be set and the runtime size will be a positive integer multiple of the
1117  /// base size.
1119  return getStoreSize() * 8;
1120  }
1121 
1122  /// Returns true if the number of bits for the type is a multiple of an
1123  /// 8-bit byte.
1124  bool isByteSized() const { return getSizeInBits().isKnownMultipleOf(8); }
1125 
1126  /// Return true if we know at compile time this has more bits than VT.
1127  bool knownBitsGT(MVT VT) const {
1129  }
1130 
1131  /// Return true if we know at compile time this has more than or the same
1132  /// bits as VT.
1133  bool knownBitsGE(MVT VT) const {
1135  }
1136 
1137  /// Return true if we know at compile time this has fewer bits than VT.
1138  bool knownBitsLT(MVT VT) const {
1140  }
1141 
1142  /// Return true if we know at compile time this has fewer than or the same
1143  /// bits as VT.
1144  bool knownBitsLE(MVT VT) const {
1146  }
1147 
1148  /// Return true if this has more bits than VT.
1149  bool bitsGT(MVT VT) const {
1151  "Comparison between scalable and fixed types");
1152  return knownBitsGT(VT);
1153  }
1154 
1155  /// Return true if this has no less bits than VT.
1156  bool bitsGE(MVT VT) const {
1158  "Comparison between scalable and fixed types");
1159  return knownBitsGE(VT);
1160  }
1161 
1162  /// Return true if this has less bits than VT.
1163  bool bitsLT(MVT VT) const {
1165  "Comparison between scalable and fixed types");
1166  return knownBitsLT(VT);
1167  }
1168 
1169  /// Return true if this has no more bits than VT.
1170  bool bitsLE(MVT VT) const {
1172  "Comparison between scalable and fixed types");
1173  return knownBitsLE(VT);
1174  }
1175 
1176  static MVT getFloatingPointVT(unsigned BitWidth) {
1177  switch (BitWidth) {
1178  default:
1179  llvm_unreachable("Bad bit width!");
1180  case 16:
1181  return MVT::f16;
1182  case 32:
1183  return MVT::f32;
1184  case 64:
1185  return MVT::f64;
1186  case 80:
1187  return MVT::f80;
1188  case 128:
1189  return MVT::f128;
1190  }
1191  }
1192 
1193  static MVT getIntegerVT(unsigned BitWidth) {
1194  switch (BitWidth) {
1195  default:
1197  case 1:
1198  return MVT::i1;
1199  case 2:
1200  return MVT::i2;
1201  case 4:
1202  return MVT::i4;
1203  case 8:
1204  return MVT::i8;
1205  case 16:
1206  return MVT::i16;
1207  case 32:
1208  return MVT::i32;
1209  case 64:
1210  return MVT::i64;
1211  case 128:
1212  return MVT::i128;
1213  }
1214  }
1215 
1216  static MVT getVectorVT(MVT VT, unsigned NumElements) {
1217  // clang-format off
1218  switch (VT.SimpleTy) {
1219  default:
1220  break;
1221  case MVT::i1:
1222  if (NumElements == 1) return MVT::v1i1;
1223  if (NumElements == 2) return MVT::v2i1;
1224  if (NumElements == 4) return MVT::v4i1;
1225  if (NumElements == 8) return MVT::v8i1;
1226  if (NumElements == 16) return MVT::v16i1;
1227  if (NumElements == 32) return MVT::v32i1;
1228  if (NumElements == 64) return MVT::v64i1;
1229  if (NumElements == 128) return MVT::v128i1;
1230  if (NumElements == 256) return MVT::v256i1;
1231  if (NumElements == 512) return MVT::v512i1;
1232  if (NumElements == 1024) return MVT::v1024i1;
1233  break;
1234  case MVT::i2:
1235  if (NumElements == 128) return MVT::v128i2;
1236  break;
1237  case MVT::i4:
1238  if (NumElements == 64) return MVT::v64i4;
1239  break;
1240  case MVT::i8:
1241  if (NumElements == 1) return MVT::v1i8;
1242  if (NumElements == 2) return MVT::v2i8;
1243  if (NumElements == 4) return MVT::v4i8;
1244  if (NumElements == 8) return MVT::v8i8;
1245  if (NumElements == 16) return MVT::v16i8;
1246  if (NumElements == 32) return MVT::v32i8;
1247  if (NumElements == 64) return MVT::v64i8;
1248  if (NumElements == 128) return MVT::v128i8;
1249  if (NumElements == 256) return MVT::v256i8;
1250  if (NumElements == 512) return MVT::v512i8;
1251  if (NumElements == 1024) return MVT::v1024i8;
1252  break;
1253  case MVT::i16:
1254  if (NumElements == 1) return MVT::v1i16;
1255  if (NumElements == 2) return MVT::v2i16;
1256  if (NumElements == 3) return MVT::v3i16;
1257  if (NumElements == 4) return MVT::v4i16;
1258  if (NumElements == 8) return MVT::v8i16;
1259  if (NumElements == 16) return MVT::v16i16;
1260  if (NumElements == 32) return MVT::v32i16;
1261  if (NumElements == 64) return MVT::v64i16;
1262  if (NumElements == 128) return MVT::v128i16;
1263  if (NumElements == 256) return MVT::v256i16;
1264  if (NumElements == 512) return MVT::v512i16;
1265  break;
1266  case MVT::i32:
1267  if (NumElements == 1) return MVT::v1i32;
1268  if (NumElements == 2) return MVT::v2i32;
1269  if (NumElements == 3) return MVT::v3i32;
1270  if (NumElements == 4) return MVT::v4i32;
1271  if (NumElements == 5) return MVT::v5i32;
1272  if (NumElements == 6) return MVT::v6i32;
1273  if (NumElements == 7) return MVT::v7i32;
1274  if (NumElements == 8) return MVT::v8i32;
1275  if (NumElements == 16) return MVT::v16i32;
1276  if (NumElements == 32) return MVT::v32i32;
1277  if (NumElements == 64) return MVT::v64i32;
1278  if (NumElements == 128) return MVT::v128i32;
1279  if (NumElements == 256) return MVT::v256i32;
1280  if (NumElements == 512) return MVT::v512i32;
1281  if (NumElements == 1024) return MVT::v1024i32;
1282  if (NumElements == 2048) return MVT::v2048i32;
1283  break;
1284  case MVT::i64:
1285  if (NumElements == 1) return MVT::v1i64;
1286  if (NumElements == 2) return MVT::v2i64;
1287  if (NumElements == 3) return MVT::v3i64;
1288  if (NumElements == 4) return MVT::v4i64;
1289  if (NumElements == 8) return MVT::v8i64;
1290  if (NumElements == 16) return MVT::v16i64;
1291  if (NumElements == 32) return MVT::v32i64;
1292  if (NumElements == 64) return MVT::v64i64;
1293  if (NumElements == 128) return MVT::v128i64;
1294  if (NumElements == 256) return MVT::v256i64;
1295  break;
1296  case MVT::i128:
1297  if (NumElements == 1) return MVT::v1i128;
1298  break;
1299  case MVT::f16:
1300  if (NumElements == 1) return MVT::v1f16;
1301  if (NumElements == 2) return MVT::v2f16;
1302  if (NumElements == 3) return MVT::v3f16;
1303  if (NumElements == 4) return MVT::v4f16;
1304  if (NumElements == 8) return MVT::v8f16;
1305  if (NumElements == 16) return MVT::v16f16;
1306  if (NumElements == 32) return MVT::v32f16;
1307  if (NumElements == 64) return MVT::v64f16;
1308  if (NumElements == 128) return MVT::v128f16;
1309  if (NumElements == 256) return MVT::v256f16;
1310  if (NumElements == 512) return MVT::v512f16;
1311  break;
1312  case MVT::bf16:
1313  if (NumElements == 2) return MVT::v2bf16;
1314  if (NumElements == 3) return MVT::v3bf16;
1315  if (NumElements == 4) return MVT::v4bf16;
1316  if (NumElements == 8) return MVT::v8bf16;
1317  if (NumElements == 16) return MVT::v16bf16;
1318  if (NumElements == 32) return MVT::v32bf16;
1319  if (NumElements == 64) return MVT::v64bf16;
1320  if (NumElements == 128) return MVT::v128bf16;
1321  break;
1322  case MVT::f32:
1323  if (NumElements == 1) return MVT::v1f32;
1324  if (NumElements == 2) return MVT::v2f32;
1325  if (NumElements == 3) return MVT::v3f32;
1326  if (NumElements == 4) return MVT::v4f32;
1327  if (NumElements == 5) return MVT::v5f32;
1328  if (NumElements == 6) return MVT::v6f32;
1329  if (NumElements == 7) return MVT::v7f32;
1330  if (NumElements == 8) return MVT::v8f32;
1331  if (NumElements == 16) return MVT::v16f32;
1332  if (NumElements == 32) return MVT::v32f32;
1333  if (NumElements == 64) return MVT::v64f32;
1334  if (NumElements == 128) return MVT::v128f32;
1335  if (NumElements == 256) return MVT::v256f32;
1336  if (NumElements == 512) return MVT::v512f32;
1337  if (NumElements == 1024) return MVT::v1024f32;
1338  if (NumElements == 2048) return MVT::v2048f32;
1339  break;
1340  case MVT::f64:
1341  if (NumElements == 1) return MVT::v1f64;
1342  if (NumElements == 2) return MVT::v2f64;
1343  if (NumElements == 3) return MVT::v3f64;
1344  if (NumElements == 4) return MVT::v4f64;
1345  if (NumElements == 8) return MVT::v8f64;
1346  if (NumElements == 16) return MVT::v16f64;
1347  if (NumElements == 32) return MVT::v32f64;
1348  if (NumElements == 64) return MVT::v64f64;
1349  if (NumElements == 128) return MVT::v128f64;
1350  if (NumElements == 256) return MVT::v256f64;
1351  break;
1352  }
1354  // clang-format on
1355  }
1356 
1357  static MVT getScalableVectorVT(MVT VT, unsigned NumElements) {
1358  switch(VT.SimpleTy) {
1359  default:
1360  break;
1361  case MVT::i1:
1362  if (NumElements == 1) return MVT::nxv1i1;
1363  if (NumElements == 2) return MVT::nxv2i1;
1364  if (NumElements == 4) return MVT::nxv4i1;
1365  if (NumElements == 8) return MVT::nxv8i1;
1366  if (NumElements == 16) return MVT::nxv16i1;
1367  if (NumElements == 32) return MVT::nxv32i1;
1368  if (NumElements == 64) return MVT::nxv64i1;
1369  break;
1370  case MVT::i8:
1371  if (NumElements == 1) return MVT::nxv1i8;
1372  if (NumElements == 2) return MVT::nxv2i8;
1373  if (NumElements == 4) return MVT::nxv4i8;
1374  if (NumElements == 8) return MVT::nxv8i8;
1375  if (NumElements == 16) return MVT::nxv16i8;
1376  if (NumElements == 32) return MVT::nxv32i8;
1377  if (NumElements == 64) return MVT::nxv64i8;
1378  break;
1379  case MVT::i16:
1380  if (NumElements == 1) return MVT::nxv1i16;
1381  if (NumElements == 2) return MVT::nxv2i16;
1382  if (NumElements == 4) return MVT::nxv4i16;
1383  if (NumElements == 8) return MVT::nxv8i16;
1384  if (NumElements == 16) return MVT::nxv16i16;
1385  if (NumElements == 32) return MVT::nxv32i16;
1386  break;
1387  case MVT::i32:
1388  if (NumElements == 1) return MVT::nxv1i32;
1389  if (NumElements == 2) return MVT::nxv2i32;
1390  if (NumElements == 4) return MVT::nxv4i32;
1391  if (NumElements == 8) return MVT::nxv8i32;
1392  if (NumElements == 16) return MVT::nxv16i32;
1393  if (NumElements == 32) return MVT::nxv32i32;
1394  break;
1395  case MVT::i64:
1396  if (NumElements == 1) return MVT::nxv1i64;
1397  if (NumElements == 2) return MVT::nxv2i64;
1398  if (NumElements == 4) return MVT::nxv4i64;
1399  if (NumElements == 8) return MVT::nxv8i64;
1400  if (NumElements == 16) return MVT::nxv16i64;
1401  if (NumElements == 32) return MVT::nxv32i64;
1402  break;
1403  case MVT::f16:
1404  if (NumElements == 1) return MVT::nxv1f16;
1405  if (NumElements == 2) return MVT::nxv2f16;
1406  if (NumElements == 4) return MVT::nxv4f16;
1407  if (NumElements == 8) return MVT::nxv8f16;
1408  if (NumElements == 16) return MVT::nxv16f16;
1409  if (NumElements == 32) return MVT::nxv32f16;
1410  break;
1411  case MVT::bf16:
1412  if (NumElements == 1) return MVT::nxv1bf16;
1413  if (NumElements == 2) return MVT::nxv2bf16;
1414  if (NumElements == 4) return MVT::nxv4bf16;
1415  if (NumElements == 8) return MVT::nxv8bf16;
1416  if (NumElements == 16) return MVT::nxv16bf16;
1417  if (NumElements == 32) return MVT::nxv32bf16;
1418  break;
1419  case MVT::f32:
1420  if (NumElements == 1) return MVT::nxv1f32;
1421  if (NumElements == 2) return MVT::nxv2f32;
1422  if (NumElements == 4) return MVT::nxv4f32;
1423  if (NumElements == 8) return MVT::nxv8f32;
1424  if (NumElements == 16) return MVT::nxv16f32;
1425  break;
1426  case MVT::f64:
1427  if (NumElements == 1) return MVT::nxv1f64;
1428  if (NumElements == 2) return MVT::nxv2f64;
1429  if (NumElements == 4) return MVT::nxv4f64;
1430  if (NumElements == 8) return MVT::nxv8f64;
1431  break;
1432  }
1434  }
1435 
1436  static MVT getVectorVT(MVT VT, unsigned NumElements, bool IsScalable) {
1437  if (IsScalable)
1438  return getScalableVectorVT(VT, NumElements);
1439  return getVectorVT(VT, NumElements);
1440  }
1441 
1442  static MVT getVectorVT(MVT VT, ElementCount EC) {
1443  if (EC.isScalable())
1444  return getScalableVectorVT(VT, EC.getKnownMinValue());
1445  return getVectorVT(VT, EC.getKnownMinValue());
1446  }
1447 
1448  /// Return the value type corresponding to the specified type. This returns
1449  /// all pointers as iPTR. If HandleUnknown is true, unknown types are
1450  /// returned as Other, otherwise they are invalid.
1451  static MVT getVT(Type *Ty, bool HandleUnknown = false);
1452 
1453  public:
1454  /// SimpleValueType Iteration
1455  /// @{
1456  static auto all_valuetypes() {
1459  }
1460 
1461  static auto integer_valuetypes() {
1465  }
1466 
1467  static auto fp_valuetypes() {
1470  }
1471 
1472  static auto vector_valuetypes() {
1476  }
1477 
1482  }
1483 
1488  }
1489 
1494  }
1495 
1500  }
1501 
1506  }
1507 
1512  }
1513  /// @}
1514  };
1515 
1516 } // end namespace llvm
1517 
1518 #endif // LLVM_SUPPORT_MACHINEVALUETYPE_H
llvm::MVT::v3i16
@ v3i16
Definition: MachineValueType.h:96
llvm::MVT::nxv4i1
@ nxv4i1
Definition: MachineValueType.h:196
llvm::MVT::v1i16
@ v1i16
Definition: MachineValueType.h:94
llvm::MVT::FIRST_FP_SCALABLE_VECTOR_VALUETYPE
@ FIRST_FP_SCALABLE_VECTOR_VALUETYPE
Definition: MachineValueType.h:259
llvm::MVT::FIRST_INTEGER_SCALABLE_VECTOR_VALUETYPE
@ FIRST_INTEGER_SCALABLE_VECTOR_VALUETYPE
Definition: MachineValueType.h:231
llvm::MVT::nxv4i64
@ nxv4i64
Definition: MachineValueType.h:226
llvm::enum_seq_inclusive
auto enum_seq_inclusive(EnumT Begin, EnumT End)
Iterate over an enum type from Begin to End inclusive.
Definition: Sequence.h:355
llvm::MVT::v16bf16
@ v16bf16
Definition: MachineValueType.h:155
llvm::MVT::v512i16
@ v512i16
Definition: MachineValueType.h:104
llvm::MVT::getScalarStoreSize
uint64_t getScalarStoreSize() const
Definition: MachineValueType.h:1108
llvm::MVT::FIRST_SCALABLE_VECTOR_VALUETYPE
@ FIRST_SCALABLE_VECTOR_VALUETYPE
Definition: MachineValueType.h:262
llvm::MVT::nxv2i1
@ nxv2i1
Definition: MachineValueType.h:195
llvm::MVT::getVectorElementType
MVT getVectorElementType() const
Definition: MachineValueType.h:528
llvm::MVT::getStoreSize
TypeSize getStoreSize() const
Return the number of bytes overwritten by a store of the specified value type.
Definition: MachineValueType.h:1101
llvm::MVT::v4f16
@ v4f16
Definition: MachineValueType.h:142
llvm::MVT::v256f16
@ v256f16
Definition: MachineValueType.h:148
MathExtras.h
llvm
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:17
llvm::MVT::v128i1
@ v128i1
Definition: MachineValueType.h:73
llvm::MVT::nxv1i32
@ nxv1i32
Definition: MachineValueType.h:217
llvm::MVT::getFixedSizeInBits
uint64_t getFixedSizeInBits() const
Return the size of the specified fixed width value type in bits.
Definition: MachineValueType.h:1087
llvm::MVT::isByteSized
bool isByteSized() const
Returns true if the number of bits for the type is a multiple of an 8-bit byte.
Definition: MachineValueType.h:1124
llvm::MVT::nxv2f64
@ nxv2f64
Definition: MachineValueType.h:255
llvm::MVT::operator>=
bool operator>=(const MVT &S) const
Definition: MachineValueType.h:338
llvm::MVT::isFixedLengthVector
bool isFixedLengthVector() const
Definition: MachineValueType.h:386
llvm::MVT::LAST_FP_FIXEDLEN_VECTOR_VALUETYPE
@ LAST_FP_FIXEDLEN_VECTOR_VALUETYPE
Definition: MachineValueType.h:189
llvm::MVT::isInteger
bool isInteger() const
Return true if this is an integer or a vector integer type.
Definition: MachineValueType.h:358
llvm::MVT::v1f64
@ v1f64
Definition: MachineValueType.h:177
llvm::LinearPolySize< TypeSize >::isKnownGT
static bool isKnownGT(const LinearPolySize &LHS, const LinearPolySize &RHS)
Definition: TypeSize.h:334
llvm::ElementCount
Definition: TypeSize.h:404
llvm::MVT::v128i32
@ v128i32
Definition: MachineValueType.h:117
llvm::TypeSize::getFixedSize
ScalarTy getFixedSize() const
Definition: TypeSize.h:444
llvm::MVT::ppcf128
@ ppcf128
Definition: MachineValueType.h:61
llvm::MVT::v512i8
@ v512i8
Definition: MachineValueType.h:91
llvm::MVT::is256BitVector
bool is256BitVector() const
Return true if this is a 256-bit vector type.
Definition: MachineValueType.h:424
llvm::MVT::nxv32f16
@ nxv32f16
Definition: MachineValueType.h:239
llvm::MVT::v3f64
@ v3f64
Definition: MachineValueType.h:179
llvm::MVT::v32f64
@ v32f64
Definition: MachineValueType.h:183
llvm::MVT::i128
@ i128
Definition: MachineValueType.h:50
llvm::MVT::nxv2f32
@ nxv2f32
Definition: MachineValueType.h:249
llvm::MVT::nxv16f16
@ nxv16f16
Definition: MachineValueType.h:238
llvm::MVT::v16f64
@ v16f64
Definition: MachineValueType.h:182
TypeSize.h
llvm::MVT::bitsLT
bool bitsLT(MVT VT) const
Return true if this has less bits than VT.
Definition: MachineValueType.h:1163
llvm::LinearPolySize< TypeSize >::isKnownLE
static bool isKnownLE(const LinearPolySize &LHS, const LinearPolySize &RHS)
Definition: TypeSize.h:340
llvm::MVT::isVector
bool isVector() const
Return true if this is a vector value type.
Definition: MachineValueType.h:374
llvm::MVT::nxv1f64
@ nxv1f64
Definition: MachineValueType.h:254
llvm::MVT::v64f32
@ v64f32
Definition: MachineValueType.h:170
llvm::MVT::v2i1
@ v2i1
Definition: MachineValueType.h:67
ErrorHandling.h
llvm::MVT::v64i64
@ v64i64
Definition: MachineValueType.h:130
llvm::MVT::v512i32
@ v512i32
Definition: MachineValueType.h:119
llvm::MVT::nxv2i64
@ nxv2i64
Definition: MachineValueType.h:225
llvm::MVT::FIRST_FP_VALUETYPE
@ FIRST_FP_VALUETYPE
Definition: MachineValueType.h:63
llvm::MVT::Glue
@ Glue
Definition: MachineValueType.h:270
llvm::MVT::fAny
@ fAny
Definition: MachineValueType.h:311
llvm::MVT::v64f16
@ v64f16
Definition: MachineValueType.h:146
llvm::MVT::nxv4f16
@ nxv4f16
Definition: MachineValueType.h:236
llvm::Type
The instances of the Type class are immutable: once they are created, they are never changed.
Definition: Type.h:45
llvm::MVT::LAST_INTEGER_FIXEDLEN_VECTOR_VALUETYPE
@ LAST_INTEGER_FIXEDLEN_VECTOR_VALUETYPE
Definition: MachineValueType.h:137
llvm::MVT::knownBitsGT
bool knownBitsGT(MVT VT) const
Return true if we know at compile time this has more bits than VT.
Definition: MachineValueType.h:1127
llvm::MVT::fp_fixedlen_vector_valuetypes
static auto fp_fixedlen_vector_valuetypes()
Definition: MachineValueType.h:1496
llvm::MVT::scalable_vector_valuetypes
static auto scalable_vector_valuetypes()
Definition: MachineValueType.h:1484
llvm::MVT::nxv4f64
@ nxv4f64
Definition: MachineValueType.h:256
llvm::MVT::getPow2VectorType
MVT getPow2VectorType() const
Widens the length of the given vector MVT up to the nearest power of 2 and returns that type.
Definition: MachineValueType.h:513
llvm::MVT::v256i32
@ v256i32
Definition: MachineValueType.h:118
llvm::MVT::v2048i32
@ v2048i32
Definition: MachineValueType.h:121
llvm::MVT::LAST_VECTOR_VALUETYPE
@ LAST_VECTOR_VALUETYPE
Definition: MachineValueType.h:266
llvm::MVT::i4
@ i4
Definition: MachineValueType.h:45
llvm::MVT::v2f64
@ v2f64
Definition: MachineValueType.h:178
Sequence.h
llvm::MVT::LAST_FIXEDLEN_VECTOR_VALUETYPE
@ LAST_FIXEDLEN_VECTOR_VALUETYPE
Definition: MachineValueType.h:192
llvm::MVT::v3f16
@ v3f16
Definition: MachineValueType.h:141
llvm::MVT::nxv8i16
@ nxv8i16
Definition: MachineValueType.h:213
llvm::LinearPolySize::isScalable
bool isScalable() const
Returns whether the size is scaled by a runtime quantity (vscale).
Definition: TypeSize.h:298
llvm::MVT::is32BitVector
bool is32BitVector() const
Return true if this is a 32-bit vector type.
Definition: MachineValueType.h:398
llvm::MVT::nxv32i16
@ nxv32i16
Definition: MachineValueType.h:215
llvm::LinearPolySize< TypeSize >::isKnownLT
static bool isKnownLT(const LinearPolySize &LHS, const LinearPolySize &RHS)
Definition: TypeSize.h:328
llvm::MVT::v128bf16
@ v128bf16
Definition: MachineValueType.h:158
llvm::MVT::isScalableVector
bool isScalableVector() const
Return true if this is a vector value type where the runtime length is machine dependent.
Definition: MachineValueType.h:381
llvm::MVT::nxv8bf16
@ nxv8bf16
Definition: MachineValueType.h:244
llvm::MVT::SimpleValueType
SimpleValueType
Definition: MachineValueType.h:33
llvm::MVT::isValid
bool isValid() const
Return true if this is a valid simple valuetype.
Definition: MachineValueType.h:342
llvm::TypeSize::Scalable
static TypeSize Scalable(ScalarTy MinVal)
Definition: TypeSize.h:442
llvm::MVT::v4bf16
@ v4bf16
Definition: MachineValueType.h:153
llvm::MVT::integer_valuetypes
static auto integer_valuetypes()
Definition: MachineValueType.h:1461
llvm::MVT::funcref
@ funcref
Definition: MachineValueType.h:278
llvm::MVT::v256f32
@ v256f32
Definition: MachineValueType.h:172
llvm::MVT::MVT
constexpr MVT()=default
llvm::MVT::i1
@ i1
Definition: MachineValueType.h:43
llvm::MVT::nxv16f32
@ nxv16f32
Definition: MachineValueType.h:252
llvm::MVT::v8f16
@ v8f16
Definition: MachineValueType.h:143
llvm::MVT::operator<
bool operator<(const MVT &S) const
Definition: MachineValueType.h:335
llvm::LinearPolySize< ElementCount >::get
static ElementCount get(ScalarTy MinVal, bool Scalable)
Definition: TypeSize.h:289
llvm::MVT::v8f64
@ v8f64
Definition: MachineValueType.h:181
llvm::MVT::changeTypeToInteger
MVT changeTypeToInteger()
Return the type converted to an equivalently sized integer or vector with integer element type.
Definition: MachineValueType.h:490
llvm::MVT::knownBitsLE
bool knownBitsLE(MVT VT) const
Return true if we know at compile time this has fewer than or the same bits as VT.
Definition: MachineValueType.h:1144
llvm::MVT::nxv2bf16
@ nxv2bf16
Definition: MachineValueType.h:242
llvm::MVT::v7f32
@ v7f32
Definition: MachineValueType.h:166
llvm::MVT::operator<=
bool operator<=(const MVT &S) const
Definition: MachineValueType.h:339
llvm::MVT::v32bf16
@ v32bf16
Definition: MachineValueType.h:156
llvm::MVT::LAST_INTEGER_SCALABLE_VECTOR_VALUETYPE
@ LAST_INTEGER_SCALABLE_VECTOR_VALUETYPE
Definition: MachineValueType.h:232
llvm::MVT::v1f16
@ v1f16
Definition: MachineValueType.h:139
llvm::MVT::f64
@ f64
Definition: MachineValueType.h:58
llvm::MVT::integer_scalable_vector_valuetypes
static auto integer_scalable_vector_valuetypes()
Definition: MachineValueType.h:1502
llvm::MVT::x86amx
@ x86amx
Definition: MachineValueType.h:280
llvm::MVT::getScalarSizeInBits
uint64_t getScalarSizeInBits() const
Definition: MachineValueType.h:1091
llvm::MVT::i2
@ i2
Definition: MachineValueType.h:44
llvm::MVT::x86mmx
@ x86mmx
Definition: MachineValueType.h:268
llvm::MVT::SimpleTy
SimpleValueType SimpleTy
Definition: MachineValueType.h:329
llvm::MVT::v64i1
@ v64i1
Definition: MachineValueType.h:72
llvm::MVT::v64i32
@ v64i32
Definition: MachineValueType.h:116
llvm::MVT::nxv32i8
@ nxv32i8
Definition: MachineValueType.h:207
llvm::MVT::v16i1
@ v16i1
Definition: MachineValueType.h:70
llvm::MVT::nxv2f16
@ nxv2f16
Definition: MachineValueType.h:235
llvm::MVT::v256i16
@ v256i16
Definition: MachineValueType.h:103
llvm::TypeSize::Fixed
static TypeSize Fixed(ScalarTy MinVal)
Definition: TypeSize.h:441
llvm::MVT::v256f64
@ v256f64
Definition: MachineValueType.h:186
llvm::MVT::isVoid
@ isVoid
Definition: MachineValueType.h:272
llvm::MVT::bitsLE
bool bitsLE(MVT VT) const
Return true if this has no more bits than VT.
Definition: MachineValueType.h:1170
llvm::MVT::v8i1
@ v8i1
Definition: MachineValueType.h:69
llvm::MVT::v4f64
@ v4f64
Definition: MachineValueType.h:180
llvm::MVT::v1i1
@ v1i1
Definition: MachineValueType.h:66
llvm::MVT::v16f16
@ v16f16
Definition: MachineValueType.h:144
llvm::MVT::nxv4i8
@ nxv4i8
Definition: MachineValueType.h:204
llvm::MVT::nxv4f32
@ nxv4f32
Definition: MachineValueType.h:250
llvm::MVT::LAST_SCALABLE_VECTOR_VALUETYPE
@ LAST_SCALABLE_VECTOR_VALUETYPE
Definition: MachineValueType.h:263
llvm::MVT::INVALID_SIMPLE_VALUE_TYPE
@ INVALID_SIMPLE_VALUE_TYPE
Definition: MachineValueType.h:38
llvm::MVT::v6i32
@ v6i32
Definition: MachineValueType.h:111
llvm::MVT::v64i4
@ v64i4
Definition: MachineValueType.h:80
llvm::MVT::v1024i32
@ v1024i32
Definition: MachineValueType.h:120
llvm::MVT::FIRST_INTEGER_VALUETYPE
@ FIRST_INTEGER_VALUETYPE
Definition: MachineValueType.h:52
llvm::MVT::v1i64
@ v1i64
Definition: MachineValueType.h:123
llvm::Metadata
Root of the metadata hierarchy.
Definition: Metadata.h:62
llvm::MVT::getVectorVT
static MVT getVectorVT(MVT VT, unsigned NumElements, bool IsScalable)
Definition: MachineValueType.h:1436
llvm::MVT::getStoreSizeInBits
TypeSize getStoreSizeInBits() const
Return the number of bits overwritten by a store of the specified value type.
Definition: MachineValueType.h:1118
llvm::MVT::v7i32
@ v7i32
Definition: MachineValueType.h:112
llvm::MVT::v4i16
@ v4i16
Definition: MachineValueType.h:97
llvm::MVT::v4i8
@ v4i8
Definition: MachineValueType.h:84
llvm::MVT::nxv4i16
@ nxv4i16
Definition: MachineValueType.h:212
llvm::MVT::getScalarType
MVT getScalarType() const
If this is a vector, return the element type, otherwise return this.
Definition: MachineValueType.h:524
llvm::MVT::nxv16bf16
@ nxv16bf16
Definition: MachineValueType.h:245
llvm::Log2_32_Ceil
unsigned Log2_32_Ceil(uint32_t Value)
Return the ceil log base 2 of the specified value, 32 if the value is zero.
Definition: MathExtras.h:636
llvm::MVT::nxv16i16
@ nxv16i16
Definition: MachineValueType.h:214
llvm::MVT::isFloatingPoint
bool isFloatingPoint() const
Return true if this is a FP or a vector FP type.
Definition: MachineValueType.h:348
llvm::MVT::f80
@ f80
Definition: MachineValueType.h:59
llvm::MVT::nxv32bf16
@ nxv32bf16
Definition: MachineValueType.h:246
llvm::MVT::iPTRAny
@ iPTRAny
Definition: MachineValueType.h:301
llvm::MVT::v2i8
@ v2i8
Definition: MachineValueType.h:83
llvm::MVT::v4i64
@ v4i64
Definition: MachineValueType.h:126
llvm::MVT::v32i16
@ v32i16
Definition: MachineValueType.h:100
llvm::MVT::nxv16i8
@ nxv16i8
Definition: MachineValueType.h:206
llvm::MVT::v5f32
@ v5f32
Definition: MachineValueType.h:164
llvm::MVT::nxv1bf16
@ nxv1bf16
Definition: MachineValueType.h:241
llvm::MVT::i64x8
@ i64x8
Definition: MachineValueType.h:281
llvm::MVT::nxv8i64
@ nxv8i64
Definition: MachineValueType.h:227
llvm::MVT::v16i8
@ v16i8
Definition: MachineValueType.h:86
llvm::MVT::bitsGE
bool bitsGE(MVT VT) const
Return true if this has no less bits than VT.
Definition: MachineValueType.h:1156
llvm::MVT::v16i16
@ v16i16
Definition: MachineValueType.h:99
llvm::MVT::v2i64
@ v2i64
Definition: MachineValueType.h:124
llvm::MVT::v2f16
@ v2f16
Definition: MachineValueType.h:140
llvm::MVT::v3i64
@ v3i64
Definition: MachineValueType.h:125
uint64_t
llvm::MVT::is16BitVector
bool is16BitVector() const
Return true if this is a 16-bit vector type.
Definition: MachineValueType.h:392
llvm::MVT::MAX_ALLOWED_VALUETYPE
@ MAX_ALLOWED_VALUETYPE
Definition: MachineValueType.h:290
llvm::MVT::v32i64
@ v32i64
Definition: MachineValueType.h:129
llvm::MVT::v16f32
@ v16f32
Definition: MachineValueType.h:168
llvm::MVT::externref
@ externref
Definition: MachineValueType.h:279
llvm::MVT::v128i8
@ v128i8
Definition: MachineValueType.h:89
llvm::MVT::v6f32
@ v6f32
Definition: MachineValueType.h:165
llvm::MVT::v1f32
@ v1f32
Definition: MachineValueType.h:160
llvm::MVT::FIRST_VALUETYPE
@ FIRST_VALUETYPE
Definition: MachineValueType.h:283
llvm::MVT::nxv32i64
@ nxv32i64
Definition: MachineValueType.h:229
llvm::MVT::v32i1
@ v32i1
Definition: MachineValueType.h:71
llvm::MVT::v2048f32
@ v2048f32
Definition: MachineValueType.h:175
llvm::MVT::v2bf16
@ v2bf16
Definition: MachineValueType.h:151
TemplateParamKind::Type
@ Type
llvm::MVT::v4f32
@ v4f32
Definition: MachineValueType.h:163
llvm::MVT::getVectorVT
static MVT getVectorVT(MVT VT, ElementCount EC)
Definition: MachineValueType.h:1442
llvm::MVT::getVectorNumElements
unsigned getVectorNumElements() const
Definition: MachineValueType.h:869
llvm::MVT::i8
@ i8
Definition: MachineValueType.h:46
llvm::MVT::v128i16
@ v128i16
Definition: MachineValueType.h:102
assert
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
llvm::MVT::v5i32
@ v5i32
Definition: MachineValueType.h:110
llvm::MVT::nxv16i32
@ nxv16i32
Definition: MachineValueType.h:221
llvm::MVT::Other
@ Other
Definition: MachineValueType.h:42
llvm::MVT::getSizeInBits
TypeSize getSizeInBits() const
Returns the size of the specified MVT in bits.
Definition: MachineValueType.h:883
llvm::MVT::nxv64i1
@ nxv64i1
Definition: MachineValueType.h:200
llvm::MVT::all_valuetypes
static auto all_valuetypes()
SimpleValueType Iteration.
Definition: MachineValueType.h:1456
llvm::MVT::nxv4i32
@ nxv4i32
Definition: MachineValueType.h:219
llvm::LinearPolySize< TypeSize >::isKnownGE
static bool isKnownGE(const LinearPolySize &LHS, const LinearPolySize &RHS)
Definition: TypeSize.h:346
iterator_range.h
llvm::MVT::getFloatingPointVT
static MVT getFloatingPointVT(unsigned BitWidth)
Definition: MachineValueType.h:1176
llvm::MVT
Machine Value Type.
Definition: MachineValueType.h:31
llvm::MVT::nxv4bf16
@ nxv4bf16
Definition: MachineValueType.h:243
llvm::MVT::v256i1
@ v256i1
Definition: MachineValueType.h:74
llvm::LinearPolySize::getKnownMinValue
ScalarTy getKnownMinValue() const
Returns the minimum value this size can represent.
Definition: TypeSize.h:296
llvm::MVT::nxv1i64
@ nxv1i64
Definition: MachineValueType.h:224
llvm::MVT::bf16
@ bf16
Definition: MachineValueType.h:55
llvm::MVT::v3i32
@ v3i32
Definition: MachineValueType.h:108
llvm::LinearPolySize::isKnownMultipleOf
bool isKnownMultipleOf(ScalarTy RHS) const
This function tells the caller whether the element count is known at compile time to be a multiple of...
Definition: TypeSize.h:305
llvm::MVT::getVectorVT
static MVT getVectorVT(MVT VT, unsigned NumElements)
Definition: MachineValueType.h:1216
llvm::MVT::fp_scalable_vector_valuetypes
static auto fp_scalable_vector_valuetypes()
Definition: MachineValueType.h:1508
llvm::MVT::nxv2i32
@ nxv2i32
Definition: MachineValueType.h:218
llvm::MVT::nxv1f32
@ nxv1f32
Definition: MachineValueType.h:248
llvm::MVT::fixedlen_vector_valuetypes
static auto fixedlen_vector_valuetypes()
Definition: MachineValueType.h:1478
llvm::MVT::changeVectorElementTypeToInteger
MVT changeVectorElementTypeToInteger() const
Return a vector with the same number of elements as this vector, but with the element type converted ...
Definition: MachineValueType.h:469
llvm::MVT::i64
@ i64
Definition: MachineValueType.h:49
llvm::MVT::v2i32
@ v2i32
Definition: MachineValueType.h:107
llvm::MVT::is2048BitVector
bool is2048BitVector() const
Return true if this is a 2048-bit vector type.
Definition: MachineValueType.h:452
llvm_unreachable
#define llvm_unreachable(msg)
Marks that the current location is not supposed to be reachable.
Definition: ErrorHandling.h:143
llvm::MVT::v2f32
@ v2f32
Definition: MachineValueType.h:161
llvm::MVT::isPow2VectorType
bool isPow2VectorType() const
Returns true if the given vector is a power of 2.
Definition: MachineValueType.h:506
llvm::MVT::is128BitVector
bool is128BitVector() const
Return true if this is a 128-bit vector type.
Definition: MachineValueType.h:415
llvm::MVT::v64i8
@ v64i8
Definition: MachineValueType.h:88
S
add sub stmia L5 ldr r0 bl L_printf $stub Instead of a and a wouldn t it be better to do three moves *Return an aggregate type is even return S
Definition: README.txt:210
llvm::MVT::FIRST_FP_FIXEDLEN_VECTOR_VALUETYPE
@ FIRST_FP_FIXEDLEN_VECTOR_VALUETYPE
Definition: MachineValueType.h:188
llvm::MVT::nxv1i8
@ nxv1i8
Definition: MachineValueType.h:202
llvm::MVT::v64i16
@ v64i16
Definition: MachineValueType.h:101
llvm::MVT::nxv32i32
@ nxv32i32
Definition: MachineValueType.h:222
llvm::MVT::v4i32
@ v4i32
Definition: MachineValueType.h:109
llvm::MVT::iPTR
@ iPTR
Definition: MachineValueType.h:320
llvm::MVT::is64BitVector
bool is64BitVector() const
Return true if this is a 64-bit vector type.
Definition: MachineValueType.h:406
llvm::MVT::v512i1
@ v512i1
Definition: MachineValueType.h:75
llvm::MVT::v32i32
@ v32i32
Definition: MachineValueType.h:115
llvm::MVT::v1i128
@ v1i128
Definition: MachineValueType.h:134
llvm::MVT::v128f32
@ v128f32
Definition: MachineValueType.h:171
llvm::MVT::v8i64
@ v8i64
Definition: MachineValueType.h:127
llvm::MVT::v64bf16
@ v64bf16
Definition: MachineValueType.h:157
llvm::MVT::getVectorElementCount
ElementCount getVectorElementCount() const
Definition: MachineValueType.h:865
llvm::MVT::v16i32
@ v16i32
Definition: MachineValueType.h:114
llvm::MVT::v256i64
@ v256i64
Definition: MachineValueType.h:132
llvm::MVT::v1i32
@ v1i32
Definition: MachineValueType.h:106
llvm::MVT::nxv64i8
@ nxv64i8
Definition: MachineValueType.h:208
llvm::MVT::nxv16i1
@ nxv16i1
Definition: MachineValueType.h:198
llvm::MVT::v8bf16
@ v8bf16
Definition: MachineValueType.h:154
llvm::MVT::nxv2i16
@ nxv2i16
Definition: MachineValueType.h:211
llvm::MVT::operator>
bool operator>(const MVT &S) const
Definition: MachineValueType.h:334
llvm::Any
Definition: Any.h:28
llvm::MVT::operator!=
bool operator!=(const MVT &S) const
Definition: MachineValueType.h:337
llvm::MVT::Metadata
@ Metadata
Definition: MachineValueType.h:296
llvm::MVT::v128i64
@ v128i64
Definition: MachineValueType.h:131
llvm::MVT::v32f16
@ v32f16
Definition: MachineValueType.h:145
llvm::MVT::isOverloaded
bool isOverloaded() const
Return true if this is an overloaded type for TableGen.
Definition: MachineValueType.h:460
llvm::MVT::token
@ token
Definition: MachineValueType.h:293
llvm::MVT::operator==
bool operator==(const MVT &S) const
Definition: MachineValueType.h:336
llvm::MVT::FIRST_VECTOR_VALUETYPE
@ FIRST_VECTOR_VALUETYPE
Definition: MachineValueType.h:265
llvm::MVT::iAny
@ iAny
Definition: MachineValueType.h:316
llvm::MVT::FIRST_FIXEDLEN_VECTOR_VALUETYPE
@ FIRST_FIXEDLEN_VECTOR_VALUETYPE
Definition: MachineValueType.h:191
llvm::MVT::v256i8
@ v256i8
Definition: MachineValueType.h:90
llvm::MVT::v8i16
@ v8i16
Definition: MachineValueType.h:98
llvm::TypeSize
Definition: TypeSize.h:435
llvm::MVT::knownBitsGE
bool knownBitsGE(MVT VT) const
Return true if we know at compile time this has more than or the same bits as VT.
Definition: MachineValueType.h:1133
llvm::MVT::FIRST_INTEGER_FIXEDLEN_VECTOR_VALUETYPE
@ FIRST_INTEGER_FIXEDLEN_VECTOR_VALUETYPE
Definition: MachineValueType.h:136
llvm::MVT::getVectorMinNumElements
unsigned getVectorMinNumElements() const
Given a vector type, return the minimum number of elements it contains.
Definition: MachineValueType.h:698
llvm::BitWidth
constexpr unsigned BitWidth
Definition: BitmaskEnum.h:147
llvm::MVT::i32
@ i32
Definition: MachineValueType.h:48
llvm::MVT::v512f16
@ v512f16
Definition: MachineValueType.h:149
llvm::MVT::nxv8i8
@ nxv8i8
Definition: MachineValueType.h:205
llvm::MVT::v512f32
@ v512f32
Definition: MachineValueType.h:173
llvm::MVT::v8i32
@ v8i32
Definition: MachineValueType.h:113
llvm::MVT::v3f32
@ v3f32
Definition: MachineValueType.h:162
llvm::MVT::nxv8i32
@ nxv8i32
Definition: MachineValueType.h:220
llvm::force_iteration_on_noniterable_enum
constexpr force_iteration_on_noniterable_enum_t force_iteration_on_noniterable_enum
Definition: Sequence.h:109
llvm::MVT::nxv1i16
@ nxv1i16
Definition: MachineValueType.h:210
llvm::MVT::nxv8f16
@ nxv8f16
Definition: MachineValueType.h:237
llvm::MVT::v1024i1
@ v1024i1
Definition: MachineValueType.h:76
llvm::MVT::v128i2
@ v128i2
Definition: MachineValueType.h:78
llvm::MVT::getHalfNumVectorElementsVT
MVT getHalfNumVectorElementsVT() const
Return a VT for a vector type with the same element type but half the number of elements.
Definition: MachineValueType.h:498
llvm::MVT::f128
@ f128
Definition: MachineValueType.h:60
llvm::MVT::v1i8
@ v1i8
Definition: MachineValueType.h:82
llvm::MVT::nxv8i1
@ nxv8i1
Definition: MachineValueType.h:197
llvm::MVT::Any
@ Any
Definition: MachineValueType.h:324
llvm::MVT::v64f64
@ v64f64
Definition: MachineValueType.h:184
llvm::MVT::f16
@ f16
Definition: MachineValueType.h:56
llvm::MVT::LAST_FP_VALUETYPE
@ LAST_FP_VALUETYPE
Definition: MachineValueType.h:64
llvm::MVT::v32f32
@ v32f32
Definition: MachineValueType.h:169
llvm::MVT::vector_valuetypes
static auto vector_valuetypes()
Definition: MachineValueType.h:1472
llvm::MVT::LAST_VALUETYPE
@ LAST_VALUETYPE
Definition: MachineValueType.h:284
llvm::MVT::nxv1i1
@ nxv1i1
Definition: MachineValueType.h:194
llvm::MVT::getVT
static MVT getVT(Type *Ty, bool HandleUnknown=false)
Return the value type corresponding to the specified type.
Definition: ValueTypes.cpp:541
llvm::MVT::isScalarInteger
bool isScalarInteger() const
Return true if this is an integer, not including vectors.
Definition: MachineValueType.h:368
llvm::MVT::getScalableVectorVT
static MVT getScalableVectorVT(MVT VT, unsigned NumElements)
Definition: MachineValueType.h:1357
llvm::MVT::changeVectorElementType
MVT changeVectorElementType(MVT EltVT) const
Return a VT for a vector type whose attributes match ourselves with the exception of the element type...
Definition: MachineValueType.h:480
llvm::TypeSize::getKnownMinSize
ScalarTy getKnownMinSize() const
Definition: TypeSize.h:445
llvm::MVT::Untyped
@ Untyped
Definition: MachineValueType.h:274
llvm::MVT::is1024BitVector
bool is1024BitVector() const
Return true if this is a 1024-bit vector type.
Definition: MachineValueType.h:443
llvm::MVT::v1024i8
@ v1024i8
Definition: MachineValueType.h:92
llvm::MVT::v32i8
@ v32i8
Definition: MachineValueType.h:87
llvm::MVT::i16
@ i16
Definition: MachineValueType.h:47
llvm::MVT::knownBitsLT
bool knownBitsLT(MVT VT) const
Return true if we know at compile time this has fewer bits than VT.
Definition: MachineValueType.h:1138
llvm::MVT::nxv32i1
@ nxv32i1
Definition: MachineValueType.h:199
llvm::MVT::fp_valuetypes
static auto fp_valuetypes()
Definition: MachineValueType.h:1467
llvm::MVT::LAST_INTEGER_VALUETYPE
@ LAST_INTEGER_VALUETYPE
Definition: MachineValueType.h:53
llvm::MVT::vAny
@ vAny
Definition: MachineValueType.h:306
llvm::MVT::v128f64
@ v128f64
Definition: MachineValueType.h:185
llvm::MVT::v8i8
@ v8i8
Definition: MachineValueType.h:85
llvm::MVT::nxv2i8
@ nxv2i8
Definition: MachineValueType.h:203
llvm::MVT::LAST_FP_SCALABLE_VECTOR_VALUETYPE
@ LAST_FP_SCALABLE_VECTOR_VALUETYPE
Definition: MachineValueType.h:260
llvm::MVT::nxv16i64
@ nxv16i64
Definition: MachineValueType.h:228
llvm::MVT::v8f32
@ v8f32
Definition: MachineValueType.h:167
llvm::MVT::v2i16
@ v2i16
Definition: MachineValueType.h:95
llvm::MVT::v16i64
@ v16i64
Definition: MachineValueType.h:128
llvm::MVT::bitsGT
bool bitsGT(MVT VT) const
Return true if this has more bits than VT.
Definition: MachineValueType.h:1149
llvm::MVT::v128f16
@ v128f16
Definition: MachineValueType.h:147
llvm::MVT::f32
@ f32
Definition: MachineValueType.h:57
llvm::MVT::nxv1f16
@ nxv1f16
Definition: MachineValueType.h:234
llvm::MVT::v3bf16
@ v3bf16
Definition: MachineValueType.h:152
llvm::MVT::MVT
constexpr MVT(SimpleValueType SVT)
Definition: MachineValueType.h:332
llvm::MVT::nxv8f64
@ nxv8f64
Definition: MachineValueType.h:257
llvm::MVT::VALUETYPE_SIZE
@ VALUETYPE_SIZE
Definition: MachineValueType.h:285
llvm::MVT::v1024f32
@ v1024f32
Definition: MachineValueType.h:174
llvm::MVT::is512BitVector
bool is512BitVector() const
Return true if this is a 512-bit vector type.
Definition: MachineValueType.h:434
llvm::reportInvalidSizeRequest
void reportInvalidSizeRequest(const char *Msg)
Reports a diagnostic message to indicate an invalid size request has been done on a scalable vector.
Definition: TypeSize.cpp:38
llvm::MVT::v4i1
@ v4i1
Definition: MachineValueType.h:68
llvm::MVT::getIntegerVT
static MVT getIntegerVT(unsigned BitWidth)
Definition: MachineValueType.h:1193
llvm::MVT::nxv8f32
@ nxv8f32
Definition: MachineValueType.h:251
llvm::MVT::integer_fixedlen_vector_valuetypes
static auto integer_fixedlen_vector_valuetypes()
Definition: MachineValueType.h:1490