clang 22.0.0git
CIROpenACCTypeInterfaces.h
Go to the documentation of this file.
1//===----------------------------------------------------------------------===//
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 contains external dialect interfaces for CIR.
10//
11//===----------------------------------------------------------------------===//
12
13#ifndef CLANG_CIR_DIALECT_OPENACC_CIROPENACCTYPEINTERFACES_H
14#define CLANG_CIR_DIALECT_OPENACC_CIROPENACCTYPEINTERFACES_H
15
16#include "mlir/Dialect/OpenACC/OpenACC.h"
17
18namespace cir::acc {
19
20template <typename T>
23 OpenACCPointerLikeModel<T>, T> {
24 mlir::Type getElementType(mlir::Type pointer) const {
25 return mlir::cast<T>(pointer).getPointee();
26 }
27 mlir::acc::VariableTypeCategory
28 getPointeeTypeCategory(mlir::Type pointer,
29 mlir::TypedValue<mlir::acc::PointerLikeType> varPtr,
30 mlir::Type varType) const;
31};
32
33} // namespace cir::acc
34
35#endif // CLANG_CIR_DIALECT_OPENACC_CIROPENACCTYPEINTERFACES_H
mlir::acc::VariableTypeCategory getPointeeTypeCategory(mlir::Type pointer, mlir::TypedValue< mlir::acc::PointerLikeType > varPtr, mlir::Type varType) const
mlir::Type getElementType(mlir::Type pointer) const