Mercurial > hg > graal-compiler
changeset 10261:9b77ca4ce35e
Merge
author | dholmes |
---|---|
date | Wed, 08 May 2013 19:38:41 -0400 |
parents | 711016f146fd (diff) 0dc028fd5101 (current diff) |
children | c272092594bd |
files | src/share/vm/runtime/arguments.cpp |
diffstat | 1 files changed, 20 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/src/share/vm/runtime/arguments.cpp Wed May 08 10:14:57 2013 -0400 +++ b/src/share/vm/runtime/arguments.cpp Wed May 08 19:38:41 2013 -0400 @@ -2088,6 +2088,26 @@ #endif } + // Need to limit the extent of the padding to reasonable size. + // 8K is well beyond the reasonable HW cache line size, even with the + // aggressive prefetching, while still leaving the room for segregating + // among the distinct pages. + if (ContendedPaddingWidth < 0 || ContendedPaddingWidth > 8192) { + jio_fprintf(defaultStream::error_stream(), + "ContendedPaddingWidth=" INTX_FORMAT " must be the between %d and %d\n", + ContendedPaddingWidth, 0, 8192); + status = false; + } + + // Need to enforce the padding not to break the existing field alignments. + // It is sufficient to check against the largest type size. + if ((ContendedPaddingWidth % BytesPerLong) != 0) { + jio_fprintf(defaultStream::error_stream(), + "ContendedPaddingWidth=" INTX_FORMAT " must be the multiple of %d\n", + ContendedPaddingWidth, BytesPerLong); + status = false; + } + return status; }