首页> 外国专利> Method and System to Space-Efficiently Track Memory Access of Object-Oriented Language in Presence of Garbage Collection

Method and System to Space-Efficiently Track Memory Access of Object-Oriented Language in Presence of Garbage Collection

机译:存在垃圾回收的空间高效跟踪面向对象语言内存访问的方法和系统

摘要

The present invention provides a method and system for processing memory access events. The method comprises: executing an extended program including instrumented memory tracking code for tracking memory access events of a plurality of objects; allocating a unique identifier for each of the plurality of tracked objects; creating a weak reference for each of the plurality of tracked objects, wherein a mapping relationship is established between the identifier of the weak reference and that of the corresponding tracked object; recording and storing the memory access events of the plurality of tracked objects; in response to receiving a notification of memory garbage collection which includes an identifier of a weak reference of a collected object, determining the identifier of the collected object based on the mapping relationship between the identifier of the weak reference and that of the corresponding tracked object, and searching the stored memory access events for the memory access events of the collected object; and deleting the memory access events of the collected object. The storage overhead may be reduced according to the above method of the present invention.
机译:本发明提供了一种用于处理存储器访问事件的方法和系统。该方法包括:执行扩展程序,该扩展程序包括用于跟踪多个对象的存储器访问事件的仪器化的存储器跟踪代码;以及为多个被跟踪对象的每一个分配唯一标识符;为多个跟踪对象的每一个创建一个弱引用,其中,在弱引用的标识符和对应的跟踪对象的标识符之间建立映射关系;记录并存储多个被跟踪对象的存储器访问事件;响应于接收到包括收集对象的弱引用的标识符的内存垃圾收集的通知,基于弱引用的标识符与对应的跟踪对象的标识符之间的映射关系,确定收集对象的标识符,在存储的内存访问事件中搜索收集对象的内存访问事件;并删除收集对象的内存访问事件。根据本发明的上述方法,可以减少存储开销。

著录项

  • 公开/公告号US2010114999A1

    专利类型

  • 公开/公告日2010-05-06

    原文格式PDF

  • 申请/专利权人 YAO QI;

    申请/专利号US20090610111

  • 发明设计人 YAO QI;

    申请日2009-10-30

  • 分类号G06F12/02;G06F12;

  • 国家 US

  • 入库时间 2022-08-21 18:51:30

相似文献

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

客服邮箱:kefu@zhangqiaokeyan.com

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

  • 服务号