您的位置:首页 > 产品设计 > UI/UE

Purify Quick Start

2004-12-14 15:25 375 查看
PURIFY 使用说明
1.下载
  可到IBM网站上下载15天试用版本。需要注册。
  https://www14.software.ibm.com/webapp/iwm/web/preLogin.do?pkgid=&S_SRCID=RATLe-PURIFYLXUX-EVAL&source=RATLe-PURIFYLXUX-EVAL&S_TACT=104AH+W42&S_CMP=&S_PKG=CR2AZML&s=z<ype=select&l=English+International&mtype=input&m=download&id=2004-04-30+03%3A36%3A51.735187R&fam=&cat=
<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /> 

2.安装,配置
  tar -zxvf purify.tar.gz
  cd PurifyPlus
4000
<?xml:namespace prefix = st1 ns = "urn:schemas-microsoft-com:office:smarttags" />.2003a.06.13/
  ./rs_install
  然后跟着提示一步步安装吧,有2个地方需要输入,一个是安装的路径,一个是LICESE文件的位置
3.配置
   假设安装再/usr/local/Rational下
  修改/etc/profile文件加入
  export PATH=$PATH:/usr/local/Rational/releases/purify.i386_linux2.2003a.06.13;
  export PURIFYOPTIONS="-follow-child-processes=yes -log-file=mylog.%v.%p";
4.重新编译程序。
  类似purify cc -o test test.c
  如果是C++的程序的话,要加上-libstdc++.
  一般来讲,修改下make文件就可以了
5.错误检查
  查看错误日志吧。看看mylog.*吧
6.错误信息
下面是Purify所能检测到的内存信息表:

 

内存信息
描述
错误等级
ABR
Array Bounds Read 数组越界读
3级
ABW
Array Bounds Write 数组越界写
2级
BSR
Beyond Stack Read 越栈读
3级
BSW
Beyond Stack Write 越栈写
3级
COR
Core Dump Imminent 非法操作
1级
FIU
File Descriptors In Use 文件描述符被使用
4级
FMM
Freeing Mismatched Memory 释放错误内存
2级
FMR
Free Memory Read 对已释放内存读
3级
FMW
Free Memory Write 对已释放内存写
2级
FNH
Freeing Non Heap Memory 释放非堆内存
2级
FUM
Freeing Unallocated Memory 释放了没有分配的内存
2级
IPR
Invalid Pointer Read 非法指针读
1级
IPW
Invalid Pointer Write 非法指针写
1级
MAF
Malloc Failure 分配内存失败
4级
MIU
Memory In-Use 内存正在使用
4级
MLK
Memory Leak 内存泄露
3级
MRE
Malloc Reentrancy Error remalloc错
2级
MSE
Memory Segment Error 内存段错
3级
NPR
Null Pointer Read 空指针读
1级
NPW
Null Pointer Write 空指针写
1级
PAR
Bad Parameter 错误的参数
3级
PLK
Potential Leak 潜在的内存泄露
3级
SBR
Stack Array Bounds Read 栈数组越界读
3级
SBW
Stack Array Bounds Write 栈数级越界写
2级
SIG
Signal 信号
4级
SOF
Stack Overflow 栈溢出
3级
UMC
Uninitialized Memory Copy 对未初始化的内存进行拷贝
3级
UMR
Uninitialized Memory Read 对未初始化的内存读
3级
WPF
Watchpoint Free 释放被监控的内存
4级
WPM
Watchpoint Malloc 被监控的内存分配
4级
WPN
Watchpoint Entry 被监控的内存
4级
WPR
Watchpoint Read 被监控的内存读
4级
WPW
Watchpoint Write 被监控的内存写
4级
WPX
Watchpoint Exit 退出被监控的内存
4级
ZPR
Zero Page Read 零页面读
1级
ZPW
Zero Page Write 零页面写
1级
 

1级:致命错误。   2级:危险错误。    3级:警告信息     4级:提示信息(非错误)

 

 

7.参考资料
  1.C/C++内存问题检查利器——Purify 陈皓 http://blog.csdn.net/haoel/archive/2003/12/11/2900.aspx
  2.  随安装包带的帮助。
 
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  leak c++ signal path maf wpf