aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authortwisti <none@none>2012-12-03 15:48:49 -0800
committertwisti <none@none>2012-12-03 15:48:49 -0800
commit1dea60e0137e901465b738389bbdd811c890352a (patch)
treeba1652ea930d089167ccc6accdec389bd3f1f24d /src
parent15f6289293cd9c043821d864c48d50734e74ae66 (diff)
8004319: test/gc/7168848/HumongousAlloc.java fails after 7172640
Reviewed-by: kvn, johnc
Diffstat (limited to 'src')
-rw-r--r--src/share/vm/opto/library_call.cpp21
1 files changed, 13 insertions, 8 deletions
diff --git a/src/share/vm/opto/library_call.cpp b/src/share/vm/opto/library_call.cpp
index 822f863bf..43d4d0502 100644
--- a/src/share/vm/opto/library_call.cpp
+++ b/src/share/vm/opto/library_call.cpp
@@ -79,14 +79,19 @@ class LibraryCallKit : public GraphKit {
_intrinsic(intrinsic),
_result(NULL)
{
- // Find out how many arguments the interpreter needs when deoptimizing
- // and save the stack pointer value so it can used by uncommon_trap.
- // We find the argument count by looking at the declared signature.
- bool ignored_will_link;
- ciSignature* declared_signature = NULL;
- ciMethod* ignored_callee = caller()->get_method_at_bci(bci(), ignored_will_link, &declared_signature);
- const int nargs = declared_signature->arg_size_for_bc(caller()->java_code_at_bci(bci()));
- _reexecute_sp = sp() + nargs; // "push" arguments back on stack
+ // Check if this is a root compile. In that case we don't have a caller.
+ if (!jvms->has_method()) {
+ _reexecute_sp = sp();
+ } else {
+ // Find out how many arguments the interpreter needs when deoptimizing
+ // and save the stack pointer value so it can used by uncommon_trap.
+ // We find the argument count by looking at the declared signature.
+ bool ignored_will_link;
+ ciSignature* declared_signature = NULL;
+ ciMethod* ignored_callee = caller()->get_method_at_bci(bci(), ignored_will_link, &declared_signature);
+ const int nargs = declared_signature->arg_size_for_bc(caller()->java_code_at_bci(bci()));
+ _reexecute_sp = sp() + nargs; // "push" arguments back on stack
+ }
}
virtual LibraryCallKit* is_LibraryCallKit() const { return (LibraryCallKit*)this; }