Operating System - HP-UX
1752637 Members
6197 Online
108788 Solutions
New Discussion юеВ

How to use librtc in HP-PA to identify the memory issues

 
How to use librtc and i
Occasional Contributor

How to use librtc in HP-PA to identify the memory issues

Hi,

In sun platform,I used libumem library instead of libc and compiled the code to identify memory issues. Is there any similar kind of a library in HP-UX?
Will librtc solve the above mentioned problem? If yes, what is the usage of librtc.sl in HP PA and HP IA?
9 REPLIES 9
Dennis Handly
Acclaimed Contributor

Re: How to use librtc in HP-PA to identify the memory issues

Read the wdb documentation:
http://www.hp.com/go/wdb
See: Memory Debugging Capabilities
See the Whitepapers on the documentation link.

This is mainly geared to finding leaks and heap corruption.
How to use librtc and i
Occasional Contributor

Re: How to use librtc in HP-PA to identify the memory issues

As per the steps mentioned in http://g4u0420c.houston.hp.com/en/5991-7502/5991-7502.pdf, I tried to execute the batch of debugging for identification of memory leaks. Though, I did not encounter any errors on exeuction of the same, no putput reports of the leaks were obtained.
Can any one help in indetification of the same?
Dennis Handly
Acclaimed Contributor

Re: How to use librtc in HP-PA to identify the memory issues

>no output reports of the leaks were obtained.

Start with a trivial program that has leaks:
#include
int main() {
(void)malloc(1000);
return 0;
}

Did you read the Prerequisites in the document?
How to use librtc and i
Occasional Contributor

Re: How to use librtc in HP-PA to identify the memory issues

I used the same example given in that document and still achieved nothing.
How to use librtc and i
Occasional Contributor

Re: How to use librtc in HP-PA to identify the memory issues

My compiler versions
------------
$Revision: 92453-07 linker linker crt0.o B.11.16.01 030316 $
HP aC++ B3910B A.03.55
HP aC++ B3910B X.03.37.01 Language Support Library
-------------
$Revision: 92453-07 linker linker crt0.o B.11.16.01 030316 $
LINT B.11.11.10 CXREF B.11.11.10
HP92453-01 B.11.11.10 HP C Compiler
$ PATCH/11.00:PHCO_27774 Oct 3 2002 09:45:59 $

HP-PA version B.11.11 U 9000/800
Dennis Handly
Acclaimed Contributor

Re: How to use librtc in HP-PA to identify the memory issues

>I used the same example given in that document and still achieved nothing.
>My compiler versions

This is near useless, what is your gdb, librtc and dld versions?
How to use librtc and i
Occasional Contributor

Re: How to use librtc in HP-PA to identify the memory issues

versions:

dld.sl:
SMART_BIND
92453-07 dld dld dld.sl B.11.60 070209

/usr/local/bin/gdb:
$Revision: 92453-07 linker linker crt0.o B.11.47 051104 $
Hewlett-Packard Wildebeest 5.3.0 30-Jan-2006 15:03 hppa1.1-hp-hpux11.00
$ PATCH/11.00:PHCO_27774 Oct 3 2002 09:45:59 $

librtc.sl:
Hewlett-Packard Wildebeest 5.3.0 30-Jan-2006 15:03 hppa1.1-hp-hpux11.00
Dennis Handly
Acclaimed Contributor

Re: How to use librtc in HP-PA to identify the memory issues

>92453-07 dld dld dld.sl B.11.60 070209

I don't know if this dld is too old.

>/usr/local/bin/gdb:
Hewlett-Packard Wildebeest 5.3.0 30-Jan-2006

gdb should be in /opt/langtools/bin/gdb.

>librtc.sl:
Hewlett-Packard Wildebeest 5.3.0 30-Jan-2006

You should download the latest wdb.
Dennis Handly
Acclaimed Contributor

Re: How to use librtc in HP-PA to identify the memory issues

If you have gotten the answers you need, please read the following about assigning points:
http://forums.itrc.hp.com/service/forums/helptips.do?#33