mini-llvm
0.1.0
Toggle main menu visibility
Loading...
Searching...
No Matches
GraphColoringAllocator.h
Go to the documentation of this file.
1
// SPDX-License-Identifier: MIT
2
3
#pragma once
4
5
#include <unordered_set>
6
7
#include "
mini-llvm/codegen/RegisterAllocator.h
"
8
#include "
mini-llvm/mir/Function.h
"
9
#include "
mini-llvm/mir/PhysicalRegister.h
"
10
#include "
mini-llvm/mir/VirtualRegister.h
"
11
#include "
mini-llvm/utils/Compiler.h
"
12
13
namespace
mini_llvm
{
14
15
class
MINI_LLVM_EXPORT
GraphColoringAllocator
:
public
RegisterAllocator
{
16
public
:
17
bool
allocate
(
18
mir::Function
&F,
19
const
std::unordered_set<mir::VirtualRegister *> &virtRegs,
20
const
std::unordered_set<mir::PhysicalRegister *> &physRegs,
21
RegisterAction
load,
22
RegisterAction
store
23
)
override
;
24
};
25
26
}
// namespace mini_llvm
Compiler.h
MINI_LLVM_EXPORT
#define MINI_LLVM_EXPORT
Definition
Compiler.h:17
PhysicalRegister.h
RegisterAllocator.h
VirtualRegister.h
mini_llvm::GraphColoringAllocator
Definition
GraphColoringAllocator.h:15
mini_llvm::GraphColoringAllocator::allocate
bool allocate(mir::Function &F, const std::unordered_set< mir::VirtualRegister * > &virtRegs, const std::unordered_set< mir::PhysicalRegister * > &physRegs, RegisterAction load, RegisterAction store) override
mini_llvm::RegisterAllocator::RegisterAction
FunctionRef< void(mir::Register *reg, mir::StackSlot *slot, const mir::BasicBlockBuilder &builder) > RegisterAction
Definition
RegisterAllocator.h:20
mini_llvm::RegisterAllocator::RegisterAllocator
RegisterAllocator()=default
mini_llvm::mir::Function
Definition
Function.h:21
Function.h
mini_llvm
Definition
GraphColoringAllocator.h:13
include
mini-llvm
codegen
register_allocators
GraphColoringAllocator.h
Generated by
1.17.0