src/share/vm/classfile/systemDictionaryShared.hpp

Wed, 23 Sep 2020 16:26:20 +0300

author
vkempik
date
Wed, 23 Sep 2020 16:26:20 +0300
changeset 10009
8adf45218add
parent 8497
50e62b688ddc
permissions
-rw-r--r--

8244955: Additional Fix for JDK-8240124
Reviewed-by: mbalao, andrew

     1 /*
     2  * Copyright (c) 2014, 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  *
    23  */
    26 #ifndef SHARE_VM_CLASSFILE_SYSTEMDICTIONARYSHARED_HPP
    27 #define SHARE_VM_CLASSFILE_SYSTEMDICTIONARYSHARED_HPP
    29 #include "classfile/dictionary.hpp"
    30 #include "classfile/systemDictionary.hpp"
    32 class SystemDictionaryShared: public SystemDictionary {
    33 public:
    34   static void initialize(TRAPS) {}
    35   static instanceKlassHandle find_or_load_shared_class(Symbol* class_name,
    36                                                        Handle class_loader,
    37                                                        TRAPS) {
    38     return instanceKlassHandle();
    39   }
    40   static void roots_oops_do(OopClosure* blk) {}
    41   static void oops_do(OopClosure* f) {}
    42   static bool is_sharing_possible(ClassLoaderData* loader_data) {
    43     oop class_loader = loader_data->class_loader();
    44     return (class_loader == NULL);
    45   }
    47   static size_t dictionary_entry_size() {
    48     return sizeof(DictionaryEntry);
    49   }
    50   static void init_shared_dictionary_entry(Klass* k, DictionaryEntry* entry) {}
    52   // The (non-application) CDS implementation supports only classes in the boot
    53   // class loader, which ensures that the verification dependencies are the same
    54   // during archive creation time and runtime. Thus we can do the dependency checks
    55   // entirely during archive creation time.
    56   static void add_verification_dependency(Klass* k, Symbol* accessor_clsname,
    57                                           Symbol* target_clsname) {}
    58   static void finalize_verification_dependencies() {}
    59   static bool check_verification_dependencies(Klass* k, Handle class_loader,
    60                                               Handle protection_domain,
    61                                               char** message_buffer, TRAPS) {return true;}
    62 };
    64 #endif // SHARE_VM_CLASSFILE_SYSTEMDICTIONARYSHARED_HPP

mercurial