2.1为什么是Fuel (Why Fuel)

具有欺诈证明的用户主权 (User Sovereignty with Fraud Proofs)

Fuel was designed and built specifically to be fraud-provable, which enable support for trust-minimized light clients. Trust minimized light clients and shared data availability enables trust minimized bridges to other modular execution layers, something impossible to achieve between L1s.

Fuel 是为了让欺诈可证明而被设计和构建,进而支持信任最小化的轻客户端。信任最小化的轻客户端和共享的数据可用性,使到其他模块化执行层的跨链/桥接也变得信任最小化成为可能,这在 L1 之间是不可能实现的。

What this means in practice: 这在实践中意味着什么:

  • Long-term liquidity access 获取长期流动性

  • Users can validate the chain without having to run full nodes 用户无需运行完整节点即可验证链

  • Safely bridging assets 安全跨链/桥接资产

Fuel’s optimization for fraud proofs is the use of the UTXO model, which in turn means Fuel has no global state tree or account trees. If you wanted to apply the general construction of a fraud proof to a chain that uses the account model like Ethereum, the cost could be unbound, making it extremely expensive to produce a fraud proof. In this general construction of a fraud proof, given a pre-state and a state transition, you locally execute the transition and compare the output to the post-state produced by the block producer. If these differ, the post-state by the block producer was invalid. If you apply this general fraud proof model to Ethereum today, someone could create a transaction that calls many different contracts, and those contracts could each have up to 24kb of bytecode. In order to locally re-execute, you need to provide all the bytecode for all the contracts that were interacted with.

Fuel 对欺诈证明的优化是应用了 UTXO 模型,这反过来意味着 Fuel 没有全局状态树或帐户树。如果您想将欺诈证明的一般结构,应用于使用像以太坊这样的账户模型的链,那成本可能完全不受限控制,制作欺诈证明的成本会极其高昂。在这种欺诈证明的一般结构中,给定前状态和状态转换,您在本地执行转换,并将输出与区块生产者生成的后状态进行比较。如果这些不同,则区块生产者的后状态无效。如果你今天将这种通用的欺诈证明模型应用到以太坊,那有人可以创建一个调用许多不同合约的交易,而这些合约每个可能有多达 24kb 的字节码。为了在本地重新执行,您需要为与之交互的所有合约提供所有字节码。

Read more about trust-minimized light clients and sovereignty here.

此处 阅读更多关于信任最小化的轻客户端和(用户)主权的信息。

Superior DevEx

Fuel’s technology comes together to provide a superior developer experience. Here’s how we do it:

Fuel 合力来为开发者提供卓越体验。我们是这样做的:

Sway 和Fuel工具链 (Sway and Fuel Toolchain)

The FuelVM is designed to be vertically integrated with tooling.

FuelVM 意在与工具垂直集成。

Unlike EVM which was designed without a language from the start, the FuelVM is built alongside its companion language, Sway, ensuring it has handy and efficient ops, such as getting specific parts of a tx. Sway is a Rust-based DSL created specifically to leverage a blockchain VM without needlessly verbose boilerplate. Sway leverages Rust’s safety and catches errors and bugs at compile-time, giving developers peace of mind. Read more about Sway here.

与从一开始就没有(编程)语言设计的 EVM 不同,FuelVM 是与其配套语言 Sway 一起构建的,进而确保其具有方便且高效,例如获取 tx 的特定部分。 Sway 是一种基于 Rust 的 DSL,专门用于使用区块链 VM 而无需冗长的样板文件。 Sway 利用 Rust 的安全性并在编译时捕获错误和漏洞,让开发人员高枕无忧。点击 此处 详细了解 Sway。

Fuel Labs has also developed the Fuel Toolchain: the full stack of tools for enabling/assisting the Fuel application development experience. Read more about the Fuel Toolchain here.

Fuel Labs 还开发了 Fuel 工具链:用于启用/协助 Fuel 应用开发体验的全套工具。在 此处 阅读有关 Fuel 工具链的更多信息。

并行执行 (Parallel Execution)

Fuel brings scale to Ethereum without sacrificing decentralization.The FuelVM is designed to reduce wasteful processing of traditional blockchain virtual machine architectures, while vastly increasing the potential design space for developers. The FuelVM can use all the threads and cores of your CPU to validate transactions.

