MLIR 24.0.0git
LLVMModuleOps.h
Go to the documentation of this file.
1//===- LLVMModuleOps.h - LLVM dialect module-level ops ----------*- 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 declares the ops of op partition `Module` of the LLVM dialect: the
10// module-level ops, such as functions, globals, aliases, comdats and metadata.
11//
12//===----------------------------------------------------------------------===//
13
14#ifndef MLIR_DIALECT_LLVMIR_LLVMMODULEOPS_H_
15#define MLIR_DIALECT_LLVMIR_LLVMMODULEOPS_H_
16
19
20#define GET_OP_CLASSES
21#include "mlir/Dialect/LLVMIR/LLVMModuleOps.h.inc"
22
23namespace mlir {
24class OpBuilder;
25namespace LLVM {
26/// Create an LLVM global containing the string "value" at the module containing
27/// surrounding the insertion point of builder. Obtain the address of that
28/// global and use it to compute the address of the first character in the
29/// string (operations inserted at the builder insertion point).
30Value createGlobalString(Location loc, OpBuilder &builder, StringRef name,
31 StringRef value, Linkage linkage);
32
33/// LLVM requires some operations to be inside of a Module operation. This
34/// function confirms that the Operation has the desired properties.
36
37/// Lookup parent Module satisfying LLVM conditions on the Module Operation.
39} // namespace LLVM
40} // namespace mlir
41
42#endif // MLIR_DIALECT_LLVMIR_LLVMMODULEOPS_H_
This class defines the main interface for locations in MLIR and acts as a non-nullable wrapper around...
Definition Location.h:76
This class helps build Operations.
Definition Builders.h:210
Operation is the basic unit of execution within MLIR.
Definition Operation.h:87
This class represents an instance of an SSA value in the MLIR system, representing a computable value...
Definition Value.h:96
Value createGlobalString(Location loc, OpBuilder &builder, StringRef name, StringRef value, Linkage linkage)
Create an LLVM global containing the string "value" at the module containing surrounding the insertio...
Operation * parentLLVMModule(Operation *op)
Lookup parent Module satisfying LLVM conditions on the Module Operation.
bool satisfiesLLVMModule(Operation *op)
LLVM requires some operations to be inside of a Module operation.
Include the generated interface declarations.