LLVM 24.0.0git
HexagonAlignGlobalArrays.cpp File Reference
#include "Hexagon.h"
#include "llvm/IR/Module.h"
#include "llvm/Pass.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/Debug.h"

Go to the source code of this file.

Macros

#define DEBUG_TYPE   "hexagon-global-array-alignment"

Functions

 INITIALIZE_PASS (HexagonAlignGlobalArrays, "hexagon-global-array-alignment", "Align Global Arrays to 8-byte", false, false) ModulePass *llvm
static TypegetUnderlyingArrayElmTy (Type *Ty)

Variables

static cl::opt< boolDisableGlobalArrayAlignment ("hexagon-disable-global-array-align", cl::desc("Disable aligning global integer arrays to an 8-byte boundary"), cl::init(false), cl::Hidden)
static cl::opt< boolDisableHexAlignOptByteHalf ("hexagon-disable-align-opt-byte-half", cl::desc("Disable keeping byte and half-word arrays at their natural " "alignment when reducing .rodata size"), cl::Hidden)

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "hexagon-global-array-alignment"

Definition at line 32 of file HexagonAlignGlobalArrays.cpp.

Function Documentation

◆ getUnderlyingArrayElmTy()

Type * getUnderlyingArrayElmTy ( Type * Ty)
static

Definition at line 76 of file HexagonAlignGlobalArrays.cpp.

References llvm::cast(), and llvm::Type::isArrayTy().

◆ INITIALIZE_PASS()

INITIALIZE_PASS ( HexagonAlignGlobalArrays ,
"hexagon-global-array-alignment" ,
"Align Global Arrays to 8-byte" ,
false ,
false  )

Variable Documentation

◆ DisableGlobalArrayAlignment

cl::opt< bool > DisableGlobalArrayAlignment("hexagon-disable-global-array-align", cl::desc("Disable aligning global integer arrays to an 8-byte boundary"), cl::init(false), cl::Hidden) ( "hexagon-disable-global-array-align" ,
cl::desc("Disable aligning global integer arrays to an 8-byte boundary") ,
cl::init(false) ,
cl::Hidden  )
static

◆ DisableHexAlignOptByteHalf

cl::opt< bool > DisableHexAlignOptByteHalf("hexagon-disable-align-opt-byte-half", cl::desc("Disable keeping byte and half-word arrays at their natural " "alignment when reducing .rodata size"), cl::Hidden) ( "hexagon-disable-align-opt-byte-half" ,
cl::desc("Disable keeping byte and half-word arrays at their natural " "alignment when reducing .rodata size") ,
cl::Hidden  )
static