retdec
Public Member Functions | Private Attributes | List of all members
retdec::llvmir2hll::LLVMTypeConverter Class Referencefinal

A converter from LLVM type to type in BIR. More...

#include <llvm_type_converter.h>

Inheritance diagram for retdec::llvmir2hll::LLVMTypeConverter:
Inheritance graph
[legend]
Collaboration diagram for retdec::llvmir2hll::LLVMTypeConverter:
Collaboration graph
[legend]

Public Member Functions

 LLVMTypeConverter ()
 Constructs a new converter. More...
 
bool isBool (const llvm::IntegerType *type) const
 Determines whether LLVM integral type type is boolean. More...
 
ShPtr< Typeconvert (const llvm::Type *type)
 Converts the given LLVM type type into a type in BIR. More...
 
ShPtr< PointerTypeconvert (const llvm::PointerType *type)
 Converts the given LLVM pointer type type into a pointer type in BIR. More...
 
ShPtr< ArrayTypeconvert (const llvm::ArrayType *type)
 Converts the given LLVM array type type into a array type in BIR. More...
 
ShPtr< StructTypeconvert (const llvm::StructType *type)
 Converts the given LLVM struct type type into a struct type in BIR. More...
 
ShPtr< FunctionTypeconvert (const llvm::FunctionType *type)
 Converts the given LLVM function type type into a function type in BIR. More...
 

Private Attributes

std::unordered_map< const llvm::Type *, ShPtr< Type > > mapLLVMTypeToType
 Mapping of an LLVM type into an already converted type in BIR. More...
 

Additional Inherited Members

- Private Member Functions inherited from retdec::utils::NonCopyable
 NonCopyable (const NonCopyable &)=delete
 
NonCopyableoperator= (const NonCopyable &)=delete
 
 NonCopyable ()=default
 
 ~NonCopyable ()=default
 

Detailed Description

A converter from LLVM type to type in BIR.

Constructor & Destructor Documentation

◆ LLVMTypeConverter()

retdec::llvmir2hll::LLVMTypeConverter::LLVMTypeConverter ( )

Constructs a new converter.

Member Function Documentation

◆ convert() [1/5]

ShPtr< ArrayType > retdec::llvmir2hll::LLVMTypeConverter::convert ( const llvm::ArrayType *  type)

Converts the given LLVM array type type into a array type in BIR.

Preconditions
  • type is non-null

◆ convert() [2/5]

ShPtr< FunctionType > retdec::llvmir2hll::LLVMTypeConverter::convert ( const llvm::FunctionType *  type)

Converts the given LLVM function type type into a function type in BIR.

Preconditions
  • type is non-null

◆ convert() [3/5]

ShPtr< PointerType > retdec::llvmir2hll::LLVMTypeConverter::convert ( const llvm::PointerType *  type)

Converts the given LLVM pointer type type into a pointer type in BIR.

Preconditions
  • type is non-null

◆ convert() [4/5]

ShPtr< StructType > retdec::llvmir2hll::LLVMTypeConverter::convert ( const llvm::StructType *  type)

Converts the given LLVM struct type type into a struct type in BIR.

Preconditions
  • type is non-null

◆ convert() [5/5]

ShPtr< Type > retdec::llvmir2hll::LLVMTypeConverter::convert ( const llvm::Type *  type)

Converts the given LLVM type type into a type in BIR.

Preconditions
  • type is non-null

◆ isBool()

bool retdec::llvmir2hll::LLVMTypeConverter::isBool ( const llvm::IntegerType *  type) const

Determines whether LLVM integral type type is boolean.

Preconditions
  • type is non-null

Member Data Documentation

◆ mapLLVMTypeToType

std::unordered_map<const llvm::Type *, ShPtr<Type> > retdec::llvmir2hll::LLVMTypeConverter::mapLLVMTypeToType
private

Mapping of an LLVM type into an already converted type in BIR.


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