Files
clang-p2996/mlir/lib/Dialect/Index/IR/IndexAttrs.cpp
Jeff Niu ddf87d6cd4 [mlir][index] Add index dialect ops and attributes
This patch adds the definitions for the operations and attributes (just
one enum attribute) for the `index` dialect.

Depends on D135688

Reviewed By: rriddle, jpienaar

Differential Revision: https://reviews.llvm.org/D135689
2022-10-21 09:46:06 -07:00

37 lines
1.2 KiB
C++

//===- IndexAttrs.cpp - Index attribute definitions ------------------------==//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===----------------------------------------------------------------------===//
#include "mlir/Dialect/Index/IR/IndexAttrs.h"
#include "mlir/Dialect/Index/IR/IndexDialect.h"
#include "mlir/IR/Builders.h"
#include "mlir/IR/DialectImplementation.h"
#include "llvm/ADT/TypeSwitch.h"
using namespace mlir;
using namespace mlir::index;
//===----------------------------------------------------------------------===//
// IndexDialect
//===----------------------------------------------------------------------===//
void IndexDialect::registerAttributes() {
addAttributes<
#define GET_ATTRDEF_LIST
#include "mlir/Dialect/Index/IR/IndexAttrs.cpp.inc"
>();
}
//===----------------------------------------------------------------------===//
// ODS-Generated Declarations
//===----------------------------------------------------------------------===//
#include "mlir/Dialect/Index/IR/IndexEnums.cpp.inc"
#define GET_ATTRDEF_CLASSES
#include "mlir/Dialect/Index/IR/IndexAttrs.cpp.inc"