diff options
author | Mathieu Chartier <mathieuc@google.com> | 2014-04-14 11:30:39 -0700 |
---|---|---|
committer | Mathieu Chartier <mathieuc@google.com> | 2014-04-14 11:55:50 -0700 |
commit | 309e3bfc6a4c682ac09c95c596e11d8678603577 (patch) | |
tree | ae37f2603bc089a102abf63e2dac9375b7ff427a /runtime/gc | |
parent | 043a7a6182870964021476484b1534106ff20600 (diff) | |
download | art-309e3bfc6a4c682ac09c95c596e11d8678603577.zip art-309e3bfc6a4c682ac09c95c596e11d8678603577.tar.gz art-309e3bfc6a4c682ac09c95c596e11d8678603577.tar.bz2 |
Reduce bump pointer space capacity.
Bug: 14058912
Change-Id: I7ae53e667539530d56ca2f5d10214e69c9c994e2
Diffstat (limited to 'runtime/gc')
-rw-r--r-- | runtime/gc/heap.cc | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/runtime/gc/heap.cc b/runtime/gc/heap.cc index 479ea2e..29d76d2 100644 --- a/runtime/gc/heap.cc +++ b/runtime/gc/heap.cc @@ -223,10 +223,15 @@ Heap::Heap(size_t initial_size, size_t growth_limit, size_t min_free, size_t max // the bitmap from the main space. if (kMovingCollector) { // TODO: Place bump-pointer spaces somewhere to minimize size of card table. - bump_pointer_space_ = space::BumpPointerSpace::Create("Bump pointer space", capacity, nullptr); + // TODO: Not create all the bump pointer spaces if not necessary (currently only GSS needs all + // 2 of bump pointer spaces + main space) b/14059466. Divide by 2 for a temporary fix. + const size_t bump_pointer_space_capacity = capacity / 2; + bump_pointer_space_ = space::BumpPointerSpace::Create("Bump pointer space", + bump_pointer_space_capacity, nullptr); CHECK(bump_pointer_space_ != nullptr) << "Failed to create bump pointer space"; AddSpace(bump_pointer_space_); - temp_space_ = space::BumpPointerSpace::Create("Bump pointer space 2", capacity, nullptr); + temp_space_ = space::BumpPointerSpace::Create("Bump pointer space 2", + bump_pointer_space_capacity, nullptr); CHECK(temp_space_ != nullptr) << "Failed to create bump pointer space"; AddSpace(temp_space_); } |