analyzer

package
v1.3.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 4, 2022 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	READ         = 1
	WRITE        = 2
	EVMALL       = 3
	UNKNOWN_TYPE = 4
	EVM_FORMAT   = "read<%dms>, write<%dms>, execute<%dms>"
	EVMCORE      = "evmcore"
)
View Source
const FlagEnableAnalyzer string = "enable-analyzer"

Variables

View Source
var (
	STATEDB_WRITE = []string{"AddBalance", "SubBalance", "SetNonce", "SetState", "SetCode", "AddLog", "AddPreimage", "AddRefund", "SubRefund", "AddAddressToAccessList", "AddSlotToAccessList", "PrepareAccessList", "AddressInAccessList", "Suicide", "CreateAccount", "ForEachStorage"}
	STATEDB_READ  = []string{"SlotInAccessList", "GetBalance", "GetNonce", "GetCode", "GetCodeSize", "GetCodeHash", "GetState", "GetCommittedState", "GetRefund", "HasSuicided", "Snapshot", "RevertToSnapshot", "Empty", "Exist"}
	EVM_OPER      = []string{EVMCORE}
)

Functions

func GetNowTimeMs

func GetNowTimeMs() int64

func InitializePprofDumper

func InitializePprofDumper(logger log.Logger, dumpPath string, coolDownStr string, abciElapsed int64)

func OnAppBeginBlockEnter

func OnAppBeginBlockEnter(height int64)

func OnAppDeliverTxEnter

func OnAppDeliverTxEnter()

func OnCommitDone added in v1.1.0

func OnCommitDone()

func RunFuncName

func RunFuncName() string

func SetDynamicConfig added in v1.1.10

func SetDynamicConfig(c IDynamicConfig)

func StartTxLog

func StartTxLog(oper string)

func StopTxLog

func StopTxLog(oper string)

Types

type DbRecord

type DbRecord struct {
	// contains filtered or unexported fields
}

func (*DbRecord) AddOperType

func (s *DbRecord) AddOperType(oper string, value int)

func (*DbRecord) GetOperType

func (s *DbRecord) GetOperType(oper string) int

type IDynamicConfig added in v1.1.10

type IDynamicConfig interface {
	GetEnableAnalyzer() bool
}

type MockDynamicConfig added in v1.1.10

type MockDynamicConfig struct {
}

func (MockDynamicConfig) GetEnableAnalyzer added in v1.1.10

func (c MockDynamicConfig) GetEnableAnalyzer() bool

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL