< prev index next >

src/share/vm/code/dependencies.cpp

Print this page
rev 9803 : 8146401: Clean up oop.hpp: add inline directives and fix header files
   1 /*
   2  * Copyright (c) 2005, 2015, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.
   8  *
   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  *


1933 bool KlassDepChange::involves_context(Klass* k) {
1934   if (k == NULL || !k->is_instance_klass()) {
1935     return false;
1936   }
1937   InstanceKlass* ik = InstanceKlass::cast(k);
1938   bool is_contained = ik->is_marked_dependent();
1939   assert(is_contained == new_type()->is_subtype_of(k),
1940          "correct marking of potential context types");
1941   return is_contained;
1942 }
1943 
1944 #ifndef PRODUCT
1945 void Dependencies::print_statistics() {
1946   if (deps_find_witness_print != 0) {
1947     // Call one final time, to flush out the data.
1948     deps_find_witness_print = -1;
1949     count_find_witness_calls();
1950   }
1951 }
1952 #endif







   1 /*
   2  * Copyright (c) 2005, 2016, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.
   8  *
   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  *


1933 bool KlassDepChange::involves_context(Klass* k) {
1934   if (k == NULL || !k->is_instance_klass()) {
1935     return false;
1936   }
1937   InstanceKlass* ik = InstanceKlass::cast(k);
1938   bool is_contained = ik->is_marked_dependent();
1939   assert(is_contained == new_type()->is_subtype_of(k),
1940          "correct marking of potential context types");
1941   return is_contained;
1942 }
1943 
1944 #ifndef PRODUCT
1945 void Dependencies::print_statistics() {
1946   if (deps_find_witness_print != 0) {
1947     // Call one final time, to flush out the data.
1948     deps_find_witness_print = -1;
1949     count_find_witness_calls();
1950   }
1951 }
1952 #endif
1953 
1954 CallSiteDepChange::CallSiteDepChange(Handle call_site, Handle method_handle) :
1955   _call_site(call_site),
1956   _method_handle(method_handle) {
1957   assert(_call_site()    ->is_a(SystemDictionary::CallSite_klass()),     "must be");
1958   assert(_method_handle.is_null() || _method_handle()->is_a(SystemDictionary::MethodHandle_klass()), "must be");
1959 }
< prev index next >