src/share/vm/ci/ciMethodHandle.cpp

changeset 2437
70427f06ea47
parent 2314
f95d63e2154a
child 2744
4124a5a27707
     1.1 --- a/src/share/vm/ci/ciMethodHandle.cpp	Mon Jan 10 00:56:39 2011 -0800
     1.2 +++ b/src/share/vm/ci/ciMethodHandle.cpp	Mon Jan 10 03:58:07 2011 -0800
     1.3 @@ -1,5 +1,5 @@
     1.4  /*
     1.5 - * Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved.
     1.6 + * Copyright (c) 2009, 2011, Oracle and/or its affiliates. All rights reserved.
     1.7   * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     1.8   *
     1.9   * This code is free software; you can redistribute it and/or modify it
    1.10 @@ -38,11 +38,12 @@
    1.11  // Return an adapter for this MethodHandle.
    1.12  ciMethod* ciMethodHandle::get_adapter(bool is_invokedynamic) const {
    1.13    VM_ENTRY_MARK;
    1.14 -
    1.15    Handle h(get_oop());
    1.16    methodHandle callee(_callee->get_methodOop());
    1.17 -  MethodHandleCompiler mhc(h, callee, is_invokedynamic, THREAD);
    1.18 -  methodHandle m = mhc.compile(CHECK_NULL);
    1.19 +  // We catch all exceptions here that could happen in the method
    1.20 +  // handle compiler and stop the VM.
    1.21 +  MethodHandleCompiler mhc(h, callee, is_invokedynamic, CATCH);
    1.22 +  methodHandle m = mhc.compile(CATCH);
    1.23    return CURRENT_ENV->get_object(m())->as_method();
    1.24  }
    1.25  

mercurial