]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
gprofng: specify the heap data collection range
authorVladimir Mezentsev <vladimir.mezentsev@oracle.com>
Fri, 9 Aug 2024 04:30:08 +0000 (21:30 -0700)
committerVladimir Mezentsev <vladimir.mezentsev@oracle.com>
Mon, 12 Aug 2024 22:54:59 +0000 (15:54 -0700)
commit6a60060d3e7b39868ca2fbb2c8ef1c593fd00313
tree80129c581623d83441d8924efcc9470ba1c2e018
parentc412d3f5d9ec6c9493232df9c91e17361af775f0
gprofng: specify the heap data collection range

Extend the -H option:
 -H {off|on|N1[-N2]}  disable , or enable heap tracing, or
                      specify the heap data collection range.
                      The default is "-H off".

gprofng/ChangeLog
2024-08-08  Vladimir Mezentsev  <vladimir.mezentsev@oracle.com>

* libcollector/heaptrace.c: Read the range in the -H option.
Do not collect data if the allocated memory is out of range.
* src/collctrl.h (heaptrace_mode): Define as char * value.
* src/envsets.cc: Updated since heaptrace_mode is changed.
* src/collctrl.cc: Accept the extended -H option.
* src/gp-collect-app.cc: Accept the extended -H option.
Remove unused code.
gprofng/libcollector/heaptrace.c
gprofng/src/collctrl.cc
gprofng/src/collctrl.h
gprofng/src/envsets.cc
gprofng/src/gp-collect-app.cc