printf("%d\n", | count); |
| |
}int printMallocInfo(const char* title) { |
| ||
static long lastValue; |
| ||
struct mallinfo | info; |
| |
info = mallinfo(); |
| ||
printf("%s\n",title); |
| ||
printf("Memory allocation info:\n"); |
| ||
printf(" | total | space in arena | = %d\n", info.arena); |
#ifdef DETAILS |
|
| |
printf(" | number of ordinary blocks | = %d\n", info.ordblks); | |
printf(" | number of small blocks | = %d\n", info.smblks); | |
printf(" | space | in holding block headers | = %d\n", info.hblkhd); |
printf(" | number of holding blocks | = %d\n", info.hblks); | |
printf(" | space | in small blocks in use | = %d\n", info.usmblks); |
printf(" | space | in free small blocks | = %d\n", info.fsmblks); |
printf(" | space | in ordinary blocks in use | = %d\n", info.uordblks); |
printf(" | space | in free ordinary blocks | = %d\n", info.fordblks); |
printf(" | keep option space penalty | = %d\n", info.keepcost); | |
#else |
|
|
|
printf(" | space | in use | = %d\n", |
| info.usmblks + info.uordblks); |
| |
printf(" | space | free | = %d\n", |
| info.fsmblks + info.fordblks); |
|
#endif
//printf("\n\n size used is //lastValue = info.arena;
return 0;
}
HP aC++ File Locations
This section gives you information on the HP aC++ file locations. It discusses the following topics:
•HP aC++ Runtime Libraries and Header Files
HP aC++ Executable Files
Following are the HP aC++ executable files and their locations:
•/opt/aCC/bin/aCC (Driver)
This is the only supported interface to HP aC++ and to the linker for HP aC++ object files.
•/opt/aCC/lbin/ecom (A.06.* Compiler)
The compiler performs source compilation; preprocessing is incorporated into it.
•/opt/aCC/lbin/ctcom (A.05.* Compiler)
The compiler performs source compilation; preprocessing is incorporated into it.
•/opt/aCC/bin/c++filt (Name Demangler)
The name demangler implements the name demangling algorithm, which encodes function name, class name, parameter number and name.
•/usr/ccs/bin/ld (Linker)
The linker links executables and builds shared libraries.
186 Tools and Libraries