struct def_chain_iterator

Declaration

template <class T, bool UseOptimizedChain = false>
struct def_chain_iterator { /* full declaration omitted */ };

Description

Walks the defining accesses of MemoryDefs. Stops after we hit something that has no defining use (e.g. a MemoryPhi or liveOnEntry). Note that, when comparing against a null def_chain_iterator, this will compare equal only after walking said Phi/liveOnEntry. The UseOptimizedChain flag specifies whether to walk the clobbering access chain, or all the accesses. Normally, MemoryDef are all just def/use linked together, so a def_chain on a MemoryDef will walk all MemoryDefs above it in the program until it hits a phi node. The optimized chain walks the clobbering access of a store. So if you are just trying to find, given a store, what the next thing that would clobber the same memory is, you want the optimized chain.

Declared at: llvm/include/llvm/Analysis/MemorySSA.h:1268

Templates

T
bool UseOptimizedChain = false

Method Overview

Methods

def_chain_iterator<T, UseOptimizedChain>()

Declared at: llvm/include/llvm/Analysis/MemorySSA.h:1271

def_chain_iterator<T, UseOptimizedChain>(T MA)

Declared at: llvm/include/llvm/Analysis/MemorySSA.h:1272

Parameters

T MA