咨询与建议

看过本文的还看了

相关文献

该作者的其他文献

文献详情 >A study of the allocation beha... 收藏

A study of the allocation behavior of C++ programs

C++ 的分配行为的研究编程序

作     者:Chang, JM Lee, WH Srisa-an, W 

作者机构:IIT Dept Comp Sci Chicago IL 60616 USA 

出 版 物:《JOURNAL OF SYSTEMS AND SOFTWARE》 (系统与软件杂志)

年 卷 期:2001年第57卷第2期

页      面:107-118页

核心收录:

学科分类:08[工学] 0835[工学-软件工程] 0812[工学-计算机科学与技术(可授工学、理学学位)] 

基  金:IIT ERIF 

主  题:software tools dynamic memory management object-oriented programming 

摘      要:The object-oriented programming (OOP) language systems tend to perform object creation and deletion prolifically. An empirical study has shown that C++ programs can have 10 times more memory allocation and deallocation than comparable C programs. However, the allocation behavior of C++ programs is rarely reported. This paper attempts to locate where the dynamic memory allocations are coming from and report an empirical study of the allocation behavior of C++ programs. Firstly, this paper summarizes the hypothesis of situations that invoke the dynamic memory management explicitly and implicitly. They are: constructors, copy constructors, overloading assignment operator=, type conversions and application-specific member functions. Secondly, the development of a source code level tracing tool is reported as a procedure to investigate the hypothesis. Most of the five C++ programs traced are real-world applications. Thirdly, allocation patterns, object size and age distribution are summarized. Among other things, we found that objects tend to have a very short life-span, and most of them are created through constructors and copy constructors. With these findings, we may improve the performance of dynamic memory management through, a profile-based strategy or reusing objects. (C) 2001 Elsevier Science Inc. All rights reserved.

读者评论 与其他读者分享你的观点

用户名:未登录
我的评分