Code Review for 7087727

Prepared by:twisti on Tue Nov 8 02:34:00 PST 2011
Workspace:/home/twisti/hsx/hotspot-comp/7087727
Compare against: /home/twisti/hsx/hotspot-comp/hotspot
Summary of changes: 4 lines changed: 1 ins; 1 del; 2 mod; 1095 unchg
Patch of changes: 7087727.patch
Printable review: 7087727.pdf
Author comments:
7087727: JSR 292: C2 crash if ScavengeRootsInCode=2 when "static final" MethodHandle constants are in use
Reviewed-by:

The flag setting ScavengeRootsInCode=2 causes the JIT to inline more
constants. This is generally a good thing for performance, but can
cause bugs in compiled code.

The test case has a code pattern that looks similar to the
selectAlternative idiom but boils down to a different invoke bytecode
(invokevirtual in that case). The current code in
PredictedDynamicCallGenerator::generate checks for invokespecial
(which is used by selectAlternative) and so code for invokedynamic is
generated (in non-debug builds) which eventually leads to a crash.

Bug id: 7087727 crash in C2 code if ScavengeRootsInCode=2 when "static final" MethodHandle constants are in use
Legend: Modified file
Deleted file
New file

Cdiffs Udiffs Wdiffs Sdiffs Frames Old New Patch Raw src/share/vm/opto/callGenerator.cpp

4 lines changed: 1 ins; 1 del; 2 mod; 1095 unchg

This code review page was prepared using /home/twisti/bin/webrev (vers 23.18-hg-never).