clang 20.0.0git
|
#include "clang/Driver/OffloadBundler.h"
Public Member Functions | |
OffloadBundler (const OffloadBundlerConfig &BC) | |
llvm::Error | BundleFiles () |
Bundle the files. Return true if an error was found. | |
llvm::Error | UnbundleFiles () |
llvm::Error | UnbundleArchive () |
UnbundleArchive takes an archive file (".a") as input containing bundled code object files, and a list of offload targets (not host), and extracts the code objects into a new archive file for each offload target. | |
Static Public Member Functions | |
static llvm::Error | ListBundleIDsInFile (llvm::StringRef InputFileName, const OffloadBundlerConfig &BundlerConfig) |
Public Attributes | |
const OffloadBundlerConfig & | BundlerConfig |
Definition at line 55 of file OffloadBundler.h.
|
inline |
Definition at line 60 of file OffloadBundler.h.
Error OffloadBundler::BundleFiles | ( | ) |
Bundle the files. Return true if an error was found.
Definition at line 1315 of file OffloadBundler.cpp.
References clang::OffloadBundlerConfig::AllowNoHost, BundlerConfig, clang::OffloadBundlerConfig::Compress, clang::CompressedOffloadBundle::compress(), clang::OffloadBundlerConfig::CompressionFormat, clang::OffloadBundlerConfig::CompressionLevel, CreateFileHandler(), clang::OffloadBundlerConfig::HostInputIndex, clang::OffloadBundlerConfig::InputFileNames, clang::OffloadBundlerConfig::OutputFileNames, clang::OffloadBundlerConfig::TargetNames, and clang::OffloadBundlerConfig::Verbose.
|
static |
Definition at line 1191 of file OffloadBundler.cpp.
References BundlerConfig, CreateFileHandler(), clang::CompressedOffloadBundle::decompress(), and clang::OffloadBundlerConfig::Verbose.
Error OffloadBundler::UnbundleArchive | ( | ) |
UnbundleArchive takes an archive file (".a") as input containing bundled code object files, and a list of offload targets (not host), and extracts the code objects into a new archive file for each offload target.
Each resulting archive file contains all code object files corresponding to that particular offload target. The created archive file does not contain an index of the symbols and code object files are named as <<Parent Bundle Name>-<CodeObject's TargetID>>, with ':' replaced with '_'.
Map of target names with list of object files that will form the device specific archive for that target
Iterate over all bundled code object files in the input archive.
Write out an archive for each target
Definition at line 1632 of file OffloadBundler.cpp.
References clang::OffloadBundlerConfig::AllowMissingBundles, BundlerConfig, CheckHeterogeneousArchive(), clang::OffloadBundlerConfig::CheckInputArchive, CreateFileHandler(), clang::CompressedOffloadBundle::decompress(), clang::FileName, getCompatibleOffloadTargets(), getDefaultArchiveKindForHost(), getDeviceLibraryFileName(), clang::OffloadBundlerConfig::InputFileNames, clang::OffloadBundlerConfig::OutputFileNames, clang::Target, clang::OffloadBundlerConfig::TargetNames, and clang::OffloadBundlerConfig::Verbose.
Error OffloadBundler::UnbundleFiles | ( | ) |
Definition at line 1392 of file OffloadBundler.cpp.
References clang::OffloadBundlerConfig::AllowMissingBundles, BundlerConfig, CreateFileHandler(), clang::CompressedOffloadBundle::decompress(), E, clang::OffloadBundlerConfig::HostInputIndex, clang::OffloadBundlerConfig::InputFileNames, isCodeObjectCompatible(), clang::Last, clang::OffloadBundlerConfig::OutputFileNames, clang::OffloadBundlerConfig::TargetNames, and clang::OffloadBundlerConfig::Verbose.
const OffloadBundlerConfig& clang::OffloadBundler::BundlerConfig |
Definition at line 57 of file OffloadBundler.h.
Referenced by BundleFiles(), ListBundleIDsInFile(), UnbundleArchive(), and UnbundleFiles().