Mercurial > hg > graal-jvmci-8
comparison src/share/vm/utilities/globalDefinitions.hpp @ 13086:096c224171c4
Merge with http://hg.openjdk.java.net/hsx/hsx25/hotspot/
author | Doug Simon <doug.simon@oracle.com> |
---|---|
date | Wed, 20 Nov 2013 00:10:38 +0100 |
parents | 36b1f3224948 610be0309a79 |
children | 800057208a2c |
comparison
equal
deleted
inserted
replaced
12782:92b7ec34ddfa | 13086:096c224171c4 |
---|---|
324 //---------------------------------------------------------------------------------------------------- | 324 //---------------------------------------------------------------------------------------------------- |
325 // JVM spec restrictions | 325 // JVM spec restrictions |
326 | 326 |
327 const int max_method_code_size = 64*K - 1; // JVM spec, 2nd ed. section 4.8.1 (p.134) | 327 const int max_method_code_size = 64*K - 1; // JVM spec, 2nd ed. section 4.8.1 (p.134) |
328 | 328 |
329 // Default ProtectionDomainCacheSize values | |
330 | |
331 const int defaultProtectionDomainCacheSize = NOT_LP64(137) LP64_ONLY(2017); | |
329 | 332 |
330 //---------------------------------------------------------------------------------------------------- | 333 //---------------------------------------------------------------------------------------------------- |
331 // Default and minimum StringTableSize values | 334 // Default and minimum StringTableSize values |
332 | 335 |
333 const int defaultStringTableSize = NOT_LP64(1009) LP64_ONLY(60013); | 336 const int defaultStringTableSize = NOT_LP64(1009) LP64_ONLY(60013); |
334 const int minimumStringTableSize=1009; | 337 const int minimumStringTableSize = 1009; |
338 | |
339 const int defaultSymbolTableSize = 20011; | |
340 const int minimumSymbolTableSize = 1009; | |
335 | 341 |
336 | 342 |
337 //---------------------------------------------------------------------------------------------------- | 343 //---------------------------------------------------------------------------------------------------- |
338 // HotSwap - for JVMTI aka Class File Replacement and PopFrame | 344 // HotSwap - for JVMTI aka Class File Replacement and PopFrame |
339 // | 345 // |
359 const int KlassAlignmentInBytes = 1 << LogKlassAlignmentInBytes; | 365 const int KlassAlignmentInBytes = 1 << LogKlassAlignmentInBytes; |
360 const int KlassAlignment = KlassAlignmentInBytes / HeapWordSize; | 366 const int KlassAlignment = KlassAlignmentInBytes / HeapWordSize; |
361 | 367 |
362 // Klass encoding metaspace max size | 368 // Klass encoding metaspace max size |
363 const uint64_t KlassEncodingMetaspaceMax = (uint64_t(max_juint) + 1) << LogKlassAlignmentInBytes; | 369 const uint64_t KlassEncodingMetaspaceMax = (uint64_t(max_juint) + 1) << LogKlassAlignmentInBytes; |
364 | |
365 const jlong CompressedKlassPointersBase = NOT_LP64(0) LP64_ONLY(CONST64(0x800000000)); // 32*G | |
366 | 370 |
367 // Machine dependent stuff | 371 // Machine dependent stuff |
368 | 372 |
369 #ifdef TARGET_ARCH_x86 | 373 #ifdef TARGET_ARCH_x86 |
370 # include "globalDefinitions_x86.hpp" | 374 # include "globalDefinitions_x86.hpp" |
448 return align_size_up(offset, HeapWordsPerLong); | 452 return align_size_up(offset, HeapWordsPerLong); |
449 } | 453 } |
450 | 454 |
451 inline void* align_pointer_up(const void* addr, size_t size) { | 455 inline void* align_pointer_up(const void* addr, size_t size) { |
452 return (void*) align_size_up_((uintptr_t)addr, size); | 456 return (void*) align_size_up_((uintptr_t)addr, size); |
457 } | |
458 | |
459 // Align down with a lower bound. If the aligning results in 0, return 'alignment'. | |
460 | |
461 inline size_t align_size_down_bounded(size_t size, size_t alignment) { | |
462 size_t aligned_size = align_size_down_(size, alignment); | |
463 return aligned_size > 0 ? aligned_size : alignment; | |
453 } | 464 } |
454 | 465 |
455 // Clamp an address to be within a specific page | 466 // Clamp an address to be within a specific page |
456 // 1. If addr is on the page it is returned as is | 467 // 1. If addr is on the page it is returned as is |
457 // 2. If addr is above the page_address the start of the *next* page will be returned | 468 // 2. If addr is above the page_address the start of the *next* page will be returned |