期刊文献+

_mJava到Micro-Dalvik虚拟机的编译验证 被引量:3

Formal Verification of _mJava Compiler Targeting Micro-Dalvik Virtual Machine
下载PDF
导出
摘要 针对类Java的面向对象语言mJava到类Dalvik的寄存器架构虚拟机Micro-Dalvik的编译验证,给出了mJava语言和Micro-Dalvik的操作语义.从mJava语言程序到Micro-Dalvik虚拟机指令的编译分为两步,首先将mJava语言程序中的本地变量名转换为相应的序号,得到一个中间语言程序,再将该中间语言程序翻译成Micro-Dalvik虚拟机指令程序.在给出中间语言的操作语义后,构造了mJava语言程序与编译后的中间语言程序的语义保持定理并证明,以及构造了中间语言程序的语义与编译后的Micro-Dalvik虚拟机程序的语义保持定理并证明.整个形式化编译验证在定理证明助手Isabelle/HOL中进行了机器检测.mJava语言和Micro-Dalvik虚拟机分别对Java语言和Dalvik虚拟机进行了抽象,是我们兼顾语言的真实性和形式化的清晰性的结果.但是,所有形式化的语义严格遵从语言规范中的定义,并与Dalvik VM的实现保持一致,从这种意义上讲,该编译器并不是一个实验性质的假想编译器,而是有其实用意义的. This paper introduces a formal verification of mJava compiler targeting Micro-Dalvik virtual machine (VM)where m Java is an object-oriented language similar to Java,and Micro-Dalvik is a Dalvik-like VM of the register-based architecture.The operational semantics of m Java and Micro-Dalvik VM are defined.The compiler operates in two sta-ges.First it replaces the names of local variables by their corresponding indices and hence translates mJava into an intermedi-ate language.Then it generates the Micro-Dalvik VM instructions.After defining the operational semantics of the intermedi-ate language,the correctness of the two stages are formulated in terms of the preservation of the semantics and is proved re-spectively.The whole formalization is machine-checked in the theorem proof assistant Isabelle/HOL.The m Java language and Micro-Dalvik VM are more abstract than the comparable Java and the Dalvik VM,respectively,which is a result of a compromise between the the realism of the language and the clarity of the formalization.However,mJava language and Mi-cro-Dalvik VM exhibit core features of an object-oriented programming language and a register-based architecture,respec-tively,and thus in this sense,this verified compiler is non-trivial.
出处 《电子学报》 EI CAS CSCD 北大核心 2016年第7期1619-1629,共11页 Acta Electronica Sinica
基金 国家自然科学基金(No.61373039)
关键词 编译验证 定理证明 操作语义 机器检测 寄存器架构 面向对象语言 compiler verification theorem proving formal semantics machine-check register-based architecture ob-ject-oriented
  • 相关文献

参考文献40

  • 1Boyle MJ, Resler DR, Winter LV. Do you trust your com- piler [ J ]. Computer, 1999,32 (5) :65-73.
  • 2何炎祥,吴伟,刘陶,李清安,陈勇,胡明昊,刘健博,石谦.可信编译理论及其核心实现技术:研究综述[J].计算机科学与探索,2011,5(1):1-22. 被引量:12
  • 3Stepney S. High Integrity Compilation:A Case Study[ M]. Haffield: Prentice Hall Intemational(UK) Ltd, 1993.
  • 4McCarthy J, Painter J. Correctness of a compiler for arith- metic expression [ A ]. Proceedings of the Symposium in Applied Mathematics[ C]. Rhode Island, USA, 1967. 33 -41.
  • 5Plotldn DG. The Origins of structural operational semantics[J ]. The Journal of Logic and Algebraic Programming, 2004,6:3 - 15.
  • 6Morris LF. Advice on structuring compilers and proving them correct[ A]. Proceedings of the 1 st Annual ACM SI- GACT-SIGPLAN Symposium on Principles of Program- ming Languages ( POPL' 73 ) [ C ]. Boston: ACM Press, 1973. 144 - 152.
  • 7Zadamowski P. C lambda calculus & compiler verification [ D]. Sydney :University of New South Wales ,2011.
  • 8Burstall MR. Proving properties of programs by structural induction[ J]. The Computer Journal, 1969, 12 ( 1 ) : 41 -48.
  • 9Nipkow T, Paulson CL, Wenzel M. A Proof for Higher- Order Logic [ M]. Berlin: Springer-Verlag, 2010.
  • 10Yves B, Pierre C. Interactive Theorem Proving and Pro- gram Development: Coq' Art: the Calculus of Inductive Constructions [ M ]. Berlin: Springer-Verlag,2004.

二级参考文献34

  • 1张焕国,罗捷,金刚,朱智强,余发江,严飞.可信计算研究进展[J].武汉大学学报(理学版),2006,52(5):513-518. 被引量:114
  • 2Department of Defense. DoD 5200.28-STD Department of defense trusted computer system evaluation criteria[S]. USA: DoD, 1985.
  • 3Ehringer D. The Dalvik virtual machine architecture. Technical Report, 2010. http://davidehringer.com/software/android/The_ Dalvik_Virtual_Machine.pdf.
  • 4Davis B, Beatty A, Casey K, Gregg D, Waldron J. The case for virtual register machines. In: Prec. of the 2003 Workshop on Interpreters, Virtual Machines and Emulators (IVME 2003). ACM Press, 2003.41-49. [doi: 10.1145/858570.858575].
  • 5Security Engineering Research Group. Analysis of Dalvik virtual machine and class path library. Technical Report, Pakistan: Institute of Management Sciences Peshawar, 2009.
  • 6He YX, Wu W. Theory and key technology of trusted compiler. Beijing: Science Press, 2013. 15-58 (in Chinese).
  • 7Sebesta RW. Concepts of Programming Languages. 10th ed., Boston: Addison-Wesley Educational Publishers, Inc., 2012.
  • 8Slonneger K, Kurtz BL. Formal Syntax and Semantics of Programming Languages. Boston: Addison Wesley Longman, 1995.
  • 9He YX, Wu W, Liu T, Li QA, Chen Y, Hu MH, Liu JB, Shi Q. Theory and key implementation techniques of trusted compiler: A survey. Journal of Frontiers of Computer Science and Technology, 2011,5(1):1-22 (in Chinese with English abstract). [doi: 10.3778/j.issn.1673-9418.2011.01.001 ].
  • 10Xu C, He YX, Wu W, Chen Y, Liu JB. Verifying implementation correctness of compiling optimization based on simulation relation. Chinese Journal of Electronics, 2012,40(11): 2171-2176 (in Chinese with English abstract). [doi: 10.3969/j.issn.0372- 2112.2012.11.005].

共引文献15

同被引文献10

引证文献3

二级引证文献11

相关作者

内容加载中请稍等...

相关机构

内容加载中请稍等...

相关主题

内容加载中请稍等...

浏览历史

内容加载中请稍等...
;
使用帮助 返回顶部