equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2003, 2014, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * |
4 * |
5 * This code is free software; you can redistribute it and/or modify it |
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 |
6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. |
7 * published by the Free Software Foundation. |
84 // loads from anything _memory_pool_obj points to or implies. |
84 // loads from anything _memory_pool_obj points to or implies. |
85 instanceOop pool_obj = (instanceOop)OrderAccess::load_ptr_acquire(&_memory_pool_obj); |
85 instanceOop pool_obj = (instanceOop)OrderAccess::load_ptr_acquire(&_memory_pool_obj); |
86 if (pool_obj == NULL) { |
86 if (pool_obj == NULL) { |
87 // It's ok for more than one thread to execute the code up to the locked region. |
87 // It's ok for more than one thread to execute the code up to the locked region. |
88 // Extra pool instances will just be gc'ed. |
88 // Extra pool instances will just be gc'ed. |
89 Klass* k = Management::sun_management_ManagementFactory_klass(CHECK_NULL); |
89 Klass* k = Management::sun_management_ManagementFactoryHelper_klass(CHECK_NULL); |
90 instanceKlassHandle ik(THREAD, k); |
90 instanceKlassHandle ik(THREAD, k); |
91 |
91 |
92 Handle pool_name = java_lang_String::create_from_str(_name, CHECK_NULL); |
92 Handle pool_name = java_lang_String::create_from_str(_name, CHECK_NULL); |
93 jlong usage_threshold_value = (_usage_threshold->is_high_threshold_supported() ? 0 : -1L); |
93 jlong usage_threshold_value = (_usage_threshold->is_high_threshold_supported() ? 0 : -1L); |
94 jlong gc_usage_threshold_value = (_gc_usage_threshold->is_high_threshold_supported() ? 0 : -1L); |
94 jlong gc_usage_threshold_value = (_gc_usage_threshold->is_high_threshold_supported() ? 0 : -1L); |