hotspot/src/share/vm/classfile/packageEntry.hpp
author jlaskey
Mon, 25 Apr 2016 09:59:43 -0300
changeset 37490 fd089d3f8cb3
parent 36508 5f9eee6b383b
child 37503 77531df4dad3
permissions -rw-r--r--
8147634: Need a JImage API that given a JImageLocationRef returns class name Reviewed-by: hseigel
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
36508
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
     1
/*
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
     2
 * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
     4
 *
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
     7
 * published by the Free Software Foundation.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
     8
 *
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
     9
 * This code is distributed in the hope that it will be useful, but WITHOUT
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    10
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    11
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    12
 * version 2 for more details (a copy is included in the LICENSE file that
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    13
 * accompanied this code).
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    14
 *
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    15
 * You should have received a copy of the GNU General Public License version
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    16
 * 2 along with this work; if not, write to the Free Software Foundation,
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    17
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    18
 *
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    19
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    20
 * or visit www.oracle.com if you need additional information or have any
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    21
 * questions.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    22
 *
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    23
 */
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    24
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    25
#ifndef SHARE_VM_CLASSFILE_PACKAGEENTRY_HPP
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    26
#define SHARE_VM_CLASSFILE_PACKAGEENTRY_HPP
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    27
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    28
#include "classfile/moduleEntry.hpp"
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    29
#include "oops/symbol.hpp"
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    30
#include "utilities/growableArray.hpp"
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    31
#include "utilities/hashtable.hpp"
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    32
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    33
// A PackageEntry basically represents a Java package.  It contains:
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    34
//   - Symbol* containing the package's name.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    35
//   - ModuleEntry* for this package's containing module.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    36
//   - a flag indicating if package is exported, either qualifiedly or
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    37
//     unqualifiedly.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    38
//   - a flag indicating if this package is exported to all unnamed modules.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    39
//   - a growable array containing other module entries that this
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    40
//     package is exported to.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    41
//
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    42
// Packages that are:
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    43
//   - not exported:        _qualified_exports = NULL  && _is_exported is false
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    44
//   - qualified exports:   (_qualified_exports != NULL || _is_exported_allUnnamed is true) && _is_exported is true
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    45
//   - unqualified exports: (_qualified_exports = NULL && _is_exported_allUnnamed is false) && _is_exported is true
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    46
//
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    47
// The Mutex Module_lock is shared between ModuleEntry and PackageEntry, to lock either
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    48
// data structure.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    49
class PackageEntry : public HashtableEntry<Symbol*, mtClass> {
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    50
private:
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    51
  ModuleEntry* _module;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    52
  // Used to indicate for packages with classes loaded by the boot loader that
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    53
  // a class in that package has been loaded.  And, for packages with classes
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    54
  // loaded by the boot loader from -Xbootclasspath/a in an unnamed module, it
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    55
  // indicates from which class path entry.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    56
  s2 _classpath_index;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    57
  bool _is_exported;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    58
  bool _is_exported_allUnnamed;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    59
  GrowableArray<ModuleEntry*>* _exported_pending_delete; // transitioned from qualified to unqualified, delete at safepoint
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    60
  GrowableArray<ModuleEntry*>* _qualified_exports;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    61
  TRACE_DEFINE_TRACE_ID_FIELD;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    62
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    63
  // Initial size of a package entry's list of qualified exports.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    64
  enum {QUAL_EXP_SIZE = 43};
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    65
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    66
public:
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    67
  void init() {
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    68
    _module = NULL;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    69
    _classpath_index = -1;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    70
    _is_exported = false;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    71
    _is_exported_allUnnamed = false;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    72
    _exported_pending_delete = NULL;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    73
    _qualified_exports = NULL;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    74
  }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    75
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    76
  // package name
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    77
  Symbol*            name() const               { return literal(); }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    78
  void               set_name(Symbol* n)        { set_literal(n); }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    79
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    80
  // the module containing the package definition
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    81
  ModuleEntry*       module() const             { return _module; }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    82
  void               set_module(ModuleEntry* m) { _module = m; }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    83
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    84
  // package's export state
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    85
  bool is_exported() const { return _is_exported; } // qualifiedly or unqualifiedly exported
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    86
  bool is_qual_exported() const {
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    87
    return (_is_exported && (_qualified_exports != NULL || _is_exported_allUnnamed));
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    88
  }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    89
  bool is_unqual_exported() const {
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    90
    return (_is_exported && (_qualified_exports == NULL && !_is_exported_allUnnamed));
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    91
  }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    92
  void set_unqual_exported() {
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    93
    _is_exported = true;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    94
    _is_exported_allUnnamed = false;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    95
    _qualified_exports = NULL;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    96
  }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    97
  bool exported_pending_delete() const     { return (_exported_pending_delete != NULL); }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    98
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
    99
  void set_exported(bool e)                { _is_exported = e; }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   100
  void set_exported(ModuleEntry* m);
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   101
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   102
  void set_is_exported_allUnnamed() {
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   103
    if (!is_unqual_exported()) {
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   104
     _is_exported_allUnnamed = true;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   105
     _is_exported = true;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   106
    }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   107
  }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   108
  bool is_exported_allUnnamed() const {
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   109
    assert(_is_exported || !_is_exported_allUnnamed,
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   110
           "is_allUnnamed set without is_exported being set");
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   111
    return _is_exported_allUnnamed;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   112
  }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   113
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   114
  void set_classpath_index(s2 classpath_index) {
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   115
    _classpath_index = classpath_index;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   116
  }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   117
  s2 classpath_index() const { return _classpath_index; }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   118
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   119
  bool has_loaded_class() const { return _classpath_index != -1; }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   120
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   121
  // returns true if the package is defined in the unnamed module
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   122
  bool in_unnamed_module() const  { return !_module->is_named(); }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   123
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   124
  // returns true if the package specifies m as a qualified export
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   125
  bool is_qexported_to(ModuleEntry* m) const;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   126
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   127
  // add the module to the package's qualified exports
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   128
  void add_qexport(ModuleEntry* m);
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   129
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   130
  PackageEntry* next() const {
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   131
    return (PackageEntry*)HashtableEntry<Symbol*, mtClass>::next();
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   132
  }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   133
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   134
  PackageEntry** next_addr() {
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   135
    return (PackageEntry**)HashtableEntry<Symbol*, mtClass>::next_addr();
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   136
  }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   137
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   138
  // iteration of qualified exports
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   139
  void package_exports_do(ModuleClosure* const f);
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   140
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   141
  TRACE_DEFINE_TRACE_ID_METHODS;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   142
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   143
  // Purge dead weak references out of exported list when any given class loader is unloaded.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   144
  void purge_qualified_exports();
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   145
  void delete_qualified_exports();
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   146
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   147
  void print() PRODUCT_RETURN;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   148
  void verify();
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   149
};
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   150
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   151
// The PackageEntryTable is a Hashtable containing a list of all packages defined
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   152
// by a particular class loader.  Each package is represented as a PackageEntry node.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   153
// The PackageEntryTable's lookup is lock free.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   154
//
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   155
class PackageEntryTable : public Hashtable<Symbol*, mtClass> {
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   156
  friend class VMStructs;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   157
public:
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   158
  enum Constants {
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   159
    _packagetable_entry_size = 1009  // number of entries in package entry table
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   160
  };
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   161
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   162
private:
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   163
  PackageEntry* new_entry(unsigned int hash, Symbol* name, ModuleEntry* module);
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   164
  void add_entry(int index, PackageEntry* new_entry);
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   165
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   166
  int entry_size() const { return BasicHashtable<mtClass>::entry_size(); }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   167
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   168
  PackageEntry** bucket_addr(int i) {
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   169
    return (PackageEntry**)Hashtable<Symbol*, mtClass>::bucket_addr(i);
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   170
  }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   171
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   172
  static unsigned int compute_hash(Symbol* name) { return (unsigned int)(name->identity_hash()); }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   173
  int index_for(Symbol* name) const { return hash_to_index(compute_hash(name)); }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   174
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   175
public:
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   176
  PackageEntryTable(int table_size);
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   177
  ~PackageEntryTable();
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   178
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   179
  PackageEntry* bucket(int i) {
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   180
    return (PackageEntry*)Hashtable<Symbol*, mtClass>::bucket(i);
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   181
  }
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   182
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   183
  // Create package in loader's package entry table and return the entry.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   184
  // If entry already exists, return null.  Assume Module lock was taken by caller.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   185
  PackageEntry* locked_create_entry_or_null(Symbol* name, ModuleEntry* module);
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   186
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   187
  // lookup Package with loader's package entry table, if not found add
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   188
  PackageEntry* lookup(Symbol* name, ModuleEntry* module);
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   189
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   190
  // Only lookup Package within loader's package entry table.  The table read is lock-free.
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   191
  PackageEntry* lookup_only(Symbol* Package);
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   192
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   193
  void verify_javabase_packages(GrowableArray<Symbol*> *pkg_list);
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   194
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   195
  // purge dead weak references out of exported list
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   196
  void purge_all_package_exports();
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   197
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   198
  void print() PRODUCT_RETURN;
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   199
  void verify();
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   200
};
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   201
5f9eee6b383b 8142968: Module System implementation
alanb
parents:
diff changeset
   202
#endif // SHARE_VM_CLASSFILE_PACKAGEENTRY_HPP