Skip to content

Commit 6234536

Browse files
committed
8349915: CTW: Lots of level 3 compiles are done at level 2 after JDK-8348570
Reviewed-by: kvn, chagedorn
1 parent b6443f6 commit 6234536

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

src/hotspot/share/compiler/compilationPolicy.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -633,6 +633,11 @@ CompileTask* CompilationPolicy::select_task(CompileQueue* compile_queue) {
633633
task = next_task;
634634
continue;
635635
}
636+
if (task->compile_reason() == CompileTask::Reason_Whitebox) {
637+
// Whitebox (CTW) tasks do not participate in rate selection and/or any level
638+
// adjustments. Just return them in order.
639+
return task;
640+
}
636641
Method* method = task->method();
637642
methodHandle mh(Thread::current(), method);
638643
if (task->can_become_stale() && is_stale(t, TieredCompileTaskTimeout, mh) && !is_old(mh)) {

src/hotspot/share/compiler/compileTask.hpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -199,6 +199,8 @@ class CompileTask : public CHeapObj<mtCompiler> {
199199
int comp_level() { return _comp_level;}
200200
void set_comp_level(int comp_level) { _comp_level = comp_level;}
201201

202+
CompileReason compile_reason() { return _compile_reason; }
203+
202204
AbstractCompiler* compiler() const;
203205
CompileTask* select_for_compilation();
204206

0 commit comments

Comments
 (0)