Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
10.1145/3372885.3373811acmconferencesArticle/Chapter ViewAbstractPublication PagespoplConference Proceedingsconference-collections
research-article

Verifying x86 instruction implementations

Published: 22 January 2020 Publication History

Abstract

Verification of modern microprocessors is a complex task that requires a substantial allocation of resources. Despite significant progress in formal verification, the goal of complete verification of an industrial design has not been achieved. In this paper, we describe a current contribution of formal methods to the validation of modern x86 microprocessors at Centaur Technology. We focus on proving correctness of instruction implementations, which includes the decoding of an instruction, its translation into a sequence of micro-operations, any subsequent execution of traps to microcode ROM, and the implementation of these micro-operations in execution units. All these tasks are performed within one verification framework, which includes a theorem prover, a verified symbolic simulator, and SAT solvers. We describe the work of defining the needed formal models for both the architecture and micro-architecture in this framework, as well as tools for decomposing the requisite properties into smaller lemmas which can be automatically checked. We additionally cover the advantages and limitations of our approach. To our knowledge, there are no similar results in the verification of implementations of an x86 microprocessor.

References

[1]
Accessed: December 2019. ACL2 Books: Codewalker. Online. https://github.com/acl2/acl2/tree/master/books/projects/ codewalker .
[2]
Accessed: December 2019. ACL2 Home Page. Online. http://www.cs.utexas.edu/users/moore/acl2 .
[3]
Accessed: December 2019. Documentation of SV: A Hardware Verification Library. Online. http://www.cs.utexas.edu/users/moore/acl2/manuals/current/ manual/?topic=ACL2____SV .
[4]
Accessed: December 2019. Documentation of VL Verilog Toolkit. Online. http://www.cs.utexas.edu/users/moore/acl2/manuals/current/ manual/?topic=ACL2____VL .
[5]
Accessed: December 2019. SV: A Hardware Verification Library. Online. https://github.com/acl2/acl2/tree/master/books/centaur/sv .
[6]
Accessed: December 2019. SVTV: A Structure for Simulation Pattern of a Hardware Design. Online. http://www.cs.utexas.edu/users/moore/acl2/manuals/current/ manual/?topic=ACL2____DEFSVTV .
[7]
Accessed: December 2019. VL Verilog Toolkit. Online. https://github.com/acl2/acl2/tree/master/books/centaur/vl .
[8]
Accessed: December 2019. x86isa Library in the ACL2 Community Books. Online. https://github.com/acl2/acl2/tree/master/books/projects/x86isa .
[9]
Warren A. Hunt Jr., Sol Swords, Jared Davis, and Anna Slobodova. 2010. Use of Formal Verification at Centaur Technology. In Design and Verification of Microprocessor Systems for High-Assurance Applications, David Hardin (Ed.). Springer, 65–88.
[10]
Mark D. Aagaard. 2003. A hazards-based correctness statement for pipelined circuits. In Advanced Research Working Conference on Correct Hardware Design and Verification Methods. Springer, 66–80.
[11]
Mark D. Aagaard, Robert B. Jones, Thomas F. Melham, John W. O’Leary, and Carl-Johan H. Seger. 2000. A methodology for large-scale hardware verification. In International Conference on Formal Methods in Computer-Aided Design. Springer, 300–319.
[12]
Mark D. Aagaard, Robert B. Jones, and Carl-Johan H. Seger. 1998. Combining Theorem Proving and Trajectory Evaluation in an Industrial Environment. In Proceedings of the 35th Annual Design Automation Conference (DAC ’98). ACM, New York, NY, USA, 538–541.
[13]
Mark D. Aagaard, Robert B. Jones, and Carl-Johan H. Seger. 1999. Formal verification using parametric representations of Boolean constraints. In Proceedings 1999 Design Automation Conference (Cat. No. 99CH36361). IEEE, 402–407.
[14]
Anna Slobodova, Jared Davis, Sol Swords, and Warren A. Hunt Jr. 2011. A flexible formal verification framework for industrial scale validation. In Proceedings of the 9th IEEE/ACM International Conference on Formal Methods and Models for Codesign (MEMOCODE). IEEE/ACM, Cambridge, UK, 89–97.
[15]
Tamarah Arons, Elad Elster, Limor Fix, Sela Mador-Haim, Michael Mishaeli, Jonathan Shalev, Eli Singerman, Andreas Tiemeyer, Moshe Y. Vardi, and Lenore D Zuck. 2005. Formal verification of backward compatibility of microcode. In International Conference on Computer Aided Verification. Springer, 185–198.
[16]
Alessandro Coglio and Shilpi Goel. 2018. Adding 32-bit Mode to the ACL2 Model of the x86 ISA. In Proceedings of the 15th International Workshop on the ACL2 Theorem Prover and Its Applications, ACL2 2018, Austin, Texas, USA, November 5-6, 2018 (EPTCS), Vol. 280. 77–94.
[17]
Jared Davis, Anna Slobodova, and Sol Swords. 2014. Microcode Verification – Another Piece of the Microprocessor Verification Puzzle. In ITP ’14: Proceedings of Interactive Theorem Proving. Springer, LNCS 8558, 1–16.
[18]
Anders Franzén, Alessandro Cimatti, Alexander Nadel, Roberto Sebastiani, and Jonathan Shalev. 2010. Applying SMT in Symbolic Execution of Microcode. In Proceedings of the 2010 Conference on Formal Methods in Computer-Aided Design (FMCAD ’10). FMCAD Inc, Austin, TX, 121–128. http://dl.acm.org/citation.cfm?id=1998496.1998520
[19]
Warren A. Hunt Jr. and Sol Swords. 2009. Centaur Technology media unit verification. In Proceedings of the 21st International Conference on Computer Aided Verification (CAV). 353–367.
[20]
Intel Corporation. May, 2019. Intel ® 64 and IA-32 Architectures Software Developer’s Manual Combined Volumes: 1, 2A, 2B, 2C, 2D, 3A, 3B, 3C, 3D, and 4. Online. Order Number: 325462-070US. https://software.intel.com/en-us/articles/intel-sdm .
[21]
Intel Corporation. May, 2019. Intel ® Architecture Instruction Set Extensions Programming Reference. Order Number: 319433-037. https://software.intel.com/en-us/articles/intel-sdm .
[22]
Robert B. Jones. 2002. Symbolic simulation methods for industrial formal verification. Springer Science & Business Media.
[23]
Roope Kaivola. 2005. Formal verification of Pentium ® 4 components with symbolic simulation and inductive invariants. In International Conference on Computer Aided Verification. Springer, 170–184.
[24]
Roope Kaivola, Rajnish Ghughal, Naren Narasimhan, Amber Telfer, Jesse Whittemore, Sudhindra Pandav, Anna Slobodova, Christopher Taylor, Vladimir Frolov, Erik Reeber, and Armaghan Naik. 2009. Replacing Testing with Formal Verification in Intel ® Core TM i7 Processor Execution Engine Validation. In Computer Aided Verification, Ahmed Bouajjani and Oded Maler (Eds.). Springer Berlin Heidelberg, Berlin, Heidelberg, 414–429.
[25]
Magnus O. Myreen, Mike Gordon, and Konrad Slind. 2008. MachineCode Verification for Multiple Architectures - An Application of Decompilation into Logic. In Formal Methods in Computer-Aided Design, 2008. FMCAD ’08. 1–8.
[26]
Alastair Reid, Rick Chen, Anastasios Deligiannis, David Gilday, David Hoyes, Will Keen, Ashan Pathirane, Erin Shepherd, Peter Vrabel, and Ali Zaidi. 2016. End-to-End Verification of ARM Processors with ISA-Formal, In Proceedings of the 2016 International Conference on Computer Aided Verification (CAV’16), S. Chaudhuri and A. Farzan (Eds.). CAV 2016, Part II, Lecture Notes in Computer Science 9780, 9780, 42–58.
[27]
Robert S. Boyer and J S. Moore. 1996. Mechanized Formal Reasoning About Programs And Computing Machines. Automated Reasoning and Its Applications: Essays in Honor of Larry Wos (1996), 147–176. https://www.cs.utexas.edu/users/boyer/bm96.pdf
[28]
David M. Russinoff. 2019. Formal Verification of Floating-Point Hardware Design: A Mathematical Approach. Springer.
[29]
Sandip Ray and J S. Moore. 2004. Proof Styles in Operational Semantics. In Proceedings of the 5th International Conference on Formal Methods in Computer-Aided Design (FMCAD 2004) (LNCS), A. J. Hu and A. K. Martin (Eds.), Vol. 3312. Springer-Verlag, Austin, TX, 67–81.
[30]
Sandip Ray, Warren A. Hunt, Jr., John Matthews, and J S. Moore. 2008. A Mechanical Analysis of Program Verification Strategies. Journal of Automated Reasoning 40, 4 (May 2008.), 245–269. http://www.cs. utexas.edu/users/sandip/publications/proofs-07/proofs.pdf
[31]
Shilpi Goel. 2016. Formal Verification of Application and System Programs Based on a Validated x86 ISA Model. Ph.D. Dissertation. Department of Computer Science, The University of Texas at Austin. https://repositories.lib.utexas.edu/handle/2152/46437
[32]
Shilpi Goel and Rob Sumners. 2019. Using x86isa for Microcode Verification. In SpISA 2019: Workshop on Instruction Set Architecture Specification. https://www.cl.cam.ac.uk/~jrh13/spisa19/paper_08.pdf
[33]
Anna Slobodova. 2015. Pragmatic Approach to Formal Verification. In SAT ’15: Proceedings of Theory And Applications Of Satisfiability Testing. Springer, LNCS 9340, IX–XI.
[34]
Daryl Stewart, David Gilday, Daniel Nevill, and Thomas Roberts. 2014. Processor memory system verification using DOGReL: a language for specifying end-to-end properties. In International Workshop on Design and Implementation of Formal Tools and Systems (DIFTS).
[35]
Sol Swords. 2017. Term-Level Reasoning in Support of Bit-blasting. In Proceedings 14th International Workshop on the ACL2 Theorem Prover and its Applications, Austin, Texas, USA, May 22-23, 2017 (Electronic Proceedings in Theoretical Computer Science), Anna Slobodova and Warren A. Hunt, Jr. (Eds.), Vol. 249. Open Publishing Association, 95–111.
[36]
Sol Swords and Jared Davis. 2011. Bit-Blasting ACL2 Theorems. In Proceedings 10th International Workshop on the ACL2 Theorem Prover and its Applications, Austin, Texas, USA, November 3-4, 2011 (Electronic Proceedings in Theoretical Computer Science), David Hardin and Julien Schmaltz (Eds.), Vol. 70. Open Publishing Association, 84–102.
[37]
Sol Otis Swords. 2010. A Verified Framework for Symbolic Execution in the ACL2 Theorem Prover. Ph.D. Dissertation. University of Texas at Austin. http://hdl.handle.net/2152/ETD-UT-2010-12-2210 .
[38]
Warren A. Hunt, Jr., Matt Kaufmann, J S. Moore, and Anna Slobodova. 2017. Industrial Hardware and Software Verification with ACL2, In Verified Trustworthy Software Systems. Phil. Trans. R. Soc. A 375.

