RFR(S): 8040920: Uninitialised memory in hotspot/src/share/vm/code/dependencies.cpp

Doug Simon doug.simon at oracle.com
Thu May 1 08:54:06 UTC 2014

(proper subject line this time)

> On 4/30/14 2:35 PM, Christian Thalinger wrote:
>> On Apr 30, 2014, at 11:26 AM, Vladimir Kozlov <vladimir.kozlov at oracle.com> wrote:
>>> Morris,
>>> How you verified that you put ResourceMark in all needed places?
>>> That is what I don't like about GrowableArray.
>> He could put a ResourceMark in front of every GrowableArray.  That would do it.
> Nested ResourceMark has bad effect on external GrowableArray: if it 
> grows after inner ResourceMark that space will be released after inner 
> scope ends. You will get memory stomps because of that. You need to be 
> sure that external GrowableArray never grows inside inner ResourceMark 
> scope.

The same problem exists for expandable stringStreams[1].


[1] http://hg.openjdk.java.net/graal/graal/file/100306ae985b/src/share/vm/graal/graalCompilerToVM.cpp#l601

More information about the hotspot-compiler-dev mailing list