PAGE
+++
本科生毕业设计(论文)
学院(系): 软件学院
专 业: 软件工程
学 生: + 成
指导教师: +
完成日期 + 年 4 月
PAGE
+学院本科生毕业设计(论文)
C语言内存检测代码库的分析与设计
The analysis and design of C language memory test code library
总 计 : 24 页
表 格 : 0 个
插 图 : 17 幅
+ 学 院 本 科 毕 业 设 计(论文)
C语言内存检测代码库的分析与设计
The analysis and design of C language memory test code library
学 院(系): 软件学院
专 业: 软件工程
学 生 姓 名: +
学 号: +8
指 导 教 师(职称): +)
评 阅 教 师: +
完 成 日 期: 2011年4月
+
C语言内存检测代码库的分析与设计
C语言内存检测代码库的分析与设计
软件工程专业 +
[摘 要]程序员在C语言编程的过程中极易出现内存泄露,内存写越界等一系列问题,从而导致计算机的性能降低。最终,过多的可用内存被分配掉导致全部或部分设备停止正常工作,或者应用程序崩溃。本系统针对这一问题做了研究,通过对C语言常用库函数中的动态分配内存所有到如malloc,realloc,calloc,free等一些函数进行重写设计封装,并且对每次申请内存进行记录并标示,在内存释放的时候调用封装后释放函数对其内存信息标示进行修改。在程序结后调用atexit函数进行内存信息块的检索与统计内存使用信息,最终查出内存泄露,内存越界写等错误同时提示用户并保存出错信息。
[关键词]内存泄露;动态分配内存;检测内存
The analysis and design of C language memory test code library
The major of software engineering LV Xiao-cheng
Abstract: Memory leaks and the series of problems appear easily in the processing of the C programming language, such as memory write cross-border, resulting in computer performance reduced. Finally, the excessive available memory assigned off cause all or part of the equipment to stop work normally, or application collapse. This system according to this problem, based on C language commonly used in the library functions such as dynamic memory allocations all to realloc, calloc malloc, some function, free to design encapsulation, and rewrite record for each application and labeled, memory in memory when calls after release of its release function package labeling modified memory information. After the program "atexit function call memory information retrieval and statistics block memor