Automatic Generation and Validation of Instruction Encoders and Decoders
Xiangzhe Xu, Jinhua Wu, Yuting Wang, Zhenguo Yin, Pengfei Li
摘要
Abstract Verification of instruction encoders and decoders is essential for formalizing manipulation of machine code. The existing approaches cannot guarantee the critical consistency property, i.e., that an encoder and its corresponding decoder are mutual inverses of each other. We observe that consistent encoder-decoder pairs can be automatically derived from bijections inherently embedded in instruction formats. Based on this observation, we develop a framework for writing specifications that capture these bijections, for automatically generating encoders and decoders from these specifications, and for formally validating the consistency and soundness of the generated encoders and decoders by synthesizing proofs in Coq and discharging verification conditions using SMT solvers. We apply this framework to a subset of X86-32 instructions to illustrate its effectiveness in these regards. We also demonstrate that the generated encoders and decoders have reasonable performance.
问问这篇 Paper
问问你的智能体。
Lune 读过与它相关的顶会 Paper,每个回答都会注明依据哪几篇。
相关 Paper
- An SMT Encoding of LLVM's Memory Model for Bounded Translation ValidationJuneyoung Lee, Dongjoo Kim, Chung-Kil Hur, Nuno P. LopesCAV 2021 · 被引用 10 次
- EXAMINER: automatically locating inconsistent instructions between real devices and CPU emulators for ARMMuhui Jiang, Tianyi Xu, Yajin Zhou, Yufeng Hu 等ASPLOS 2022 · 被引用 13 次
- InstrSem: Automatically and Generically Inferring Semantics of (Undocumented) CPU InstructionsLorenz Hetterich, Fabian Thomas, Tristan Hornetz, Michael SchwarzUSENIX Security 2026
- Counterexample-Guided Inference of Modular SpecificationsWilliam T. Hallahan, Ranjit Jhala, Ruzica PiskacOOPSLA 2025 · 被引用 1 次
- Counterexample-guided correlation algorithm for translation validationShubhani Gupta, Abhishek Rose, Sorav BansalOOPSLA 2020 · 被引用 14 次
