Thank you, we also using the HEAPCHK to check the heap corruption, but we find it is very slow and not always easy to find the place
of error(it is sometimes far from the check).
I hope HEAPZONE will be faster. In the meantime my colleague find the SHARE presentation "Heap Damage Get into Zone"

On 03.12.2013 16:51, Charles Mills wrote:
FWIW I use HEAPCHK as part of the standard regression testing of a product
written in C++. I don't notice the performance impact while the product is
running (but that is a very subjective "don't notice" -- I have made no
attempt to measure the impact because I don't really care about the
performance of one test). I use RPTSTG(ON) as part of the same test and one
of them really slows down termination: a product termination that normally
is essentially instantaneous takes perhaps 30 seconds. I do a lot of
delete's at that point so perhaps it is HEAPCHK that slows things down.

//CEEOPTS DD  *
       RPTSTG(ON)
       HEAPCHK(ON,1,0,10,10,1024,0)
/*

HEAPZONE sounds useful. A similar feature is the default in MS Visual Studio
(where I do my alpha testing -- and I suspect similarly in things like
Eclipse). It works great. If you allocate 27 bytes and use 28, then on the
free() or delete C++ asserts. You tend to find buffer overruns shortly after
they happen, rather than down the road when all sorts of seemingly unrelated
things start misbehaving.

Charles
-----Original Message-----
From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On
Behalf Of Lizette Koehler
Sent: Monday, December 02, 2013 6:15 AM
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Re: HEAPCHECK and HEAPZONE difference in zOS 2.1

Miklos,

I found HEAPCHK in z/OS Language Environment Customization

HEAPCHK Derivation: HEAP storage CHecKing  Use HEAPCHK to run additional
heap check tests.
If HEAPCHK(ON) is used with STORAGE(,heap_free_value), the free areas of the
heap will also be checked.
If HEAPCHK(ON) is specified, this will result in a performance degradation
due to the additional error checking that is performed.
A U4042 abend dump will be generated when an error is detected, but no
CEEDUMP will be produced.



And for HEAPZONE I found in z/OS Language Environment Programming Reference

Derivation: HEAP check ZONES

The HEAPZONES runtime option is used to turn on overlay toleration and
checking for user heaps. When activated, the runtime option affects any
obtained storage that can be controlled by the HEAP or HEAP64 runtime
options. HEAPZONES also affects storage obtained from a heap pool.   A heap
check zone is an additional piece of storage that is appended to an
allocated element during a storage request. The size of the check zone
depends on the size31 and size64 suboptions of HEAPZONES. The check zone can
be examined for overlays when the heap element is freed.


So it looks that HEAPCHK has a performance overhead and validates heaps of
(I think) all HEAPS and the other a runtime option to provide overly
toleration and check for USER heaps.

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN



--
Kind regards, / Mit freundlichen Grüßen
Miklos Szigetvari

Research&  Development
ISIS Papyrus Europe AG
Alter Wienerweg 12, A-2344 Maria Enzersdorf, Austria
T: +43(2236) 27551 333, F: +43(2236)21081
E-mail: miklos.szigetv...@isis-papyrus.com
Info: i...@isis-papyrus.com Hotline: +43-2236-27551-111
Visit our brand new extended Website at www.isis-papyrus.com
---------------------------------------------------------------
This e-mail is only intended for the recipient and not legally
binding. Unauthorised use, publication, reproduction or
disclosure of the content of this e-mail is not permitted.
This email has been checked for known viruses, but ISIS Papyrus accepts
no responsibility for malicious or inappropriate content.
---------------------------------------------------------------

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to