LLVM 22.0.0git
HexagonConstExtenders.cpp File Reference
#include "HexagonInstrInfo.h"
#include "HexagonRegisterInfo.h"
#include "HexagonSubtarget.h"
#include "llvm/ADT/SetVector.h"
#include "llvm/ADT/SmallVector.h"
#include "llvm/CodeGen/MachineDominators.h"
#include "llvm/CodeGen/MachineFunctionPass.h"
#include "llvm/CodeGen/MachineInstrBuilder.h"
#include "llvm/CodeGen/MachineRegisterInfo.h"
#include "llvm/CodeGen/Register.h"
#include "llvm/InitializePasses.h"
#include "llvm/Pass.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/raw_ostream.h"
#include <map>
#include <set>
#include <utility>
#include <vector>

Go to the source code of this file.

Macros

#define DEBUG_TYPE   "hexagon-cext-opt"

Functions

static int32_t adjustUp (int32_t V, uint8_t A, uint8_t O)
static int32_t adjustDown (int32_t V, uint8_t A, uint8_t O)
 INITIALIZE_PASS_BEGIN (HexagonConstExtenders, "hexagon-cext-opt", "Hexagon constant-extender optimization", false, false) INITIALIZE_PASS_END(HexagonConstExtenders

Variables

static cl::opt< unsignedCountThreshold ("hexagon-cext-threshold", cl::init(3), cl::Hidden, cl::desc("Minimum number of extenders to trigger replacement"))
static cl::opt< unsignedReplaceLimit ("hexagon-cext-limit", cl::init(0), cl::Hidden, cl::desc("Maximum number of replacements"))
hexagon cext opt
hexagon cext Hexagon constant extender optimization
hexagon cext Hexagon constant extender false
hexagon cext Hexagon constant extender static false unsigned ReplaceCounter = 0

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "hexagon-cext-opt"

Definition at line 28 of file HexagonConstExtenders.cpp.

Function Documentation

◆ adjustDown()

int32_t adjustDown ( int32_t V,
uint8_t A,
uint8_t O )
static

Definition at line 46 of file HexagonConstExtenders.cpp.

References A(), assert(), and llvm::isPowerOf2_32().

◆ adjustUp()

int32_t adjustUp ( int32_t V,
uint8_t A,
uint8_t O )
static

Definition at line 40 of file HexagonConstExtenders.cpp.

References A(), assert(), and llvm::isPowerOf2_32().

◆ INITIALIZE_PASS_BEGIN()

INITIALIZE_PASS_BEGIN ( HexagonConstExtenders ,
"hexagon-cext-opt" ,
"Hexagon constant-extender optimization" ,
false ,
false  )

Variable Documentation

◆ CountThreshold

cl::opt< unsigned > CountThreshold("hexagon-cext-threshold", cl::init(3), cl::Hidden, cl::desc("Minimum number of extenders to trigger replacement")) ( "hexagon-cext-threshold" ,
cl::init(3) ,
cl::Hidden ,
cl::desc("Minimum number of extenders to trigger replacement")  )
static

◆ false

hexagon cext Hexagon constant extender false

Definition at line 561 of file HexagonConstExtenders.cpp.

◆ opt

hexagon cext opt

Definition at line 560 of file HexagonConstExtenders.cpp.

◆ optimization

hexagon cext Hexagon constant extender optimization

Definition at line 561 of file HexagonConstExtenders.cpp.

◆ ReplaceCounter

hexagon cext Hexagon constant extender static false unsigned ReplaceCounter = 0
static

Definition at line 563 of file HexagonConstExtenders.cpp.

◆ ReplaceLimit

cl::opt< unsigned > ReplaceLimit("hexagon-cext-limit", cl::init(0), cl::Hidden, cl::desc("Maximum number of replacements")) ( "hexagon-cext-limit" ,
cl::init(0) ,
cl::Hidden ,
cl::desc("Maximum number of replacements")  )
static