revert dead code
This commit is contained in:
parent
b908096a88
commit
371028a42a
@ -192,7 +192,6 @@ func (t *TipSetExecutor) ApplyBlocks(ctx context.Context,
|
||||
cronGas = 0
|
||||
partDone = metrics.Timer(ctx, metrics.VMApplyMessages)
|
||||
|
||||
// TODO reorg the code to minimize the execution critical section
|
||||
vmi, err := makeVm(pstate, epoch, ts.MinTimestamp())
|
||||
if err != nil {
|
||||
return cid.Undef, cid.Undef, xerrors.Errorf("making vm: %w", err)
|
||||
@ -259,7 +258,7 @@ func (t *TipSetExecutor) ApplyBlocks(ctx context.Context,
|
||||
return cid.Cid{}, cid.Cid{}, err
|
||||
}
|
||||
|
||||
vmDoCron := partDone()
|
||||
vmCron := partDone()
|
||||
partDone = metrics.Timer(ctx, metrics.VMApplyFlush)
|
||||
|
||||
rectarr := blockadt.MakeEmptyArray(sm.ChainStore().ActorStore(ctx))
|
||||
@ -298,7 +297,7 @@ func (t *TipSetExecutor) ApplyBlocks(ctx context.Context,
|
||||
vmFlush := partDone()
|
||||
partDone = func() time.Duration { return time.Duration(0) }
|
||||
|
||||
log.Infow("ApplyBlocks stats", "early", vmEarly, "earlyCronGas", earlyCronGas, "vmMsg", vmMsg, "msgGas", msgGas, "vmCron", vmDoCron, "cronGas", cronGas, "vmFlush", vmFlush, "epoch", epoch, "tsk", ts.Key())
|
||||
log.Infow("ApplyBlocks stats", "early", vmEarly, "earlyCronGas", earlyCronGas, "vmMsg", vmMsg, "msgGas", msgGas, "vmCron", vmCron, "cronGas", cronGas, "vmFlush", vmFlush, "epoch", epoch, "tsk", ts.Key())
|
||||
|
||||
stats.Record(ctx, metrics.VMSends.M(int64(atomic.LoadUint64(&vm.StatSends))),
|
||||
metrics.VMApplied.M(int64(atomic.LoadUint64(&vm.StatApplied))))
|
||||
|
@ -169,7 +169,6 @@ func (sm *StateManager) callInternal(ctx context.Context, msg *types.Message, pr
|
||||
if err != nil {
|
||||
return nil, xerrors.Errorf("failed to set up vm: %w", err)
|
||||
}
|
||||
|
||||
for i, m := range priorMsgs {
|
||||
_, err = vmi.ApplyMessage(ctx, m)
|
||||
if err != nil {
|
||||
|
@ -26,9 +26,7 @@ const (
|
||||
DefaultPriorityExecutionLanes = 2
|
||||
)
|
||||
|
||||
var ErrExecutorDone = errors.New("executor has been released")
|
||||
|
||||
// the execution environment; see below for definition, methods, and initilization
|
||||
// the execution environment; see below for definition, methods, and initialization
|
||||
var execution *executionEnv
|
||||
|
||||
// implementation of vm executor with simple sanity check preventing use after free.
|
||||
|
Loading…
Reference in New Issue
Block a user