14.10.8 Scenarios in memory debugging.....................................................................174
14.10.8.1 Stop when freeing unallocated or deallocated blocks.............................174
14.10.8.2 Stop when freeing a block if bad writes occurred outside block
boundary................................................................................................................174
14.10.8.3 Stop when a specified block address is allocated or deallocated............175
14.10.8.4 Scramble previous memory contents at malloc/free calls.......................175
14.10.8.5 Detect dangling pointers and dangling blocks.......................................175
14.10.8.6 Detect in-block corruption of freed blocks..............................................176
14.10.8.7 Specify the amount of guard bytes for every block of allocated
memory..................................................................................................................176
14.10.9 Comparison of Memory Debugging Commands in Interactive Mode and
Batch Mode..................................................................................................................176
14.10.10 Heap Profiling................................................................................................178
14.10.10.1 Commands for heap profiling...............................................................178
14.10.10.2 info heap arena...............................................................................179
14.10.10.3 info heap arena [0 |1|2|..] blocks stacks..............................179
14.10.10.4 info module ADDRESS.....................................................................179
14.10.10.5 info heap process..........................................................................179
14.10.10.6 Example for heap profiling....................................................................179
14.10.11 Memory Checking Analysis for User Defined Memory Management
Routines.......................................................................................................................180
14.10.12 Commands to track the change in data segment value.................................180
14.11 Thread Debugging Support.....................................................................................181
14.11.1 Support for Enabling and Disabling Specific Threads....................................181
14.11.2 Backtrace Support for Thread Debugging.......................................................182
14.11.3 Advanced Thread Debugging Support...........................................................182
14.11.3.1 Pre-requisites for Advanced Thread Debugging....................................183
14.11.3.2 Enabling and Disabling Advanced Thread Debugging Features...........183
14.11.3.3 Commands to view information on pthread primitives.........................187
14.11.4 Debugging Threads Interactively After Attaching to a Process......................187
14.11.5 Thread Debugging in Batch Mode..................................................................189
14.11.5.1 Pre-requisites for Batch mode of Thread Debugging..............................190
14.11.5.2 Limitations in Batch mode of thread debugging....................................193
14.11.6 Thread Debugging in +check Mode..............................................................193
14.11.7 Known issues with Thread Debugging for Interactive and Batch mode........194
14.12 Debugging MPI Programs.......................................................................................194
14.13 Debugging multiple processes ( programs with fork and vfork calls)...............195
14.13.1 Ask mode for set follow-fork-mode......................................................195
14.13.2 Serial mode for set follow-fork-mode....................................................195
14.13.3 Support for showing unwind info...................................................................195
14.13.4 Printing CFM and PFS registers......................................................................196
14.14 Command to Search for a Pattern in the Memory Address Space..........................196
14.15 Debugging Core Files..............................................................................................200
14.15.1 Generating core files with packcore /unpackcore/getcore....................200
Table of Contents 7