Need a sponsor for push 8147906 into jdk9/hs-rt
Alexander Harlap
alexander.harlap at oracle.com
Thu Jan 28 21:17:50 UTC 2016
I need a sponsor to push attached 8147906 - G1 use of os::processor_count()
Attached change has copyright modification (2015 -> 2016), requested in
David review.
I re-tested JPRT after copyright modification.
Alex
-------------- next part --------------
# HG changeset patch
# User aharlap
# Date 1454015141 18000
# Node ID b282803294592b640e87fd15508d862c3ceac91d
# Parent 42e1ea096597f7fce184340171de4545bde9e896
8147906: G1 use of os::processor_count()
Summary: Use os::active_processor_count() instead of os::processor_count() in G1
Reviewed-by: dholmes, jmasa
diff -r 42e1ea096597 -r b28280329459 src/share/vm/gc/g1/concurrentMark.cpp
--- a/src/share/vm/gc/g1/concurrentMark.cpp Thu Jan 28 15:03:33 2016 +0100
+++ b/src/share/vm/gc/g1/concurrentMark.cpp Thu Jan 28 16:05:41 2016 -0500
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2001, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -489,11 +489,11 @@
double overall_cm_overhead =
(double) MaxGCPauseMillis * marking_overhead /
(double) GCPauseIntervalMillis;
- double cpu_ratio = 1.0 / (double) os::processor_count();
+ double cpu_ratio = 1.0 / (double) os::active_processor_count();
double marking_thread_num = ceil(overall_cm_overhead / cpu_ratio);
double marking_task_overhead =
overall_cm_overhead / marking_thread_num *
- (double) os::processor_count();
+ (double) os::active_processor_count();
double sleep_factor =
(1.0 - marking_task_overhead) / marking_task_overhead;
diff -r 42e1ea096597 -r b28280329459 src/share/vm/gc/g1/dirtyCardQueue.cpp
--- a/src/share/vm/gc/g1/dirtyCardQueue.cpp Thu Jan 28 15:03:33 2016 +0100
+++ b/src/share/vm/gc/g1/dirtyCardQueue.cpp Thu Jan 28 16:05:41 2016 -0500
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2001, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -160,7 +160,7 @@
// Determines how many mutator threads can process the buffers in parallel.
uint DirtyCardQueueSet::num_par_ids() {
- return (uint)os::processor_count();
+ return (uint)os::active_processor_count();
}
void DirtyCardQueueSet::initialize(CardTableEntryClosure* cl,
More information about the hotspot-gc-dev
mailing list