eosnetworkfoundation / product

A workspace for product management primarily for planning purposes
2 stars 3 forks source link

Selectively Leverage EOS VM OC #165

Closed bhazzard closed 10 months ago

bhazzard commented 1 year ago

Short Description

In order to enhance the performance of EOS and EOS EVM, we are introducing the use of OC (Optimistic Concurrency) for the EOS VM. This initiative aims to improve the overall efficiency and scalability of the platform.

What

The primary goal of this initiative is to leverage OC for the EOS VM by implementing an Auto OC Mode as the default setting. This new mode, eos-vm-oc-enable=auto, will be introduced to enhance performance. Additionally, we will determine when to apply OC or use the baseline mode based on different contexts, such as building blocks, applying blocks, executing transactions from HTTP or P2P, and various transaction types.

Why

By utilizing OC, we can significantly boost the performance of EOS and EOS EVM. With the Auto OC Mode as the default, the system will automatically apply OC when appropriate, optimizing the execution of transactions and improving overall throughput. The introduction of OC for specific contexts, such as building blocks and speculative transaction executions, further enhances the efficiency of the platform. Moreover, we will evaluate and potentially increase subjective limits for contracts that leverage OC

Requirements

Auto OC Mode as default

Add a new Auto OC Mode option (eos-vm-oc-enable=auto), and apply it as the default.

Baseline / OC selection

In Auto OC Mode, leverage EOS VM OC, as follows:

Context OC?
Building block baseline, but OC if account is eosio.*
Applying block OC, or
if producer: baseline, but OC if account is eosio.*
Speculatively executing trx from HTTP baseline, but OC if account is eosio.*
Speculatively executing trx from p2p OC (but see :bulb: below)
Compute transaction baseline, but OC if account is eosio.*
Read only transaction OC

Evaluate increasing subjective limits for OC contracts

We propose an analysis to determine the most appropriate subjective limits for contracts that leverage OC. Depending on the results of the analysis, subjective limits may be increased for eosio.* contracts.

### Tasks
- [ ] https://github.com/AntelopeIO/leap/issues/1251
bhazzard commented 1 year ago

Full proposal: https://github.com/eosnetworkfoundation/product/pull/164

heifner commented 1 year ago

Propose: --eos-vm-oc-enable options auto (default), all, none. all corresponds to previous true and none corresponds to previous false.

heifner commented 1 year ago

Propose: