LLVM 24.0.0git
llvm::RecordResolver Class Referencefinal

Resolve all variables from a record except for unset variables. More...

#include "llvm/TableGen/Record.h"

Inheritance diagram for llvm::RecordResolver:
[legend]

Public Member Functions

 RecordResolver (const Record &R)
void setName (const Init *NewName)
const Init * resolve (const Init *VarName) override
 Return the initializer for the given variable name (should normally be a StringInit), or nullptr if the name could not be resolved.
bool keepUnsetBits () const override
const Init * getCachedResult (const Init *I, bool &FoundUnresolved) const override
 Return the cached result of resolving I, or nullptr.
void cacheResult (const Init *I, const Init *Result, bool FoundUnresolved) override
 Cache the result of resolving I.
Public Member Functions inherited from llvm::Resolver
 Resolver (const Record *CurRec)
virtual ~Resolver ()=default
const Record * getCurrentRecord () const
bool isFinal () const
void setFinal (bool Final)
virtual void noteUnresolved ()
 Called when a cached result has unresolved references.

Protected Member Functions

void clearCachedResults () override

Detailed Description

Resolve all variables from a record except for unset variables.

Definition at line 2369 of file Record.h.

Constructor & Destructor Documentation

◆ RecordResolver()

llvm::RecordResolver::RecordResolver ( const Record & R)
inlineexplicit

Definition at line 2376 of file Record.h.

References llvm::Resolver::Resolver().

Member Function Documentation

◆ cacheResult()

void llvm::RecordResolver::cacheResult ( const Init * I,
const Init * Result,
bool FoundUnresolved )
inlineoverridevirtual

Cache the result of resolving I.

Reimplemented from llvm::Resolver.

Definition at line 2398 of file Record.h.

References I.

◆ clearCachedResults()

void llvm::RecordResolver::clearCachedResults ( )
inlineoverrideprotectedvirtual

Reimplemented from llvm::Resolver.

Definition at line 2405 of file Record.h.

Referenced by setName().

◆ getCachedResult()

const Init * llvm::RecordResolver::getCachedResult ( const Init * I,
bool & FoundUnresolved ) const
inlineoverridevirtual

Return the cached result of resolving I, or nullptr.

FoundUnresolved is set if the result has unresolved references.

Reimplemented from llvm::Resolver.

Definition at line 2389 of file Record.h.

References I.

◆ keepUnsetBits()

bool llvm::RecordResolver::keepUnsetBits ( ) const
inlineoverridevirtual

Reimplemented from llvm::Resolver.

Definition at line 2385 of file Record.h.

◆ resolve()

const Init * RecordResolver::resolve ( const Init * VarName)
overridevirtual

Return the initializer for the given variable name (should normally be a StringInit), or nullptr if the name could not be resolved.

Implements llvm::Resolver.

Definition at line 3273 of file Record.cpp.

References llvm::Resolver::getCurrentRecord(), getValue(), llvm::is_contained(), llvm::isa(), and llvm::Init::resolveReferences().

◆ setName()

void llvm::RecordResolver::setName ( const Init * NewName)
inline

Definition at line 2378 of file Record.h.

References clearCachedResults().


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