High-Performance Virtual Machine Design for Domain-Specific Languages
Access status:
Open Access
Type
ThesisThesis type
Doctor of PhilosophyAuthor/s
Hu, XiaowenAbstract
Domain-specific languages (DSLs) play a crucial role in addressing unique computational challenges and applications. Traditionally, many DSLs are implemented via interpreters, chosen for their ease of implementation, superior portability, and flexibility. Yet, interpreters are often ...
See moreDomain-specific languages (DSLs) play a crucial role in addressing unique computational challenges and applications. Traditionally, many DSLs are implemented via interpreters, chosen for their ease of implementation, superior portability, and flexibility. Yet, interpreters are often critiqued for their inefficiency relative to compilers. Many optimization techniques for interpreters are largely dated, originating from the late 90s, or rely on modern Just-In-Time (JIT) compilation methods, which demand substantial engineering effort and are not universally applicable across all DSLs. Moreover, these techniques frequently overlook the domain-specific knowledge intrinsic to DSLs, treating DSL interpreters as mere general-purpose language implementations. This work aims to analyze and enhance the performance of two distinct DSLs: Soufflé, a modern Datalog implementation for program analysis, and the Ethereum Virtual Machine (EVM), the fundamental engine of the Ethereum blockchain platform. For Soufflé, we introduce an innovative tree representation and employ de-specialization techniques. The de-specialization capitalizes on the synthesis nature of high-performance Datalog, substantially improving interpreter performance. In the context of the EVM, we utilize the blockchain's global state to develop a sophisticated dynamic tracing tool. This tool aids in understanding the EVM's runtime characteristics, revealing insights into potential parallelism and identifying redundancies in memory and storage operations within low-level smart contracts. Lastly, by analyzing the EVM's execution history, we identify common execution patterns and experiment with an advanced super-instruction selection strategy. This strategy enables the generation of a specialized EVM interpreter using a meta-compiler, as an effort to improve its overall performance.
See less
See moreDomain-specific languages (DSLs) play a crucial role in addressing unique computational challenges and applications. Traditionally, many DSLs are implemented via interpreters, chosen for their ease of implementation, superior portability, and flexibility. Yet, interpreters are often critiqued for their inefficiency relative to compilers. Many optimization techniques for interpreters are largely dated, originating from the late 90s, or rely on modern Just-In-Time (JIT) compilation methods, which demand substantial engineering effort and are not universally applicable across all DSLs. Moreover, these techniques frequently overlook the domain-specific knowledge intrinsic to DSLs, treating DSL interpreters as mere general-purpose language implementations. This work aims to analyze and enhance the performance of two distinct DSLs: Soufflé, a modern Datalog implementation for program analysis, and the Ethereum Virtual Machine (EVM), the fundamental engine of the Ethereum blockchain platform. For Soufflé, we introduce an innovative tree representation and employ de-specialization techniques. The de-specialization capitalizes on the synthesis nature of high-performance Datalog, substantially improving interpreter performance. In the context of the EVM, we utilize the blockchain's global state to develop a sophisticated dynamic tracing tool. This tool aids in understanding the EVM's runtime characteristics, revealing insights into potential parallelism and identifying redundancies in memory and storage operations within low-level smart contracts. Lastly, by analyzing the EVM's execution history, we identify common execution patterns and experiment with an advanced super-instruction selection strategy. This strategy enables the generation of a specialized EVM interpreter using a meta-compiler, as an effort to improve its overall performance.
See less
Date
2024Rights statement
The author retains copyright of this thesis. It may only be used for the purposes of research and study. It must not be used for any other purposes and may not be transmitted or shared with others without prior permission.Faculty/School
Faculty of Engineering, School of Computer ScienceAwarding institution
The University of SydneyShare