1/ It's high time for @optimismPBC vs @arbitrum. I know you've been waiting for it so let's go!🔥🔥🔥

Long 🧵 Image
2/ Let me start with similarities, they both:

• are rollups ie. real L2s and they store all txs on L1
• are optimistic meaning they use fraud proofs
• use sequencers for instant "finality"
• have generic cross-chain messaging allowing creation of advanced token bridges like @MakerDAO's fast withdrawal bridge: forum.makerdao.com/t/announcing-t…
4/ Now, the fun part - differences. The biggest distinction is what happens when two parties disagree on the state after executing a tx ie. implementation of the fraud proof (FP) mechanism.
5/ Optimism uses single round fraud proofs. This means that L1 executes the whole L2 transaction on-chain to verify the state root. This makes FPs instant which is nice.
6/ But there are some problems too:

• you need to supervise tx execution hence need for OVM (aka rewriting EVM to avoid sideeffects)
• L2 tx gas is bound by L1 block gas limit
• you need on-chain state roots after each TX - costs more :(
• source of potential security issues
7/ Arbitrum features multi-round fraud proofs. You can dumb it down to doing a binary search between two parties to find the first opcode of a whole block that they disagree on. Once found only this particular opcode is executed on-chain.
8/ It has some nice properties:

• it requires posting on-chain just one state proof for a whole bunch of txs,
• L1 block gas limit doesn't matter since L2 txs will never entirely execute on L1
9/ Drawbacks:
• It requires EVM -> AVM translation (thankfully it's automatic)
• it's slow - in the worst case it takes up to 2 weeks to finish FP. Realistically it's 1 week.
• requires original claimer to be online and cooperative
10/ Another way of thinking about this is that Optimism does containerization and Arbitrum virtualization.
11/ Optimism's approach has one *HUGE* drawback. Imagine that there is a hardfork and Ethereum consensus rules change. One of the opcodes is removed/repriced or modified in some other way.
12/ Suddenly re-executing past tx on L1 will result in a different final state 😨 I am not sure how Optimism team is going to solve this but I am sure they will figure out something when the time comes. Arbitrum fully controls AVM specs and doesn't have this problem.
13/ Both projects try to stick as close as possible to the ethereum ecosystem but there are some differences here too. Generally speaking, you can still use EVM-related tooling that you know (solidity, hardhat, waffle etc.) BUT it's not that simple.
14/ Optimism requires a special solidity compiler to generate OVM bytecode. So, unfortunately, it works only with Solidity and only with particular versions of solidity. On the other hand, their L2 node is just modified geth which is great for compatibility.
15/ Arbitrum on the surface is fully compatible with EVM/JSON RPC spec but their node is a custom implementation. It does automatic EVM→ AVM transpilation to support fraud proofs. Thanks to this low-level translation, it supports any EVM language (vyper, YUL+ etc).
16/ Optimism uses weth but Arbtirum has native eth support. Optimism launches with wallet abstraction built in too.
17/ Arbitrum launches with a unified permissionless bridge to bridge any tokens to L2 (it deploys generic ERC20 as a L2 counterpart). Optimism prefers dedicated bridges but of course, deploying "unibridge" on optimism is possible as well. @dmihal knows more about this ;)
18/ The last difference is a launch date. Arbitrum launches "mainnet for developers" at the end of the month. For Optimism, we will have to wait until July.
19/ If you want to learn more, I recommend watching @karl_dot_tech and @hkalodner friendly debate moderated by @stonecoldpat0:
20/ Personally I am cheering for both projects and I can't wait for them to arrive on the mainnet. The whole ethereum community is in desperate need of a proper L2 solution, not some smoke and mirrors scalable sidechain (ekhm).
21/ Oof, this was my longest tweetstorm ever. Let me know what do you think. If you want to check out Optimism bridge example take a look at: github.com/BellwoodStudio… We will have Arbitrum compatible version ready next week 😏

• • •

Missing some Tweet in this thread? You can try to force a refresh

Keep Current with Kris Kaczor 🦆

Kris Kaczor 🦆 Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!


Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @krzKaczor

14 Jul
I just saw A LOT of excitement about fast confirmations on newly deployed @Uniswap on @optimismPBC , but how does it really work, and can users trust them? Finally, isn't a single sequencer that provides such confirmations a threat to decentralization? Let's talk it through👇👇👇
2/ First, things first — sequencers are privileged actors in many rollup systems (@optimismPBC , @arbitrum, @StarkWareLtd , @zksync ). They receive transactions from users, order them and submit them in batches to L1.
3/ The main reason why they exist is the simplicity and efficiency of having a single coordinator. At this stage, there is usually a single sequencer per rollup, and it's run by the creators of a rollup.
Read 21 tweets
9 May
TypeChain v5 is finally here!🔥

👉Incremental generation and typed getContractFactory (!) with @HardhatHQ
👉No more index signature for @ethersproject - catches more mistakes early
👉By default doesn't generate overloads when not needed - less clutter

I also couldn't help myself from adding a readme section with current users of TypeChain. All these awesome companies/protocols (and many others!) use TC: @MakerDAO (duh), @Uniswap, @AaveAave, @optimismPBC, and @zksync.
Browse full changelog at: github.com/ethereum-ts/Ty…
Read 4 tweets
4 May
A really cool deep dive into zkEVM by @gluk64 :

One of the interesting things is that zkEVM takes YUL as input and uses LLVM to generate the bytecode of the circuit. This means few things: 👇
First of all, the @zksync team didn't have to reimplement the whole solc but rather write only the LLVM backend. While this for sure is still not a trivial task, it makes bug surface smaller and toolchain audits easier.
Smart contracts written in other languages like Vyper or YUL+ can be ported to zkEVM too.
Read 5 tweets

Did Thread Reader help you today?

Support us! We are indie developers!

This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal Become our Patreon

Thank you for your support!

Follow Us on Twitter!