1//===- IndexEnums.td - Index enum definitions --------------*- tablegen -*-===// 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#ifndef INDEX_ENUMS 10#define INDEX_ENUMS 11 12include "mlir/Dialect/Index/IR/IndexDialect.td" 13include "mlir/IR/EnumAttr.td" 14 15//===----------------------------------------------------------------------===// 16// IndexCmpPredicate 17//===----------------------------------------------------------------------===// 18 19def IndexCmpPredicate : I32EnumAttr< 20 "IndexCmpPredicate", "index comparison predicate kind", 21 [ 22 I32EnumAttrCase<"EQ", 0, "eq">, 23 I32EnumAttrCase<"NE", 1, "ne">, 24 I32EnumAttrCase<"SLT", 2, "slt">, 25 I32EnumAttrCase<"SLE", 3, "sle">, 26 I32EnumAttrCase<"SGT", 4, "sgt">, 27 I32EnumAttrCase<"SGE", 5, "sge">, 28 I32EnumAttrCase<"ULT", 6, "ult">, 29 I32EnumAttrCase<"ULE", 7, "ule">, 30 I32EnumAttrCase<"UGT", 8, "ugt">, 31 I32EnumAttrCase<"UGE", 9, "uge"> 32 ]> { 33 let cppNamespace = "::mlir::index"; 34 let genSpecializedAttr = 0; 35} 36 37//===----------------------------------------------------------------------===// 38// IndexCmpPredicateAttr 39//===----------------------------------------------------------------------===// 40 41def IndexCmpPredicateAttr : EnumAttr< 42 IndexDialect, IndexCmpPredicate, "cmp_predicate">; 43 44#endif // INDEX_ENUMS 45