Cited By

View all
  • (2024)Complete and Efficient Verification for a RISC-V Processor Using Formal Verification2024 Design, Automation & Test in Europe Conference & Exhibition (DATE)10.23919/DATE58400.2024.10546693(1-6)Online publication date: 25-Mar-2024
  • (2024)Formalizing x86-64 ISA in Isabelle/HOL: A Binary Semantics for eBPF JIT CorrectnessDependable Software Engineering. Theories, Tools, and Applications10.1007/978-981-96-0602-3_11(197-216)Online publication date: 25-Nov-2024
  • (2023)A High-Coverage and Efficient Instruction-Level Testing Approach for x86 ProcessorsIEEE Transactions on Computers10.1109/TC.2023.328876272:11(3203-3217)Online publication date: 1-Nov-2023
  • Show More Cited By

Index Terms

  1. Verifying x86 instruction implementations

    Recommendations

    Comments

    Information & Contributors

    Information

    Published In

    cover image ACM Conferences
    CPP 2020: Proceedings of the 9th ACM SIGPLAN International Conference on Certified Programs and Proofs
    January 2020
    381 pages
    ISBN:9781450370974
    DOI:10.1145/3372885
    Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than the author(s) must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected].

    Sponsors

    In-Cooperation

    Publisher

    Association for Computing Machinery

    New York, NY, United States

    Publication History

    Published: 22 January 2020

    Permissions

    Request permissions for this article.

    Check for updates

    Author Tags

    1. ACL2
    2. formal verification
    3. hardware verification
    4. microcode verification
    5. x86 ISA

    Qualifiers

    • Research-article

    Conference

    POPL '20
    Sponsor:

    Acceptance Rates

    Overall Acceptance Rate 18 of 26 submissions, 69%

    Upcoming Conference

    POPL '26

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • Downloads (Last 12 months)56
    • Downloads (Last 6 weeks)3
    Reflects downloads up to 26 Jan 2025

    Other Metrics

    Citations

    Cited By

    View all
    • (2024)Complete and Efficient Verification for a RISC-V Processor Using Formal Verification2024 Design, Automation & Test in Europe Conference & Exhibition (DATE)10.23919/DATE58400.2024.10546693(1-6)Online publication date: 25-Mar-2024
    • (2024)Formalizing x86-64 ISA in Isabelle/HOL: A Binary Semantics for eBPF JIT CorrectnessDependable Software Engineering. Theories, Tools, and Applications10.1007/978-981-96-0602-3_11(197-216)Online publication date: 25-Nov-2024
    • (2023)A High-Coverage and Efficient Instruction-Level Testing Approach for x86 ProcessorsIEEE Transactions on Computers10.1109/TC.2023.328876272:11(3203-3217)Online publication date: 1-Nov-2023
    • (2023)Polynomial Formal Verification of a Processor: A RISC-V Case Study2023 24th International Symposium on Quality Electronic Design (ISQED)10.1109/ISQED57927.2023.10129397(1-7)Online publication date: 5-Apr-2023
    • (2022)Application of Emu8086 in Digital Teaching Mode of Microcomputer Principle and Interface TechnologyInternational Journal of Education and Humanities10.54097/ijeh.v6i1.30836:1(158-161)Online publication date: 27-Nov-2022
    • (2022)A verified algebraic representation of cairo program executionProceedings of the 11th ACM SIGPLAN International Conference on Certified Programs and Proofs10.1145/3497775.3503675(153-165)Online publication date: 17-Jan-2022
    • (2020)Metamath Zero: Designing a Theorem Prover ProverIntelligent Computer Mathematics10.1007/978-3-030-53518-6_5(71-88)Online publication date: 17-Jul-2020

    View Options

    Login options

    View options

    PDF

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader

    Figures

    Tables

    Media

    Share

    Share

    Share this Publication link

    Share on social media