Mercurial > hg > graal-compiler
comparison src/share/vm/memory/compactingPermGenGen.cpp @ 356:1ee8caae33af
Merge
author | tonyp |
---|---|
date | Thu, 21 Aug 2008 23:36:31 -0400 |
parents | 818a18cd69a8 |
children | 5251a9cd8eb8 |
comparison
equal
deleted
inserted
replaced
355:0edda524b58c | 356:1ee8caae33af |
---|---|
1 /* | 1 /* |
2 * Copyright 2003-2006 Sun Microsystems, Inc. All Rights Reserved. | 2 * Copyright 2003-2008 Sun Microsystems, Inc. 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. |
430 } | 430 } |
431 return OneContigSpaceCardGeneration::grow_by(bytes); | 431 return OneContigSpaceCardGeneration::grow_by(bytes); |
432 } | 432 } |
433 | 433 |
434 | 434 |
435 void CompactingPermGenGen::grow_to_reserved() { | 435 bool CompactingPermGenGen::grow_to_reserved() { |
436 // Don't allow _virtual_size to expand into shared spaces. | 436 // Don't allow _virtual_size to expand into shared spaces. |
437 bool success = false; | |
437 if (_virtual_space.uncommitted_size() > _shared_space_size) { | 438 if (_virtual_space.uncommitted_size() > _shared_space_size) { |
438 size_t remaining_bytes = | 439 size_t remaining_bytes = |
439 _virtual_space.uncommitted_size() - _shared_space_size; | 440 _virtual_space.uncommitted_size() - _shared_space_size; |
440 bool success = OneContigSpaceCardGeneration::grow_by(remaining_bytes); | 441 success = OneContigSpaceCardGeneration::grow_by(remaining_bytes); |
441 DEBUG_ONLY(if (!success) warning("grow to reserved failed");) | 442 DEBUG_ONLY(if (!success) warning("grow to reserved failed");) |
442 } | 443 } |
444 return success; | |
443 } | 445 } |
444 | 446 |
445 | 447 |
446 // No young generation references, clear this generation's main space's | 448 // No young generation references, clear this generation's main space's |
447 // card table entries. Do NOT clear the card table entries for the | 449 // card table entries. Do NOT clear the card table entries for the |