首页> 外文会议>High integrity language technology >Tutorial Overview: Understanding Dynamic Memory Management in Safety Critical Java
【24h】

Tutorial Overview: Understanding Dynamic Memory Management in Safety Critical Java

机译:教程概述:了解安全关键Java中的动态内存管理

获取原文
获取原文并翻译 | 示例

摘要

In spite of the high-level abstraction benefits of automatic tracing garbage collection, current prevailing sentiment within the safety certification community is that a simpler memory model is required for the most rigorous levels of software safety certification. Thus, the draft JSR-302 specification for safety critical Java relies on scope-based memory allocation rather than tracing garbage collection. The scoped memory model for JSR-302 is a simplification of the RTSJ model. JSR-302 enforces a strict hierarchy of scopes and distinguishes private scopes, which can be seen only by one thread, from mission scopes, which can be accessed by all the threads that comprise a mission, including threads running within inner-nested sub-missions. The hierarchical memory structure allows implementations to guarantee the absence of memory fragmentation for scope management, unlike the Real-Time Specification for Java from which the JSR-302 specification was derived. In the absence of block structure, it is more difficult in Java to safely manage references to stack-allocated objects than in Ada. While the simplified hierarchical management of scoped memory that is part of JSR-302 addresses memory fragmentation concerns, it does not guarantee the absence of dangling pointers. As with the Real-Time Specification for Java, JSR-302 requires a run-time check to enforce that no reference assignment creates a relationship whereby an outer-nested object is allowed to point to an inner-nested object. This rule assures the absence of dangling pointers, but it introduces a different problem: every assignment to a reference field must be accompanied by a run-time check to validate the appropriate scope nesting relationship. This run-time check will throw a run-time exception if the assignment is deemed inappropriate. The safety certification evidence for a given safety-critical Java program must therefore include an argument for every reference assignment that it will not cause the program to abort with a runtime exception. Furthermore, the certification evidence must prove that sufficient memory is available to reliably execute each safety-critical task in the system. This tutorial provides an overview of dynamic memory management in Safety Critical Java and describes two annotation systems that have been designed to support static (compile-time) enforcement of memory safety properties. The first annotation system is described in an appendix to the draft JSR-302 standard. This relatively simple annotation system, which is not considered normative, serves to demonstrate that memory safety can be statically proven without requiring extensive annotations throughout existing library code. The second annotation system is the system implemented in Perc Pico. This annotation system, which is much richer than the draft JSR-302 annotation, has been in experimental use for over five years. During that time, tens of thousands of lines of experimental application code have been developed, with the experience motivating a variety of refinements to the original design.
机译:尽管自动跟踪垃圾收集具有高层抽象的好处,但是安全认证界当前普遍认为,对于最严格的软件安全认证级别,需要更简单的内存模型。因此,针对安全性强的Java的JSR-302规范草案依赖于基于范围的内存分配,而不是跟踪垃圾回收。 JSR-302的作用域内存模型是RTSJ模型的简化。 JSR-302强制执行严格的作用域层次结构,并区分私有作用域和任务作用域,私有作用域只能由一个线程看到,而任务作用域可以由组成任务的所有线程(包括内部嵌套子任务中运行的线程)访问。分层内存结构允许实现来保证范围管理不存在内存碎片,这与JSR-302规范所源自的Java实时规范不同。在没有块结构的情况下,Java中安全地管理对堆栈分配的对象的引用比Ada中的困难。虽然作为JSR-302一部分的范围内存的简化分层管理解决了内存碎片问题,但它不能保证没有悬空指针。与Java实时规范一样,JSR-302需要运行时检查以强制没有引用分配创建关系,从而使外部嵌套对象指向内部嵌套对象。该规则可确保没有悬空的指针,但它引入了一个不同的问题:对参考字段的每个分配都必须伴随运行时检查,以验证适当的作用域嵌套关系。如果认为分配不适当,则此运行时检查将引发运行时异常。因此,给定的安全关键型Java程序的安全认证证据必须为每个引用分配都包含一个参数,该参数不会导致程序因运行时异常而中止。此外,认证证据必须证明有足够的内存来可靠地执行系统中的每个安全关键任务。本教程概述了Safety Critical Java中的动态内存管理,并介绍了两个注释系统,这些注释系统旨在支持内存安全属性的静态(编译时)实施。在JSR-302标准草案的附录中描述了第一个注释系统。这种相对简单的注释系统(未被认为是规范性的)用于证明内存安全性可以被静态证明,而无需在整个现有库代码中进行大量注释。第二个注释系统是在Perc Pico中实现的系统。这个注释系统比JSR-302注释草案要丰富得多,已经在实验中使用了五年多。在这段时间里,已经开发了成千上万行实验应用程序代码,并具有对原始设计进行各种改进的经验。

著录项

相似文献

  • 外文文献
  • 中文文献
  • 专利
获取原文

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号