equal
deleted
inserted
replaced
371 // |
371 // |
372 // GCTaskManager |
372 // GCTaskManager |
373 // |
373 // |
374 GCTaskManager::GCTaskManager(uint workers) : |
374 GCTaskManager::GCTaskManager(uint workers) : |
375 _workers(workers), |
375 _workers(workers), |
|
376 _created_workers(0), |
376 _active_workers(0), |
377 _active_workers(0), |
377 _idle_workers(0), |
378 _idle_workers(0) { |
378 _created_workers(0) { |
|
379 initialize(); |
379 initialize(); |
380 } |
380 } |
381 |
381 |
382 GCTaskThread* GCTaskManager::install_worker(uint t) { |
382 GCTaskThread* GCTaskManager::install_worker(uint t) { |
383 GCTaskThread* new_worker = GCTaskThread::create(this, t, _processor_assignment[t]); |
383 GCTaskThread* new_worker = GCTaskThread::create(this, t, _processor_assignment[t]); |
960 } |
960 } |
961 // Then notify the waiter. |
961 // Then notify the waiter. |
962 _wait_helper.notify(); |
962 _wait_helper.notify(); |
963 } |
963 } |
964 |
964 |
965 WaitHelper::WaitHelper() : _should_wait(true), _monitor(MonitorSupply::reserve()) { |
965 WaitHelper::WaitHelper() : _monitor(MonitorSupply::reserve()), _should_wait(true) { |
966 if (TraceGCTaskManager) { |
966 if (TraceGCTaskManager) { |
967 tty->print_cr("[" INTPTR_FORMAT "]" |
967 tty->print_cr("[" INTPTR_FORMAT "]" |
968 " WaitHelper::WaitHelper()" |
968 " WaitHelper::WaitHelper()" |
969 " monitor: " INTPTR_FORMAT, |
969 " monitor: " INTPTR_FORMAT, |
970 p2i(this), p2i(monitor())); |
970 p2i(this), p2i(monitor())); |