annotate src/share/vm/shark/shark_globals.hpp @ 17716:cdb71841f4bc

6498581: ThreadInterruptTest3 produces wrong output on Windows Summary: There is race condition between os::interrupt and os::is_interrupted on Windows. In JVM_Sleep(Thread.sleep), check if thread gets interrupted, it may see interrupted but not really interrupted so cause spurious waking up (early return from sleep). Fix by checking if interrupt event really gets set thus prevent false return. For intrinsic of _isInterrupted, on Windows, go fastpath only on bit not set. Reviewed-by: acorn, kvn Contributed-by: david.holmes@oracle.com, yumin.qi@oracle.com
author minqi
date Wed, 26 Feb 2014 15:20:41 -0800
parents 2cd5e15048e6
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1692
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
1 /*
1972
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1692
diff changeset
2 * Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
1692
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
3 * Copyright 2008, 2009, 2010 Red Hat, Inc.
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
5 *
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
6 * This code is free software; you can redistribute it and/or modify it
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
7 * under the terms of the GNU General Public License version 2 only, as
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
8 * published by the Free Software Foundation.
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
9 *
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
10 * This code is distributed in the hope that it will be useful, but WITHOUT
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
11 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
12 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
13 * version 2 for more details (a copy is included in the LICENSE file that
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
14 * accompanied this code).
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
15 *
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
16 * You should have received a copy of the GNU General Public License version
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
17 * 2 along with this work; if not, write to the Free Software Foundation,
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
18 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
19 *
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
20 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
21 * or visit www.oracle.com if you need additional information or have any
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
22 * questions.
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
23 *
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
24 */
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
25
1972
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1692
diff changeset
26 #ifndef SHARE_VM_SHARK_SHARK_GLOBALS_HPP
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1692
diff changeset
27 #define SHARE_VM_SHARK_SHARK_GLOBALS_HPP
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1692
diff changeset
28
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1692
diff changeset
29 #include "runtime/globals.hpp"
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1692
diff changeset
30 #ifdef TARGET_ARCH_zero
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1692
diff changeset
31 # include "shark_globals_zero.hpp"
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1692
diff changeset
32 #endif
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1692
diff changeset
33
1692
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
34 #define SHARK_FLAGS(develop, develop_pd, product, product_pd, diagnostic, notproduct) \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
35 \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
36 product(intx, MaxNodeLimit, 65000, \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
37 "Maximum number of nodes") \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
38 \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
39 /* inlining */ \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
40 product(intx, SharkMaxInlineSize, 32, \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
41 "Maximum bytecode size of methods to inline when using Shark") \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
42 \
7195
2cd5e15048e6 8003868: fix shark for latest HotSpot and LLVM
twisti
parents: 1972
diff changeset
43 product(bool, EliminateNestedLocks, true, \
2cd5e15048e6 8003868: fix shark for latest HotSpot and LLVM
twisti
parents: 1972
diff changeset
44 "Eliminate nested locks of the same object when possible") \
2cd5e15048e6 8003868: fix shark for latest HotSpot and LLVM
twisti
parents: 1972
diff changeset
45 \
2cd5e15048e6 8003868: fix shark for latest HotSpot and LLVM
twisti
parents: 1972
diff changeset
46 product(ccstr, SharkOptimizationLevel, "Default", \
2cd5e15048e6 8003868: fix shark for latest HotSpot and LLVM
twisti
parents: 1972
diff changeset
47 "The optimization level passed to LLVM, possible values: None, Less, Default and Agressive") \
2cd5e15048e6 8003868: fix shark for latest HotSpot and LLVM
twisti
parents: 1972
diff changeset
48 \
1692
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
49 /* compiler debugging */ \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
50 develop(ccstr, SharkPrintTypeflowOf, NULL, \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
51 "Print the typeflow of the specified method") \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
52 \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
53 diagnostic(ccstr, SharkPrintBitcodeOf, NULL, \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
54 "Print the LLVM bitcode of the specified method") \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
55 \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
56 diagnostic(ccstr, SharkPrintAsmOf, NULL, \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
57 "Print the asm of the specified method") \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
58 \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
59 develop(bool, SharkTraceBytecodes, false, \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
60 "Trace bytecode compilation") \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
61 \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
62 diagnostic(bool, SharkTraceInstalls, false, \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
63 "Trace method installation") \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
64 \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
65 diagnostic(bool, SharkPerformanceWarnings, false, \
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
66 "Warn about things that could be made faster") \
7195
2cd5e15048e6 8003868: fix shark for latest HotSpot and LLVM
twisti
parents: 1972
diff changeset
67 \
2cd5e15048e6 8003868: fix shark for latest HotSpot and LLVM
twisti
parents: 1972
diff changeset
68 develop(ccstr, SharkVerifyFunction, NULL, \
2cd5e15048e6 8003868: fix shark for latest HotSpot and LLVM
twisti
parents: 1972
diff changeset
69 "Runs LLVM verify over LLVM IR") \
2cd5e15048e6 8003868: fix shark for latest HotSpot and LLVM
twisti
parents: 1972
diff changeset
70
1692
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
71
d2ede61b7a12 6976186: integrate Shark HotSpot changes
twisti
parents:
diff changeset
72 SHARK_FLAGS(DECLARE_DEVELOPER_FLAG, DECLARE_PD_DEVELOPER_FLAG, DECLARE_PRODUCT_FLAG, DECLARE_PD_PRODUCT_FLAG, DECLARE_DIAGNOSTIC_FLAG, DECLARE_NOTPRODUCT_FLAG)
1972
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1692
diff changeset
73
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1692
diff changeset
74 #endif // SHARE_VM_SHARK_SHARK_GLOBALS_HPP