LLVM 23.0.0git
SIMemoryLegalizer.cpp File Reference

Memory legalizer - implements memory model. More...

Go to the source code of this file.

Macros

#define DEBUG_TYPE   "si-memory-legalizer"
#define PASS_NAME   "SI Memory Legalizer"

Functions

static bool isNonVolatileMemoryAccess (const MachineInstr &MI)
static bool canUseBUFFER_WBINVL1_VOL (const GCNSubtarget &ST)

Variables

static cl::opt< boolAmdgcnSkipCacheInvalidations ("amdgcn-skip-cache-invalidations", cl::init(false), cl::Hidden, cl::desc("Use this to skip inserting cache invalidating instructions."))

Detailed Description

Memory legalizer - implements memory model.

More information can be found here: http://llvm.org/docs/AMDGPUUsage.html#memory-model

Definition in file SIMemoryLegalizer.cpp.

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "si-memory-legalizer"

Definition at line 35 of file SIMemoryLegalizer.cpp.

◆ PASS_NAME

#define PASS_NAME   "SI Memory Legalizer"

Definition at line 36 of file SIMemoryLegalizer.cpp.

Function Documentation

◆ canUseBUFFER_WBINVL1_VOL()

bool canUseBUFFER_WBINVL1_VOL ( const GCNSubtarget & ST)
static

Definition at line 1279 of file SIMemoryLegalizer.cpp.

References llvm::AMDGPUSubtarget::SOUTHERN_ISLANDS.

◆ isNonVolatileMemoryAccess()

bool isNonVolatileMemoryAccess ( const MachineInstr & MI)
static
Returns
true if MI has one or more MMO, and all of them are fit for being marked as non-volatile. This means that either they are accessing the constant address space, are accessing a known invariant memory location, or that they are marked with the non-volatile metadata/MMO flag.

Definition at line 912 of file SIMemoryLegalizer.cpp.

References llvm::all_of(), and MI.

Variable Documentation

◆ AmdgcnSkipCacheInvalidations

cl::opt< bool > AmdgcnSkipCacheInvalidations("amdgcn-skip-cache-invalidations", cl::init(false), cl::Hidden, cl::desc("Use this to skip inserting cache invalidating instructions.")) ( "amdgcn-skip-cache-invalidations" ,
cl::init(false) ,
cl::Hidden ,
cl::desc("Use this to skip inserting cache invalidating instructions.")  )
static