Mercurial > hg > truffle
diff src/share/vm/memory/metaspace.cpp @ 8754:82ab039b9680
Merge
author | dcubed |
---|---|
date | Sun, 17 Mar 2013 08:57:56 -0700 |
parents | 15401203db6b 82f49e8e2c28 |
children | 47902e9acb3a 91bf0bdae37b |
line wrap: on
line diff
--- a/src/share/vm/memory/metaspace.cpp Fri Mar 15 11:44:33 2013 -0700 +++ b/src/share/vm/memory/metaspace.cpp Sun Mar 17 08:57:56 2013 -0700 @@ -334,6 +334,9 @@ // byte_size is the size of the associated virtualspace. VirtualSpaceNode::VirtualSpaceNode(size_t byte_size) : _top(NULL), _next(NULL), _rs(0) { + // align up to vm allocation granularity + byte_size = align_size_up(byte_size, os::vm_allocation_granularity()); + // This allocates memory with mmap. For DumpSharedspaces, allocate the // space at low memory so that other shared images don't conflict. // This is the same address as memory needed for UseCompressedOops but