comparison src/share/vm/runtime/thread.cpp @ 2106:91fe28b03d6a

Merge.
author Thomas Wuerthinger <wuerthinger@ssw.jku.at>
date Wed, 26 Jan 2011 18:17:37 +0100
parents 06f017f7daa7 b1a2afa37ec4
children d25d4ca69222
comparison
equal deleted inserted replaced
2062:231bf6b9f5ad 2106:91fe28b03d6a
1 /* 1 /*
2 * Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 1997, 2011, 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.
175 // Base class for all threads: VMThread, WatcherThread, ConcurrentMarkSweepThread, 175 // Base class for all threads: VMThread, WatcherThread, ConcurrentMarkSweepThread,
176 // JavaThread 176 // JavaThread
177 177
178 178
179 Thread::Thread() { 179 Thread::Thread() {
180 // stack 180 // stack and get_thread
181 _stack_base = NULL; 181 set_stack_base(NULL);
182 _stack_size = 0; 182 set_stack_size(0);
183 _self_raw_id = 0; 183 set_self_raw_id(0);
184 _lgrp_id = -1; 184 set_lgrp_id(-1);
185 _osthread = NULL;
186 185
187 // allocated data structures 186 // allocated data structures
187 set_osthread(NULL);
188 set_resource_area(new ResourceArea()); 188 set_resource_area(new ResourceArea());
189 set_handle_area(new HandleArea(NULL)); 189 set_handle_area(new HandleArea(NULL));
190 set_active_handles(NULL); 190 set_active_handles(NULL);
191 set_free_handle_block(NULL); 191 set_free_handle_block(NULL);
192 set_last_handle_mark(NULL); 192 set_last_handle_mark(NULL);
193 set_osthread(NULL);
194 193
195 // This initial value ==> never claimed. 194 // This initial value ==> never claimed.
196 _oops_do_parity = 0; 195 _oops_do_parity = 0;
197 196
198 // the handle mark links itself to last_handle_mark 197 // the handle mark links itself to last_handle_mark
203 debug_only(_allow_allocation_count = 0;) 202 debug_only(_allow_allocation_count = 0;)
204 NOT_PRODUCT(_allow_safepoint_count = 0;) 203 NOT_PRODUCT(_allow_safepoint_count = 0;)
205 NOT_PRODUCT(_skip_gcalot = false;) 204 NOT_PRODUCT(_skip_gcalot = false;)
206 CHECK_UNHANDLED_OOPS_ONLY(_gc_locked_out_count = 0;) 205 CHECK_UNHANDLED_OOPS_ONLY(_gc_locked_out_count = 0;)
207 _jvmti_env_iteration_count = 0; 206 _jvmti_env_iteration_count = 0;
207 set_allocated_bytes(0);
208 _vm_operation_started_count = 0; 208 _vm_operation_started_count = 0;
209 _vm_operation_completed_count = 0; 209 _vm_operation_completed_count = 0;
210 _current_pending_monitor = NULL; 210 _current_pending_monitor = NULL;
211 _current_pending_monitor_is_from_java = true; 211 _current_pending_monitor_is_from_java = true;
212 _current_waiting_monitor = NULL; 212 _current_waiting_monitor = NULL;
3232 warning("java.lang.ClassCastException has not been initialized"); 3232 warning("java.lang.ClassCastException has not been initialized");
3233 warning("java.lang.ArrayStoreException has not been initialized"); 3233 warning("java.lang.ArrayStoreException has not been initialized");
3234 warning("java.lang.ArithmeticException has not been initialized"); 3234 warning("java.lang.ArithmeticException has not been initialized");
3235 warning("java.lang.StackOverflowError has not been initialized"); 3235 warning("java.lang.StackOverflowError has not been initialized");
3236 } 3236 }
3237 } 3237 }
3238 3238
3239 // See : bugid 4211085. 3239 // See : bugid 4211085.
3240 // Background : the static initializer of java.lang.Compiler tries to read 3240 // Background : the static initializer of java.lang.Compiler tries to read
3241 // property"java.compiler" and read & write property "java.vm.info". 3241 // property"java.compiler" and read & write property "java.vm.info".
3242 // When a security manager is installed through the command line 3242 // When a security manager is installed through the command line