Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / tools / clang-linker-wrapper / OffloadWrapper.h
blob679333975b2120d5e8429d2ace1d32e3c7eab3c5
1 //===- OffloadWrapper.h --r-------------------------------------*- 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 //===----------------------------------------------------------------------===//
9 #ifndef LLVM_CLANG_TOOLS_CLANG_LINKER_WRAPPER_OFFLOAD_WRAPPER_H
10 #define LLVM_CLANG_TOOLS_CLANG_LINKER_WRAPPER_OFFLOAD_WRAPPER_H
12 #include "llvm/ADT/ArrayRef.h"
13 #include "llvm/IR/Module.h"
15 /// Wraps the input device images into the module \p M as global symbols and
16 /// registers the images with the OpenMP Offloading runtime libomptarget.
17 llvm::Error wrapOpenMPBinaries(llvm::Module &M,
18 llvm::ArrayRef<llvm::ArrayRef<char>> Images);
20 /// Wraps the input fatbinary image into the module \p M as global symbols and
21 /// registers the images with the CUDA runtime.
22 llvm::Error wrapCudaBinary(llvm::Module &M, llvm::ArrayRef<char> Images);
24 /// Wraps the input bundled image into the module \p M as global symbols and
25 /// registers the images with the HIP runtime.
26 llvm::Error wrapHIPBinary(llvm::Module &M, llvm::ArrayRef<char> Images);
28 #endif