Fuel 在不牺牲去中心化的情况下为以太坊进行扩容。FuelVM 旨在减少传统区块链虚拟机架构的浪费/冗余处理,同时极大地增加开发人员的潜在设计空间。 FuelVM 可以使用 CPU 的所有线程和内核来验证交易。

Fuel的配置 (Fuel Configurations)

As a Modular Execution Layer, Fuel can function in any one of these categories. Developers can configure Fuel as-needed by switching out a few modules in the client.

作为模块化执行层,Fuel 可以在这些类别中的任何一个类别中发挥作用。开发人员可以根据需要通过切换客户端中的几个模块来配置 Fuel。

改进的虚拟机 (Improved VM)

The Ethereum community has suggested many implementation improvements to improve EVM performance. Unfortunately, many of these improvement proposals haven’t been implemented because they would break backward compatibility.

以太坊社区提出了许多实施改进以提高 EVM 性能。不幸的是,许多这些改进建议尚未实施,因为它们会破坏向后兼容性。

Execution layers built on Ethereum give us a new opportunity to build something better. Designs don’t need to be backward compatible and in fact, can do whatever is necessary to deliver global throughput and adoption for Ethereum. The FuelVM is the EVM greatly improved. Check out this non-exhaustive list of EIPs (Ethereum Improvement Proposals) implemented in the FuelVM here.

建立在以太坊上的执行层给了我们一个新的机会来构建更好的东西。设计不需要向后兼容,事实上,可以做任何必要的事情来为以太坊提供全球吞吐量和采用。 FuelVM 是大大改进的 EVM。查看 FuelVM 此处 中实施的 EIP(以太坊改进提案)的非详尽列表。

FuelVM 和 EVM 有很多重叠。以下是它们的不同之处,请在 FuelVM 与 EVM 查看更完整的列表 (The FuelVM and EVM have a lot of overlap. Here's how they're different, view a more complete list at FuelVM vs. EVM)

FuelVM 具有全局共享内存架构而不是情景化的本地内存 (The FuelVM has a globally shared memory architecture instead of context-local memory)

The FuelVM has a globally shared memory architecture. Instead of every contract call having its own separate memory space, call data, and return data, all contract call frames share global memory. This chunk of memory is shared amongst all call frames and is globally readable. This allows you to pass data around between contracts without expensive storage and pass chunks of data without having to serialize, copy from call data to memory, etc. Read more about the FuelVM memory model here.

FuelVM 具有全局共享内存架构。不是每个合约调用都有自己独立的内存空间、调用数据和返回数据,而是所有合约调用帧共享全局内存。这块内存在所有调用帧之间共享,并且是全局可读的。这使您可以在合约之间传递数据而无需昂贵的存储空间,并且无需序列化、无需从调用数据复制到内存等。在阅读有关 FuelVM 内存模型的更多信息 此处

FuelVM 专为欺诈证明而设计 (The FuelVM is designed for fraud-provability)

The EVM is a complicated machine to construct fraud proofs for. It usually requires a second layer such as WASM or MIPS to be interpreted into a fraud provable system. Check out User Sovereignty with Fraud Proofs and how fraud proofs unlock key functionality.

构建欺诈证明,对EVM 来说就十分复杂。它通常需要第二层,如 WASM 或 MIPS,才能被解释为欺诈可证明的系统。查看带有欺诈证明的用户主权欺诈证明如何解锁关键功能

FuelVM 有多个原生资产 (FuelVM has multiple native assets)

In Ethereum, the only native asset is Ether. It’s the only one that gets first-class treatment in terms of cost and ability to be pushed and pulled through a call. In Fuel, any contract can mint its UTXO-based native asset using a set of easy asset opcodes. All of which can gain the benefits of native-level call and optimization. Read more about support for multiple native assets in the Sway docs, and here.

在以太坊中,唯一的原生资产是以Ether。它是唯一在成本与通过调用来“折腾”的能力两方面,(都)获得一流待遇的产品。在 Fuel 中,任何合约都可以使用一组简单的资产操作码来铸造其基于 UTXO 的原生资产。所有这些都可以获得原生级别调用和优化的好处。查看 Sway 文档此处

Read the full specification of the FuelVM here.

此处 阅读 FuelVM 的完整规范。

Last updated