equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2002, 2018, 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. |
112 // them in this method. If there are no tasks to execute, |
112 // them in this method. If there are no tasks to execute, |
113 // the GC workers wait in the GCTaskManager's get_task() |
113 // the GC workers wait in the GCTaskManager's get_task() |
114 // for tasks to be enqueued for execution. |
114 // for tasks to be enqueued for execution. |
115 |
115 |
116 void GCTaskThread::run() { |
116 void GCTaskThread::run() { |
117 this->initialize_named_thread(); |
|
118 // Bind yourself to your processor. |
117 // Bind yourself to your processor. |
119 if (processor_id() != GCTaskManager::sentinel_worker()) { |
118 if (processor_id() != GCTaskManager::sentinel_worker()) { |
120 log_trace(gc, task, thread)("GCTaskThread::run: binding to processor %u", processor_id()); |
119 log_trace(gc, task, thread)("GCTaskThread::run: binding to processor %u", processor_id()); |
121 if (!os::bind_to_processor(processor_id())) { |
120 if (!os::bind_to_processor(processor_id())) { |
122 DEBUG_ONLY( |
121 DEBUG_ONLY( |