author | pliden |
Tue, 10 Sep 2019 11:11:31 +0200 | |
changeset 58066 | 8407928b9fe5 |
parent 57658 | 0022b39ae5ae |
child 58679 | 9c3209ff7550 |
child 58815 | a4cdca87152b |
permissions | -rw-r--r-- |
55603
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
1 |
/* |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
2 |
* Copyright (c) 2019, Oracle and/or its affiliates. All rights reserved. |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
3 |
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
4 |
* |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
5 |
* This code is free software; you can redistribute it and/or modify it |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
6 |
* under the terms of the GNU General Public License version 2 only, as |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
7 |
* published by the Free Software Foundation. |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
8 |
* |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
9 |
* This code is distributed in the hope that it will be useful, but WITHOUT |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
10 |
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
11 |
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
12 |
* version 2 for more details (a copy is included in the LICENSE file that |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
13 |
* accompanied this code). |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
14 |
* |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
15 |
* You should have received a copy of the GNU General Public License version |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
16 |
* 2 along with this work; if not, write to the Free Software Foundation, |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
17 |
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
18 |
* |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
19 |
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
20 |
* or visit www.oracle.com if you need additional information or have any |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
21 |
* questions. |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
22 |
*/ |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
23 |
|
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
24 |
#ifndef SHARE_GC_Z_ZVERIFY_HPP |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
25 |
#define SHARE_GC_Z_ZVERIFY_HPP |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
26 |
|
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
27 |
#include "memory/allocation.hpp" |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
28 |
|
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
29 |
class ZVerify : public AllStatic { |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
30 |
private: |
57658 | 31 |
template <typename RootsIterator> static void roots(); |
55603
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
32 |
|
57656
9429ecaee2e0
8229135: ZGC: Adding missing ZStatTimerDisable before call to ZVerify::roots_strong()
pliden
parents:
55603
diff
changeset
|
33 |
static void roots_strong(); |
55603
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
34 |
static void roots_weak(); |
57658 | 35 |
static void roots_concurrent_strong(); |
55603
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
36 |
static void roots_concurrent_weak(); |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
37 |
|
57658 | 38 |
static void roots(bool verify_weaks); |
55603
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
39 |
static void objects(bool verify_weaks); |
57658 | 40 |
static void roots_and_objects(bool verify_weaks); |
55603
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
41 |
|
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
42 |
public: |
57656
9429ecaee2e0
8229135: ZGC: Adding missing ZStatTimerDisable before call to ZVerify::roots_strong()
pliden
parents:
55603
diff
changeset
|
43 |
static void before_zoperation(); |
55603
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
44 |
static void after_mark(); |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
45 |
static void after_weak_processing(); |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
46 |
}; |
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
47 |
|
3868dde58ebb
8227175: ZGC: ZHeapIterator visits potentially dead objects
stefank
parents:
diff
changeset
|
48 |
#endif // SHARE_GC_Z_ZVERIFY_HPP |