LLVM 19.0.0git
Public Member Functions | Public Attributes | List of all members
llvm::SplitAnalysis::BlockInfo Struct Reference

Additional information about basic blocks where the current variable is live. More...

#include "CodeGen/SplitKit.h"

Public Member Functions

bool isOneInstr () const
 isOneInstr - Returns true when this BlockInfo describes a single instruction.
void print (raw_ostream &OS) const
void dump () const

Public Attributes

SlotIndex FirstInstr
 First instr accessing current reg.
SlotIndex LastInstr
 Last instr accessing current reg.
SlotIndex FirstDef
 First non-phi valno->def, or SlotIndex().
bool LiveIn
 Current reg is live in.
bool LiveOut
 Current reg is live out.

Detailed Description

Additional information about basic blocks where the current variable is live.

Such a block will look like one of these templates:

  1. | o—x | Internal to block. Variable is only live in this block.
  2. |—x | Live-in, kill.
  3. | o—| Def, live-out.
  4. |—x o—| Live-in, kill, def, live-out. Counted by NumGapBlocks.
  5. |—o—o—| Live-through with uses or defs.
  6. |--------—| Live-through without uses. Counted by NumThroughBlocks.

Two BlockInfo entries are created for template 4. One for the live-in segment, and one for the live-out segment. These entries look as if the block were split in the middle where the live range isn't live.

Live-through blocks without any uses don't get BlockInfo entries. They are simply listed in ThroughBlocks instead.

Definition at line 121 of file SplitKit.h.

Member Function Documentation

◆ dump()

void SplitAnalysis::BlockInfo::dump ( ) const

Definition at line 1900 of file SplitKit.cpp.

References llvm::dbgs(), and llvm::print().

◆ isOneInstr()

bool llvm::SplitAnalysis::BlockInfo::isOneInstr ( ) const

isOneInstr - Returns true when this BlockInfo describes a single instruction.

Definition at line 131 of file SplitKit.h.

Referenced by llvm::SplitAnalysis::shouldSplitSingleBlock().

◆ print()

void SplitAnalysis::BlockInfo::print ( raw_ostream OS) const

Definition at line 1892 of file SplitKit.cpp.

References FirstDef, FirstInstr, LastInstr, LiveIn, LiveOut, MBB, OS, and llvm::printMBBReference().

Member Data Documentation

◆ FirstDef

SlotIndex llvm::SplitAnalysis::BlockInfo::FirstDef

First non-phi valno->def, or SlotIndex().

Definition at line 125 of file SplitKit.h.

Referenced by print().

◆ FirstInstr

SlotIndex llvm::SplitAnalysis::BlockInfo::FirstInstr

◆ LastInstr

SlotIndex llvm::SplitAnalysis::BlockInfo::LastInstr

Last instr accessing current reg.

Definition at line 124 of file SplitKit.h.

Referenced by print(), llvm::SplitEditor::splitRegInBlock(), llvm::SplitEditor::splitRegOutBlock(), and llvm::SplitEditor::splitSingleBlock().

◆ LiveIn

bool llvm::SplitAnalysis::BlockInfo::LiveIn

◆ LiveOut

bool llvm::SplitAnalysis::BlockInfo::LiveOut


MachineBasicBlock* llvm::SplitAnalysis::BlockInfo::MBB

The documentation for this struct was generated from the following files: