Fabcoin Core  0.16.2
P2P Digital Currency
Public Member Functions | Private Member Functions | Private Attributes | List of all members
dev::eth::jit::Ext Class Reference

#include <Ext.h>

Inheritance diagram for dev::eth::jit::Ext:
[legend]
Collaboration diagram for dev::eth::jit::Ext:
[legend]

Public Member Functions

 Ext (RuntimeManager &_runtimeManager, Memory &_memoryMan)
 
llvm::Value * sload (llvm::Value *_index)
 
void sstore (llvm::Value *_index, llvm::Value *_value)
 
llvm::Value * query (evm_query_key _key)
 
llvm::Value * balance (llvm::Value *_address)
 
llvm::Value * exists (llvm::Value *_address)
 
llvm::Value * calldataload (llvm::Value *_index)
 
std::tuple< llvm::Value *, llvm::Value * > create (llvm::Value *_gas, llvm::Value *_endowment, llvm::Value *_initOff, llvm::Value *_initSize)
 
llvm::Value * blockHash (llvm::Value *_number)
 
llvm::Value * sha3 (llvm::Value *_inOff, llvm::Value *_inSize)
 
MemoryRef extcode (llvm::Value *_addr)
 
llvm::Value * extcodesize (llvm::Value *_addr)
 
void log (llvm::Value *_memIdx, llvm::Value *_numBytes, llvm::ArrayRef< llvm::Value * > _topics)
 
void selfdestruct (llvm::Value *_beneficiary)
 
llvm::Value * call (evm_call_kind _kind, llvm::Value *_gas, llvm::Value *_addr, llvm::Value *_value, llvm::Value *_inOff, llvm::Value *_inSize, llvm::Value *_outOff, llvm::Value *_outSize)
 

Private Member Functions

llvm::CallInst * createCall (EnvFunc _funcId, std::initializer_list< llvm::Value * > const &_args)
 
llvm::Value * getArgAlloca ()
 
llvm::Value * byPtr (llvm::Value *_value)
 
llvm::Value * createCABICall (llvm::Function *_func, std::initializer_list< llvm::Value * > const &_args)
 

Private Attributes

Memorym_memoryMan
 
llvm::Value * m_size
 
std::array< llvm::Function *, sizeOf< EnvFunc >::value > m_funcs
 
std::array< llvm::Value *, 8 > m_argAllocas
 
size_t m_argCounter = 0
 
llvm::Value * m_topics = nullptr
 Memory for array of up to 4 log topics TODO: Merge this memory with args allocas. More...
 

Additional Inherited Members

- Protected Member Functions inherited from dev::eth::jit::RuntimeHelper
 RuntimeHelper (RuntimeManager &_runtimeManager)
 
RuntimeManagergetRuntimeManager ()
 
- Protected Member Functions inherited from dev::eth::jit::CompilerHelper
 CompilerHelper (IRBuilder &_builder)
 
 CompilerHelper (const CompilerHelper &)=delete
 
CompilerHelperoperator= (CompilerHelper)=delete
 
llvm::Module * getModule ()
 Reference to the IR module being compiled. More...
 
llvm::Function * getMainFunction ()
 Reference to the main module function. More...
 
- Protected Attributes inherited from dev::eth::jit::CompilerHelper
IRBuilderm_builder
 Reference to parent compiler IR builder. More...
 

Detailed Description

Definition at line 43 of file Ext.h.

Constructor & Destructor Documentation

dev::eth::jit::Ext::Ext ( RuntimeManager _runtimeManager,
Memory _memoryMan 
)

Definition at line 20 of file Ext.cpp.

Here is the call graph for this function:

Member Function Documentation

llvm::Value * dev::eth::jit::Ext::balance ( llvm::Value *  _address)

Definition at line 355 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

llvm::Value * dev::eth::jit::Ext::blockHash ( llvm::Value *  _number)

Definition at line 373 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

llvm::Value * dev::eth::jit::Ext::byPtr ( llvm::Value *  _value)
private

Definition at line 224 of file Ext.cpp.

Here is the call graph for this function:

llvm::Value * dev::eth::jit::Ext::call ( evm_call_kind  _kind,
llvm::Value *  _gas,
llvm::Value *  _addr,
llvm::Value *  _value,
llvm::Value *  _inOff,
llvm::Value *  _inSize,
llvm::Value *  _outOff,
llvm::Value *  _outSize 
)

Definition at line 461 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

llvm::Value * dev::eth::jit::Ext::calldataload ( llvm::Value *  _index)

Definition at line 290 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

std::tuple< llvm::Value *, llvm::Value * > dev::eth::jit::Ext::create ( llvm::Value *  _gas,
llvm::Value *  _endowment,
llvm::Value *  _initOff,
llvm::Value *  _initSize 
)

Definition at line 487 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

llvm::Value * dev::eth::jit::Ext::createCABICall ( llvm::Function *  _func,
std::initializer_list< llvm::Value * > const &  _args 
)
private

Definition at line 241 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

llvm::CallInst * dev::eth::jit::Ext::createCall ( EnvFunc  _funcId,
std::initializer_list< llvm::Value * > const &  _args 
)
private

Definition at line 231 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

llvm::Value * dev::eth::jit::Ext::exists ( llvm::Value *  _address)

Definition at line 364 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

MemoryRef dev::eth::jit::Ext::extcode ( llvm::Value *  _addr)

Definition at line 393 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

llvm::Value * dev::eth::jit::Ext::extcodesize ( llvm::Value *  _addr)

Definition at line 409 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

llvm::Value * dev::eth::jit::Ext::getArgAlloca ( )
private

Definition at line 208 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void dev::eth::jit::Ext::log ( llvm::Value *  _memIdx,
llvm::Value *  _numBytes,
llvm::ArrayRef< llvm::Value * >  _topics 
)

Definition at line 422 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

llvm::Value * dev::eth::jit::Ext::query ( evm_query_key  _key)

Definition at line 313 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void dev::eth::jit::Ext::selfdestruct ( llvm::Value *  _beneficiary)

Definition at line 282 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

llvm::Value * dev::eth::jit::Ext::sha3 ( llvm::Value *  _inOff,
llvm::Value *  _inSize 
)

Definition at line 383 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

llvm::Value * dev::eth::jit::Ext::sload ( llvm::Value *  _index)

Definition at line 265 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void dev::eth::jit::Ext::sstore ( llvm::Value *  _index,
llvm::Value *  _value 
)

Definition at line 274 of file Ext.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

Member Data Documentation

std::array<llvm::Value*, 8> dev::eth::jit::Ext::m_argAllocas
private

Definition at line 80 of file Ext.h.

size_t dev::eth::jit::Ext::m_argCounter = 0
private

Definition at line 81 of file Ext.h.

std::array<llvm::Function*, sizeOf<EnvFunc>::value> dev::eth::jit::Ext::m_funcs
private

Definition at line 79 of file Ext.h.

Memory& dev::eth::jit::Ext::m_memoryMan
private

Definition at line 75 of file Ext.h.

llvm::Value* dev::eth::jit::Ext::m_size
private

Definition at line 77 of file Ext.h.

llvm::Value* dev::eth::jit::Ext::m_topics = nullptr
private

Memory for array of up to 4 log topics TODO: Merge this memory with args allocas.

Definition at line 85 of file Ext.h.


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