Thu, 07 Sep 2017 09:17:43 -0400
8072428: Enable UseLoopCounter ergonomically if on-stack-replacement is enabled
Summary: Set UseLoopCounter ergonomically if on-stack-replacement is enabled. Print warning.
Reviewed-by: kvn
duke@435 | 1 | /* |
shshahma@8584 | 2 | * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. |
duke@435 | 3 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
duke@435 | 4 | * |
duke@435 | 5 | * This code is free software; you can redistribute it and/or modify it |
duke@435 | 6 | * under the terms of the GNU General Public License version 2 only, as |
duke@435 | 7 | * published by the Free Software Foundation. |
duke@435 | 8 | * |
duke@435 | 9 | * This code is distributed in the hope that it will be useful, but WITHOUT |
duke@435 | 10 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
duke@435 | 11 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
duke@435 | 12 | * version 2 for more details (a copy is included in the LICENSE file that |
duke@435 | 13 | * accompanied this code). |
duke@435 | 14 | * |
duke@435 | 15 | * You should have received a copy of the GNU General Public License version |
duke@435 | 16 | * 2 along with this work; if not, write to the Free Software Foundation, |
duke@435 | 17 | * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
duke@435 | 18 | * |
trims@1907 | 19 | * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
trims@1907 | 20 | * or visit www.oracle.com if you need additional information or have any |
trims@1907 | 21 | * questions. |
duke@435 | 22 | * |
duke@435 | 23 | */ |
duke@435 | 24 | |
stefank@2314 | 25 | #include "precompiled.hpp" |
stefank@2314 | 26 | #include "classfile/classLoader.hpp" |
stefank@2314 | 27 | #include "classfile/symbolTable.hpp" |
stefank@2314 | 28 | #include "classfile/systemDictionary.hpp" |
stefank@2314 | 29 | #include "code/codeCache.hpp" |
stefank@2314 | 30 | #include "compiler/compileBroker.hpp" |
stefank@2314 | 31 | #include "compiler/compilerOracle.hpp" |
stefank@2314 | 32 | #include "interpreter/bytecodeHistogram.hpp" |
stefank@2314 | 33 | #include "memory/genCollectedHeap.hpp" |
stefank@2314 | 34 | #include "memory/oopFactory.hpp" |
stefank@2314 | 35 | #include "memory/universe.hpp" |
coleenp@4037 | 36 | #include "oops/constantPool.hpp" |
stefank@2314 | 37 | #include "oops/generateOopMap.hpp" |
stefank@2314 | 38 | #include "oops/instanceKlass.hpp" |
stefank@2314 | 39 | #include "oops/instanceOop.hpp" |
coleenp@4037 | 40 | #include "oops/method.hpp" |
stefank@2314 | 41 | #include "oops/objArrayOop.hpp" |
stefank@2314 | 42 | #include "oops/oop.inline.hpp" |
coleenp@2497 | 43 | #include "oops/symbol.hpp" |
stefank@2314 | 44 | #include "prims/jvmtiExport.hpp" |
stefank@2314 | 45 | #include "runtime/arguments.hpp" |
stefank@2314 | 46 | #include "runtime/biasedLocking.hpp" |
stefank@2314 | 47 | #include "runtime/compilationPolicy.hpp" |
stefank@2314 | 48 | #include "runtime/fprofiler.hpp" |
stefank@2314 | 49 | #include "runtime/init.hpp" |
stefank@2314 | 50 | #include "runtime/interfaceSupport.hpp" |
stefank@2314 | 51 | #include "runtime/java.hpp" |
stefank@2314 | 52 | #include "runtime/memprofiler.hpp" |
stefank@2314 | 53 | #include "runtime/sharedRuntime.hpp" |
stefank@2314 | 54 | #include "runtime/statSampler.hpp" |
anoll@6207 | 55 | #include "runtime/sweeper.hpp" |
stefank@2314 | 56 | #include "runtime/task.hpp" |
stefank@4299 | 57 | #include "runtime/thread.inline.hpp" |
stefank@2314 | 58 | #include "runtime/timer.hpp" |
stefank@2314 | 59 | #include "runtime/vm_operations.hpp" |
zgu@4081 | 60 | #include "services/memTracker.hpp" |
phh@3427 | 61 | #include "trace/tracing.hpp" |
stefank@2314 | 62 | #include "utilities/dtrace.hpp" |
stefank@2314 | 63 | #include "utilities/globalDefinitions.hpp" |
stefank@2314 | 64 | #include "utilities/histogram.hpp" |
jprovino@4542 | 65 | #include "utilities/macros.hpp" |
stefank@2314 | 66 | #include "utilities/vmError.hpp" |
stefank@2314 | 67 | #ifdef TARGET_ARCH_x86 |
stefank@2314 | 68 | # include "vm_version_x86.hpp" |
stefank@2314 | 69 | #endif |
stefank@2314 | 70 | #ifdef TARGET_ARCH_sparc |
stefank@2314 | 71 | # include "vm_version_sparc.hpp" |
stefank@2314 | 72 | #endif |
stefank@2314 | 73 | #ifdef TARGET_ARCH_zero |
stefank@2314 | 74 | # include "vm_version_zero.hpp" |
stefank@2314 | 75 | #endif |
bobv@2508 | 76 | #ifdef TARGET_ARCH_arm |
bobv@2508 | 77 | # include "vm_version_arm.hpp" |
bobv@2508 | 78 | #endif |
bobv@2508 | 79 | #ifdef TARGET_ARCH_ppc |
bobv@2508 | 80 | # include "vm_version_ppc.hpp" |
bobv@2508 | 81 | #endif |
jprovino@4542 | 82 | #if INCLUDE_ALL_GCS |
stefank@2314 | 83 | #include "gc_implementation/concurrentMarkSweep/concurrentMarkSweepThread.hpp" |
stefank@2314 | 84 | #include "gc_implementation/parallelScavenge/psScavenge.hpp" |
stefank@2314 | 85 | #include "gc_implementation/parallelScavenge/psScavenge.inline.hpp" |
jprovino@4542 | 86 | #endif // INCLUDE_ALL_GCS |
stefank@2314 | 87 | #ifdef COMPILER1 |
stefank@2314 | 88 | #include "c1/c1_Compiler.hpp" |
stefank@2314 | 89 | #include "c1/c1_Runtime1.hpp" |
stefank@2314 | 90 | #endif |
stefank@2314 | 91 | #ifdef COMPILER2 |
stefank@2314 | 92 | #include "code/compiledIC.hpp" |
stefank@2314 | 93 | #include "compiler/methodLiveness.hpp" |
stefank@2314 | 94 | #include "opto/compile.hpp" |
stefank@2314 | 95 | #include "opto/indexSet.hpp" |
stefank@2314 | 96 | #include "opto/runtime.hpp" |
stefank@2314 | 97 | #endif |
duke@435 | 98 | |
dcubed@3202 | 99 | #ifndef USDT2 |
duke@435 | 100 | HS_DTRACE_PROBE_DECL(hotspot, vm__shutdown); |
dcubed@3202 | 101 | #endif /* !USDT2 */ |
duke@435 | 102 | |
duke@435 | 103 | #ifndef PRODUCT |
duke@435 | 104 | |
duke@435 | 105 | // Statistics printing (method invocation histogram) |
duke@435 | 106 | |
coleenp@4037 | 107 | GrowableArray<Method*>* collected_invoked_methods; |
duke@435 | 108 | |
coleenp@4037 | 109 | void collect_invoked_methods(Method* m) { |
duke@435 | 110 | if (m->invocation_count() + m->compiled_invocation_count() >= 1 ) { |
duke@435 | 111 | collected_invoked_methods->push(m); |
duke@435 | 112 | } |
duke@435 | 113 | } |
duke@435 | 114 | |
drchase@6680 | 115 | PRAGMA_FORMAT_MUTE_WARNINGS_FOR_GCC |
duke@435 | 116 | |
coleenp@4037 | 117 | GrowableArray<Method*>* collected_profiled_methods; |
duke@435 | 118 | |
coleenp@4037 | 119 | void collect_profiled_methods(Method* m) { |
coleenp@4037 | 120 | Thread* thread = Thread::current(); |
coleenp@4037 | 121 | // This HandleMark prevents a huge amount of handles from being added |
coleenp@4037 | 122 | // to the metadata_handles() array on the thread. |
coleenp@4037 | 123 | HandleMark hm(thread); |
coleenp@4037 | 124 | methodHandle mh(thread, m); |
duke@435 | 125 | if ((m->method_data() != NULL) && |
duke@435 | 126 | (PrintMethodData || CompilerOracle::should_print(mh))) { |
duke@435 | 127 | collected_profiled_methods->push(m); |
duke@435 | 128 | } |
duke@435 | 129 | } |
duke@435 | 130 | |
duke@435 | 131 | |
coleenp@4037 | 132 | int compare_methods(Method** a, Method** b) { |
duke@435 | 133 | // %%% there can be 32-bit overflow here |
duke@435 | 134 | return ((*b)->invocation_count() + (*b)->compiled_invocation_count()) |
duke@435 | 135 | - ((*a)->invocation_count() + (*a)->compiled_invocation_count()); |
duke@435 | 136 | } |
duke@435 | 137 | |
duke@435 | 138 | |
duke@435 | 139 | void print_method_invocation_histogram() { |
duke@435 | 140 | ResourceMark rm; |
duke@435 | 141 | HandleMark hm; |
coleenp@4037 | 142 | collected_invoked_methods = new GrowableArray<Method*>(1024); |
duke@435 | 143 | SystemDictionary::methods_do(collect_invoked_methods); |
duke@435 | 144 | collected_invoked_methods->sort(&compare_methods); |
duke@435 | 145 | // |
duke@435 | 146 | tty->cr(); |
duke@435 | 147 | tty->print_cr("Histogram Over MethodOop Invocation Counters (cutoff = %d):", MethodHistogramCutoff); |
duke@435 | 148 | tty->cr(); |
duke@435 | 149 | tty->print_cr("____Count_(I+C)____Method________________________Module_________________"); |
duke@435 | 150 | unsigned total = 0, int_total = 0, comp_total = 0, static_total = 0, final_total = 0, |
duke@435 | 151 | synch_total = 0, nativ_total = 0, acces_total = 0; |
duke@435 | 152 | for (int index = 0; index < collected_invoked_methods->length(); index++) { |
coleenp@4037 | 153 | Method* m = collected_invoked_methods->at(index); |
duke@435 | 154 | int c = m->invocation_count() + m->compiled_invocation_count(); |
duke@435 | 155 | if (c >= MethodHistogramCutoff) m->print_invocation_count(); |
duke@435 | 156 | int_total += m->invocation_count(); |
duke@435 | 157 | comp_total += m->compiled_invocation_count(); |
duke@435 | 158 | if (m->is_final()) final_total += c; |
duke@435 | 159 | if (m->is_static()) static_total += c; |
duke@435 | 160 | if (m->is_synchronized()) synch_total += c; |
duke@435 | 161 | if (m->is_native()) nativ_total += c; |
duke@435 | 162 | if (m->is_accessor()) acces_total += c; |
duke@435 | 163 | } |
duke@435 | 164 | tty->cr(); |
duke@435 | 165 | total = int_total + comp_total; |
duke@435 | 166 | tty->print_cr("Invocations summary:"); |
duke@435 | 167 | tty->print_cr("\t%9d (%4.1f%%) interpreted", int_total, 100.0 * int_total / total); |
duke@435 | 168 | tty->print_cr("\t%9d (%4.1f%%) compiled", comp_total, 100.0 * comp_total / total); |
duke@435 | 169 | tty->print_cr("\t%9d (100%%) total", total); |
duke@435 | 170 | tty->print_cr("\t%9d (%4.1f%%) synchronized", synch_total, 100.0 * synch_total / total); |
duke@435 | 171 | tty->print_cr("\t%9d (%4.1f%%) final", final_total, 100.0 * final_total / total); |
duke@435 | 172 | tty->print_cr("\t%9d (%4.1f%%) static", static_total, 100.0 * static_total / total); |
duke@435 | 173 | tty->print_cr("\t%9d (%4.1f%%) native", nativ_total, 100.0 * nativ_total / total); |
duke@435 | 174 | tty->print_cr("\t%9d (%4.1f%%) accessor", acces_total, 100.0 * acces_total / total); |
duke@435 | 175 | tty->cr(); |
duke@435 | 176 | SharedRuntime::print_call_statistics(comp_total); |
duke@435 | 177 | } |
duke@435 | 178 | |
duke@435 | 179 | void print_method_profiling_data() { |
duke@435 | 180 | ResourceMark rm; |
duke@435 | 181 | HandleMark hm; |
coleenp@4037 | 182 | collected_profiled_methods = new GrowableArray<Method*>(1024); |
duke@435 | 183 | SystemDictionary::methods_do(collect_profiled_methods); |
duke@435 | 184 | collected_profiled_methods->sort(&compare_methods); |
duke@435 | 185 | |
duke@435 | 186 | int count = collected_profiled_methods->length(); |
roland@5914 | 187 | int total_size = 0; |
duke@435 | 188 | if (count > 0) { |
duke@435 | 189 | for (int index = 0; index < count; index++) { |
coleenp@4037 | 190 | Method* m = collected_profiled_methods->at(index); |
duke@435 | 191 | ttyLocker ttyl; |
duke@435 | 192 | tty->print_cr("------------------------------------------------------------------------"); |
duke@435 | 193 | //m->print_name(tty); |
duke@435 | 194 | m->print_invocation_count(); |
roland@5914 | 195 | tty->print_cr(" mdo size: %d bytes", m->method_data()->size_in_bytes()); |
duke@435 | 196 | tty->cr(); |
roland@5987 | 197 | // Dump data on parameters if any |
roland@5987 | 198 | if (m->method_data() != NULL && m->method_data()->parameters_type_data() != NULL) { |
roland@5987 | 199 | tty->fill_to(2); |
roland@5987 | 200 | m->method_data()->parameters_type_data()->print_data_on(tty); |
roland@5987 | 201 | } |
duke@435 | 202 | m->print_codes(); |
roland@5914 | 203 | total_size += m->method_data()->size_in_bytes(); |
duke@435 | 204 | } |
duke@435 | 205 | tty->print_cr("------------------------------------------------------------------------"); |
roland@5914 | 206 | tty->print_cr("Total MDO size: %d bytes", total_size); |
duke@435 | 207 | } |
duke@435 | 208 | } |
duke@435 | 209 | |
duke@435 | 210 | void print_bytecode_count() { |
duke@435 | 211 | if (CountBytecodes || TraceBytecodes || StopInterpreterAt) { |
duke@435 | 212 | tty->print_cr("[BytecodeCounter::counter_value = %d]", BytecodeCounter::counter_value()); |
duke@435 | 213 | } |
duke@435 | 214 | } |
duke@435 | 215 | |
duke@435 | 216 | AllocStats alloc_stats; |
duke@435 | 217 | |
duke@435 | 218 | |
duke@435 | 219 | |
duke@435 | 220 | // General statistics printing (profiling ...) |
duke@435 | 221 | void print_statistics() { |
duke@435 | 222 | #ifdef ASSERT |
duke@435 | 223 | |
duke@435 | 224 | if (CountRuntimeCalls) { |
duke@435 | 225 | extern Histogram *RuntimeHistogram; |
duke@435 | 226 | RuntimeHistogram->print(); |
duke@435 | 227 | } |
duke@435 | 228 | |
duke@435 | 229 | if (CountJNICalls) { |
duke@435 | 230 | extern Histogram *JNIHistogram; |
duke@435 | 231 | JNIHistogram->print(); |
duke@435 | 232 | } |
duke@435 | 233 | |
duke@435 | 234 | if (CountJVMCalls) { |
duke@435 | 235 | extern Histogram *JVMHistogram; |
duke@435 | 236 | JVMHistogram->print(); |
duke@435 | 237 | } |
duke@435 | 238 | |
duke@435 | 239 | #endif |
duke@435 | 240 | |
duke@435 | 241 | if (MemProfiling) { |
duke@435 | 242 | MemProfiler::disengage(); |
duke@435 | 243 | } |
duke@435 | 244 | |
duke@435 | 245 | if (CITime) { |
duke@435 | 246 | CompileBroker::print_times(); |
duke@435 | 247 | } |
duke@435 | 248 | |
duke@435 | 249 | #ifdef COMPILER1 |
duke@435 | 250 | if ((PrintC1Statistics || LogVMOutput || LogCompilation) && UseCompiler) { |
duke@435 | 251 | FlagSetting fs(DisplayVMOutput, DisplayVMOutput && PrintC1Statistics); |
duke@435 | 252 | Runtime1::print_statistics(); |
duke@435 | 253 | Deoptimization::print_statistics(); |
never@3039 | 254 | SharedRuntime::print_statistics(); |
duke@435 | 255 | nmethod::print_statistics(); |
duke@435 | 256 | } |
duke@435 | 257 | #endif /* COMPILER1 */ |
duke@435 | 258 | |
duke@435 | 259 | #ifdef COMPILER2 |
duke@435 | 260 | if ((PrintOptoStatistics || LogVMOutput || LogCompilation) && UseCompiler) { |
duke@435 | 261 | FlagSetting fs(DisplayVMOutput, DisplayVMOutput && PrintOptoStatistics); |
duke@435 | 262 | Compile::print_statistics(); |
duke@435 | 263 | #ifndef COMPILER1 |
duke@435 | 264 | Deoptimization::print_statistics(); |
duke@435 | 265 | nmethod::print_statistics(); |
never@3039 | 266 | SharedRuntime::print_statistics(); |
duke@435 | 267 | #endif //COMPILER1 |
duke@435 | 268 | os::print_statistics(); |
duke@435 | 269 | } |
duke@435 | 270 | |
kvn@6429 | 271 | if (PrintLockStatistics || PrintPreciseBiasedLockingStatistics || PrintPreciseRTMLockingStatistics) { |
duke@435 | 272 | OptoRuntime::print_named_counters(); |
duke@435 | 273 | } |
duke@435 | 274 | |
duke@435 | 275 | if (TimeLivenessAnalysis) { |
duke@435 | 276 | MethodLiveness::print_times(); |
duke@435 | 277 | } |
duke@435 | 278 | #ifdef ASSERT |
duke@435 | 279 | if (CollectIndexSetStatistics) { |
duke@435 | 280 | IndexSet::print_statistics(); |
duke@435 | 281 | } |
duke@435 | 282 | #endif // ASSERT |
duke@435 | 283 | #endif // COMPILER2 |
duke@435 | 284 | if (CountCompiledCalls) { |
duke@435 | 285 | print_method_invocation_histogram(); |
duke@435 | 286 | } |
iveresov@2273 | 287 | if (ProfileInterpreter COMPILER1_PRESENT(|| C1UpdateMethodData)) { |
duke@435 | 288 | print_method_profiling_data(); |
duke@435 | 289 | } |
duke@435 | 290 | if (TimeCompiler) { |
duke@435 | 291 | COMPILER2_PRESENT(Compile::print_timers();) |
duke@435 | 292 | } |
duke@435 | 293 | if (TimeCompilationPolicy) { |
duke@435 | 294 | CompilationPolicy::policy()->print_time(); |
duke@435 | 295 | } |
duke@435 | 296 | if (TimeOopMap) { |
duke@435 | 297 | GenerateOopMap::print_time(); |
duke@435 | 298 | } |
duke@435 | 299 | if (ProfilerCheckIntervals) { |
duke@435 | 300 | PeriodicTask::print_intervals(); |
duke@435 | 301 | } |
duke@435 | 302 | if (PrintSymbolTableSizeHistogram) { |
duke@435 | 303 | SymbolTable::print_histogram(); |
duke@435 | 304 | } |
duke@435 | 305 | if (CountBytecodes || TraceBytecodes || StopInterpreterAt) { |
duke@435 | 306 | BytecodeCounter::print(); |
duke@435 | 307 | } |
duke@435 | 308 | if (PrintBytecodePairHistogram) { |
duke@435 | 309 | BytecodePairHistogram::print(); |
duke@435 | 310 | } |
duke@435 | 311 | |
duke@435 | 312 | if (PrintCodeCache) { |
duke@435 | 313 | MutexLockerEx mu(CodeCache_lock, Mutex::_no_safepoint_check_flag); |
duke@435 | 314 | CodeCache::print(); |
duke@435 | 315 | } |
duke@435 | 316 | |
anoll@6207 | 317 | if (PrintMethodFlushingStatistics) { |
anoll@6207 | 318 | NMethodSweeper::print(); |
anoll@6207 | 319 | } |
anoll@6207 | 320 | |
duke@435 | 321 | if (PrintCodeCache2) { |
duke@435 | 322 | MutexLockerEx mu(CodeCache_lock, Mutex::_no_safepoint_check_flag); |
duke@435 | 323 | CodeCache::print_internals(); |
duke@435 | 324 | } |
duke@435 | 325 | |
duke@435 | 326 | if (PrintClassStatistics) { |
duke@435 | 327 | SystemDictionary::print_class_statistics(); |
duke@435 | 328 | } |
duke@435 | 329 | if (PrintMethodStatistics) { |
duke@435 | 330 | SystemDictionary::print_method_statistics(); |
duke@435 | 331 | } |
duke@435 | 332 | |
duke@435 | 333 | if (PrintVtableStats) { |
duke@435 | 334 | klassVtable::print_statistics(); |
duke@435 | 335 | klassItable::print_statistics(); |
duke@435 | 336 | } |
duke@435 | 337 | if (VerifyOops) { |
duke@435 | 338 | tty->print_cr("+VerifyOops count: %d", StubRoutines::verify_oop_count()); |
duke@435 | 339 | } |
duke@435 | 340 | |
duke@435 | 341 | print_bytecode_count(); |
kvn@2557 | 342 | if (PrintMallocStatistics) { |
duke@435 | 343 | tty->print("allocation stats: "); |
duke@435 | 344 | alloc_stats.print(); |
duke@435 | 345 | tty->cr(); |
duke@435 | 346 | } |
duke@435 | 347 | |
duke@435 | 348 | if (PrintSystemDictionaryAtExit) { |
duke@435 | 349 | SystemDictionary::print(); |
duke@435 | 350 | } |
duke@435 | 351 | |
duke@435 | 352 | if (PrintBiasedLockingStatistics) { |
duke@435 | 353 | BiasedLocking::print_counters(); |
duke@435 | 354 | } |
duke@435 | 355 | |
duke@435 | 356 | #ifdef ENABLE_ZAP_DEAD_LOCALS |
duke@435 | 357 | #ifdef COMPILER2 |
duke@435 | 358 | if (ZapDeadCompiledLocals) { |
duke@435 | 359 | tty->print_cr("Compile::CompiledZap_count = %d", Compile::CompiledZap_count); |
duke@435 | 360 | tty->print_cr("OptoRuntime::ZapDeadCompiledLocals_count = %d", OptoRuntime::ZapDeadCompiledLocals_count); |
duke@435 | 361 | } |
duke@435 | 362 | #endif // COMPILER2 |
duke@435 | 363 | #endif // ENABLE_ZAP_DEAD_LOCALS |
zgu@4081 | 364 | // Native memory tracking data |
zgu@4081 | 365 | if (PrintNMTStatistics) { |
zgu@7074 | 366 | MemTracker::final_report(tty); |
zgu@4081 | 367 | } |
duke@435 | 368 | } |
duke@435 | 369 | |
duke@435 | 370 | #else // PRODUCT MODE STATISTICS |
duke@435 | 371 | |
duke@435 | 372 | void print_statistics() { |
duke@435 | 373 | |
duke@435 | 374 | if (CITime) { |
duke@435 | 375 | CompileBroker::print_times(); |
duke@435 | 376 | } |
vladidan@4438 | 377 | |
vladidan@4438 | 378 | if (PrintCodeCache) { |
vladidan@4438 | 379 | MutexLockerEx mu(CodeCache_lock, Mutex::_no_safepoint_check_flag); |
vladidan@4438 | 380 | CodeCache::print(); |
vladidan@4438 | 381 | } |
vladidan@4438 | 382 | |
anoll@6207 | 383 | if (PrintMethodFlushingStatistics) { |
anoll@6207 | 384 | NMethodSweeper::print(); |
anoll@6207 | 385 | } |
anoll@6207 | 386 | |
duke@435 | 387 | #ifdef COMPILER2 |
kvn@6429 | 388 | if (PrintPreciseBiasedLockingStatistics || PrintPreciseRTMLockingStatistics) { |
duke@435 | 389 | OptoRuntime::print_named_counters(); |
duke@435 | 390 | } |
duke@435 | 391 | #endif |
duke@435 | 392 | if (PrintBiasedLockingStatistics) { |
duke@435 | 393 | BiasedLocking::print_counters(); |
duke@435 | 394 | } |
zgu@4081 | 395 | |
zgu@4081 | 396 | // Native memory tracking data |
zgu@4081 | 397 | if (PrintNMTStatistics) { |
zgu@7074 | 398 | MemTracker::final_report(tty); |
zgu@4081 | 399 | } |
duke@435 | 400 | } |
duke@435 | 401 | |
duke@435 | 402 | #endif |
duke@435 | 403 | |
duke@435 | 404 | |
duke@435 | 405 | // Helper class for registering on_exit calls through JVM_OnExit |
duke@435 | 406 | |
duke@435 | 407 | extern "C" { |
duke@435 | 408 | typedef void (*__exit_proc)(void); |
duke@435 | 409 | } |
duke@435 | 410 | |
zgu@3900 | 411 | class ExitProc : public CHeapObj<mtInternal> { |
duke@435 | 412 | private: |
duke@435 | 413 | __exit_proc _proc; |
duke@435 | 414 | // void (*_proc)(void); |
duke@435 | 415 | ExitProc* _next; |
duke@435 | 416 | public: |
duke@435 | 417 | // ExitProc(void (*proc)(void)) { |
duke@435 | 418 | ExitProc(__exit_proc proc) { |
duke@435 | 419 | _proc = proc; |
duke@435 | 420 | _next = NULL; |
duke@435 | 421 | } |
duke@435 | 422 | void evaluate() { _proc(); } |
duke@435 | 423 | ExitProc* next() const { return _next; } |
duke@435 | 424 | void set_next(ExitProc* next) { _next = next; } |
duke@435 | 425 | }; |
duke@435 | 426 | |
duke@435 | 427 | |
duke@435 | 428 | // Linked list of registered on_exit procedures |
duke@435 | 429 | |
duke@435 | 430 | static ExitProc* exit_procs = NULL; |
duke@435 | 431 | |
duke@435 | 432 | |
duke@435 | 433 | extern "C" { |
duke@435 | 434 | void register_on_exit_function(void (*func)(void)) { |
duke@435 | 435 | ExitProc *entry = new ExitProc(func); |
duke@435 | 436 | // Classic vm does not throw an exception in case the allocation failed, |
duke@435 | 437 | if (entry != NULL) { |
duke@435 | 438 | entry->set_next(exit_procs); |
duke@435 | 439 | exit_procs = entry; |
duke@435 | 440 | } |
duke@435 | 441 | } |
duke@435 | 442 | } |
duke@435 | 443 | |
duke@435 | 444 | // Note: before_exit() can be executed only once, if more than one threads |
duke@435 | 445 | // are trying to shutdown the VM at the same time, only one thread |
duke@435 | 446 | // can run before_exit() and all other threads must wait. |
duke@435 | 447 | void before_exit(JavaThread * thread) { |
duke@435 | 448 | #define BEFORE_EXIT_NOT_RUN 0 |
duke@435 | 449 | #define BEFORE_EXIT_RUNNING 1 |
duke@435 | 450 | #define BEFORE_EXIT_DONE 2 |
duke@435 | 451 | static jint volatile _before_exit_status = BEFORE_EXIT_NOT_RUN; |
duke@435 | 452 | |
duke@435 | 453 | // Note: don't use a Mutex to guard the entire before_exit(), as |
duke@435 | 454 | // JVMTI post_thread_end_event and post_vm_death_event will run native code. |
duke@435 | 455 | // A CAS or OSMutex would work just fine but then we need to manipulate |
duke@435 | 456 | // thread state for Safepoint. Here we use Monitor wait() and notify_all() |
duke@435 | 457 | // for synchronization. |
duke@435 | 458 | { MutexLocker ml(BeforeExit_lock); |
duke@435 | 459 | switch (_before_exit_status) { |
duke@435 | 460 | case BEFORE_EXIT_NOT_RUN: |
duke@435 | 461 | _before_exit_status = BEFORE_EXIT_RUNNING; |
duke@435 | 462 | break; |
duke@435 | 463 | case BEFORE_EXIT_RUNNING: |
duke@435 | 464 | while (_before_exit_status == BEFORE_EXIT_RUNNING) { |
duke@435 | 465 | BeforeExit_lock->wait(); |
duke@435 | 466 | } |
duke@435 | 467 | assert(_before_exit_status == BEFORE_EXIT_DONE, "invalid state"); |
duke@435 | 468 | return; |
duke@435 | 469 | case BEFORE_EXIT_DONE: |
duke@435 | 470 | return; |
duke@435 | 471 | } |
duke@435 | 472 | } |
duke@435 | 473 | |
duke@435 | 474 | // The only difference between this and Win32's _onexit procs is that |
duke@435 | 475 | // this version is invoked before any threads get killed. |
duke@435 | 476 | ExitProc* current = exit_procs; |
duke@435 | 477 | while (current != NULL) { |
duke@435 | 478 | ExitProc* next = current->next(); |
duke@435 | 479 | current->evaluate(); |
duke@435 | 480 | delete current; |
duke@435 | 481 | current = next; |
duke@435 | 482 | } |
duke@435 | 483 | |
duke@435 | 484 | // Hang forever on exit if we're reporting an error. |
duke@435 | 485 | if (ShowMessageBoxOnError && is_error_reported()) { |
duke@435 | 486 | os::infinite_sleep(); |
duke@435 | 487 | } |
duke@435 | 488 | |
duke@435 | 489 | // Terminate watcher thread - must before disenrolling any periodic task |
bobv@2036 | 490 | if (PeriodicTask::num_tasks() > 0) |
bobv@2036 | 491 | WatcherThread::stop(); |
duke@435 | 492 | |
duke@435 | 493 | // Print statistics gathered (profiling ...) |
duke@435 | 494 | if (Arguments::has_profile()) { |
duke@435 | 495 | FlatProfiler::disengage(); |
duke@435 | 496 | FlatProfiler::print(10); |
duke@435 | 497 | } |
duke@435 | 498 | |
duke@435 | 499 | // shut down the StatSampler task |
duke@435 | 500 | StatSampler::disengage(); |
duke@435 | 501 | StatSampler::destroy(); |
duke@435 | 502 | |
pliden@6735 | 503 | // Stop concurrent GC threads |
pliden@6735 | 504 | Universe::heap()->stop(); |
duke@435 | 505 | |
duke@435 | 506 | // Print GC/heap related information. |
duke@435 | 507 | if (PrintGCDetails) { |
duke@435 | 508 | Universe::print(); |
duke@435 | 509 | AdaptiveSizePolicyOutput(0); |
coleenp@4037 | 510 | if (Verbose) { |
coleenp@4037 | 511 | ClassLoaderDataGraph::dump_on(gclog_or_tty); |
coleenp@4037 | 512 | } |
duke@435 | 513 | } |
duke@435 | 514 | |
duke@435 | 515 | if (PrintBytecodeHistogram) { |
duke@435 | 516 | BytecodeHistogram::print(); |
duke@435 | 517 | } |
duke@435 | 518 | |
duke@435 | 519 | if (JvmtiExport::should_post_thread_life()) { |
duke@435 | 520 | JvmtiExport::post_thread_end(thread); |
duke@435 | 521 | } |
phh@3427 | 522 | |
sla@5237 | 523 | |
sla@5237 | 524 | EventThreadEnd event; |
sla@5237 | 525 | if (event.should_commit()) { |
sla@5237 | 526 | event.set_javalangthread(java_lang_Thread::thread_id(thread->threadObj())); |
sla@5237 | 527 | event.commit(); |
sla@5237 | 528 | } |
phh@3427 | 529 | |
duke@435 | 530 | // Always call even when there are not JVMTI environments yet, since environments |
duke@435 | 531 | // may be attached late and JVMTI must track phases of VM execution |
duke@435 | 532 | JvmtiExport::post_vm_death(); |
duke@435 | 533 | Threads::shutdown_vm_agents(); |
duke@435 | 534 | |
duke@435 | 535 | // Terminate the signal thread |
duke@435 | 536 | // Note: we don't wait until it actually dies. |
duke@435 | 537 | os::terminate_signal_thread(); |
duke@435 | 538 | |
duke@435 | 539 | print_statistics(); |
duke@435 | 540 | Universe::heap()->print_tracing_info(); |
duke@435 | 541 | |
duke@435 | 542 | { MutexLocker ml(BeforeExit_lock); |
duke@435 | 543 | _before_exit_status = BEFORE_EXIT_DONE; |
duke@435 | 544 | BeforeExit_lock->notify_all(); |
duke@435 | 545 | } |
duke@435 | 546 | |
dcubed@5743 | 547 | if (VerifyStringTableAtExit) { |
dcubed@5743 | 548 | int fail_cnt = 0; |
dcubed@5743 | 549 | { |
dcubed@5743 | 550 | MutexLocker ml(StringTable_lock); |
dcubed@5743 | 551 | fail_cnt = StringTable::verify_and_compare_entries(); |
dcubed@5743 | 552 | } |
dcubed@5743 | 553 | |
dcubed@5743 | 554 | if (fail_cnt != 0) { |
dcubed@5743 | 555 | tty->print_cr("ERROR: fail_cnt=%d", fail_cnt); |
dcubed@5743 | 556 | guarantee(fail_cnt == 0, "unexpected StringTable verification failures"); |
dcubed@5743 | 557 | } |
dcubed@5743 | 558 | } |
dcubed@5743 | 559 | |
duke@435 | 560 | #undef BEFORE_EXIT_NOT_RUN |
duke@435 | 561 | #undef BEFORE_EXIT_RUNNING |
duke@435 | 562 | #undef BEFORE_EXIT_DONE |
duke@435 | 563 | } |
duke@435 | 564 | |
duke@435 | 565 | void vm_exit(int code) { |
coleenp@2419 | 566 | Thread* thread = ThreadLocalStorage::is_initialized() ? |
coleenp@2419 | 567 | ThreadLocalStorage::get_thread_slow() : NULL; |
duke@435 | 568 | if (thread == NULL) { |
duke@435 | 569 | // we have serious problems -- just exit |
duke@435 | 570 | vm_direct_exit(code); |
duke@435 | 571 | } |
duke@435 | 572 | |
duke@435 | 573 | if (VMThread::vm_thread() != NULL) { |
duke@435 | 574 | // Fire off a VM_Exit operation to bring VM to a safepoint and exit |
duke@435 | 575 | VM_Exit op(code); |
duke@435 | 576 | if (thread->is_Java_thread()) |
duke@435 | 577 | ((JavaThread*)thread)->set_thread_state(_thread_in_vm); |
duke@435 | 578 | VMThread::execute(&op); |
duke@435 | 579 | // should never reach here; but in case something wrong with VM Thread. |
duke@435 | 580 | vm_direct_exit(code); |
duke@435 | 581 | } else { |
duke@435 | 582 | // VM thread is gone, just exit |
duke@435 | 583 | vm_direct_exit(code); |
duke@435 | 584 | } |
duke@435 | 585 | ShouldNotReachHere(); |
duke@435 | 586 | } |
duke@435 | 587 | |
duke@435 | 588 | void notify_vm_shutdown() { |
duke@435 | 589 | // For now, just a dtrace probe. |
dcubed@3202 | 590 | #ifndef USDT2 |
duke@435 | 591 | HS_DTRACE_PROBE(hotspot, vm__shutdown); |
jcoomes@1902 | 592 | HS_DTRACE_WORKAROUND_TAIL_CALL_BUG(); |
dcubed@3202 | 593 | #else /* USDT2 */ |
dcubed@3202 | 594 | HOTSPOT_VM_SHUTDOWN(); |
dcubed@3202 | 595 | #endif /* USDT2 */ |
duke@435 | 596 | } |
duke@435 | 597 | |
duke@435 | 598 | void vm_direct_exit(int code) { |
duke@435 | 599 | notify_vm_shutdown(); |
sla@2584 | 600 | os::wait_for_keypress_at_exit(); |
duke@435 | 601 | ::exit(code); |
duke@435 | 602 | } |
duke@435 | 603 | |
duke@435 | 604 | void vm_perform_shutdown_actions() { |
duke@435 | 605 | // Warning: do not call 'exit_globals()' here. All threads are still running. |
duke@435 | 606 | // Calling 'exit_globals()' will disable thread-local-storage and cause all |
duke@435 | 607 | // kinds of assertions to trigger in debug mode. |
duke@435 | 608 | if (is_init_completed()) { |
coleenp@2419 | 609 | Thread* thread = ThreadLocalStorage::is_initialized() ? |
coleenp@2419 | 610 | ThreadLocalStorage::get_thread_slow() : NULL; |
coleenp@2419 | 611 | if (thread != NULL && thread->is_Java_thread()) { |
duke@435 | 612 | // We are leaving the VM, set state to native (in case any OS exit |
duke@435 | 613 | // handlers call back to the VM) |
duke@435 | 614 | JavaThread* jt = (JavaThread*)thread; |
duke@435 | 615 | // Must always be walkable or have no last_Java_frame when in |
duke@435 | 616 | // thread_in_native |
duke@435 | 617 | jt->frame_anchor()->make_walkable(jt); |
duke@435 | 618 | jt->set_thread_state(_thread_in_native); |
duke@435 | 619 | } |
duke@435 | 620 | } |
duke@435 | 621 | notify_vm_shutdown(); |
duke@435 | 622 | } |
duke@435 | 623 | |
duke@435 | 624 | void vm_shutdown() |
duke@435 | 625 | { |
duke@435 | 626 | vm_perform_shutdown_actions(); |
sla@2584 | 627 | os::wait_for_keypress_at_exit(); |
duke@435 | 628 | os::shutdown(); |
duke@435 | 629 | } |
duke@435 | 630 | |
poonam@662 | 631 | void vm_abort(bool dump_core) { |
duke@435 | 632 | vm_perform_shutdown_actions(); |
sla@2584 | 633 | os::wait_for_keypress_at_exit(); |
poonam@662 | 634 | os::abort(dump_core); |
duke@435 | 635 | ShouldNotReachHere(); |
duke@435 | 636 | } |
duke@435 | 637 | |
duke@435 | 638 | void vm_notify_during_shutdown(const char* error, const char* message) { |
duke@435 | 639 | if (error != NULL) { |
duke@435 | 640 | tty->print_cr("Error occurred during initialization of VM"); |
duke@435 | 641 | tty->print("%s", error); |
duke@435 | 642 | if (message != NULL) { |
duke@435 | 643 | tty->print_cr(": %s", message); |
duke@435 | 644 | } |
duke@435 | 645 | else { |
duke@435 | 646 | tty->cr(); |
duke@435 | 647 | } |
duke@435 | 648 | } |
duke@435 | 649 | if (ShowMessageBoxOnError && WizardMode) { |
duke@435 | 650 | fatal("Error occurred during initialization of VM"); |
duke@435 | 651 | } |
duke@435 | 652 | } |
duke@435 | 653 | |
duke@435 | 654 | void vm_exit_during_initialization(Handle exception) { |
duke@435 | 655 | tty->print_cr("Error occurred during initialization of VM"); |
duke@435 | 656 | // If there are exceptions on this thread it must be cleared |
duke@435 | 657 | // first and here. Any future calls to EXCEPTION_MARK requires |
duke@435 | 658 | // that no pending exceptions exist. |
duke@435 | 659 | Thread *THREAD = Thread::current(); |
duke@435 | 660 | if (HAS_PENDING_EXCEPTION) { |
duke@435 | 661 | CLEAR_PENDING_EXCEPTION; |
duke@435 | 662 | } |
duke@435 | 663 | java_lang_Throwable::print(exception, tty); |
duke@435 | 664 | tty->cr(); |
duke@435 | 665 | java_lang_Throwable::print_stack_trace(exception(), tty); |
duke@435 | 666 | tty->cr(); |
duke@435 | 667 | vm_notify_during_shutdown(NULL, NULL); |
poonam@662 | 668 | |
poonam@662 | 669 | // Failure during initialization, we don't want to dump core |
poonam@662 | 670 | vm_abort(false); |
duke@435 | 671 | } |
duke@435 | 672 | |
coleenp@2497 | 673 | void vm_exit_during_initialization(Symbol* ex, const char* message) { |
duke@435 | 674 | ResourceMark rm; |
duke@435 | 675 | vm_notify_during_shutdown(ex->as_C_string(), message); |
poonam@662 | 676 | |
poonam@662 | 677 | // Failure during initialization, we don't want to dump core |
poonam@662 | 678 | vm_abort(false); |
duke@435 | 679 | } |
duke@435 | 680 | |
duke@435 | 681 | void vm_exit_during_initialization(const char* error, const char* message) { |
duke@435 | 682 | vm_notify_during_shutdown(error, message); |
poonam@662 | 683 | |
poonam@662 | 684 | // Failure during initialization, we don't want to dump core |
poonam@662 | 685 | vm_abort(false); |
duke@435 | 686 | } |
duke@435 | 687 | |
duke@435 | 688 | void vm_shutdown_during_initialization(const char* error, const char* message) { |
duke@435 | 689 | vm_notify_during_shutdown(error, message); |
duke@435 | 690 | vm_shutdown(); |
duke@435 | 691 | } |
duke@435 | 692 | |
kamg@677 | 693 | JDK_Version JDK_Version::_current; |
twisti@3884 | 694 | const char* JDK_Version::_runtime_name; |
sla@4232 | 695 | const char* JDK_Version::_runtime_version; |
duke@435 | 696 | |
duke@435 | 697 | void JDK_Version::initialize() { |
kamg@677 | 698 | jdk_version_info info; |
kamg@677 | 699 | assert(!_current.is_valid(), "Don't initialize twice"); |
kamg@677 | 700 | |
duke@435 | 701 | void *lib_handle = os::native_java_library(); |
kamg@677 | 702 | jdk_version_info_fn_t func = CAST_TO_FN_PTR(jdk_version_info_fn_t, |
kamg@677 | 703 | os::dll_lookup(lib_handle, "JDK_GetVersionInfo0")); |
duke@435 | 704 | |
duke@435 | 705 | if (func == NULL) { |
duke@435 | 706 | // JDK older than 1.6 |
kamg@677 | 707 | _current._partially_initialized = true; |
kamg@677 | 708 | } else { |
kamg@677 | 709 | (*func)(&info, sizeof(info)); |
kamg@677 | 710 | |
kamg@677 | 711 | int major = JDK_VERSION_MAJOR(info.jdk_version); |
kamg@677 | 712 | int minor = JDK_VERSION_MINOR(info.jdk_version); |
kamg@677 | 713 | int micro = JDK_VERSION_MICRO(info.jdk_version); |
kamg@677 | 714 | int build = JDK_VERSION_BUILD(info.jdk_version); |
kamg@677 | 715 | if (major == 1 && minor > 4) { |
kamg@677 | 716 | // We represent "1.5.0" as "5.0", but 1.4.2 as itself. |
kamg@677 | 717 | major = minor; |
kamg@677 | 718 | minor = micro; |
kamg@677 | 719 | micro = 0; |
kamg@677 | 720 | } |
kamg@677 | 721 | _current = JDK_Version(major, minor, micro, info.update_version, |
kamg@677 | 722 | info.special_update_version, build, |
kevinw@2449 | 723 | info.thread_park_blocker == 1, |
ysr@3117 | 724 | info.post_vm_init_hook_enabled == 1, |
ysr@3117 | 725 | info.pending_list_uses_discovered_field == 1); |
duke@435 | 726 | } |
kamg@677 | 727 | } |
duke@435 | 728 | |
kamg@677 | 729 | void JDK_Version::fully_initialize( |
kamg@677 | 730 | uint8_t major, uint8_t minor, uint8_t micro, uint8_t update) { |
kamg@677 | 731 | // This is only called when current is less than 1.6 and we've gotten |
kamg@677 | 732 | // far enough in the initialization to determine the exact version. |
kamg@677 | 733 | assert(major < 6, "not needed for JDK version >= 6"); |
kamg@677 | 734 | assert(is_partially_initialized(), "must not initialize"); |
kamg@677 | 735 | if (major < 5) { |
kamg@677 | 736 | // JDK verison sequence: 1.2.x, 1.3.x, 1.4.x, 5.0.x, 6.0.x, etc. |
kamg@677 | 737 | micro = minor; |
kamg@677 | 738 | minor = major; |
kamg@677 | 739 | major = 1; |
duke@435 | 740 | } |
kamg@677 | 741 | _current = JDK_Version(major, minor, micro, update); |
duke@435 | 742 | } |
duke@435 | 743 | |
duke@435 | 744 | void JDK_Version_init() { |
duke@435 | 745 | JDK_Version::initialize(); |
duke@435 | 746 | } |
kamg@677 | 747 | |
kamg@677 | 748 | static int64_t encode_jdk_version(const JDK_Version& v) { |
kamg@677 | 749 | return |
kamg@677 | 750 | ((int64_t)v.major_version() << (BitsPerByte * 5)) | |
kamg@677 | 751 | ((int64_t)v.minor_version() << (BitsPerByte * 4)) | |
kamg@677 | 752 | ((int64_t)v.micro_version() << (BitsPerByte * 3)) | |
kamg@677 | 753 | ((int64_t)v.update_version() << (BitsPerByte * 2)) | |
kamg@677 | 754 | ((int64_t)v.special_update_version() << (BitsPerByte * 1)) | |
kamg@677 | 755 | ((int64_t)v.build_number() << (BitsPerByte * 0)); |
kamg@677 | 756 | } |
kamg@677 | 757 | |
kamg@677 | 758 | int JDK_Version::compare(const JDK_Version& other) const { |
kamg@677 | 759 | assert(is_valid() && other.is_valid(), "Invalid version (uninitialized?)"); |
kamg@677 | 760 | if (!is_partially_initialized() && other.is_partially_initialized()) { |
kamg@677 | 761 | return -(other.compare(*this)); // flip the comparators |
kamg@677 | 762 | } |
kamg@677 | 763 | assert(!other.is_partially_initialized(), "Not initialized yet"); |
kamg@677 | 764 | if (is_partially_initialized()) { |
kamg@677 | 765 | assert(other.major_version() >= 6, |
kamg@677 | 766 | "Invalid JDK version comparison during initialization"); |
kamg@677 | 767 | return -1; |
kamg@677 | 768 | } else { |
kamg@677 | 769 | uint64_t e = encode_jdk_version(*this); |
kamg@677 | 770 | uint64_t o = encode_jdk_version(other); |
kamg@677 | 771 | return (e > o) ? 1 : ((e == o) ? 0 : -1); |
kamg@677 | 772 | } |
kamg@677 | 773 | } |
kamg@677 | 774 | |
kamg@677 | 775 | void JDK_Version::to_string(char* buffer, size_t buflen) const { |
shshahma@8584 | 776 | assert(buffer && buflen > 0, "call with useful buffer"); |
kamg@677 | 777 | size_t index = 0; |
kamg@677 | 778 | if (!is_valid()) { |
kamg@677 | 779 | jio_snprintf(buffer, buflen, "%s", "(uninitialized)"); |
kamg@677 | 780 | } else if (is_partially_initialized()) { |
kamg@677 | 781 | jio_snprintf(buffer, buflen, "%s", "(uninitialized) pre-1.6.0"); |
kamg@677 | 782 | } else { |
shshahma@8584 | 783 | int rc = jio_snprintf( |
kamg@677 | 784 | &buffer[index], buflen - index, "%d.%d", _major, _minor); |
shshahma@8584 | 785 | if (rc == -1) return; |
shshahma@8584 | 786 | index += rc; |
kamg@677 | 787 | if (_micro > 0) { |
shshahma@8584 | 788 | rc = jio_snprintf(&buffer[index], buflen - index, ".%d", _micro); |
shshahma@8584 | 789 | if (rc == -1) return; |
shshahma@8584 | 790 | index += rc; |
kamg@677 | 791 | } |
kamg@677 | 792 | if (_update > 0) { |
shshahma@8584 | 793 | rc = jio_snprintf(&buffer[index], buflen - index, "_%02d", _update); |
shshahma@8584 | 794 | if (rc == -1) return; |
shshahma@8584 | 795 | index += rc; |
kamg@677 | 796 | } |
kamg@677 | 797 | if (_special > 0) { |
shshahma@8584 | 798 | rc = jio_snprintf(&buffer[index], buflen - index, "%c", _special); |
shshahma@8584 | 799 | if (rc == -1) return; |
shshahma@8584 | 800 | index += rc; |
kamg@677 | 801 | } |
kamg@677 | 802 | if (_build > 0) { |
shshahma@8584 | 803 | rc = jio_snprintf(&buffer[index], buflen - index, "-b%02d", _build); |
shshahma@8584 | 804 | if (rc == -1) return; |
shshahma@8584 | 805 | index += rc; |
kamg@677 | 806 | } |
kamg@677 | 807 | } |
kamg@677 | 808 | } |