LLVM 22.0.0git
llvm::Comdat Class Reference

#include "llvm/IR/Comdat.h"

Public Types

enum  SelectionKind {
  Any , ExactMatch , Largest , NoDeduplicate ,
  SameSize
}

Public Member Functions

 Comdat (const Comdat &)=delete
LLVM_ABI Comdat (Comdat &&C)
SelectionKind getSelectionKind () const
void setSelectionKind (SelectionKind Val)
LLVM_ABI StringRef getName () const
LLVM_ABI void print (raw_ostream &OS, bool IsForDebug=false) const
LLVM_ABI void dump () const
const SmallPtrSetImpl< GlobalObject * > & getUsers () const

Friends

class Module
class GlobalObject

Detailed Description

Definition at line 34 of file Comdat.h.

Member Enumeration Documentation

◆ SelectionKind

Enumerator
Any 

The linker may choose any COMDAT.

ExactMatch 

The data referenced by the COMDAT must be the same.

Largest 

The linker will choose the largest COMDAT.

NoDeduplicate 

No deduplication is performed.

SameSize 

The data referenced by the COMDAT must be the same size.

Definition at line 36 of file Comdat.h.

Constructor & Destructor Documentation

◆ Comdat() [1/2]

llvm::Comdat::Comdat ( const Comdat & )
delete

References llvm::CallingConv::C, Comdat(), and LLVM_ABI.

Referenced by Comdat(), and Comdat().

◆ Comdat() [2/2]

Comdat::Comdat ( Comdat && C)

Definition at line 24 of file Comdat.cpp.

References llvm::CallingConv::C, and Comdat().

Member Function Documentation

◆ dump()

LLVM_DUMP_METHOD void Comdat::dump ( ) const

Definition at line 5508 of file AsmWriter.cpp.

References llvm::dbgs(), and print().

◆ getName()

StringRef Comdat::getName ( ) const

Definition at line 28 of file Comdat.cpp.

Referenced by copyComdat().

◆ getSelectionKind()

SelectionKind llvm::Comdat::getSelectionKind ( ) const
inline

Definition at line 47 of file Comdat.h.

Referenced by copyComdat(), copyLinkageVisibility(), and print().

◆ getUsers()

const SmallPtrSetImpl< GlobalObject * > & llvm::Comdat::getUsers ( ) const
inline

Definition at line 52 of file Comdat.h.

◆ print()

void Comdat::print ( raw_ostream & OS,
bool IsForDebug = false ) const

◆ setSelectionKind()

void llvm::Comdat::setSelectionKind ( SelectionKind Val)
inline

Definition at line 48 of file Comdat.h.

Referenced by copyComdat(), copyLinkageVisibility(), and LLVMSetComdatSelectionKind().

◆ GlobalObject

friend class GlobalObject
friend

Definition at line 56 of file Comdat.h.

References Any, and GlobalObject.

Referenced by GlobalObject.

◆ Module

friend class Module
friend

Definition at line 55 of file Comdat.h.

References Module.

Referenced by Module.


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