LLVM 22.0.0git
|
This file defines the MIR2Vec vocabulary analysis(MIR2VecVocabLegacyAnalysis), the core mir2vec::MIREmbedder interface for generating Machine IR embeddings, and related utilities. More...
#include "llvm/Analysis/IR2Vec.h"
#include "llvm/CodeGen/MachineBasicBlock.h"
#include "llvm/CodeGen/MachineFunction.h"
#include "llvm/CodeGen/MachineFunctionPass.h"
#include "llvm/CodeGen/MachineInstr.h"
#include "llvm/CodeGen/MachineModuleInfo.h"
#include "llvm/IR/PassManager.h"
#include "llvm/Pass.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/ErrorOr.h"
#include <map>
#include <set>
#include <string>
Go to the source code of this file.
Classes | |
class | llvm::mir2vec::MIRVocabulary |
Class for storing and accessing the MIR2Vec vocabulary. More... | |
class | llvm::MIR2VecVocabLegacyAnalysis |
Pass to analyze and populate MIR2Vec vocabulary from a module. More... | |
class | llvm::MIR2VecVocabPrinterLegacyPass |
This pass prints the embeddings in the MIR2Vec vocabulary. More... |
Namespaces | |
namespace | llvm |
This is an optimization pass for GlobalISel generic memory operations. | |
namespace | llvm::mir2vec |
Typedefs | |
using | llvm::mir2vec::Embedding = ir2vec::Embedding |
Variables | |
llvm::cl::OptionCategory | llvm::mir2vec::MIR2VecCategory |
cl::opt< float > | llvm::mir2vec::OpcWeight |
This file defines the MIR2Vec vocabulary analysis(MIR2VecVocabLegacyAnalysis), the core mir2vec::MIREmbedder interface for generating Machine IR embeddings, and related utilities.
MIR2Vec extends IR2Vec to support Machine IR embeddings. It represents the LLVM Machine IR as embeddings which can be used as input to machine learning algorithms.
The original idea of MIR2Vec is described in the following paper:
RL4ReAl: Reinforcement Learning for Register Allocation. S. VenkataKeerthy, Siddharth Jain, Anilava Kundu, Rohit Aggarwal, Albert Cohen, and Ramakrishna Upadrasta. 2023. RL4ReAl: Reinforcement Learning for Register Allocation. Proceedings of the 32nd ACM SIGPLAN International Conference on Compiler Construction (CC 2023). https://doi.org/10.1145/3578360.3580273. https://arxiv.org/abs/2204.02013
Definition in file MIR2Vec.h.