MimIR
MimIR is my Intermediate Representation
Loading...
Searching...
No Matches
insn.h File Reference
#include <bit>
#include <optional>
#include <mim/axm.h>
#include <mim/lam.h>
#include <mim/plug/mach/mach.h>
#include "mim/plug/x86/autogen.h"
#include "mim/plug/x86/imm.h"
Include dependency graph for insn.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  mim
namespace  mim::plug
namespace  mim::plug::x86
 The x86 Plugin
namespace  mim::plug::x86::insn
 Machine facts about the instructions of the x86 plugin, shared by x86_isel.gen and the backend.

Functions

std::optional< size_t > mim::plug::x86::insn::tied (flags_t base)
 The operand whose register the result of a two-address instruction base takes.
bool mim::plug::x86::insn::commutes (flags_t base)
 Does the two-address instruction base compute the same with its operands swapped?
flags_t mim::plug::x86::insn::op (const App *app)
 The operation f of the memory form x86.rm f, x86.rm1 f, or x86.mr f app.
std::optional< size_t > mim::plug::x86::insn::tied (const App *app)
 The operand whose register the result of the two-address instruction app takes.
u32 mim::plug::x86::insn::latency (flags_t base, nat_t s)
 The latency in cycles of the instruction base on s-bit operands, roughly as on recent cores (uops.info).
u32 mim::plug::x86::insn::cost (const App *app)
 The cost of the instruction app: its latency plus one, so of two equally fast covers the shorter wins.

Variables

constexpr u32 mim::plug::x86::insn::Load = 4