Ethereum, Block Time 15s, Block Gas Limit: 30m Gas(target: 15m), Gas/sec: 1m - ETH Transfer: 47tx/s - Token Transfer: 12 ~ 20 tx/s - Exchange on dexes: 4 ~ 8 tx/s Block space is limited to keep the characteristics of a blockchain that allows normal PCs to participate. (≒ Decentralization) That cause Usage fees are skyrocketing. 4
trying to achieve Scaling through a technology called Lightning Network How it works? (in a nutshell) Alis Bob Open a 0.2BTC Channel (2of2 Multisig) Create a tx for both to broadcast when closing. 0.1BTC 0.1BTC 1.Open Channel 6 6
trying to achieve Scaling through a technology called Lightning Network How it works? (in a nutshell) Alis Bob Channel (2of2 Multisig) Create a tx that send 0.09BTC to Alis and 0.11 BTC to Bob when closing the channel 0.1BTC -0.01BTC 2. When Alis send 0.01 BTC to bob 0.1BTC +0.01BTC … That Not write on The Bitcoin Network! 7 7
trying to achieve Scaling through a technology called Lightning Network How it works? (in a nutshell) Alis Bob Bitcoin Network Execute the HTLC Manner. Send the tx that Alis have 0.1BTC Tx(Older tx) 3. When Alis is evil and send Old Tx Bob send newer Tx that Alis has a fraud 8 8
be done with Lightning Network/Channel? - Ethereum mainly execute Smart Contract (Not ETH/Token transfers) - has a Contract account - has a Public Storage - increase the someone’s balance without permission Public Contract Account 10 10
not “execute” transaction →L1 does not check the result(state) is true. - All of Rollup tx data or proof of transactions is on Layer 1 - Tx on Rollup can be force in Layer 1 How do you refuse to be a fraud State? 1. Optimistic Rollup: Validators watch for several days and provide fraud proof if someone found a fraud. 2. zk Rollup: Refuse to update to fake Merkle Root with zero knowledge proof. (Won't let you know that I did a lot of computation, but I will prove that I did computation turely with zero-knowledge proofs.) 12 12
gas cost per batch ~40,000 (a lightweight transaction that mainly just changes the value of the state root) ~500,000 (verification of a ZK-SNARK is quite computationally intensive) Withdrawal period ~1 week (withdrawals need to be delayed to give time for someone to publish a fraud proof and cancel the withdrawal if it is fraudulent) Very fast (just wait for the next batch) Complexity of technology Low High (ZK-SNARKs are very new and mathematically complex technology) Ref: https://vitalik.ca/general/2021/01/05/rollup.html 13 13
Harder (ZK-SNARK proving general-purpose EVM execution is much harder than proving simple computations, though there are efforts (eg. Cairo) working to improve on this) Per-transaction on-chain gas costs Higher Lower (if data in a transaction is only used to verify, and not to cause state changes, then this data can be left out, whereas in an optimistic rollup it would need to be published in case it needs to be checked in a fraud proof) Off-chain computation costs Lower (though there is more need for many full nodes to redo the computation) Higher (ZK-SNARK proving especially for general-purpose computation can be expensive, potentially many thousands of times more expensive than running the computation directly) Ref: https://vitalik.ca/general/2021/01/05/rollup.html 14 14
on how dev implements. I introduce basics. 💤 💤 ORU Sequencer Rollup! Rollup! Rollup! 💼 OR Contract 💤 Ethereum Validator/Verifier checking that Sequencer submit correctly 15 15
on how dev implements. I introduce basics. 💤 💤 ORU Sequencer Rollup! Rollup! Rollup! 💼 OR Contract 💤 Ethereum Validator/Verifier found the sequencer fault 🚨Wrong! actual state is S2’ S1 S2 S3 16 16
on how dev implements. I introduce basics. 💤 💤 ORU Sequencer Rollup! Rollup! Rollup! 💼 OR Contract 🔍 Ethereum Validator/Verifier found the sequencer fault 🚨Wrong! actual state is S2’ S1 S2 S3 17 17
on how dev implements. I introduce basics. 💤 💤 ORU Sequencer Rollup! Rollup! Rollup! OR Contract 🟢 Ethereum Validator/Verifier found the sequencer fault I totally agree. It’s rewards.💰 S1 S2’ S3’ 💸 18 18
Rollup can restore nonce from previous batch (state) - from/to: replace from address to index number - sig: Compress all txs sig in Batch to 1 1 sig using BLS aggregate sig. Parameter Ethereum Rollup Nonce ~3 0 Gasprice ~8 0-0.5 Gas 3 0-0.5 To 21 4 Value ~9 ~3 Signature ~68 (2 + 33 + 33) ~0.5 From 0 (recovered from sig) 4 Total ~112 ~12 20 20
depend on how dev implements. I introduce basics. 💤 💤 OR Sequencer Rollup! Rollup! Rollup! OR Contract 🟢 Ethereum Validator/Verifier found the sequencer fault I totally agree. It’s rewards.💰 S1 S2’ S3’ 💸 ? 22 22
and Rollup Execution is sometimes not match - Return the same result if it is a simple addition like (1+1). But, block.timestamp + 1 isn’t match… (‘cause L1 block.timestamp and L2 block.timestamp isn’t the same) Solution - Build Execution Manager that bridge to L1 from L2 state that work on Solidity. https://medium.com/ethereum-optimism/ovm-deep-dive-a300d1085f52 https://medium.com/ethereum-optimism/introducing-evm-equivalence-5c2021deb306 23 23