From 2ec2eb6a58f2ccff4ed8080fc67919a2a943e61c Mon Sep 17 00:00:00 2001 From: brutisso Date: Fri, 25 May 2012 22:35:13 +0200 Subject: [PATCH] 7171936: LOG_G incorrectly defined in globalDefinitions.hpp Summary: Removed LOG_G and LOG_K. Moved LOG_M to where it is being used. Reviewed-by: twisti, johnc --- src/share/vm/gc_implementation/g1/heapRegionRemSet.cpp | 3 ++- src/share/vm/utilities/globalDefinitions.hpp | 4 ---- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/src/share/vm/gc_implementation/g1/heapRegionRemSet.cpp b/src/share/vm/gc_implementation/g1/heapRegionRemSet.cpp index a23bd79a7..fc275a6ed 100644 --- a/src/share/vm/gc_implementation/g1/heapRegionRemSet.cpp +++ b/src/share/vm/gc_implementation/g1/heapRegionRemSet.cpp @@ -1106,7 +1106,8 @@ HeapRegionRemSet::HeapRegionRemSet(G1BlockOffsetSharedArray* bosa, void HeapRegionRemSet::setup_remset_size() { // Setup sparse and fine-grain tables sizes. // table_size = base * (log(region_size / 1M) + 1) - int region_size_log_mb = MAX2((int)HeapRegion::LogOfHRGrainBytes - (int)LOG_M, 0); + const int LOG_M = 20; + int region_size_log_mb = MAX2(HeapRegion::LogOfHRGrainBytes - LOG_M, 0); if (FLAG_IS_DEFAULT(G1RSetSparseRegionEntries)) { G1RSetSparseRegionEntries = G1RSetSparseRegionEntriesBase * (region_size_log_mb + 1); } diff --git a/src/share/vm/utilities/globalDefinitions.hpp b/src/share/vm/utilities/globalDefinitions.hpp index 82a9333b7..19dcec160 100644 --- a/src/share/vm/utilities/globalDefinitions.hpp +++ b/src/share/vm/utilities/globalDefinitions.hpp @@ -161,10 +161,6 @@ const size_t M = K*K; const size_t G = M*K; const size_t HWperKB = K / sizeof(HeapWord); -const size_t LOG_K = 10; -const size_t LOG_M = 2 * LOG_K; -const size_t LOG_G = 2 * LOG_M; - const jint min_jint = (jint)1 << (sizeof(jint)*BitsPerByte-1); // 0x80000000 == smallest jint const jint max_jint = (juint)min_jint - 1; // 0x7FFFFFFF == largest jint -- GitLab