Wed, 03 Jul 2013 11:50:29 -0700
Merge
1.1 --- a/.hgtags Wed Jun 26 16:06:38 2013 +0200 1.2 +++ b/.hgtags Wed Jul 03 11:50:29 2013 -0700 1.3 @@ -353,3 +353,5 @@ 1.4 69689078dff8b21e6df30870464f5d736eebdf72 hs25-b37 1.5 5d65c078cd0ac455aa5e58a09844c7acce54b487 jdk8-b95 1.6 2cc5a9d1ba66dfdff578918b393c727bd9450210 hs25-b38 1.7 +e6a4b8c71fa6f225bd989a34de2d0d0a656a8be8 jdk8-b96 1.8 +2b9380b0bf0b649f40704735773e8956c2d88ba0 hs25-b39
2.1 --- a/make/bsd/makefiles/build_vm_def.sh Wed Jun 26 16:06:38 2013 +0200 2.2 +++ b/make/bsd/makefiles/build_vm_def.sh Wed Jul 03 11:50:29 2013 -0700 2.3 @@ -7,6 +7,6 @@ 2.4 NM=nm 2.5 fi 2.6 2.7 -$NM --defined-only $* | awk ' 2.8 - { if ($3 ~ /^_ZTV/ || $3 ~ /^gHotSpotVM/) print "\t" $3 ";" } 2.9 +$NM -Uj $* | awk ' 2.10 + { if ($3 ~ /^_ZTV/ || $3 ~ /^gHotSpotVM/) print "\t" $3 } 2.11 '
3.1 --- a/make/bsd/makefiles/gcc.make Wed Jun 26 16:06:38 2013 +0200 3.2 +++ b/make/bsd/makefiles/gcc.make Wed Jul 03 11:50:29 2013 -0700 3.3 @@ -1,5 +1,5 @@ 3.4 # 3.5 -# Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved. 3.6 +# Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved. 3.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3.8 # 3.9 # This code is free software; you can redistribute it and/or modify it 3.10 @@ -368,8 +368,8 @@ 3.11 # Standard linker flags 3.12 LFLAGS += 3.13 3.14 - # Darwin doesn't use ELF and doesn't support version scripts 3.15 - LDNOMAP = true 3.16 + # The apple linker has its own variant of mapfiles/version-scripts 3.17 + MAPFLAG = -Xlinker -exported_symbols_list -Xlinker FILENAME 3.18 3.19 # Use $(SONAMEFLAG:SONAME=soname) to specify the intrinsic name of a shared obj 3.20 SONAMEFLAG =
4.1 --- a/make/bsd/makefiles/mapfile-vers-debug Wed Jun 26 16:06:38 2013 +0200 4.2 +++ b/make/bsd/makefiles/mapfile-vers-debug Wed Jul 03 11:50:29 2013 -0700 4.3 @@ -1,7 +1,3 @@ 4.4 -# 4.5 -# @(#)mapfile-vers-debug 1.18 07/10/25 16:47:35 4.6 -# 4.7 - 4.8 # 4.9 # Copyright (c) 2002, 2013, Oracle and/or its affiliates. All rights reserved. 4.10 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4.11 @@ -23,273 +19,244 @@ 4.12 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4.13 # or visit www.oracle.com if you need additional information or have any 4.14 # questions. 4.15 -# 4.16 # 4.17 +# 4.18 +# Only used for OSX/Darwin builds 4.19 4.20 # Define public interface. 4.21 + # _JNI 4.22 + _JNI_CreateJavaVM 4.23 + _JNI_GetCreatedJavaVMs 4.24 + _JNI_GetDefaultJavaVMInitArgs 4.25 4.26 -SUNWprivate_1.1 { 4.27 - global: 4.28 - # JNI 4.29 - JNI_CreateJavaVM; 4.30 - JNI_GetCreatedJavaVMs; 4.31 - JNI_GetDefaultJavaVMInitArgs; 4.32 + # _JVM 4.33 + _JVM_Accept 4.34 + _JVM_ActiveProcessorCount 4.35 + _JVM_AllocateNewArray 4.36 + _JVM_AllocateNewObject 4.37 + _JVM_ArrayCopy 4.38 + _JVM_AssertionStatusDirectives 4.39 + _JVM_Available 4.40 + _JVM_Bind 4.41 + _JVM_ClassDepth 4.42 + _JVM_ClassLoaderDepth 4.43 + _JVM_Clone 4.44 + _JVM_Close 4.45 + _JVM_CX8Field 4.46 + _JVM_CompileClass 4.47 + _JVM_CompileClasses 4.48 + _JVM_CompilerCommand 4.49 + _JVM_Connect 4.50 + _JVM_ConstantPoolGetClassAt 4.51 + _JVM_ConstantPoolGetClassAtIfLoaded 4.52 + _JVM_ConstantPoolGetDoubleAt 4.53 + _JVM_ConstantPoolGetFieldAt 4.54 + _JVM_ConstantPoolGetFieldAtIfLoaded 4.55 + _JVM_ConstantPoolGetFloatAt 4.56 + _JVM_ConstantPoolGetIntAt 4.57 + _JVM_ConstantPoolGetLongAt 4.58 + _JVM_ConstantPoolGetMethodAt 4.59 + _JVM_ConstantPoolGetMethodAtIfLoaded 4.60 + _JVM_ConstantPoolGetMemberRefInfoAt 4.61 + _JVM_ConstantPoolGetSize 4.62 + _JVM_ConstantPoolGetStringAt 4.63 + _JVM_ConstantPoolGetUTF8At 4.64 + _JVM_CountStackFrames 4.65 + _JVM_CurrentClassLoader 4.66 + _JVM_CurrentLoadedClass 4.67 + _JVM_CurrentThread 4.68 + _JVM_CurrentTimeMillis 4.69 + _JVM_DefineClass 4.70 + _JVM_DefineClassWithSource 4.71 + _JVM_DefineClassWithSourceCond 4.72 + _JVM_DesiredAssertionStatus 4.73 + _JVM_DisableCompiler 4.74 + _JVM_DoPrivileged 4.75 + _JVM_DTraceGetVersion 4.76 + _JVM_DTraceActivate 4.77 + _JVM_DTraceIsProbeEnabled 4.78 + _JVM_DTraceIsSupported 4.79 + _JVM_DTraceDispose 4.80 + _JVM_DumpAllStacks 4.81 + _JVM_DumpThreads 4.82 + _JVM_EnableCompiler 4.83 + _JVM_Exit 4.84 + _JVM_FillInStackTrace 4.85 + _JVM_FindClassFromClass 4.86 + _JVM_FindClassFromClassLoader 4.87 + _JVM_FindClassFromBootLoader 4.88 + _JVM_FindLibraryEntry 4.89 + _JVM_FindLoadedClass 4.90 + _JVM_FindPrimitiveClass 4.91 + _JVM_FindSignal 4.92 + _JVM_FreeMemory 4.93 + _JVM_GC 4.94 + _JVM_GetAllThreads 4.95 + _JVM_GetArrayElement 4.96 + _JVM_GetArrayLength 4.97 + _JVM_GetCPClassNameUTF 4.98 + _JVM_GetCPFieldClassNameUTF 4.99 + _JVM_GetCPFieldModifiers 4.100 + _JVM_GetCPFieldNameUTF 4.101 + _JVM_GetCPFieldSignatureUTF 4.102 + _JVM_GetCPMethodClassNameUTF 4.103 + _JVM_GetCPMethodModifiers 4.104 + _JVM_GetCPMethodNameUTF 4.105 + _JVM_GetCPMethodSignatureUTF 4.106 + _JVM_GetCallerClass 4.107 + _JVM_GetClassAccessFlags 4.108 + _JVM_GetClassAnnotations 4.109 + _JVM_GetClassCPEntriesCount 4.110 + _JVM_GetClassCPTypes 4.111 + _JVM_GetClassConstantPool 4.112 + _JVM_GetClassContext 4.113 + _JVM_GetClassDeclaredConstructors 4.114 + _JVM_GetClassDeclaredFields 4.115 + _JVM_GetClassDeclaredMethods 4.116 + _JVM_GetClassFieldsCount 4.117 + _JVM_GetClassInterfaces 4.118 + _JVM_GetClassLoader 4.119 + _JVM_GetClassMethodsCount 4.120 + _JVM_GetClassModifiers 4.121 + _JVM_GetClassName 4.122 + _JVM_GetClassNameUTF 4.123 + _JVM_GetClassSignature 4.124 + _JVM_GetClassSigners 4.125 + _JVM_GetClassTypeAnnotations 4.126 + _JVM_GetComponentType 4.127 + _JVM_GetDeclaredClasses 4.128 + _JVM_GetDeclaringClass 4.129 + _JVM_GetEnclosingMethodInfo 4.130 + _JVM_GetFieldAnnotations 4.131 + _JVM_GetFieldIxModifiers 4.132 + _JVM_GetFieldTypeAnnotations 4.133 + _JVM_GetHostName 4.134 + _JVM_GetInheritedAccessControlContext 4.135 + _JVM_GetInterfaceVersion 4.136 + _JVM_GetLastErrorString 4.137 + _JVM_GetManagement 4.138 + _JVM_GetMethodAnnotations 4.139 + _JVM_GetMethodDefaultAnnotationValue 4.140 + _JVM_GetMethodIxArgsSize 4.141 + _JVM_GetMethodIxByteCode 4.142 + _JVM_GetMethodIxByteCodeLength 4.143 + _JVM_GetMethodIxExceptionIndexes 4.144 + _JVM_GetMethodIxExceptionTableEntry 4.145 + _JVM_GetMethodIxExceptionTableLength 4.146 + _JVM_GetMethodIxExceptionsCount 4.147 + _JVM_GetMethodIxLocalsCount 4.148 + _JVM_GetMethodIxMaxStack 4.149 + _JVM_GetMethodIxModifiers 4.150 + _JVM_GetMethodIxNameUTF 4.151 + _JVM_GetMethodIxSignatureUTF 4.152 + _JVM_GetMethodParameterAnnotations 4.153 + _JVM_GetMethodParameters 4.154 + _JVM_GetMethodTypeAnnotations 4.155 + _JVM_GetPrimitiveArrayElement 4.156 + _JVM_GetProtectionDomain 4.157 + _JVM_GetSockName 4.158 + _JVM_GetSockOpt 4.159 + _JVM_GetStackAccessControlContext 4.160 + _JVM_GetStackTraceDepth 4.161 + _JVM_GetStackTraceElement 4.162 + _JVM_GetSystemPackage 4.163 + _JVM_GetSystemPackages 4.164 + _JVM_GetThreadStateNames 4.165 + _JVM_GetThreadStateValues 4.166 + _JVM_GetVersionInfo 4.167 + _JVM_Halt 4.168 + _JVM_HoldsLock 4.169 + _JVM_IHashCode 4.170 + _JVM_InitAgentProperties 4.171 + _JVM_InitProperties 4.172 + _JVM_InitializeCompiler 4.173 + _JVM_InitializeSocketLibrary 4.174 + _JVM_InternString 4.175 + _JVM_Interrupt 4.176 + _JVM_InvokeMethod 4.177 + _JVM_IsArrayClass 4.178 + _JVM_IsConstructorIx 4.179 + _JVM_IsInterface 4.180 + _JVM_IsInterrupted 4.181 + _JVM_IsNaN 4.182 + _JVM_IsPrimitiveClass 4.183 + _JVM_IsSameClassPackage 4.184 + _JVM_IsSilentCompiler 4.185 + _JVM_IsSupportedJNIVersion 4.186 + _JVM_IsThreadAlive 4.187 + _JVM_IsVMGeneratedMethodIx 4.188 + _JVM_LatestUserDefinedLoader 4.189 + _JVM_Listen 4.190 + _JVM_LoadClass0 4.191 + _JVM_LoadLibrary 4.192 + _JVM_Lseek 4.193 + _JVM_MaxObjectInspectionAge 4.194 + _JVM_MaxMemory 4.195 + _JVM_MonitorNotify 4.196 + _JVM_MonitorNotifyAll 4.197 + _JVM_MonitorWait 4.198 + _JVM_NanoTime 4.199 + _JVM_NativePath 4.200 + _JVM_NewArray 4.201 + _JVM_NewInstanceFromConstructor 4.202 + _JVM_NewMultiArray 4.203 + _JVM_OnExit 4.204 + _JVM_Open 4.205 + _JVM_RaiseSignal 4.206 + _JVM_RawMonitorCreate 4.207 + _JVM_RawMonitorDestroy 4.208 + _JVM_RawMonitorEnter 4.209 + _JVM_RawMonitorExit 4.210 + _JVM_Read 4.211 + _JVM_Recv 4.212 + _JVM_RecvFrom 4.213 + _JVM_RegisterSignal 4.214 + _JVM_ReleaseUTF 4.215 + _JVM_ResolveClass 4.216 + _JVM_ResumeThread 4.217 + _JVM_Send 4.218 + _JVM_SendTo 4.219 + _JVM_SetArrayElement 4.220 + _JVM_SetClassSigners 4.221 + _JVM_SetLength 4.222 + _JVM_SetNativeThreadName 4.223 + _JVM_SetPrimitiveArrayElement 4.224 + _JVM_SetProtectionDomain 4.225 + _JVM_SetSockOpt 4.226 + _JVM_SetThreadPriority 4.227 + _JVM_Sleep 4.228 + _JVM_Socket 4.229 + _JVM_SocketAvailable 4.230 + _JVM_SocketClose 4.231 + _JVM_SocketShutdown 4.232 + _JVM_StartThread 4.233 + _JVM_StopThread 4.234 + _JVM_SuspendThread 4.235 + _JVM_SupportsCX8 4.236 + _JVM_Sync 4.237 + _JVM_Timeout 4.238 + _JVM_TotalMemory 4.239 + _JVM_TraceInstructions 4.240 + _JVM_TraceMethodCalls 4.241 + _JVM_UnloadLibrary 4.242 + _JVM_Write 4.243 + _JVM_Yield 4.244 + _JVM_handle_bsd_signal 4.245 4.246 - # JVM 4.247 - JVM_Accept; 4.248 - JVM_ActiveProcessorCount; 4.249 - JVM_AllocateNewArray; 4.250 - JVM_AllocateNewObject; 4.251 - JVM_ArrayCopy; 4.252 - JVM_AssertionStatusDirectives; 4.253 - JVM_Available; 4.254 - JVM_Bind; 4.255 - JVM_ClassDepth; 4.256 - JVM_ClassLoaderDepth; 4.257 - JVM_Clone; 4.258 - JVM_Close; 4.259 - JVM_CX8Field; 4.260 - JVM_CompileClass; 4.261 - JVM_CompileClasses; 4.262 - JVM_CompilerCommand; 4.263 - JVM_Connect; 4.264 - JVM_ConstantPoolGetClassAt; 4.265 - JVM_ConstantPoolGetClassAtIfLoaded; 4.266 - JVM_ConstantPoolGetDoubleAt; 4.267 - JVM_ConstantPoolGetFieldAt; 4.268 - JVM_ConstantPoolGetFieldAtIfLoaded; 4.269 - JVM_ConstantPoolGetFloatAt; 4.270 - JVM_ConstantPoolGetIntAt; 4.271 - JVM_ConstantPoolGetLongAt; 4.272 - JVM_ConstantPoolGetMethodAt; 4.273 - JVM_ConstantPoolGetMethodAtIfLoaded; 4.274 - JVM_ConstantPoolGetMemberRefInfoAt; 4.275 - JVM_ConstantPoolGetSize; 4.276 - JVM_ConstantPoolGetStringAt; 4.277 - JVM_ConstantPoolGetUTF8At; 4.278 - JVM_CountStackFrames; 4.279 - JVM_CurrentClassLoader; 4.280 - JVM_CurrentLoadedClass; 4.281 - JVM_CurrentThread; 4.282 - JVM_CurrentTimeMillis; 4.283 - JVM_DefineClass; 4.284 - JVM_DefineClassWithSource; 4.285 - JVM_DefineClassWithSourceCond; 4.286 - JVM_DesiredAssertionStatus; 4.287 - JVM_DisableCompiler; 4.288 - JVM_DoPrivileged; 4.289 - JVM_DTraceGetVersion; 4.290 - JVM_DTraceActivate; 4.291 - JVM_DTraceIsProbeEnabled; 4.292 - JVM_DTraceIsSupported; 4.293 - JVM_DTraceDispose; 4.294 - JVM_DumpAllStacks; 4.295 - JVM_DumpThreads; 4.296 - JVM_EnableCompiler; 4.297 - JVM_Exit; 4.298 - JVM_FillInStackTrace; 4.299 - JVM_FindClassFromClass; 4.300 - JVM_FindClassFromClassLoader; 4.301 - JVM_FindClassFromBootLoader; 4.302 - JVM_FindLibraryEntry; 4.303 - JVM_FindLoadedClass; 4.304 - JVM_FindPrimitiveClass; 4.305 - JVM_FindSignal; 4.306 - JVM_FreeMemory; 4.307 - JVM_GC; 4.308 - JVM_GetAllThreads; 4.309 - JVM_GetArrayElement; 4.310 - JVM_GetArrayLength; 4.311 - JVM_GetCPClassNameUTF; 4.312 - JVM_GetCPFieldClassNameUTF; 4.313 - JVM_GetCPFieldModifiers; 4.314 - JVM_GetCPFieldNameUTF; 4.315 - JVM_GetCPFieldSignatureUTF; 4.316 - JVM_GetCPMethodClassNameUTF; 4.317 - JVM_GetCPMethodModifiers; 4.318 - JVM_GetCPMethodNameUTF; 4.319 - JVM_GetCPMethodSignatureUTF; 4.320 - JVM_GetCallerClass; 4.321 - JVM_GetClassAccessFlags; 4.322 - JVM_GetClassAnnotations; 4.323 - JVM_GetClassCPEntriesCount; 4.324 - JVM_GetClassCPTypes; 4.325 - JVM_GetClassConstantPool; 4.326 - JVM_GetClassContext; 4.327 - JVM_GetClassDeclaredConstructors; 4.328 - JVM_GetClassDeclaredFields; 4.329 - JVM_GetClassDeclaredMethods; 4.330 - JVM_GetClassFieldsCount; 4.331 - JVM_GetClassInterfaces; 4.332 - JVM_GetClassLoader; 4.333 - JVM_GetClassMethodsCount; 4.334 - JVM_GetClassModifiers; 4.335 - JVM_GetClassName; 4.336 - JVM_GetClassNameUTF; 4.337 - JVM_GetClassSignature; 4.338 - JVM_GetClassSigners; 4.339 - JVM_GetClassTypeAnnotations; 4.340 - JVM_GetComponentType; 4.341 - JVM_GetDeclaredClasses; 4.342 - JVM_GetDeclaringClass; 4.343 - JVM_GetEnclosingMethodInfo; 4.344 - JVM_GetFieldAnnotations; 4.345 - JVM_GetFieldIxModifiers; 4.346 - JVM_GetFieldTypeAnnotations; 4.347 - JVM_GetHostName; 4.348 - JVM_GetInheritedAccessControlContext; 4.349 - JVM_GetInterfaceVersion; 4.350 - JVM_GetLastErrorString; 4.351 - JVM_GetManagement; 4.352 - JVM_GetMethodAnnotations; 4.353 - JVM_GetMethodDefaultAnnotationValue; 4.354 - JVM_GetMethodIxArgsSize; 4.355 - JVM_GetMethodIxByteCode; 4.356 - JVM_GetMethodIxByteCodeLength; 4.357 - JVM_GetMethodIxExceptionIndexes; 4.358 - JVM_GetMethodIxExceptionTableEntry; 4.359 - JVM_GetMethodIxExceptionTableLength; 4.360 - JVM_GetMethodIxExceptionsCount; 4.361 - JVM_GetMethodIxLocalsCount; 4.362 - JVM_GetMethodIxMaxStack; 4.363 - JVM_GetMethodIxModifiers; 4.364 - JVM_GetMethodIxNameUTF; 4.365 - JVM_GetMethodIxSignatureUTF; 4.366 - JVM_GetMethodParameterAnnotations; 4.367 - JVM_GetMethodParameters; 4.368 - JVM_GetMethodTypeAnnotations; 4.369 - JVM_GetPrimitiveArrayElement; 4.370 - JVM_GetProtectionDomain; 4.371 - JVM_GetSockName; 4.372 - JVM_GetSockOpt; 4.373 - JVM_GetStackAccessControlContext; 4.374 - JVM_GetStackTraceDepth; 4.375 - JVM_GetStackTraceElement; 4.376 - JVM_GetSystemPackage; 4.377 - JVM_GetSystemPackages; 4.378 - JVM_GetThreadStateNames; 4.379 - JVM_GetThreadStateValues; 4.380 - JVM_GetVersionInfo; 4.381 - JVM_Halt; 4.382 - JVM_HoldsLock; 4.383 - JVM_IHashCode; 4.384 - JVM_InitAgentProperties; 4.385 - JVM_InitProperties; 4.386 - JVM_InitializeCompiler; 4.387 - JVM_InitializeSocketLibrary; 4.388 - JVM_InternString; 4.389 - JVM_Interrupt; 4.390 - JVM_InvokeMethod; 4.391 - JVM_IsArrayClass; 4.392 - JVM_IsConstructorIx; 4.393 - JVM_IsInterface; 4.394 - JVM_IsInterrupted; 4.395 - JVM_IsNaN; 4.396 - JVM_IsPrimitiveClass; 4.397 - JVM_IsSameClassPackage; 4.398 - JVM_IsSilentCompiler; 4.399 - JVM_IsSupportedJNIVersion; 4.400 - JVM_IsThreadAlive; 4.401 - JVM_IsVMGeneratedMethodIx; 4.402 - JVM_LatestUserDefinedLoader; 4.403 - JVM_Listen; 4.404 - JVM_LoadClass0; 4.405 - JVM_LoadLibrary; 4.406 - JVM_Lseek; 4.407 - JVM_MaxObjectInspectionAge; 4.408 - JVM_MaxMemory; 4.409 - JVM_MonitorNotify; 4.410 - JVM_MonitorNotifyAll; 4.411 - JVM_MonitorWait; 4.412 - JVM_NanoTime; 4.413 - JVM_NativePath; 4.414 - JVM_NewArray; 4.415 - JVM_NewInstanceFromConstructor; 4.416 - JVM_NewMultiArray; 4.417 - JVM_OnExit; 4.418 - JVM_Open; 4.419 - JVM_RaiseSignal; 4.420 - JVM_RawMonitorCreate; 4.421 - JVM_RawMonitorDestroy; 4.422 - JVM_RawMonitorEnter; 4.423 - JVM_RawMonitorExit; 4.424 - JVM_Read; 4.425 - JVM_Recv; 4.426 - JVM_RecvFrom; 4.427 - JVM_RegisterSignal; 4.428 - JVM_ReleaseUTF; 4.429 - JVM_ResolveClass; 4.430 - JVM_ResumeThread; 4.431 - JVM_Send; 4.432 - JVM_SendTo; 4.433 - JVM_SetArrayElement; 4.434 - JVM_SetClassSigners; 4.435 - JVM_SetLength; 4.436 - JVM_SetPrimitiveArrayElement; 4.437 - JVM_SetProtectionDomain; 4.438 - JVM_SetSockOpt; 4.439 - JVM_SetThreadPriority; 4.440 - JVM_Sleep; 4.441 - JVM_Socket; 4.442 - JVM_SocketAvailable; 4.443 - JVM_SocketClose; 4.444 - JVM_SocketShutdown; 4.445 - JVM_StartThread; 4.446 - JVM_StopThread; 4.447 - JVM_SuspendThread; 4.448 - JVM_SupportsCX8; 4.449 - JVM_Sync; 4.450 - JVM_Timeout; 4.451 - JVM_TotalMemory; 4.452 - JVM_TraceInstructions; 4.453 - JVM_TraceMethodCalls; 4.454 - JVM_UnloadLibrary; 4.455 - JVM_Write; 4.456 - JVM_Yield; 4.457 - JVM_handle_bsd_signal; 4.458 - 4.459 - # Old reflection routines 4.460 - # These do not need to be present in the product build in JDK 1.4 4.461 - # but their code has not been removed yet because there will not 4.462 - # be a substantial code savings until JVM_InvokeMethod and 4.463 - # JVM_NewInstanceFromConstructor can also be removed; see 4.464 - # reflectionCompat.hpp. 4.465 - JVM_GetClassConstructor; 4.466 - JVM_GetClassConstructors; 4.467 - JVM_GetClassField; 4.468 - JVM_GetClassFields; 4.469 - JVM_GetClassMethod; 4.470 - JVM_GetClassMethods; 4.471 - JVM_GetField; 4.472 - JVM_GetPrimitiveField; 4.473 - JVM_NewInstance; 4.474 - JVM_SetField; 4.475 - JVM_SetPrimitiveField; 4.476 - 4.477 - # debug JVM 4.478 - JVM_AccessVMBooleanFlag; 4.479 - JVM_AccessVMIntFlag; 4.480 - JVM_VMBreakPoint; 4.481 + # debug _JVM 4.482 + _JVM_AccessVMBooleanFlag 4.483 + _JVM_AccessVMIntFlag 4.484 + _JVM_VMBreakPoint 4.485 4.486 # miscellaneous functions 4.487 - jio_fprintf; 4.488 - jio_printf; 4.489 - jio_snprintf; 4.490 - jio_vfprintf; 4.491 - jio_vsnprintf; 4.492 - fork1; 4.493 - numa_warn; 4.494 - numa_error; 4.495 - 4.496 - # Needed because there is no JVM interface for this. 4.497 - sysThreadAvailableStackWithSlack; 4.498 + _jio_fprintf 4.499 + _jio_printf 4.500 + _jio_snprintf 4.501 + _jio_vfprintf 4.502 + _jio_vsnprintf 4.503 4.504 # This is for Forte Analyzer profiling support. 4.505 - AsyncGetCallTrace; 4.506 + _AsyncGetCallTrace 4.507 4.508 # INSERT VTABLE SYMBOLS HERE 4.509 4.510 - local: 4.511 - *; 4.512 -}; 4.513 -
5.1 --- a/make/bsd/makefiles/mapfile-vers-product Wed Jun 26 16:06:38 2013 +0200 5.2 +++ b/make/bsd/makefiles/mapfile-vers-product Wed Jul 03 11:50:29 2013 -0700 5.3 @@ -1,7 +1,3 @@ 5.4 -# 5.5 -# @(#)mapfile-vers-product 1.19 08/02/12 10:56:37 5.6 -# 5.7 - 5.8 # 5.9 # Copyright (c) 2002, 2013, Oracle and/or its affiliates. All rights reserved. 5.10 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 5.11 @@ -23,268 +19,239 @@ 5.12 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 5.13 # or visit www.oracle.com if you need additional information or have any 5.14 # questions. 5.15 -# 5.16 # 5.17 +# 5.18 +# Only used for OSX/Darwin builds 5.19 5.20 # Define public interface. 5.21 + # _JNI 5.22 + _JNI_CreateJavaVM 5.23 + _JNI_GetCreatedJavaVMs 5.24 + _JNI_GetDefaultJavaVMInitArgs 5.25 5.26 -SUNWprivate_1.1 { 5.27 - global: 5.28 - # JNI 5.29 - JNI_CreateJavaVM; 5.30 - JNI_GetCreatedJavaVMs; 5.31 - JNI_GetDefaultJavaVMInitArgs; 5.32 - 5.33 - # JVM 5.34 - JVM_Accept; 5.35 - JVM_ActiveProcessorCount; 5.36 - JVM_AllocateNewArray; 5.37 - JVM_AllocateNewObject; 5.38 - JVM_ArrayCopy; 5.39 - JVM_AssertionStatusDirectives; 5.40 - JVM_Available; 5.41 - JVM_Bind; 5.42 - JVM_ClassDepth; 5.43 - JVM_ClassLoaderDepth; 5.44 - JVM_Clone; 5.45 - JVM_Close; 5.46 - JVM_CX8Field; 5.47 - JVM_CompileClass; 5.48 - JVM_CompileClasses; 5.49 - JVM_CompilerCommand; 5.50 - JVM_Connect; 5.51 - JVM_ConstantPoolGetClassAt; 5.52 - JVM_ConstantPoolGetClassAtIfLoaded; 5.53 - JVM_ConstantPoolGetDoubleAt; 5.54 - JVM_ConstantPoolGetFieldAt; 5.55 - JVM_ConstantPoolGetFieldAtIfLoaded; 5.56 - JVM_ConstantPoolGetFloatAt; 5.57 - JVM_ConstantPoolGetIntAt; 5.58 - JVM_ConstantPoolGetLongAt; 5.59 - JVM_ConstantPoolGetMethodAt; 5.60 - JVM_ConstantPoolGetMethodAtIfLoaded; 5.61 - JVM_ConstantPoolGetMemberRefInfoAt; 5.62 - JVM_ConstantPoolGetSize; 5.63 - JVM_ConstantPoolGetStringAt; 5.64 - JVM_ConstantPoolGetUTF8At; 5.65 - JVM_CountStackFrames; 5.66 - JVM_CurrentClassLoader; 5.67 - JVM_CurrentLoadedClass; 5.68 - JVM_CurrentThread; 5.69 - JVM_CurrentTimeMillis; 5.70 - JVM_DefineClass; 5.71 - JVM_DefineClassWithSource; 5.72 - JVM_DefineClassWithSourceCond; 5.73 - JVM_DesiredAssertionStatus; 5.74 - JVM_DisableCompiler; 5.75 - JVM_DoPrivileged; 5.76 - JVM_DTraceGetVersion; 5.77 - JVM_DTraceActivate; 5.78 - JVM_DTraceIsProbeEnabled; 5.79 - JVM_DTraceIsSupported; 5.80 - JVM_DTraceDispose; 5.81 - JVM_DumpAllStacks; 5.82 - JVM_DumpThreads; 5.83 - JVM_EnableCompiler; 5.84 - JVM_Exit; 5.85 - JVM_FillInStackTrace; 5.86 - JVM_FindClassFromClass; 5.87 - JVM_FindClassFromClassLoader; 5.88 - JVM_FindClassFromBootLoader; 5.89 - JVM_FindLibraryEntry; 5.90 - JVM_FindLoadedClass; 5.91 - JVM_FindPrimitiveClass; 5.92 - JVM_FindSignal; 5.93 - JVM_FreeMemory; 5.94 - JVM_GC; 5.95 - JVM_GetAllThreads; 5.96 - JVM_GetArrayElement; 5.97 - JVM_GetArrayLength; 5.98 - JVM_GetCPClassNameUTF; 5.99 - JVM_GetCPFieldClassNameUTF; 5.100 - JVM_GetCPFieldModifiers; 5.101 - JVM_GetCPFieldNameUTF; 5.102 - JVM_GetCPFieldSignatureUTF; 5.103 - JVM_GetCPMethodClassNameUTF; 5.104 - JVM_GetCPMethodModifiers; 5.105 - JVM_GetCPMethodNameUTF; 5.106 - JVM_GetCPMethodSignatureUTF; 5.107 - JVM_GetCallerClass; 5.108 - JVM_GetClassAccessFlags; 5.109 - JVM_GetClassAnnotations; 5.110 - JVM_GetClassCPEntriesCount; 5.111 - JVM_GetClassCPTypes; 5.112 - JVM_GetClassConstantPool; 5.113 - JVM_GetClassContext; 5.114 - JVM_GetClassDeclaredConstructors; 5.115 - JVM_GetClassDeclaredFields; 5.116 - JVM_GetClassDeclaredMethods; 5.117 - JVM_GetClassFieldsCount; 5.118 - JVM_GetClassInterfaces; 5.119 - JVM_GetClassLoader; 5.120 - JVM_GetClassMethodsCount; 5.121 - JVM_GetClassModifiers; 5.122 - JVM_GetClassName; 5.123 - JVM_GetClassNameUTF; 5.124 - JVM_GetClassSignature; 5.125 - JVM_GetClassSigners; 5.126 - JVM_GetClassTypeAnnotations; 5.127 - JVM_GetComponentType; 5.128 - JVM_GetDeclaredClasses; 5.129 - JVM_GetDeclaringClass; 5.130 - JVM_GetEnclosingMethodInfo; 5.131 - JVM_GetFieldAnnotations; 5.132 - JVM_GetFieldIxModifiers; 5.133 - JVM_GetFieldTypeAnnotations; 5.134 - JVM_GetHostName; 5.135 - JVM_GetInheritedAccessControlContext; 5.136 - JVM_GetInterfaceVersion; 5.137 - JVM_GetLastErrorString; 5.138 - JVM_GetManagement; 5.139 - JVM_GetMethodAnnotations; 5.140 - JVM_GetMethodDefaultAnnotationValue; 5.141 - JVM_GetMethodIxArgsSize; 5.142 - JVM_GetMethodIxByteCode; 5.143 - JVM_GetMethodIxByteCodeLength; 5.144 - JVM_GetMethodIxExceptionIndexes; 5.145 - JVM_GetMethodIxExceptionTableEntry; 5.146 - JVM_GetMethodIxExceptionTableLength; 5.147 - JVM_GetMethodIxExceptionsCount; 5.148 - JVM_GetMethodIxLocalsCount; 5.149 - JVM_GetMethodIxMaxStack; 5.150 - JVM_GetMethodIxModifiers; 5.151 - JVM_GetMethodIxNameUTF; 5.152 - JVM_GetMethodIxSignatureUTF; 5.153 - JVM_GetMethodParameterAnnotations; 5.154 - JVM_GetMethodParameters; 5.155 - JVM_GetMethodTypeAnnotations; 5.156 - JVM_GetPrimitiveArrayElement; 5.157 - JVM_GetProtectionDomain; 5.158 - JVM_GetSockName; 5.159 - JVM_GetSockOpt; 5.160 - JVM_GetStackAccessControlContext; 5.161 - JVM_GetStackTraceDepth; 5.162 - JVM_GetStackTraceElement; 5.163 - JVM_GetSystemPackage; 5.164 - JVM_GetSystemPackages; 5.165 - JVM_GetThreadStateNames; 5.166 - JVM_GetThreadStateValues; 5.167 - JVM_GetVersionInfo; 5.168 - JVM_Halt; 5.169 - JVM_HoldsLock; 5.170 - JVM_IHashCode; 5.171 - JVM_InitAgentProperties; 5.172 - JVM_InitProperties; 5.173 - JVM_InitializeCompiler; 5.174 - JVM_InitializeSocketLibrary; 5.175 - JVM_InternString; 5.176 - JVM_Interrupt; 5.177 - JVM_InvokeMethod; 5.178 - JVM_IsArrayClass; 5.179 - JVM_IsConstructorIx; 5.180 - JVM_IsInterface; 5.181 - JVM_IsInterrupted; 5.182 - JVM_IsNaN; 5.183 - JVM_IsPrimitiveClass; 5.184 - JVM_IsSameClassPackage; 5.185 - JVM_IsSilentCompiler; 5.186 - JVM_IsSupportedJNIVersion; 5.187 - JVM_IsThreadAlive; 5.188 - JVM_IsVMGeneratedMethodIx; 5.189 - JVM_LatestUserDefinedLoader; 5.190 - JVM_Listen; 5.191 - JVM_LoadClass0; 5.192 - JVM_LoadLibrary; 5.193 - JVM_Lseek; 5.194 - JVM_MaxObjectInspectionAge; 5.195 - JVM_MaxMemory; 5.196 - JVM_MonitorNotify; 5.197 - JVM_MonitorNotifyAll; 5.198 - JVM_MonitorWait; 5.199 - JVM_NanoTime; 5.200 - JVM_NativePath; 5.201 - JVM_NewArray; 5.202 - JVM_NewInstanceFromConstructor; 5.203 - JVM_NewMultiArray; 5.204 - JVM_OnExit; 5.205 - JVM_Open; 5.206 - JVM_RaiseSignal; 5.207 - JVM_RawMonitorCreate; 5.208 - JVM_RawMonitorDestroy; 5.209 - JVM_RawMonitorEnter; 5.210 - JVM_RawMonitorExit; 5.211 - JVM_Read; 5.212 - JVM_Recv; 5.213 - JVM_RecvFrom; 5.214 - JVM_RegisterSignal; 5.215 - JVM_ReleaseUTF; 5.216 - JVM_ResolveClass; 5.217 - JVM_ResumeThread; 5.218 - JVM_Send; 5.219 - JVM_SendTo; 5.220 - JVM_SetArrayElement; 5.221 - JVM_SetClassSigners; 5.222 - JVM_SetLength; 5.223 - JVM_SetPrimitiveArrayElement; 5.224 - JVM_SetProtectionDomain; 5.225 - JVM_SetSockOpt; 5.226 - JVM_SetThreadPriority; 5.227 - JVM_Sleep; 5.228 - JVM_Socket; 5.229 - JVM_SocketAvailable; 5.230 - JVM_SocketClose; 5.231 - JVM_SocketShutdown; 5.232 - JVM_StartThread; 5.233 - JVM_StopThread; 5.234 - JVM_SuspendThread; 5.235 - JVM_SupportsCX8; 5.236 - JVM_Sync; 5.237 - JVM_Timeout; 5.238 - JVM_TotalMemory; 5.239 - JVM_TraceInstructions; 5.240 - JVM_TraceMethodCalls; 5.241 - JVM_UnloadLibrary; 5.242 - JVM_Write; 5.243 - JVM_Yield; 5.244 - JVM_handle_bsd_signal; 5.245 - 5.246 - # Old reflection routines 5.247 - # These do not need to be present in the product build in JDK 1.4 5.248 - # but their code has not been removed yet because there will not 5.249 - # be a substantial code savings until JVM_InvokeMethod and 5.250 - # JVM_NewInstanceFromConstructor can also be removed; see 5.251 - # reflectionCompat.hpp. 5.252 - JVM_GetClassConstructor; 5.253 - JVM_GetClassConstructors; 5.254 - JVM_GetClassField; 5.255 - JVM_GetClassFields; 5.256 - JVM_GetClassMethod; 5.257 - JVM_GetClassMethods; 5.258 - JVM_GetField; 5.259 - JVM_GetPrimitiveField; 5.260 - JVM_NewInstance; 5.261 - JVM_SetField; 5.262 - JVM_SetPrimitiveField; 5.263 + # _JVM 5.264 + _JVM_Accept 5.265 + _JVM_ActiveProcessorCount 5.266 + _JVM_AllocateNewArray 5.267 + _JVM_AllocateNewObject 5.268 + _JVM_ArrayCopy 5.269 + _JVM_AssertionStatusDirectives 5.270 + _JVM_Available 5.271 + _JVM_Bind 5.272 + _JVM_ClassDepth 5.273 + _JVM_ClassLoaderDepth 5.274 + _JVM_Clone 5.275 + _JVM_Close 5.276 + _JVM_CX8Field 5.277 + _JVM_CompileClass 5.278 + _JVM_CompileClasses 5.279 + _JVM_CompilerCommand 5.280 + _JVM_Connect 5.281 + _JVM_ConstantPoolGetClassAt 5.282 + _JVM_ConstantPoolGetClassAtIfLoaded 5.283 + _JVM_ConstantPoolGetDoubleAt 5.284 + _JVM_ConstantPoolGetFieldAt 5.285 + _JVM_ConstantPoolGetFieldAtIfLoaded 5.286 + _JVM_ConstantPoolGetFloatAt 5.287 + _JVM_ConstantPoolGetIntAt 5.288 + _JVM_ConstantPoolGetLongAt 5.289 + _JVM_ConstantPoolGetMethodAt 5.290 + _JVM_ConstantPoolGetMethodAtIfLoaded 5.291 + _JVM_ConstantPoolGetMemberRefInfoAt 5.292 + _JVM_ConstantPoolGetSize 5.293 + _JVM_ConstantPoolGetStringAt 5.294 + _JVM_ConstantPoolGetUTF8At 5.295 + _JVM_CountStackFrames 5.296 + _JVM_CurrentClassLoader 5.297 + _JVM_CurrentLoadedClass 5.298 + _JVM_CurrentThread 5.299 + _JVM_CurrentTimeMillis 5.300 + _JVM_DefineClass 5.301 + _JVM_DefineClassWithSource 5.302 + _JVM_DefineClassWithSourceCond 5.303 + _JVM_DesiredAssertionStatus 5.304 + _JVM_DisableCompiler 5.305 + _JVM_DoPrivileged 5.306 + _JVM_DTraceGetVersion 5.307 + _JVM_DTraceActivate 5.308 + _JVM_DTraceIsProbeEnabled 5.309 + _JVM_DTraceIsSupported 5.310 + _JVM_DTraceDispose 5.311 + _JVM_DumpAllStacks 5.312 + _JVM_DumpThreads 5.313 + _JVM_EnableCompiler 5.314 + _JVM_Exit 5.315 + _JVM_FillInStackTrace 5.316 + _JVM_FindClassFromClass 5.317 + _JVM_FindClassFromClassLoader 5.318 + _JVM_FindClassFromBootLoader 5.319 + _JVM_FindLibraryEntry 5.320 + _JVM_FindLoadedClass 5.321 + _JVM_FindPrimitiveClass 5.322 + _JVM_FindSignal 5.323 + _JVM_FreeMemory 5.324 + _JVM_GC 5.325 + _JVM_GetAllThreads 5.326 + _JVM_GetArrayElement 5.327 + _JVM_GetArrayLength 5.328 + _JVM_GetCPClassNameUTF 5.329 + _JVM_GetCPFieldClassNameUTF 5.330 + _JVM_GetCPFieldModifiers 5.331 + _JVM_GetCPFieldNameUTF 5.332 + _JVM_GetCPFieldSignatureUTF 5.333 + _JVM_GetCPMethodClassNameUTF 5.334 + _JVM_GetCPMethodModifiers 5.335 + _JVM_GetCPMethodNameUTF 5.336 + _JVM_GetCPMethodSignatureUTF 5.337 + _JVM_GetCallerClass 5.338 + _JVM_GetClassAccessFlags 5.339 + _JVM_GetClassAnnotations 5.340 + _JVM_GetClassCPEntriesCount 5.341 + _JVM_GetClassCPTypes 5.342 + _JVM_GetClassConstantPool 5.343 + _JVM_GetClassContext 5.344 + _JVM_GetClassDeclaredConstructors 5.345 + _JVM_GetClassDeclaredFields 5.346 + _JVM_GetClassDeclaredMethods 5.347 + _JVM_GetClassFieldsCount 5.348 + _JVM_GetClassInterfaces 5.349 + _JVM_GetClassLoader 5.350 + _JVM_GetClassMethodsCount 5.351 + _JVM_GetClassModifiers 5.352 + _JVM_GetClassName 5.353 + _JVM_GetClassNameUTF 5.354 + _JVM_GetClassSignature 5.355 + _JVM_GetClassSigners 5.356 + _JVM_GetClassTypeAnnotations 5.357 + _JVM_GetComponentType 5.358 + _JVM_GetDeclaredClasses 5.359 + _JVM_GetDeclaringClass 5.360 + _JVM_GetEnclosingMethodInfo 5.361 + _JVM_GetFieldAnnotations 5.362 + _JVM_GetFieldIxModifiers 5.363 + _JVM_GetFieldTypeAnnotations 5.364 + _JVM_GetHostName 5.365 + _JVM_GetInheritedAccessControlContext 5.366 + _JVM_GetInterfaceVersion 5.367 + _JVM_GetLastErrorString 5.368 + _JVM_GetManagement 5.369 + _JVM_GetMethodAnnotations 5.370 + _JVM_GetMethodDefaultAnnotationValue 5.371 + _JVM_GetMethodIxArgsSize 5.372 + _JVM_GetMethodIxByteCode 5.373 + _JVM_GetMethodIxByteCodeLength 5.374 + _JVM_GetMethodIxExceptionIndexes 5.375 + _JVM_GetMethodIxExceptionTableEntry 5.376 + _JVM_GetMethodIxExceptionTableLength 5.377 + _JVM_GetMethodIxExceptionsCount 5.378 + _JVM_GetMethodIxLocalsCount 5.379 + _JVM_GetMethodIxMaxStack 5.380 + _JVM_GetMethodIxModifiers 5.381 + _JVM_GetMethodIxNameUTF 5.382 + _JVM_GetMethodIxSignatureUTF 5.383 + _JVM_GetMethodParameterAnnotations 5.384 + _JVM_GetMethodParameters 5.385 + _JVM_GetMethodTypeAnnotations 5.386 + _JVM_GetPrimitiveArrayElement 5.387 + _JVM_GetProtectionDomain 5.388 + _JVM_GetSockName 5.389 + _JVM_GetSockOpt 5.390 + _JVM_GetStackAccessControlContext 5.391 + _JVM_GetStackTraceDepth 5.392 + _JVM_GetStackTraceElement 5.393 + _JVM_GetSystemPackage 5.394 + _JVM_GetSystemPackages 5.395 + _JVM_GetThreadStateNames 5.396 + _JVM_GetThreadStateValues 5.397 + _JVM_GetVersionInfo 5.398 + _JVM_Halt 5.399 + _JVM_HoldsLock 5.400 + _JVM_IHashCode 5.401 + _JVM_InitAgentProperties 5.402 + _JVM_InitProperties 5.403 + _JVM_InitializeCompiler 5.404 + _JVM_InitializeSocketLibrary 5.405 + _JVM_InternString 5.406 + _JVM_Interrupt 5.407 + _JVM_InvokeMethod 5.408 + _JVM_IsArrayClass 5.409 + _JVM_IsConstructorIx 5.410 + _JVM_IsInterface 5.411 + _JVM_IsInterrupted 5.412 + _JVM_IsNaN 5.413 + _JVM_IsPrimitiveClass 5.414 + _JVM_IsSameClassPackage 5.415 + _JVM_IsSilentCompiler 5.416 + _JVM_IsSupportedJNIVersion 5.417 + _JVM_IsThreadAlive 5.418 + _JVM_IsVMGeneratedMethodIx 5.419 + _JVM_LatestUserDefinedLoader 5.420 + _JVM_Listen 5.421 + _JVM_LoadClass0 5.422 + _JVM_LoadLibrary 5.423 + _JVM_Lseek 5.424 + _JVM_MaxObjectInspectionAge 5.425 + _JVM_MaxMemory 5.426 + _JVM_MonitorNotify 5.427 + _JVM_MonitorNotifyAll 5.428 + _JVM_MonitorWait 5.429 + _JVM_NanoTime 5.430 + _JVM_NativePath 5.431 + _JVM_NewArray 5.432 + _JVM_NewInstanceFromConstructor 5.433 + _JVM_NewMultiArray 5.434 + _JVM_OnExit 5.435 + _JVM_Open 5.436 + _JVM_RaiseSignal 5.437 + _JVM_RawMonitorCreate 5.438 + _JVM_RawMonitorDestroy 5.439 + _JVM_RawMonitorEnter 5.440 + _JVM_RawMonitorExit 5.441 + _JVM_Read 5.442 + _JVM_Recv 5.443 + _JVM_RecvFrom 5.444 + _JVM_RegisterSignal 5.445 + _JVM_ReleaseUTF 5.446 + _JVM_ResolveClass 5.447 + _JVM_ResumeThread 5.448 + _JVM_Send 5.449 + _JVM_SendTo 5.450 + _JVM_SetArrayElement 5.451 + _JVM_SetClassSigners 5.452 + _JVM_SetLength 5.453 + _JVM_SetNativeThreadName 5.454 + _JVM_SetPrimitiveArrayElement 5.455 + _JVM_SetProtectionDomain 5.456 + _JVM_SetSockOpt 5.457 + _JVM_SetThreadPriority 5.458 + _JVM_Sleep 5.459 + _JVM_Socket 5.460 + _JVM_SocketAvailable 5.461 + _JVM_SocketClose 5.462 + _JVM_SocketShutdown 5.463 + _JVM_StartThread 5.464 + _JVM_StopThread 5.465 + _JVM_SuspendThread 5.466 + _JVM_SupportsCX8 5.467 + _JVM_Sync 5.468 + _JVM_Timeout 5.469 + _JVM_TotalMemory 5.470 + _JVM_TraceInstructions 5.471 + _JVM_TraceMethodCalls 5.472 + _JVM_UnloadLibrary 5.473 + _JVM_Write 5.474 + _JVM_Yield 5.475 + _JVM_handle_bsd_signal 5.476 5.477 # miscellaneous functions 5.478 - jio_fprintf; 5.479 - jio_printf; 5.480 - jio_snprintf; 5.481 - jio_vfprintf; 5.482 - jio_vsnprintf; 5.483 - fork1; 5.484 - numa_warn; 5.485 - numa_error; 5.486 - 5.487 - # Needed because there is no JVM interface for this. 5.488 - sysThreadAvailableStackWithSlack; 5.489 + _jio_fprintf 5.490 + _jio_printf 5.491 + _jio_snprintf 5.492 + _jio_vfprintf 5.493 + _jio_vsnprintf 5.494 5.495 # This is for Forte Analyzer profiling support. 5.496 - AsyncGetCallTrace; 5.497 + _AsyncGetCallTrace 5.498 5.499 - # INSERT VTABLE SYMBOLS HERE 5.500 + # INSERT VTABLE SYMBOLS HERE 5.501 5.502 - local: 5.503 - *; 5.504 -}; 5.505 -
6.1 --- a/make/excludeSrc.make Wed Jun 26 16:06:38 2013 +0200 6.2 +++ b/make/excludeSrc.make Wed Jul 03 11:50:29 2013 -0700 6.3 @@ -112,3 +112,5 @@ 6.4 endif 6.5 6.6 -include $(HS_ALT_MAKE)/excludeSrc.make 6.7 + 6.8 +.PHONY: $(HS_ALT_MAKE)/excludeSrc.make
7.1 --- a/make/hotspot_version Wed Jun 26 16:06:38 2013 +0200 7.2 +++ b/make/hotspot_version Wed Jul 03 11:50:29 2013 -0700 7.3 @@ -35,7 +35,7 @@ 7.4 7.5 HS_MAJOR_VER=25 7.6 HS_MINOR_VER=0 7.7 -HS_BUILD_NUMBER=38 7.8 +HS_BUILD_NUMBER=39 7.9 7.10 JDK_MAJOR_VER=1 7.11 JDK_MINOR_VER=8
8.1 --- a/make/linux/makefiles/gcc.make Wed Jun 26 16:06:38 2013 +0200 8.2 +++ b/make/linux/makefiles/gcc.make Wed Jul 03 11:50:29 2013 -0700 8.3 @@ -350,9 +350,9 @@ 8.4 ifeq ($(DEBUG_CFLAGS/$(BUILDARCH)),) 8.5 ifeq ($(USE_CLANG), true) 8.6 # Clang doesn't understand -gstabs 8.7 - OPT_CFLAGS += -g 8.8 + DEBUG_CFLAGS += -g 8.9 else 8.10 - OPT_CFLAGS += -gstabs 8.11 + DEBUG_CFLAGS += -gstabs 8.12 endif 8.13 endif 8.14 8.15 @@ -365,9 +365,9 @@ 8.16 ifeq ($(FASTDEBUG_CFLAGS/$(BUILDARCH)),) 8.17 ifeq ($(USE_CLANG), true) 8.18 # Clang doesn't understand -gstabs 8.19 - OPT_CFLAGS += -g 8.20 + FASTDEBUG_CFLAGS += -g 8.21 else 8.22 - OPT_CFLAGS += -gstabs 8.23 + FASTDEBUG_CFLAGS += -gstabs 8.24 endif 8.25 endif 8.26
9.1 --- a/make/linux/makefiles/vm.make Wed Jun 26 16:06:38 2013 +0200 9.2 +++ b/make/linux/makefiles/vm.make Wed Jul 03 11:50:29 2013 -0700 9.3 @@ -107,6 +107,10 @@ 9.4 # File specific flags 9.5 CXXFLAGS += $(CXXFLAGS/BYFILE) 9.6 9.7 +# Large File Support 9.8 +ifneq ($(LP64), 1) 9.9 +CXXFLAGS/ostream.o += -D_FILE_OFFSET_BITS=64 9.10 +endif # ifneq ($(LP64), 1) 9.11 9.12 # CFLAGS_WARN holds compiler options to suppress/enable warnings. 9.13 CFLAGS += $(CFLAGS_WARN/BYFILE)
10.1 --- a/make/solaris/makefiles/vm.make Wed Jun 26 16:06:38 2013 +0200 10.2 +++ b/make/solaris/makefiles/vm.make Wed Jul 03 11:50:29 2013 -0700 10.3 @@ -95,6 +95,10 @@ 10.4 # File specific flags 10.5 CXXFLAGS += $(CXXFLAGS/BYFILE) 10.6 10.7 +# Large File Support 10.8 +ifneq ($(LP64), 1) 10.9 +CXXFLAGS/ostream.o += -D_FILE_OFFSET_BITS=64 10.10 +endif # ifneq ($(LP64), 1) 10.11 10.12 # CFLAGS_WARN holds compiler options to suppress/enable warnings. 10.13 CFLAGS += $(CFLAGS_WARN)
11.1 --- a/src/cpu/sparc/vm/frame_sparc.cpp Wed Jun 26 16:06:38 2013 +0200 11.2 +++ b/src/cpu/sparc/vm/frame_sparc.cpp Wed Jul 03 11:50:29 2013 -0700 11.3 @@ -680,7 +680,7 @@ 11.4 11.5 // validate ConstantPoolCache* 11.6 ConstantPoolCache* cp = *interpreter_frame_cache_addr(); 11.7 - if (cp == NULL || !cp->is_metadata()) return false; 11.8 + if (cp == NULL || !cp->is_metaspace_object()) return false; 11.9 11.10 // validate locals 11.11
12.1 --- a/src/cpu/sparc/vm/macroAssembler_sparc.cpp Wed Jun 26 16:06:38 2013 +0200 12.2 +++ b/src/cpu/sparc/vm/macroAssembler_sparc.cpp Wed Jul 03 11:50:29 2013 -0700 12.3 @@ -1161,12 +1161,6 @@ 12.4 while (offset() % modulus != 0) nop(); 12.5 } 12.6 12.7 - 12.8 -void MacroAssembler::safepoint() { 12.9 - relocate(breakpoint_Relocation::spec(breakpoint_Relocation::safepoint)); 12.10 -} 12.11 - 12.12 - 12.13 void RegistersForDebugging::print(outputStream* s) { 12.14 FlagSetting fs(Debugging, true); 12.15 int j;
13.1 --- a/src/cpu/sparc/vm/relocInfo_sparc.cpp Wed Jun 26 16:06:38 2013 +0200 13.2 +++ b/src/cpu/sparc/vm/relocInfo_sparc.cpp Wed Jul 03 11:50:29 2013 -0700 13.3 @@ -193,36 +193,6 @@ 13.4 return *(address*)addr(); 13.5 } 13.6 13.7 - 13.8 -int Relocation::pd_breakpoint_size() { 13.9 - // minimum breakpoint size, in short words 13.10 - return NativeIllegalInstruction::instruction_size / sizeof(short); 13.11 -} 13.12 - 13.13 -void Relocation::pd_swap_in_breakpoint(address x, short* instrs, int instrlen) { 13.14 - Untested("pd_swap_in_breakpoint"); 13.15 - // %%% probably do not need a general instrlen; just use the trap size 13.16 - if (instrs != NULL) { 13.17 - assert(instrlen * sizeof(short) == NativeIllegalInstruction::instruction_size, "enough instrlen in reloc. data"); 13.18 - for (int i = 0; i < instrlen; i++) { 13.19 - instrs[i] = ((short*)x)[i]; 13.20 - } 13.21 - } 13.22 - NativeIllegalInstruction::insert(x); 13.23 -} 13.24 - 13.25 - 13.26 -void Relocation::pd_swap_out_breakpoint(address x, short* instrs, int instrlen) { 13.27 - Untested("pd_swap_out_breakpoint"); 13.28 - assert(instrlen * sizeof(short) == sizeof(int), "enough buf"); 13.29 - union { int l; short s[1]; } u; 13.30 - for (int i = 0; i < instrlen; i++) { 13.31 - u.s[i] = instrs[i]; 13.32 - } 13.33 - NativeInstruction* ni = nativeInstruction_at(x); 13.34 - ni->set_long_at(0, u.l); 13.35 -} 13.36 - 13.37 void poll_Relocation::fix_relocation_after_move(const CodeBuffer* src, CodeBuffer* dest) { 13.38 } 13.39
14.1 --- a/src/cpu/x86/vm/frame_x86.cpp Wed Jun 26 16:06:38 2013 +0200 14.2 +++ b/src/cpu/x86/vm/frame_x86.cpp Wed Jul 03 11:50:29 2013 -0700 14.3 @@ -587,7 +587,7 @@ 14.4 14.5 // validate ConstantPoolCache* 14.6 ConstantPoolCache* cp = *interpreter_frame_cache_addr(); 14.7 - if (cp == NULL || !cp->is_metadata()) return false; 14.8 + if (cp == NULL || !cp->is_metaspace_object()) return false; 14.9 14.10 // validate locals 14.11
15.1 --- a/src/cpu/x86/vm/relocInfo_x86.cpp Wed Jun 26 16:06:38 2013 +0200 15.2 +++ b/src/cpu/x86/vm/relocInfo_x86.cpp Wed Jul 03 11:50:29 2013 -0700 15.3 @@ -177,30 +177,6 @@ 15.4 return *pd_address_in_code(); 15.5 } 15.6 15.7 -int Relocation::pd_breakpoint_size() { 15.8 - // minimum breakpoint size, in short words 15.9 - return NativeIllegalInstruction::instruction_size / sizeof(short); 15.10 -} 15.11 - 15.12 -void Relocation::pd_swap_in_breakpoint(address x, short* instrs, int instrlen) { 15.13 - Untested("pd_swap_in_breakpoint"); 15.14 - if (instrs != NULL) { 15.15 - assert(instrlen * sizeof(short) == NativeIllegalInstruction::instruction_size, "enough instrlen in reloc. data"); 15.16 - for (int i = 0; i < instrlen; i++) { 15.17 - instrs[i] = ((short*)x)[i]; 15.18 - } 15.19 - } 15.20 - NativeIllegalInstruction::insert(x); 15.21 -} 15.22 - 15.23 - 15.24 -void Relocation::pd_swap_out_breakpoint(address x, short* instrs, int instrlen) { 15.25 - Untested("pd_swap_out_breakpoint"); 15.26 - assert(NativeIllegalInstruction::instruction_size == sizeof(short), "right address unit for update"); 15.27 - NativeInstruction* ni = nativeInstruction_at(x); 15.28 - *(short*)ni->addr_at(0) = instrs[0]; 15.29 -} 15.30 - 15.31 void poll_Relocation::fix_relocation_after_move(const CodeBuffer* src, CodeBuffer* dest) { 15.32 #ifdef _LP64 15.33 if (!Assembler::is_polling_page_far()) {
16.1 --- a/src/cpu/zero/vm/relocInfo_zero.cpp Wed Jun 26 16:06:38 2013 +0200 16.2 +++ b/src/cpu/zero/vm/relocInfo_zero.cpp Wed Jul 03 11:50:29 2013 -0700 16.3 @@ -52,22 +52,6 @@ 16.4 return (address *) addr(); 16.5 } 16.6 16.7 -int Relocation::pd_breakpoint_size() { 16.8 - ShouldNotCallThis(); 16.9 -} 16.10 - 16.11 -void Relocation::pd_swap_in_breakpoint(address x, 16.12 - short* instrs, 16.13 - int instrlen) { 16.14 - ShouldNotCallThis(); 16.15 -} 16.16 - 16.17 -void Relocation::pd_swap_out_breakpoint(address x, 16.18 - short* instrs, 16.19 - int instrlen) { 16.20 - ShouldNotCallThis(); 16.21 -} 16.22 - 16.23 void poll_Relocation::fix_relocation_after_move(const CodeBuffer* src, 16.24 CodeBuffer* dst) { 16.25 ShouldNotCallThis();
17.1 --- a/src/os/solaris/vm/os_solaris.inline.hpp Wed Jun 26 16:06:38 2013 +0200 17.2 +++ b/src/os/solaris/vm/os_solaris.inline.hpp Wed Jul 03 11:50:29 2013 -0700 17.3 @@ -89,7 +89,7 @@ 17.4 17.5 inline struct dirent* os::readdir(DIR* dirp, dirent* dbuf) { 17.6 assert(dirp != NULL, "just checking"); 17.7 -#if defined(_LP64) || defined(_GNU_SOURCE) 17.8 +#if defined(_LP64) || defined(_GNU_SOURCE) || _FILE_OFFSET_BITS==64 17.9 dirent* p; 17.10 int status; 17.11 17.12 @@ -98,9 +98,9 @@ 17.13 return NULL; 17.14 } else 17.15 return p; 17.16 -#else // defined(_LP64) || defined(_GNU_SOURCE) 17.17 +#else // defined(_LP64) || defined(_GNU_SOURCE) || _FILE_OFFSET_BITS==64 17.18 return ::readdir_r(dirp, dbuf); 17.19 -#endif // defined(_LP64) || defined(_GNU_SOURCE) 17.20 +#endif // defined(_LP64) || defined(_GNU_SOURCE) || _FILE_OFFSET_BITS==64 17.21 } 17.22 17.23 inline int os::closedir(DIR *dirp) {
18.1 --- a/src/os_cpu/linux_x86/vm/os_linux_x86.cpp Wed Jun 26 16:06:38 2013 +0200 18.2 +++ b/src/os_cpu/linux_x86/vm/os_linux_x86.cpp Wed Jul 03 11:50:29 2013 -0700 18.3 @@ -289,6 +289,16 @@ 18.4 } 18.5 #endif // AMD64 18.6 18.7 +#ifndef AMD64 18.8 + // Halt if SI_KERNEL before more crashes get misdiagnosed as Java bugs 18.9 + // This can happen in any running code (currently more frequently in 18.10 + // interpreter code but has been seen in compiled code) 18.11 + if (sig == SIGSEGV && info->si_addr == 0 && info->si_code == SI_KERNEL) { 18.12 + fatal("An irrecoverable SI_KERNEL SIGSEGV has occurred due " 18.13 + "to unstable signal handling in this distribution."); 18.14 + } 18.15 +#endif // AMD64 18.16 + 18.17 // Handle ALL stack overflow variations here 18.18 if (sig == SIGSEGV) { 18.19 address addr = (address) info->si_addr;
19.1 --- a/src/share/vm/ci/ciObjectFactory.cpp Wed Jun 26 16:06:38 2013 +0200 19.2 +++ b/src/share/vm/ci/ciObjectFactory.cpp Wed Jul 03 11:50:29 2013 -0700 19.3 @@ -265,8 +265,6 @@ 19.4 ciMetadata* ciObjectFactory::get_metadata(Metadata* key) { 19.5 ASSERT_IN_VM; 19.6 19.7 - assert(key == NULL || key->is_metadata(), "must be"); 19.8 - 19.9 #ifdef ASSERT 19.10 if (CIObjectFactoryVerify) { 19.11 Metadata* last = NULL;
20.1 --- a/src/share/vm/classfile/dictionary.cpp Wed Jun 26 16:06:38 2013 +0200 20.2 +++ b/src/share/vm/classfile/dictionary.cpp Wed Jul 03 11:50:29 2013 -0700 20.3 @@ -555,7 +555,7 @@ 20.4 loader_data->class_loader() == NULL || 20.5 loader_data->class_loader()->is_instance(), 20.6 "checking type of class_loader"); 20.7 - e->verify(); 20.8 + e->verify(/*check_dictionary*/false); 20.9 probe->verify_protection_domain_set(); 20.10 element_count++; 20.11 }
21.1 --- a/src/share/vm/code/debugInfo.hpp Wed Jun 26 16:06:38 2013 +0200 21.2 +++ b/src/share/vm/code/debugInfo.hpp Wed Jul 03 11:50:29 2013 -0700 21.3 @@ -274,7 +274,7 @@ 21.4 Method* read_method() { 21.5 Method* o = (Method*)(code()->metadata_at(read_int())); 21.6 assert(o == NULL || 21.7 - o->is_metadata(), "meta data only"); 21.8 + o->is_metaspace_object(), "meta data only"); 21.9 return o; 21.10 } 21.11 ScopeValue* read_object_value();
22.1 --- a/src/share/vm/code/dependencies.cpp Wed Jun 26 16:06:38 2013 +0200 22.2 +++ b/src/share/vm/code/dependencies.cpp Wed Jul 03 11:50:29 2013 -0700 22.3 @@ -655,8 +655,8 @@ 22.4 } else { 22.5 o = _deps->oop_recorder()->metadata_at(i); 22.6 } 22.7 - assert(o == NULL || o->is_metadata(), 22.8 - err_msg("Should be perm " PTR_FORMAT, o)); 22.9 + assert(o == NULL || o->is_metaspace_object(), 22.10 + err_msg("Should be metadata " PTR_FORMAT, o)); 22.11 return o; 22.12 } 22.13
23.1 --- a/src/share/vm/code/nmethod.cpp Wed Jun 26 16:06:38 2013 +0200 23.2 +++ b/src/share/vm/code/nmethod.cpp Wed Jul 03 11:50:29 2013 -0700 23.3 @@ -1081,11 +1081,6 @@ 23.4 metadata_Relocation* reloc = iter.metadata_reloc(); 23.5 reloc->fix_metadata_relocation(); 23.6 } 23.7 - 23.8 - // There must not be any interfering patches or breakpoints. 23.9 - assert(!(iter.type() == relocInfo::breakpoint_type 23.10 - && iter.breakpoint_reloc()->active()), 23.11 - "no active breakpoint"); 23.12 } 23.13 } 23.14
24.1 --- a/src/share/vm/code/relocInfo.cpp Wed Jun 26 16:06:38 2013 +0200 24.2 +++ b/src/share/vm/code/relocInfo.cpp Wed Jul 03 11:50:29 2013 -0700 24.3 @@ -338,31 +338,6 @@ 24.4 _limit = limit; 24.5 } 24.6 24.7 - 24.8 -void PatchingRelocIterator:: prepass() { 24.9 - // turn breakpoints off during patching 24.10 - _init_state = (*this); // save cursor 24.11 - while (next()) { 24.12 - if (type() == relocInfo::breakpoint_type) { 24.13 - breakpoint_reloc()->set_active(false); 24.14 - } 24.15 - } 24.16 - (RelocIterator&)(*this) = _init_state; // reset cursor for client 24.17 -} 24.18 - 24.19 - 24.20 -void PatchingRelocIterator:: postpass() { 24.21 - // turn breakpoints back on after patching 24.22 - (RelocIterator&)(*this) = _init_state; // reset cursor again 24.23 - while (next()) { 24.24 - if (type() == relocInfo::breakpoint_type) { 24.25 - breakpoint_Relocation* bpt = breakpoint_reloc(); 24.26 - bpt->set_active(bpt->enabled()); 24.27 - } 24.28 - } 24.29 -} 24.30 - 24.31 - 24.32 // All the strange bit-encodings are in here. 24.33 // The idea is to encode relocation data which are small integers 24.34 // very efficiently (a single extra halfword). Larger chunks of 24.35 @@ -704,51 +679,6 @@ 24.36 _target = address_from_scaled_offset(offset, base); 24.37 } 24.38 24.39 - 24.40 -void breakpoint_Relocation::pack_data_to(CodeSection* dest) { 24.41 - short* p = (short*) dest->locs_end(); 24.42 - address point = dest->locs_point(); 24.43 - 24.44 - *p++ = _bits; 24.45 - 24.46 - assert(_target != NULL, "sanity"); 24.47 - 24.48 - if (internal()) normalize_address(_target, dest); 24.49 - 24.50 - jint target_bits = 24.51 - (jint)( internal() ? scaled_offset (_target, point) 24.52 - : runtime_address_to_index(_target) ); 24.53 - if (settable()) { 24.54 - // save space for set_target later 24.55 - p = add_jint(p, target_bits); 24.56 - } else { 24.57 - p = add_var_int(p, target_bits); 24.58 - } 24.59 - 24.60 - for (int i = 0; i < instrlen(); i++) { 24.61 - // put placeholder words until bytes can be saved 24.62 - p = add_short(p, (short)0x7777); 24.63 - } 24.64 - 24.65 - dest->set_locs_end((relocInfo*) p); 24.66 -} 24.67 - 24.68 - 24.69 -void breakpoint_Relocation::unpack_data() { 24.70 - _bits = live_bits(); 24.71 - 24.72 - int targetlen = datalen() - 1 - instrlen(); 24.73 - jint target_bits = 0; 24.74 - if (targetlen == 0) target_bits = 0; 24.75 - else if (targetlen == 1) target_bits = *(data()+1); 24.76 - else if (targetlen == 2) target_bits = relocInfo::jint_from_data(data()+1); 24.77 - else { ShouldNotReachHere(); } 24.78 - 24.79 - _target = internal() ? address_from_scaled_offset(target_bits, addr()) 24.80 - : index_to_runtime_address (target_bits); 24.81 -} 24.82 - 24.83 - 24.84 //// miscellaneous methods 24.85 oop* oop_Relocation::oop_addr() { 24.86 int n = _oop_index; 24.87 @@ -933,81 +863,6 @@ 24.88 return target; 24.89 } 24.90 24.91 - 24.92 -breakpoint_Relocation::breakpoint_Relocation(int kind, address target, bool internal) { 24.93 - bool active = false; 24.94 - bool enabled = (kind == initialization); 24.95 - bool removable = (kind != safepoint); 24.96 - bool settable = (target == NULL); 24.97 - 24.98 - int bits = kind; 24.99 - if (enabled) bits |= enabled_state; 24.100 - if (internal) bits |= internal_attr; 24.101 - if (removable) bits |= removable_attr; 24.102 - if (settable) bits |= settable_attr; 24.103 - 24.104 - _bits = bits | high_bit; 24.105 - _target = target; 24.106 - 24.107 - assert(this->kind() == kind, "kind encoded"); 24.108 - assert(this->enabled() == enabled, "enabled encoded"); 24.109 - assert(this->active() == active, "active encoded"); 24.110 - assert(this->internal() == internal, "internal encoded"); 24.111 - assert(this->removable() == removable, "removable encoded"); 24.112 - assert(this->settable() == settable, "settable encoded"); 24.113 -} 24.114 - 24.115 - 24.116 -address breakpoint_Relocation::target() const { 24.117 - return _target; 24.118 -} 24.119 - 24.120 - 24.121 -void breakpoint_Relocation::set_target(address x) { 24.122 - assert(settable(), "must be settable"); 24.123 - jint target_bits = 24.124 - (jint)(internal() ? scaled_offset (x, addr()) 24.125 - : runtime_address_to_index(x)); 24.126 - short* p = &live_bits() + 1; 24.127 - p = add_jint(p, target_bits); 24.128 - assert(p == instrs(), "new target must fit"); 24.129 - _target = x; 24.130 -} 24.131 - 24.132 - 24.133 -void breakpoint_Relocation::set_enabled(bool b) { 24.134 - if (enabled() == b) return; 24.135 - 24.136 - if (b) { 24.137 - set_bits(bits() | enabled_state); 24.138 - } else { 24.139 - set_active(false); // remove the actual breakpoint insn, if any 24.140 - set_bits(bits() & ~enabled_state); 24.141 - } 24.142 -} 24.143 - 24.144 - 24.145 -void breakpoint_Relocation::set_active(bool b) { 24.146 - assert(!b || enabled(), "cannot activate a disabled breakpoint"); 24.147 - 24.148 - if (active() == b) return; 24.149 - 24.150 - // %%% should probably seize a lock here (might not be the right lock) 24.151 - //MutexLockerEx ml_patch(Patching_lock, true); 24.152 - //if (active() == b) return; // recheck state after locking 24.153 - 24.154 - if (b) { 24.155 - set_bits(bits() | active_state); 24.156 - if (instrlen() == 0) 24.157 - fatal("breakpoints in original code must be undoable"); 24.158 - pd_swap_in_breakpoint (addr(), instrs(), instrlen()); 24.159 - } else { 24.160 - set_bits(bits() & ~active_state); 24.161 - pd_swap_out_breakpoint(addr(), instrs(), instrlen()); 24.162 - } 24.163 -} 24.164 - 24.165 - 24.166 //--------------------------------------------------------------------------------- 24.167 // Non-product code 24.168
25.1 --- a/src/share/vm/code/relocInfo.hpp Wed Jun 26 16:06:38 2013 +0200 25.2 +++ b/src/share/vm/code/relocInfo.hpp Wed Jul 03 11:50:29 2013 -0700 25.3 @@ -49,9 +49,6 @@ 25.4 // RelocIterator 25.5 // A StackObj which iterates over the relocations associated with 25.6 // a range of code addresses. Can be used to operate a copy of code. 25.7 -// PatchingRelocIterator 25.8 -// Specialized subtype of RelocIterator which removes breakpoints 25.9 -// temporarily during iteration, then restores them. 25.10 // BoundRelocation 25.11 // An _internal_ type shared by packers and unpackers of relocations. 25.12 // It pastes together a RelocationHolder with some pointers into 25.13 @@ -204,15 +201,6 @@ 25.14 // immediate field must not straddle a unit of memory coherence. 25.15 // //%note reloc_3 25.16 // 25.17 -// relocInfo::breakpoint_type -- a conditional breakpoint in the code 25.18 -// Value: none 25.19 -// Instruction types: any whatsoever 25.20 -// Data: [b [T]t i...] 25.21 -// The b is a bit-packed word representing the breakpoint's attributes. 25.22 -// The t is a target address which the breakpoint calls (when it is enabled). 25.23 -// The i... is a place to store one or two instruction words overwritten 25.24 -// by a trap, so that the breakpoint may be subsequently removed. 25.25 -// 25.26 // relocInfo::static_stub_type -- an extra stub for each static_call_type 25.27 // Value: none 25.28 // Instruction types: a virtual call: { set_oop; jump; } 25.29 @@ -271,8 +259,8 @@ 25.30 section_word_type = 9, // internal, but a cross-section reference 25.31 poll_type = 10, // polling instruction for safepoints 25.32 poll_return_type = 11, // polling instruction for safepoints at return 25.33 - breakpoint_type = 12, // an initialization barrier or safepoint 25.34 - metadata_type = 13, // metadata that used to be oops 25.35 + metadata_type = 12, // metadata that used to be oops 25.36 + yet_unused_type_1 = 13, // Still unused 25.37 yet_unused_type_2 = 14, // Still unused 25.38 data_prefix_tag = 15, // tag for a prefix (carries data arguments) 25.39 type_mask = 15 // A mask which selects only the above values 25.40 @@ -312,7 +300,6 @@ 25.41 visitor(internal_word) \ 25.42 visitor(poll) \ 25.43 visitor(poll_return) \ 25.44 - visitor(breakpoint) \ 25.45 visitor(section_word) \ 25.46 25.47 25.48 @@ -454,7 +441,7 @@ 25.49 public: 25.50 enum { 25.51 // Conservatively large estimate of maximum length (in shorts) 25.52 - // of any relocation record (probably breakpoints are largest). 25.53 + // of any relocation record. 25.54 // Extended format is length prefix, data words, and tag/offset suffix. 25.55 length_limit = 1 + 1 + (3*BytesPerWord/BytesPerShort) + 1, 25.56 have_format = format_width > 0 25.57 @@ -571,8 +558,6 @@ 25.58 25.59 void initialize(nmethod* nm, address begin, address limit); 25.60 25.61 - friend class PatchingRelocIterator; 25.62 - // make an uninitialized one, for PatchingRelocIterator: 25.63 RelocIterator() { initialize_misc(); } 25.64 25.65 public: 25.66 @@ -779,9 +764,6 @@ 25.67 void pd_verify_data_value (address x, intptr_t off) { pd_set_data_value(x, off, true); } 25.68 address pd_call_destination (address orig_addr = NULL); 25.69 void pd_set_call_destination (address x); 25.70 - void pd_swap_in_breakpoint (address x, short* instrs, int instrlen); 25.71 - void pd_swap_out_breakpoint (address x, short* instrs, int instrlen); 25.72 - static int pd_breakpoint_size (); 25.73 25.74 // this extracts the address of an address in the code stream instead of the reloc data 25.75 address* pd_address_in_code (); 25.76 @@ -1302,87 +1284,6 @@ 25.77 void fix_relocation_after_move(const CodeBuffer* src, CodeBuffer* dest); 25.78 }; 25.79 25.80 - 25.81 -class breakpoint_Relocation : public Relocation { 25.82 - relocInfo::relocType type() { return relocInfo::breakpoint_type; } 25.83 - 25.84 - enum { 25.85 - // attributes which affect the interpretation of the data: 25.86 - removable_attr = 0x0010, // buffer [i...] allows for undoing the trap 25.87 - internal_attr = 0x0020, // the target is an internal addr (local stub) 25.88 - settable_attr = 0x0040, // the target is settable 25.89 - 25.90 - // states which can change over time: 25.91 - enabled_state = 0x0100, // breakpoint must be active in running code 25.92 - active_state = 0x0200, // breakpoint instruction actually in code 25.93 - 25.94 - kind_mask = 0x000F, // mask for extracting kind 25.95 - high_bit = 0x4000 // extra bit which is always set 25.96 - }; 25.97 - 25.98 - public: 25.99 - enum { 25.100 - // kinds: 25.101 - initialization = 1, 25.102 - safepoint = 2 25.103 - }; 25.104 - 25.105 - // If target is NULL, 32 bits are reserved for a later set_target(). 25.106 - static RelocationHolder spec(int kind, address target = NULL, bool internal_target = false) { 25.107 - RelocationHolder rh = newHolder(); 25.108 - new(rh) breakpoint_Relocation(kind, target, internal_target); 25.109 - return rh; 25.110 - } 25.111 - 25.112 - private: 25.113 - // We require every bits value to NOT to fit into relocInfo::datalen_width, 25.114 - // because we are going to actually store state in the reloc, and so 25.115 - // cannot allow it to be compressed (and hence copied by the iterator). 25.116 - 25.117 - short _bits; // bit-encoded kind, attrs, & state 25.118 - address _target; 25.119 - 25.120 - breakpoint_Relocation(int kind, address target, bool internal_target); 25.121 - 25.122 - friend class RelocIterator; 25.123 - breakpoint_Relocation() { } 25.124 - 25.125 - short bits() const { return _bits; } 25.126 - short& live_bits() const { return data()[0]; } 25.127 - short* instrs() const { return data() + datalen() - instrlen(); } 25.128 - int instrlen() const { return removable() ? pd_breakpoint_size() : 0; } 25.129 - 25.130 - void set_bits(short x) { 25.131 - assert(live_bits() == _bits, "must be the only mutator of reloc info"); 25.132 - live_bits() = _bits = x; 25.133 - } 25.134 - 25.135 - public: 25.136 - address target() const; 25.137 - void set_target(address x); 25.138 - 25.139 - int kind() const { return bits() & kind_mask; } 25.140 - bool enabled() const { return (bits() & enabled_state) != 0; } 25.141 - bool active() const { return (bits() & active_state) != 0; } 25.142 - bool internal() const { return (bits() & internal_attr) != 0; } 25.143 - bool removable() const { return (bits() & removable_attr) != 0; } 25.144 - bool settable() const { return (bits() & settable_attr) != 0; } 25.145 - 25.146 - void set_enabled(bool b); // to activate, you must also say set_active 25.147 - void set_active(bool b); // actually inserts bpt (must be enabled 1st) 25.148 - 25.149 - // data is packed as 16 bits, followed by the target (1 or 2 words), followed 25.150 - // if necessary by empty storage for saving away original instruction bytes. 25.151 - void pack_data_to(CodeSection* dest); 25.152 - void unpack_data(); 25.153 - 25.154 - // during certain operations, breakpoints must be out of the way: 25.155 - void fix_relocation_after_move(const CodeBuffer* src, CodeBuffer* dest) { 25.156 - assert(!active(), "cannot perform relocation on enabled breakpoints"); 25.157 - } 25.158 -}; 25.159 - 25.160 - 25.161 // We know all the xxx_Relocation classes, so now we can define these: 25.162 #define EACH_CASE(name) \ 25.163 inline name##_Relocation* RelocIterator::name##_reloc() { \ 25.164 @@ -1401,25 +1302,4 @@ 25.165 initialize(nm, begin, limit); 25.166 } 25.167 25.168 -// if you are going to patch code, you should use this subclass of 25.169 -// RelocIterator 25.170 -class PatchingRelocIterator : public RelocIterator { 25.171 - private: 25.172 - RelocIterator _init_state; 25.173 - 25.174 - void prepass(); // deactivates all breakpoints 25.175 - void postpass(); // reactivates all enabled breakpoints 25.176 - 25.177 - // do not copy these puppies; it would have unpredictable side effects 25.178 - // these are private and have no bodies defined because they should not be called 25.179 - PatchingRelocIterator(const RelocIterator&); 25.180 - void operator=(const RelocIterator&); 25.181 - 25.182 - public: 25.183 - PatchingRelocIterator(nmethod* nm, address begin = NULL, address limit = NULL) 25.184 - : RelocIterator(nm, begin, limit) { prepass(); } 25.185 - 25.186 - ~PatchingRelocIterator() { postpass(); } 25.187 -}; 25.188 - 25.189 #endif // SHARE_VM_CODE_RELOCINFO_HPP
26.1 --- a/src/share/vm/gc_implementation/g1/heapRegion.cpp Wed Jun 26 16:06:38 2013 +0200 26.2 +++ b/src/share/vm/gc_implementation/g1/heapRegion.cpp Wed Jul 03 11:50:29 2013 -0700 26.3 @@ -798,7 +798,7 @@ 26.4 if (!g1->is_obj_dead_cond(obj, this, vo)) { 26.5 if (obj->is_oop()) { 26.6 Klass* klass = obj->klass(); 26.7 - if (!klass->is_metadata()) { 26.8 + if (!klass->is_metaspace_object()) { 26.9 gclog_or_tty->print_cr("klass "PTR_FORMAT" of object "PTR_FORMAT" " 26.10 "not metadata", klass, obj); 26.11 *failures = true;
27.1 --- a/src/share/vm/gc_implementation/parallelScavenge/asPSOldGen.cpp Wed Jun 26 16:06:38 2013 +0200 27.2 +++ b/src/share/vm/gc_implementation/parallelScavenge/asPSOldGen.cpp Wed Jul 03 11:50:29 2013 -0700 27.3 @@ -70,6 +70,17 @@ 27.4 _virtual_space = vs; 27.5 } 27.6 27.7 +void ASPSOldGen::initialize_work(const char* perf_data_name, int level) { 27.8 + 27.9 + PSOldGen::initialize_work(perf_data_name, level); 27.10 + 27.11 + // The old gen can grow to gen_size_limit(). _reserve reflects only 27.12 + // the current maximum that can be committed. 27.13 + assert(_reserved.byte_size() <= gen_size_limit(), "Consistency check"); 27.14 + 27.15 + initialize_performance_counters(perf_data_name, level); 27.16 +} 27.17 + 27.18 void ASPSOldGen::reset_after_change() { 27.19 _reserved = MemRegion((HeapWord*)virtual_space()->low_boundary(), 27.20 (HeapWord*)virtual_space()->high_boundary());
28.1 --- a/src/share/vm/gc_implementation/parallelScavenge/asPSOldGen.hpp Wed Jun 26 16:06:38 2013 +0200 28.2 +++ b/src/share/vm/gc_implementation/parallelScavenge/asPSOldGen.hpp Wed Jul 03 11:50:29 2013 -0700 28.3 @@ -50,6 +50,8 @@ 28.4 size_t max_gen_size() { return _reserved.byte_size(); } 28.5 void set_gen_size_limit(size_t v) { _gen_size_limit = v; } 28.6 28.7 + virtual void initialize_work(const char* perf_data_name, int level); 28.8 + 28.9 // After a shrink or expand reset the generation 28.10 void reset_after_change(); 28.11
29.1 --- a/src/share/vm/gc_implementation/parallelScavenge/psOldGen.hpp Wed Jun 26 16:06:38 2013 +0200 29.2 +++ b/src/share/vm/gc_implementation/parallelScavenge/psOldGen.hpp Wed Jul 03 11:50:29 2013 -0700 29.3 @@ -110,7 +110,7 @@ 29.4 virtual void initialize(ReservedSpace rs, size_t alignment, 29.5 const char* perf_data_name, int level); 29.6 void initialize_virtual_space(ReservedSpace rs, size_t alignment); 29.7 - void initialize_work(const char* perf_data_name, int level); 29.8 + virtual void initialize_work(const char* perf_data_name, int level); 29.9 virtual void initialize_performance_counters(const char* perf_data_name, int level); 29.10 29.11 MemRegion reserved() const { return _reserved; }
30.1 --- a/src/share/vm/interpreter/bytecodeInterpreter.cpp Wed Jun 26 16:06:38 2013 +0200 30.2 +++ b/src/share/vm/interpreter/bytecodeInterpreter.cpp Wed Jul 03 11:50:29 2013 -0700 30.3 @@ -482,9 +482,9 @@ 30.4 // So we have a second version of the assertion which handles the case where EnableInvokeDynamic was 30.5 // switched off because of the wrong classes. 30.6 if (EnableInvokeDynamic || FLAG_IS_CMDLINE(EnableInvokeDynamic)) { 30.7 - assert(abs(istate->_stack_base - istate->_stack_limit) == (istate->_method->max_stack() + 1), "bad stack limit"); 30.8 + assert(labs(istate->_stack_base - istate->_stack_limit) == (istate->_method->max_stack() + 1), "bad stack limit"); 30.9 } else { 30.10 - const int extra_stack_entries = Method::extra_stack_entries_for_indy; 30.11 + const int extra_stack_entries = Method::extra_stack_entries_for_jsr292; 30.12 assert(labs(istate->_stack_base - istate->_stack_limit) == (istate->_method->max_stack() + extra_stack_entries 30.13 + 1), "bad stack limit"); 30.14 } 30.15 @@ -2362,7 +2362,7 @@ 30.16 } 30.17 30.18 Method* method = cache->f1_as_method(); 30.19 - VERIFY_OOP(method); 30.20 + if (VerifyOops) method->verify(); 30.21 30.22 if (cache->has_appendix()) { 30.23 ConstantPool* constants = METHOD->constants(); 30.24 @@ -2394,8 +2394,7 @@ 30.25 } 30.26 30.27 Method* method = cache->f1_as_method(); 30.28 - 30.29 - VERIFY_OOP(method); 30.30 + if (VerifyOops) method->verify(); 30.31 30.32 if (cache->has_appendix()) { 30.33 ConstantPool* constants = METHOD->constants();
31.1 --- a/src/share/vm/memory/allocation.cpp Wed Jun 26 16:06:38 2013 +0200 31.2 +++ b/src/share/vm/memory/allocation.cpp Wed Jul 03 11:50:29 2013 -0700 31.3 @@ -71,13 +71,6 @@ 31.4 return MetaspaceShared::is_in_shared_space(this); 31.5 } 31.6 31.7 -bool MetaspaceObj::is_metadata() const { 31.8 - // GC Verify checks use this in guarantees. 31.9 - // TODO: either replace them with is_metaspace_object() or remove them. 31.10 - // is_metaspace_object() is slower than this test. This test doesn't 31.11 - // seem very useful for metaspace objects anymore though. 31.12 - return !Universe::heap()->is_in_reserved(this); 31.13 -} 31.14 31.15 bool MetaspaceObj::is_metaspace_object() const { 31.16 return Metaspace::contains((void*)this);
32.1 --- a/src/share/vm/memory/allocation.hpp Wed Jun 26 16:06:38 2013 +0200 32.2 +++ b/src/share/vm/memory/allocation.hpp Wed Jul 03 11:50:29 2013 -0700 32.3 @@ -264,7 +264,6 @@ 32.4 32.5 class MetaspaceObj { 32.6 public: 32.7 - bool is_metadata() const; 32.8 bool is_metaspace_object() const; // more specific test but slower 32.9 bool is_shared() const; 32.10 void print_address_on(outputStream* st) const; // nonvirtual address printing
33.1 --- a/src/share/vm/memory/heapInspection.cpp Wed Jun 26 16:06:38 2013 +0200 33.2 +++ b/src/share/vm/memory/heapInspection.cpp Wed Jul 03 11:50:29 2013 -0700 33.3 @@ -157,7 +157,6 @@ 33.4 } 33.5 33.6 uint KlassInfoTable::hash(const Klass* p) { 33.7 - assert(p->is_metadata(), "all klasses are metadata"); 33.8 return (uint)(((uintptr_t)p - (uintptr_t)_ref) >> 2); 33.9 } 33.10
34.1 --- a/src/share/vm/memory/metaspace.cpp Wed Jun 26 16:06:38 2013 +0200 34.2 +++ b/src/share/vm/memory/metaspace.cpp Wed Jul 03 11:50:29 2013 -0700 34.3 @@ -1556,19 +1556,7 @@ 34.4 34.5 // ChunkManager methods 34.6 34.7 -// Verification of _free_chunks_total and _free_chunks_count does not 34.8 -// work with the CMS collector because its use of additional locks 34.9 -// complicate the mutex deadlock detection but it can still be useful 34.10 -// for detecting errors in the chunk accounting with other collectors. 34.11 - 34.12 size_t ChunkManager::free_chunks_total() { 34.13 -#ifdef ASSERT 34.14 - if (!UseConcMarkSweepGC && !SpaceManager::expand_lock()->is_locked()) { 34.15 - MutexLockerEx cl(SpaceManager::expand_lock(), 34.16 - Mutex::_no_safepoint_check_flag); 34.17 - slow_locked_verify_free_chunks_total(); 34.18 - } 34.19 -#endif 34.20 return _free_chunks_total; 34.21 } 34.22 34.23 @@ -2608,14 +2596,14 @@ 34.24 "->" SIZE_FORMAT 34.25 "(" SIZE_FORMAT ")", 34.26 prev_metadata_used, 34.27 - allocated_capacity_bytes(), 34.28 + allocated_used_bytes(), 34.29 reserved_in_bytes()); 34.30 } else { 34.31 gclog_or_tty->print(" " SIZE_FORMAT "K" 34.32 "->" SIZE_FORMAT "K" 34.33 "(" SIZE_FORMAT "K)", 34.34 prev_metadata_used / K, 34.35 - allocated_capacity_bytes() / K, 34.36 + allocated_used_bytes() / K, 34.37 reserved_in_bytes()/ K); 34.38 } 34.39
35.1 --- a/src/share/vm/memory/universe.cpp Wed Jun 26 16:06:38 2013 +0200 35.2 +++ b/src/share/vm/memory/universe.cpp Wed Jul 03 11:50:29 2013 -0700 35.3 @@ -1147,6 +1147,7 @@ 35.4 35.5 // Initialize performance counters for metaspaces 35.6 MetaspaceCounters::initialize_performance_counters(); 35.7 + MemoryService::add_metaspace_memory_pools(); 35.8 35.9 GC_locker::unlock(); // allow gc after bootstrapping 35.10
36.1 --- a/src/share/vm/oops/arrayKlass.cpp Wed Jun 26 16:06:38 2013 +0200 36.2 +++ b/src/share/vm/oops/arrayKlass.cpp Wed Jul 03 11:50:29 2013 -0700 36.3 @@ -221,8 +221,8 @@ 36.4 36.5 // Verification 36.6 36.7 -void ArrayKlass::verify_on(outputStream* st) { 36.8 - Klass::verify_on(st); 36.9 +void ArrayKlass::verify_on(outputStream* st, bool check_dictionary) { 36.10 + Klass::verify_on(st, check_dictionary); 36.11 36.12 if (component_mirror() != NULL) { 36.13 guarantee(component_mirror()->klass() != NULL, "should have a class");
37.1 --- a/src/share/vm/oops/arrayKlass.hpp Wed Jun 26 16:06:38 2013 +0200 37.2 +++ b/src/share/vm/oops/arrayKlass.hpp Wed Jul 03 11:50:29 2013 -0700 37.3 @@ -152,7 +152,7 @@ 37.4 void oop_print_on(oop obj, outputStream* st); 37.5 37.6 // Verification 37.7 - void verify_on(outputStream* st); 37.8 + void verify_on(outputStream* st, bool check_dictionary); 37.9 37.10 void oop_verify_on(oop obj, outputStream* st); 37.11 };
38.1 --- a/src/share/vm/oops/compiledICHolder.cpp Wed Jun 26 16:06:38 2013 +0200 38.2 +++ b/src/share/vm/oops/compiledICHolder.cpp Wed Jul 03 11:50:29 2013 -0700 38.3 @@ -48,8 +48,6 @@ 38.4 // Verification 38.5 38.6 void CompiledICHolder::verify_on(outputStream* st) { 38.7 - guarantee(holder_method()->is_metadata(), "should be in metaspace"); 38.8 guarantee(holder_method()->is_method(), "should be method"); 38.9 - guarantee(holder_klass()->is_metadata(), "should be in metaspace"); 38.10 guarantee(holder_klass()->is_klass(), "should be klass"); 38.11 }
39.1 --- a/src/share/vm/oops/constMethod.cpp Wed Jun 26 16:06:38 2013 +0200 39.2 +++ b/src/share/vm/oops/constMethod.cpp Wed Jul 03 11:50:29 2013 -0700 39.3 @@ -440,7 +440,6 @@ 39.4 39.5 void ConstMethod::verify_on(outputStream* st) { 39.6 guarantee(is_constMethod(), "object must be constMethod"); 39.7 - guarantee(is_metadata(), err_msg("Should be metadata " PTR_FORMAT, this)); 39.8 39.9 // Verification can occur during oop construction before the method or 39.10 // other fields have been initialized.
40.1 --- a/src/share/vm/oops/constantPool.cpp Wed Jun 26 16:06:38 2013 +0200 40.2 +++ b/src/share/vm/oops/constantPool.cpp Wed Jul 03 11:50:29 2013 -0700 40.3 @@ -2095,12 +2095,10 @@ 40.4 CPSlot entry = slot_at(i); 40.5 if (tag.is_klass()) { 40.6 if (entry.is_resolved()) { 40.7 - guarantee(entry.get_klass()->is_metadata(), "should be metadata"); 40.8 guarantee(entry.get_klass()->is_klass(), "should be klass"); 40.9 } 40.10 } else if (tag.is_unresolved_klass()) { 40.11 if (entry.is_resolved()) { 40.12 - guarantee(entry.get_klass()->is_metadata(), "should be metadata"); 40.13 guarantee(entry.get_klass()->is_klass(), "should be klass"); 40.14 } 40.15 } else if (tag.is_symbol()) { 40.16 @@ -2112,13 +2110,11 @@ 40.17 if (cache() != NULL) { 40.18 // Note: cache() can be NULL before a class is completely setup or 40.19 // in temporary constant pools used during constant pool merging 40.20 - guarantee(cache()->is_metadata(), "should be metadata"); 40.21 guarantee(cache()->is_constantPoolCache(), "should be constant pool cache"); 40.22 } 40.23 if (pool_holder() != NULL) { 40.24 // Note: pool_holder() can be NULL in temporary constant pools 40.25 // used during constant pool merging 40.26 - guarantee(pool_holder()->is_metadata(), "should be metadata"); 40.27 guarantee(pool_holder()->is_klass(), "should be klass"); 40.28 } 40.29 }
41.1 --- a/src/share/vm/oops/instanceKlass.cpp Wed Jun 26 16:06:38 2013 +0200 41.2 +++ b/src/share/vm/oops/instanceKlass.cpp Wed Jul 03 11:50:29 2013 -0700 41.3 @@ -3088,27 +3088,26 @@ 41.4 virtual void do_oop(narrowOop* p) { VerifyFieldClosure::do_oop_work(p); } 41.5 }; 41.6 41.7 -void InstanceKlass::verify_on(outputStream* st) { 41.8 - Klass::verify_on(st); 41.9 - Thread *thread = Thread::current(); 41.10 - 41.11 +void InstanceKlass::verify_on(outputStream* st, bool check_dictionary) { 41.12 #ifndef PRODUCT 41.13 - // Avoid redundant verifies 41.14 + // Avoid redundant verifies, this really should be in product. 41.15 if (_verify_count == Universe::verify_count()) return; 41.16 _verify_count = Universe::verify_count(); 41.17 #endif 41.18 - // Verify that klass is present in SystemDictionary 41.19 - if (is_loaded() && !is_anonymous()) { 41.20 + 41.21 + // Verify Klass 41.22 + Klass::verify_on(st, check_dictionary); 41.23 + 41.24 + // Verify that klass is present in SystemDictionary if not already 41.25 + // verifying the SystemDictionary. 41.26 + if (is_loaded() && !is_anonymous() && check_dictionary) { 41.27 Symbol* h_name = name(); 41.28 SystemDictionary::verify_obj_klass_present(h_name, class_loader_data()); 41.29 } 41.30 41.31 - // Verify static fields 41.32 - VerifyFieldClosure blk; 41.33 - 41.34 // Verify vtables 41.35 if (is_linked()) { 41.36 - ResourceMark rm(thread); 41.37 + ResourceMark rm; 41.38 // $$$ This used to be done only for m/s collections. Doing it 41.39 // always seemed a valid generalization. (DLD -- 6/00) 41.40 vtable()->verify(st); 41.41 @@ -3116,7 +3115,6 @@ 41.42 41.43 // Verify first subklass 41.44 if (subklass_oop() != NULL) { 41.45 - guarantee(subklass_oop()->is_metadata(), "should be in metaspace"); 41.46 guarantee(subklass_oop()->is_klass(), "should be klass"); 41.47 } 41.48 41.49 @@ -3128,7 +3126,6 @@ 41.50 fatal(err_msg("subclass points to itself " PTR_FORMAT, sib)); 41.51 } 41.52 41.53 - guarantee(sib->is_metadata(), "should be in metaspace"); 41.54 guarantee(sib->is_klass(), "should be klass"); 41.55 guarantee(sib->super() == super, "siblings should have same superklass"); 41.56 } 41.57 @@ -3164,7 +3161,6 @@ 41.58 if (methods() != NULL) { 41.59 Array<Method*>* methods = this->methods(); 41.60 for (int j = 0; j < methods->length(); j++) { 41.61 - guarantee(methods->at(j)->is_metadata(), "should be in metaspace"); 41.62 guarantee(methods->at(j)->is_method(), "non-method in methods array"); 41.63 } 41.64 for (int j = 0; j < methods->length() - 1; j++) { 41.65 @@ -3202,16 +3198,13 @@ 41.66 41.67 // Verify other fields 41.68 if (array_klasses() != NULL) { 41.69 - guarantee(array_klasses()->is_metadata(), "should be in metaspace"); 41.70 guarantee(array_klasses()->is_klass(), "should be klass"); 41.71 } 41.72 if (constants() != NULL) { 41.73 - guarantee(constants()->is_metadata(), "should be in metaspace"); 41.74 guarantee(constants()->is_constantPool(), "should be constant pool"); 41.75 } 41.76 const Klass* host = host_klass(); 41.77 if (host != NULL) { 41.78 - guarantee(host->is_metadata(), "should be in metaspace"); 41.79 guarantee(host->is_klass(), "should be klass"); 41.80 } 41.81 }
42.1 --- a/src/share/vm/oops/instanceKlass.hpp Wed Jun 26 16:06:38 2013 +0200 42.2 +++ b/src/share/vm/oops/instanceKlass.hpp Wed Jul 03 11:50:29 2013 -0700 42.3 @@ -1050,7 +1050,7 @@ 42.4 const char* internal_name() const; 42.5 42.6 // Verification 42.7 - void verify_on(outputStream* st); 42.8 + void verify_on(outputStream* st, bool check_dictionary); 42.9 42.10 void oop_verify_on(oop obj, outputStream* st); 42.11 };
43.1 --- a/src/share/vm/oops/klass.cpp Wed Jun 26 16:06:38 2013 +0200 43.2 +++ b/src/share/vm/oops/klass.cpp Wed Jul 03 11:50:29 2013 -0700 43.3 @@ -377,7 +377,6 @@ 43.4 } 43.5 43.6 bool Klass::is_loader_alive(BoolObjectClosure* is_alive) { 43.7 - assert(is_metadata(), "p is not meta-data"); 43.8 assert(ClassLoaderDataGraph::contains((address)this), "is in the metaspace"); 43.9 43.10 #ifdef ASSERT 43.11 @@ -648,27 +647,24 @@ 43.12 43.13 // Verification 43.14 43.15 -void Klass::verify_on(outputStream* st) { 43.16 - guarantee(!Universe::heap()->is_in_reserved(this), "Shouldn't be"); 43.17 - guarantee(this->is_metadata(), "should be in metaspace"); 43.18 +void Klass::verify_on(outputStream* st, bool check_dictionary) { 43.19 43.20 + // This can be expensive, but it is worth checking that this klass is actually 43.21 + // in the CLD graph but not in production. 43.22 assert(ClassLoaderDataGraph::contains((address)this), "Should be"); 43.23 43.24 guarantee(this->is_klass(),"should be klass"); 43.25 43.26 if (super() != NULL) { 43.27 - guarantee(super()->is_metadata(), "should be in metaspace"); 43.28 guarantee(super()->is_klass(), "should be klass"); 43.29 } 43.30 if (secondary_super_cache() != NULL) { 43.31 Klass* ko = secondary_super_cache(); 43.32 - guarantee(ko->is_metadata(), "should be in metaspace"); 43.33 guarantee(ko->is_klass(), "should be klass"); 43.34 } 43.35 for ( uint i = 0; i < primary_super_limit(); i++ ) { 43.36 Klass* ko = _primary_supers[i]; 43.37 if (ko != NULL) { 43.38 - guarantee(ko->is_metadata(), "should be in metaspace"); 43.39 guarantee(ko->is_klass(), "should be klass"); 43.40 } 43.41 } 43.42 @@ -680,7 +676,6 @@ 43.43 43.44 void Klass::oop_verify_on(oop obj, outputStream* st) { 43.45 guarantee(obj->is_oop(), "should be oop"); 43.46 - guarantee(obj->klass()->is_metadata(), "should not be in Java heap"); 43.47 guarantee(obj->klass()->is_klass(), "klass field is not a klass"); 43.48 } 43.49
44.1 --- a/src/share/vm/oops/klass.hpp Wed Jun 26 16:06:38 2013 +0200 44.2 +++ b/src/share/vm/oops/klass.hpp Wed Jul 03 11:50:29 2013 -0700 44.3 @@ -703,8 +703,8 @@ 44.4 virtual const char* internal_name() const = 0; 44.5 44.6 // Verification 44.7 - virtual void verify_on(outputStream* st); 44.8 - void verify() { verify_on(tty); } 44.9 + virtual void verify_on(outputStream* st, bool check_dictionary); 44.10 + void verify(bool check_dictionary = true) { verify_on(tty, check_dictionary); } 44.11 44.12 #ifndef PRODUCT 44.13 void verify_vtable_index(int index);
45.1 --- a/src/share/vm/oops/method.cpp Wed Jun 26 16:06:38 2013 +0200 45.2 +++ b/src/share/vm/oops/method.cpp Wed Jul 03 11:50:29 2013 -0700 45.3 @@ -1969,14 +1969,9 @@ 45.4 45.5 void Method::verify_on(outputStream* st) { 45.6 guarantee(is_method(), "object must be method"); 45.7 - guarantee(is_metadata(), "should be metadata"); 45.8 guarantee(constants()->is_constantPool(), "should be constant pool"); 45.9 - guarantee(constants()->is_metadata(), "should be metadata"); 45.10 guarantee(constMethod()->is_constMethod(), "should be ConstMethod*"); 45.11 - guarantee(constMethod()->is_metadata(), "should be metadata"); 45.12 MethodData* md = method_data(); 45.13 guarantee(md == NULL || 45.14 - md->is_metadata(), "should be metadata"); 45.15 - guarantee(md == NULL || 45.16 md->is_methodData(), "should be method data"); 45.17 }
46.1 --- a/src/share/vm/oops/objArrayKlass.cpp Wed Jun 26 16:06:38 2013 +0200 46.2 +++ b/src/share/vm/oops/objArrayKlass.cpp Wed Jul 03 11:50:29 2013 -0700 46.3 @@ -676,11 +676,9 @@ 46.4 46.5 // Verification 46.6 46.7 -void ObjArrayKlass::verify_on(outputStream* st) { 46.8 - ArrayKlass::verify_on(st); 46.9 - guarantee(element_klass()->is_metadata(), "should be in metaspace"); 46.10 +void ObjArrayKlass::verify_on(outputStream* st, bool check_dictionary) { 46.11 + ArrayKlass::verify_on(st, check_dictionary); 46.12 guarantee(element_klass()->is_klass(), "should be klass"); 46.13 - guarantee(bottom_klass()->is_metadata(), "should be in metaspace"); 46.14 guarantee(bottom_klass()->is_klass(), "should be klass"); 46.15 Klass* bk = bottom_klass(); 46.16 guarantee(bk->oop_is_instance() || bk->oop_is_typeArray(), "invalid bottom klass");
47.1 --- a/src/share/vm/oops/objArrayKlass.hpp Wed Jun 26 16:06:38 2013 +0200 47.2 +++ b/src/share/vm/oops/objArrayKlass.hpp Wed Jul 03 11:50:29 2013 -0700 47.3 @@ -151,7 +151,7 @@ 47.4 const char* internal_name() const; 47.5 47.6 // Verification 47.7 - void verify_on(outputStream* st); 47.8 + void verify_on(outputStream* st, bool check_dictionary); 47.9 47.10 void oop_verify_on(oop obj, outputStream* st); 47.11 };
48.1 --- a/src/share/vm/oops/symbol.cpp Wed Jun 26 16:06:38 2013 +0200 48.2 +++ b/src/share/vm/oops/symbol.cpp Wed Jul 03 11:50:29 2013 -0700 48.3 @@ -32,7 +32,9 @@ 48.4 #include "memory/allocation.inline.hpp" 48.5 #include "memory/resourceArea.hpp" 48.6 48.7 -Symbol::Symbol(const u1* name, int length, int refcount) : _refcount(refcount), _length(length) { 48.8 +Symbol::Symbol(const u1* name, int length, int refcount) { 48.9 + _refcount = refcount; 48.10 + _length = length; 48.11 _identity_hash = os::random(); 48.12 for (int i = 0; i < _length; i++) { 48.13 byte_at_put(i, name[i]);
49.1 --- a/src/share/vm/oops/symbol.hpp Wed Jun 26 16:06:38 2013 +0200 49.2 +++ b/src/share/vm/oops/symbol.hpp Wed Jul 03 11:50:29 2013 -0700 49.3 @@ -27,6 +27,7 @@ 49.4 49.5 #include "utilities/utf8.hpp" 49.6 #include "memory/allocation.hpp" 49.7 +#include "runtime/atomic.hpp" 49.8 49.9 // A Symbol is a canonicalized string. 49.10 // All Symbols reside in global SymbolTable and are reference counted. 49.11 @@ -101,14 +102,22 @@ 49.12 // type without virtual functions. 49.13 class ClassLoaderData; 49.14 49.15 -class Symbol : public MetaspaceObj { 49.16 +// We separate the fields in SymbolBase from Symbol::_body so that 49.17 +// Symbol::size(int) can correctly calculate the space needed. 49.18 +class SymbolBase : public MetaspaceObj { 49.19 + public: 49.20 + ATOMIC_SHORT_PAIR( 49.21 + volatile short _refcount, // needs atomic operation 49.22 + unsigned short _length // number of UTF8 characters in the symbol (does not need atomic op) 49.23 + ); 49.24 + int _identity_hash; 49.25 +}; 49.26 + 49.27 +class Symbol : private SymbolBase { 49.28 friend class VMStructs; 49.29 friend class SymbolTable; 49.30 friend class MoveSymbols; 49.31 private: 49.32 - volatile int _refcount; 49.33 - int _identity_hash; 49.34 - unsigned short _length; // number of UTF8 characters in the symbol 49.35 jbyte _body[1]; 49.36 49.37 enum { 49.38 @@ -117,7 +126,7 @@ 49.39 }; 49.40 49.41 static int size(int length) { 49.42 - size_t sz = heap_word_size(sizeof(Symbol) + (length > 0 ? length - 1 : 0)); 49.43 + size_t sz = heap_word_size(sizeof(SymbolBase) + (length > 0 ? length : 0)); 49.44 return align_object_size(sz); 49.45 } 49.46
50.1 --- a/src/share/vm/opto/memnode.cpp Wed Jun 26 16:06:38 2013 +0200 50.2 +++ b/src/share/vm/opto/memnode.cpp Wed Jul 03 11:50:29 2013 -0700 50.3 @@ -2943,11 +2943,19 @@ 50.4 Node* my_mem = in(MemBarNode::Precedent); 50.5 // The MembarAquire may keep an unused LoadNode alive through the Precedent edge 50.6 if ((my_mem != NULL) && (opc == Op_MemBarAcquire) && (my_mem->outcnt() == 1)) { 50.7 - assert(my_mem->unique_out() == this, "sanity"); 50.8 - phase->hash_delete(this); 50.9 - del_req(Precedent); 50.10 - phase->is_IterGVN()->_worklist.push(my_mem); // remove dead node later 50.11 - my_mem = NULL; 50.12 + // if the Precedent is a decodeN and its input (a Load) is used at more than one place, 50.13 + // replace this Precedent (decodeN) with the Load instead. 50.14 + if ((my_mem->Opcode() == Op_DecodeN) && (my_mem->in(1)->outcnt() > 1)) { 50.15 + Node* load_node = my_mem->in(1); 50.16 + set_req(MemBarNode::Precedent, load_node); 50.17 + phase->is_IterGVN()->_worklist.push(my_mem); 50.18 + my_mem = load_node; 50.19 + } else { 50.20 + assert(my_mem->unique_out() == this, "sanity"); 50.21 + del_req(Precedent); 50.22 + phase->is_IterGVN()->_worklist.push(my_mem); // remove dead node later 50.23 + my_mem = NULL; 50.24 + } 50.25 } 50.26 if (my_mem != NULL && my_mem->is_Mem()) { 50.27 const TypeOopPtr* t_oop = my_mem->in(MemNode::Address)->bottom_type()->isa_oopptr();
51.1 --- a/src/share/vm/runtime/atomic.cpp Wed Jun 26 16:06:38 2013 +0200 51.2 +++ b/src/share/vm/runtime/atomic.cpp Wed Jul 03 11:50:29 2013 -0700 51.3 @@ -80,3 +80,32 @@ 51.4 } 51.5 return old; 51.6 } 51.7 + 51.8 +void Atomic::inc(volatile short* dest) { 51.9 + // Most platforms do not support atomic increment on a 2-byte value. However, 51.10 + // if the value occupies the most significant 16 bits of an aligned 32-bit 51.11 + // word, then we can do this with an atomic add of 0x10000 to the 32-bit word. 51.12 + // 51.13 + // The least significant parts of this 32-bit word will never be affected, even 51.14 + // in case of overflow/underflow. 51.15 + // 51.16 + // Use the ATOMIC_SHORT_PAIR macro to get the desired alignment. 51.17 +#ifdef VM_LITTLE_ENDIAN 51.18 + assert((intx(dest) & 0x03) == 0x02, "wrong alignment"); 51.19 + (void)Atomic::add(0x10000, (volatile int*)(dest-1)); 51.20 +#else 51.21 + assert((intx(dest) & 0x03) == 0x00, "wrong alignment"); 51.22 + (void)Atomic::add(0x10000, (volatile int*)(dest)); 51.23 +#endif 51.24 +} 51.25 + 51.26 +void Atomic::dec(volatile short* dest) { 51.27 +#ifdef VM_LITTLE_ENDIAN 51.28 + assert((intx(dest) & 0x03) == 0x02, "wrong alignment"); 51.29 + (void)Atomic::add(-0x10000, (volatile int*)(dest-1)); 51.30 +#else 51.31 + assert((intx(dest) & 0x03) == 0x00, "wrong alignment"); 51.32 + (void)Atomic::add(-0x10000, (volatile int*)(dest)); 51.33 +#endif 51.34 +} 51.35 +
52.1 --- a/src/share/vm/runtime/atomic.hpp Wed Jun 26 16:06:38 2013 +0200 52.2 +++ b/src/share/vm/runtime/atomic.hpp Wed Jul 03 11:50:29 2013 -0700 52.3 @@ -64,11 +64,13 @@ 52.4 52.5 // Atomically increment location 52.6 inline static void inc (volatile jint* dest); 52.7 + static void inc (volatile jshort* dest); 52.8 inline static void inc_ptr(volatile intptr_t* dest); 52.9 inline static void inc_ptr(volatile void* dest); 52.10 52.11 // Atomically decrement a location 52.12 inline static void dec (volatile jint* dest); 52.13 + static void dec (volatile jshort* dest); 52.14 inline static void dec_ptr(volatile intptr_t* dest); 52.15 inline static void dec_ptr(volatile void* dest); 52.16 52.17 @@ -95,4 +97,24 @@ 52.18 inline static void* cmpxchg_ptr(void* exchange_value, volatile void* dest, void* compare_value); 52.19 }; 52.20 52.21 +// To use Atomic::inc(jshort* dest) and Atomic::dec(jshort* dest), the address must be specially 52.22 +// aligned, such that (*dest) occupies the upper 16 bits of an aligned 32-bit word. The best way to 52.23 +// achieve is to place your short value next to another short value, which doesn't need atomic ops. 52.24 +// 52.25 +// Example 52.26 +// ATOMIC_SHORT_PAIR( 52.27 +// volatile short _refcount, // needs atomic operation 52.28 +// unsigned short _length // number of UTF8 characters in the symbol (does not need atomic op) 52.29 +// ); 52.30 + 52.31 +#ifdef VM_LITTLE_ENDIAN 52.32 +#define ATOMIC_SHORT_PAIR(atomic_decl, non_atomic_decl) \ 52.33 + non_atomic_decl; \ 52.34 + atomic_decl 52.35 +#else 52.36 +#define ATOMIC_SHORT_PAIR(atomic_decl, non_atomic_decl) \ 52.37 + atomic_decl ; \ 52.38 + non_atomic_decl 52.39 +#endif 52.40 + 52.41 #endif // SHARE_VM_RUNTIME_ATOMIC_HPP
53.1 --- a/src/share/vm/runtime/frame.cpp Wed Jun 26 16:06:38 2013 +0200 53.2 +++ b/src/share/vm/runtime/frame.cpp Wed Jul 03 11:50:29 2013 -0700 53.3 @@ -387,7 +387,6 @@ 53.4 Method* frame::interpreter_frame_method() const { 53.5 assert(is_interpreted_frame(), "interpreted frame expected"); 53.6 Method* m = *interpreter_frame_method_addr(); 53.7 - assert(m->is_metadata(), "bad Method* in interpreter frame"); 53.8 assert(m->is_method(), "not a Method*"); 53.9 return m; 53.10 } 53.11 @@ -713,7 +712,8 @@ 53.12 Method* m = ((nmethod *)_cb)->method(); 53.13 if (m != NULL) { 53.14 m->name_and_sig_as_C_string(buf, buflen); 53.15 - st->print("J %s", buf); 53.16 + st->print("J %s @ " PTR_FORMAT " [" PTR_FORMAT "+" SIZE_FORMAT "]", 53.17 + buf, _pc, _cb->code_begin(), _pc - _cb->code_begin()); 53.18 } else { 53.19 st->print("J " PTR_FORMAT, pc()); 53.20 }
54.1 --- a/src/share/vm/runtime/globals.cpp Wed Jun 26 16:06:38 2013 +0200 54.2 +++ b/src/share/vm/runtime/globals.cpp Wed Jul 03 11:50:29 2013 -0700 54.3 @@ -73,12 +73,6 @@ 54.4 strcmp(kind, "{C2 diagnostic}") == 0 || 54.5 strcmp(kind, "{ARCH diagnostic}") == 0 || 54.6 strcmp(kind, "{Shark diagnostic}") == 0) { 54.7 - if (strcmp(name, "EnableInvokeDynamic") == 0 && UnlockExperimentalVMOptions && !UnlockDiagnosticVMOptions) { 54.8 - // transitional logic to allow tests to run until they are changed 54.9 - static int warned; 54.10 - if (++warned == 1) warning("Use -XX:+UnlockDiagnosticVMOptions before EnableInvokeDynamic flag"); 54.11 - return true; 54.12 - } 54.13 return UnlockDiagnosticVMOptions; 54.14 } else if (strcmp(kind, "{experimental}") == 0 || 54.15 strcmp(kind, "{C2 experimental}") == 0 ||
55.1 --- a/src/share/vm/runtime/sharedRuntime.cpp Wed Jun 26 16:06:38 2013 +0200 55.2 +++ b/src/share/vm/runtime/sharedRuntime.cpp Wed Jul 03 11:50:29 2013 -0700 55.3 @@ -813,8 +813,11 @@ 55.4 // 3. Implict null exception in nmethod 55.5 55.6 if (!cb->is_nmethod()) { 55.7 - guarantee(cb->is_adapter_blob() || cb->is_method_handles_adapter_blob(), 55.8 - "exception happened outside interpreter, nmethods and vtable stubs (1)"); 55.9 + bool is_in_blob = cb->is_adapter_blob() || cb->is_method_handles_adapter_blob(); 55.10 + if (!is_in_blob) { 55.11 + cb->print(); 55.12 + fatal(err_msg("exception happened outside interpreter, nmethods and vtable stubs at pc " INTPTR_FORMAT, pc)); 55.13 + } 55.14 Events::log_exception(thread, "NullPointerException in code blob at " INTPTR_FORMAT, pc); 55.15 // There is no handler here, so we will simply unwind. 55.16 return StubRoutines::throw_NullPointerException_at_call_entry();
56.1 --- a/src/share/vm/runtime/thread.cpp Wed Jun 26 16:06:38 2013 +0200 56.2 +++ b/src/share/vm/runtime/thread.cpp Wed Jul 03 11:50:29 2013 -0700 56.3 @@ -220,7 +220,7 @@ 56.4 set_osthread(NULL); 56.5 set_resource_area(new (mtThread)ResourceArea()); 56.6 set_handle_area(new (mtThread) HandleArea(NULL)); 56.7 - set_metadata_handles(new (ResourceObj::C_HEAP, mtClass) GrowableArray<Metadata*>(300, true)); 56.8 + set_metadata_handles(new (ResourceObj::C_HEAP, mtClass) GrowableArray<Metadata*>(30, true)); 56.9 set_active_handles(NULL); 56.10 set_free_handle_block(NULL); 56.11 set_last_handle_mark(NULL);
57.1 --- a/src/share/vm/runtime/vmStructs.cpp Wed Jun 26 16:06:38 2013 +0200 57.2 +++ b/src/share/vm/runtime/vmStructs.cpp Wed Jul 03 11:50:29 2013 -0700 57.3 @@ -382,7 +382,7 @@ 57.4 nonstatic_field(ConstMethod, _size_of_parameters, u2) \ 57.5 nonstatic_field(ObjArrayKlass, _element_klass, Klass*) \ 57.6 nonstatic_field(ObjArrayKlass, _bottom_klass, Klass*) \ 57.7 - volatile_nonstatic_field(Symbol, _refcount, int) \ 57.8 + volatile_nonstatic_field(Symbol, _refcount, short) \ 57.9 nonstatic_field(Symbol, _identity_hash, int) \ 57.10 nonstatic_field(Symbol, _length, unsigned short) \ 57.11 unchecked_nonstatic_field(Symbol, _body, sizeof(jbyte)) /* NOTE: no type */ \
58.1 --- a/src/share/vm/services/management.cpp Wed Jun 26 16:06:38 2013 +0200 58.2 +++ b/src/share/vm/services/management.cpp Wed Jul 03 11:50:29 2013 -0700 58.3 @@ -894,12 +894,6 @@ 58.4 } 58.5 } 58.6 58.7 - // In our current implementation, we make sure that all non-heap 58.8 - // pools have defined init and max sizes. Heap pools do not matter, 58.9 - // as we never use total_init and total_max for them. 58.10 - assert(heap || !has_undefined_init_size, "Undefined init size"); 58.11 - assert(heap || !has_undefined_max_size, "Undefined max size"); 58.12 - 58.13 MemoryUsage usage((heap ? InitialHeapSize : total_init), 58.14 total_used, 58.15 total_committed,
59.1 --- a/src/share/vm/services/memoryManager.cpp Wed Jun 26 16:06:38 2013 +0200 59.2 +++ b/src/share/vm/services/memoryManager.cpp Wed Jul 03 11:50:29 2013 -0700 59.3 @@ -61,6 +61,10 @@ 59.4 return (MemoryManager*) new CodeCacheMemoryManager(); 59.5 } 59.6 59.7 +MemoryManager* MemoryManager::get_metaspace_memory_manager() { 59.8 + return (MemoryManager*) new MetaspaceMemoryManager(); 59.9 +} 59.10 + 59.11 GCMemoryManager* MemoryManager::get_copy_memory_manager() { 59.12 return (GCMemoryManager*) new CopyMemoryManager(); 59.13 }
60.1 --- a/src/share/vm/services/memoryManager.hpp Wed Jun 26 16:06:38 2013 +0200 60.2 +++ b/src/share/vm/services/memoryManager.hpp Wed Jul 03 11:50:29 2013 -0700 60.3 @@ -56,6 +56,7 @@ 60.4 enum Name { 60.5 Abstract, 60.6 CodeCache, 60.7 + Metaspace, 60.8 Copy, 60.9 MarkSweepCompact, 60.10 ParNew, 60.11 @@ -88,6 +89,7 @@ 60.12 60.13 // Static factory methods to get a memory manager of a specific type 60.14 static MemoryManager* get_code_cache_memory_manager(); 60.15 + static MemoryManager* get_metaspace_memory_manager(); 60.16 static GCMemoryManager* get_copy_memory_manager(); 60.17 static GCMemoryManager* get_msc_memory_manager(); 60.18 static GCMemoryManager* get_parnew_memory_manager(); 60.19 @@ -108,6 +110,14 @@ 60.20 const char* name() { return "CodeCacheManager"; } 60.21 }; 60.22 60.23 +class MetaspaceMemoryManager : public MemoryManager { 60.24 +public: 60.25 + MetaspaceMemoryManager() : MemoryManager() {} 60.26 + 60.27 + MemoryManager::Name kind() { return MemoryManager::Metaspace; } 60.28 + const char *name() { return "Metaspace Manager"; } 60.29 +}; 60.30 + 60.31 class GCStatInfo : public ResourceObj { 60.32 private: 60.33 size_t _index;
61.1 --- a/src/share/vm/services/memoryPool.cpp Wed Jun 26 16:06:38 2013 +0200 61.2 +++ b/src/share/vm/services/memoryPool.cpp Wed Jul 03 11:50:29 2013 -0700 61.3 @@ -25,6 +25,7 @@ 61.4 #include "precompiled.hpp" 61.5 #include "classfile/systemDictionary.hpp" 61.6 #include "classfile/vmSymbols.hpp" 61.7 +#include "memory/metaspace.hpp" 61.8 #include "oops/oop.inline.hpp" 61.9 #include "runtime/handles.inline.hpp" 61.10 #include "runtime/javaCalls.hpp" 61.11 @@ -33,6 +34,7 @@ 61.12 #include "services/memoryManager.hpp" 61.13 #include "services/memoryPool.hpp" 61.14 #include "utilities/macros.hpp" 61.15 +#include "utilities/globalDefinitions.hpp" 61.16 61.17 MemoryPool::MemoryPool(const char* name, 61.18 PoolType type, 61.19 @@ -256,3 +258,39 @@ 61.20 61.21 return MemoryUsage(initial_size(), used, committed, maxSize); 61.22 } 61.23 + 61.24 +MetaspacePool::MetaspacePool() : 61.25 + MemoryPool("Metaspace", NonHeap, capacity_in_bytes(), calculate_max_size(), true, false) { } 61.26 + 61.27 +MemoryUsage MetaspacePool::get_memory_usage() { 61.28 + size_t committed = align_size_down_(capacity_in_bytes(), os::vm_page_size()); 61.29 + return MemoryUsage(initial_size(), used_in_bytes(), committed, max_size()); 61.30 +} 61.31 + 61.32 +size_t MetaspacePool::used_in_bytes() { 61.33 + return MetaspaceAux::allocated_used_bytes(Metaspace::NonClassType); 61.34 +} 61.35 + 61.36 +size_t MetaspacePool::capacity_in_bytes() const { 61.37 + return MetaspaceAux::allocated_capacity_bytes(Metaspace::NonClassType); 61.38 +} 61.39 + 61.40 +size_t MetaspacePool::calculate_max_size() const { 61.41 + return FLAG_IS_CMDLINE(MaxMetaspaceSize) ? MaxMetaspaceSize : max_uintx; 61.42 +} 61.43 + 61.44 +CompressedKlassSpacePool::CompressedKlassSpacePool() : 61.45 + MemoryPool("Compressed Class Space", NonHeap, capacity_in_bytes(), ClassMetaspaceSize, true, false) { } 61.46 + 61.47 +size_t CompressedKlassSpacePool::used_in_bytes() { 61.48 + return MetaspaceAux::allocated_used_bytes(Metaspace::ClassType); 61.49 +} 61.50 + 61.51 +size_t CompressedKlassSpacePool::capacity_in_bytes() const { 61.52 + return MetaspaceAux::allocated_capacity_bytes(Metaspace::ClassType); 61.53 +} 61.54 + 61.55 +MemoryUsage CompressedKlassSpacePool::get_memory_usage() { 61.56 + size_t committed = align_size_down_(capacity_in_bytes(), os::vm_page_size()); 61.57 + return MemoryUsage(initial_size(), used_in_bytes(), committed, max_size()); 61.58 +}
62.1 --- a/src/share/vm/services/memoryPool.hpp Wed Jun 26 16:06:38 2013 +0200 62.2 +++ b/src/share/vm/services/memoryPool.hpp Wed Jul 03 11:50:29 2013 -0700 62.3 @@ -222,4 +222,21 @@ 62.4 size_t used_in_bytes() { return _codeHeap->allocated_capacity(); } 62.5 }; 62.6 62.7 +class MetaspacePool : public MemoryPool { 62.8 + size_t calculate_max_size() const; 62.9 + size_t capacity_in_bytes() const; 62.10 + public: 62.11 + MetaspacePool(); 62.12 + MemoryUsage get_memory_usage(); 62.13 + size_t used_in_bytes(); 62.14 +}; 62.15 + 62.16 +class CompressedKlassSpacePool : public MemoryPool { 62.17 + size_t capacity_in_bytes() const; 62.18 + public: 62.19 + CompressedKlassSpacePool(); 62.20 + MemoryUsage get_memory_usage(); 62.21 + size_t used_in_bytes(); 62.22 +}; 62.23 + 62.24 #endif // SHARE_VM_SERVICES_MEMORYPOOL_HPP
63.1 --- a/src/share/vm/services/memoryService.cpp Wed Jun 26 16:06:38 2013 +0200 63.2 +++ b/src/share/vm/services/memoryService.cpp Wed Jul 03 11:50:29 2013 -0700 63.3 @@ -35,6 +35,7 @@ 63.4 #include "memory/memRegion.hpp" 63.5 #include "memory/tenuredGeneration.hpp" 63.6 #include "oops/oop.inline.hpp" 63.7 +#include "runtime/globals.hpp" 63.8 #include "runtime/javaCalls.hpp" 63.9 #include "services/classLoadingService.hpp" 63.10 #include "services/lowMemoryDetector.hpp" 63.11 @@ -60,9 +61,11 @@ 63.12 GrowableArray<MemoryManager*>* MemoryService::_managers_list = 63.13 new (ResourceObj::C_HEAP, mtInternal) GrowableArray<MemoryManager*>(init_managers_list_size, true); 63.14 63.15 -GCMemoryManager* MemoryService::_minor_gc_manager = NULL; 63.16 -GCMemoryManager* MemoryService::_major_gc_manager = NULL; 63.17 -MemoryPool* MemoryService::_code_heap_pool = NULL; 63.18 +GCMemoryManager* MemoryService::_minor_gc_manager = NULL; 63.19 +GCMemoryManager* MemoryService::_major_gc_manager = NULL; 63.20 +MemoryPool* MemoryService::_code_heap_pool = NULL; 63.21 +MemoryPool* MemoryService::_metaspace_pool = NULL; 63.22 +MemoryPool* MemoryService::_compressed_class_pool = NULL; 63.23 63.24 class GcThreadCountClosure: public ThreadClosure { 63.25 private: 63.26 @@ -399,6 +402,22 @@ 63.27 _managers_list->append(mgr); 63.28 } 63.29 63.30 +void MemoryService::add_metaspace_memory_pools() { 63.31 + MemoryManager* mgr = MemoryManager::get_metaspace_memory_manager(); 63.32 + 63.33 + _metaspace_pool = new MetaspacePool(); 63.34 + mgr->add_pool(_metaspace_pool); 63.35 + _pools_list->append(_metaspace_pool); 63.36 + 63.37 + if (UseCompressedKlassPointers) { 63.38 + _compressed_class_pool = new CompressedKlassSpacePool(); 63.39 + mgr->add_pool(_compressed_class_pool); 63.40 + _pools_list->append(_compressed_class_pool); 63.41 + } 63.42 + 63.43 + _managers_list->append(mgr); 63.44 +} 63.45 + 63.46 MemoryManager* MemoryService::get_memory_manager(instanceHandle mh) { 63.47 for (int i = 0; i < _managers_list->length(); i++) { 63.48 MemoryManager* mgr = _managers_list->at(i);
64.1 --- a/src/share/vm/services/memoryService.hpp Wed Jun 26 16:06:38 2013 +0200 64.2 +++ b/src/share/vm/services/memoryService.hpp Wed Jul 03 11:50:29 2013 -0700 64.3 @@ -73,6 +73,9 @@ 64.4 // Code heap memory pool 64.5 static MemoryPool* _code_heap_pool; 64.6 64.7 + static MemoryPool* _metaspace_pool; 64.8 + static MemoryPool* _compressed_class_pool; 64.9 + 64.10 static void add_generation_memory_pool(Generation* gen, 64.11 MemoryManager* major_mgr, 64.12 MemoryManager* minor_mgr); 64.13 @@ -121,6 +124,7 @@ 64.14 public: 64.15 static void set_universe_heap(CollectedHeap* heap); 64.16 static void add_code_heap_memory_pool(CodeHeap* heap); 64.17 + static void add_metaspace_memory_pools(); 64.18 64.19 static MemoryPool* get_memory_pool(instanceHandle pool); 64.20 static MemoryManager* get_memory_manager(instanceHandle mgr);
65.1 --- a/src/share/vm/shark/sharkBuilder.cpp Wed Jun 26 16:06:38 2013 +0200 65.2 +++ b/src/share/vm/shark/sharkBuilder.cpp Wed Jul 03 11:50:29 2013 -0700 65.3 @@ -471,7 +471,7 @@ 65.4 65.5 Value* SharkBuilder::CreateInlineMetadata(Metadata* metadata, llvm::PointerType* type, const char* name) { 65.6 assert(metadata != NULL, "inlined metadata must not be NULL"); 65.7 - assert(metadata->is_metadata(), "sanity check"); 65.8 + assert(metadata->is_metaspace_object(), "sanity check"); 65.9 return CreateLoad( 65.10 CreateIntToPtr( 65.11 code_buffer_address(code_buffer()->inline_Metadata(metadata)),
66.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 66.2 +++ b/test/compiler/8005956/PolynomialRoot.java Wed Jul 03 11:50:29 2013 -0700 66.3 @@ -0,0 +1,776 @@ 66.4 +//package com.polytechnik.utils; 66.5 +/* 66.6 + * (C) Vladislav Malyshkin 2010 66.7 + * This file is under GPL version 3. 66.8 + * 66.9 + */ 66.10 + 66.11 +/** Polynomial root. 66.12 + * @version $Id: PolynomialRoot.java,v 1.105 2012/08/18 00:00:05 mal Exp $ 66.13 + * @author Vladislav Malyshkin mal@gromco.com 66.14 + */ 66.15 + 66.16 +/** 66.17 +* @test 66.18 +* @bug 8005956 66.19 +* @summary C2: assert(!def_outside->member(r)) failed: Use of external LRG overlaps the same LRG defined in this block 66.20 +* 66.21 +* @run main PolynomialRoot 66.22 +*/ 66.23 + 66.24 +public class PolynomialRoot { 66.25 + 66.26 + 66.27 +public static int findPolynomialRoots(final int n, 66.28 + final double [] p, 66.29 + final double [] re_root, 66.30 + final double [] im_root) 66.31 +{ 66.32 + if(n==4) 66.33 + { 66.34 + return root4(p,re_root,im_root); 66.35 + } 66.36 + else if(n==3) 66.37 + { 66.38 + return root3(p,re_root,im_root); 66.39 + } 66.40 + else if(n==2) 66.41 + { 66.42 + return root2(p,re_root,im_root); 66.43 + } 66.44 + else if(n==1) 66.45 + { 66.46 + return root1(p,re_root,im_root); 66.47 + } 66.48 + else 66.49 + { 66.50 + throw new RuntimeException("n="+n+" is not supported yet"); 66.51 + } 66.52 +} 66.53 + 66.54 + 66.55 + 66.56 +static final double SQRT3=Math.sqrt(3.0),SQRT2=Math.sqrt(2.0); 66.57 + 66.58 + 66.59 +private static final boolean PRINT_DEBUG=false; 66.60 + 66.61 +public static int root4(final double [] p,final double [] re_root,final double [] im_root) 66.62 +{ 66.63 + if(PRINT_DEBUG) System.err.println("=====================root4:p="+java.util.Arrays.toString(p)); 66.64 + final double vs=p[4]; 66.65 + if(PRINT_DEBUG) System.err.println("p[4]="+p[4]); 66.66 + if(!(Math.abs(vs)>EPS)) 66.67 + { 66.68 + re_root[0]=re_root[1]=re_root[2]=re_root[3]= 66.69 + im_root[0]=im_root[1]=im_root[2]=im_root[3]=Double.NaN; 66.70 + return -1; 66.71 + } 66.72 + 66.73 +/* zsolve_quartic.c - finds the complex roots of 66.74 + * x^4 + a x^3 + b x^2 + c x + d = 0 66.75 + */ 66.76 + final double a=p[3]/vs,b=p[2]/vs,c=p[1]/vs,d=p[0]/vs; 66.77 + if(PRINT_DEBUG) System.err.println("input a="+a+" b="+b+" c="+c+" d="+d); 66.78 + 66.79 + 66.80 + final double r4 = 1.0 / 4.0; 66.81 + final double q2 = 1.0 / 2.0, q4 = 1.0 / 4.0, q8 = 1.0 / 8.0; 66.82 + final double q1 = 3.0 / 8.0, q3 = 3.0 / 16.0; 66.83 + final int mt; 66.84 + 66.85 + /* Deal easily with the cases where the quartic is degenerate. The 66.86 + * ordering of solutions is done explicitly. */ 66.87 + if (0 == b && 0 == c) 66.88 + { 66.89 + if (0 == d) 66.90 + { 66.91 + re_root[0]=-a; 66.92 + im_root[0]=im_root[1]=im_root[2]=im_root[3]=0; 66.93 + re_root[1]=re_root[2]=re_root[3]=0; 66.94 + return 4; 66.95 + } 66.96 + else if (0 == a) 66.97 + { 66.98 + if (d > 0) 66.99 + { 66.100 + final double sq4 = Math.sqrt(Math.sqrt(d)); 66.101 + re_root[0]=sq4*SQRT2/2; 66.102 + im_root[0]=re_root[0]; 66.103 + re_root[1]=-re_root[0]; 66.104 + im_root[1]=re_root[0]; 66.105 + re_root[2]=-re_root[0]; 66.106 + im_root[2]=-re_root[0]; 66.107 + re_root[3]=re_root[0]; 66.108 + im_root[3]=-re_root[0]; 66.109 + if(PRINT_DEBUG) System.err.println("Path a=0 d>0"); 66.110 + } 66.111 + else 66.112 + { 66.113 + final double sq4 = Math.sqrt(Math.sqrt(-d)); 66.114 + re_root[0]=sq4; 66.115 + im_root[0]=0; 66.116 + re_root[1]=0; 66.117 + im_root[1]=sq4; 66.118 + re_root[2]=0; 66.119 + im_root[2]=-sq4; 66.120 + re_root[3]=-sq4; 66.121 + im_root[3]=0; 66.122 + if(PRINT_DEBUG) System.err.println("Path a=0 d<0"); 66.123 + } 66.124 + return 4; 66.125 + } 66.126 + } 66.127 + 66.128 + if (0.0 == c && 0.0 == d) 66.129 + { 66.130 + root2(new double []{p[2],p[3],p[4]},re_root,im_root); 66.131 + re_root[2]=im_root[2]=re_root[3]=im_root[3]=0; 66.132 + return 4; 66.133 + } 66.134 + 66.135 + if(PRINT_DEBUG) System.err.println("G Path c="+c+" d="+d); 66.136 + final double [] u=new double[3]; 66.137 + 66.138 + if(PRINT_DEBUG) System.err.println("Generic Path"); 66.139 + /* For non-degenerate solutions, proceed by constructing and 66.140 + * solving the resolvent cubic */ 66.141 + final double aa = a * a; 66.142 + final double pp = b - q1 * aa; 66.143 + final double qq = c - q2 * a * (b - q4 * aa); 66.144 + final double rr = d - q4 * a * (c - q4 * a * (b - q3 * aa)); 66.145 + final double rc = q2 * pp , rc3 = rc / 3; 66.146 + final double sc = q4 * (q4 * pp * pp - rr); 66.147 + final double tc = -(q8 * qq * q8 * qq); 66.148 + if(PRINT_DEBUG) System.err.println("aa="+aa+" pp="+pp+" qq="+qq+" rr="+rr+" rc="+rc+" sc="+sc+" tc="+tc); 66.149 + final boolean flag_realroots; 66.150 + 66.151 + /* This code solves the resolvent cubic in a convenient fashion 66.152 + * for this implementation of the quartic. If there are three real 66.153 + * roots, then they are placed directly into u[]. If two are 66.154 + * complex, then the real root is put into u[0] and the real 66.155 + * and imaginary part of the complex roots are placed into 66.156 + * u[1] and u[2], respectively. */ 66.157 + { 66.158 + final double qcub = (rc * rc - 3 * sc); 66.159 + final double rcub = (rc*(2 * rc * rc - 9 * sc) + 27 * tc); 66.160 + 66.161 + final double Q = qcub / 9; 66.162 + final double R = rcub / 54; 66.163 + 66.164 + final double Q3 = Q * Q * Q; 66.165 + final double R2 = R * R; 66.166 + 66.167 + final double CR2 = 729 * rcub * rcub; 66.168 + final double CQ3 = 2916 * qcub * qcub * qcub; 66.169 + 66.170 + if(PRINT_DEBUG) System.err.println("CR2="+CR2+" CQ3="+CQ3+" R="+R+" Q="+Q); 66.171 + 66.172 + if (0 == R && 0 == Q) 66.173 + { 66.174 + flag_realroots=true; 66.175 + u[0] = -rc3; 66.176 + u[1] = -rc3; 66.177 + u[2] = -rc3; 66.178 + } 66.179 + else if (CR2 == CQ3) 66.180 + { 66.181 + flag_realroots=true; 66.182 + final double sqrtQ = Math.sqrt (Q); 66.183 + if (R > 0) 66.184 + { 66.185 + u[0] = -2 * sqrtQ - rc3; 66.186 + u[1] = sqrtQ - rc3; 66.187 + u[2] = sqrtQ - rc3; 66.188 + } 66.189 + else 66.190 + { 66.191 + u[0] = -sqrtQ - rc3; 66.192 + u[1] = -sqrtQ - rc3; 66.193 + u[2] = 2 * sqrtQ - rc3; 66.194 + } 66.195 + } 66.196 + else if (R2 < Q3) 66.197 + { 66.198 + flag_realroots=true; 66.199 + final double ratio = (R >= 0?1:-1) * Math.sqrt (R2 / Q3); 66.200 + final double theta = Math.acos (ratio); 66.201 + final double norm = -2 * Math.sqrt (Q); 66.202 + 66.203 + u[0] = norm * Math.cos (theta / 3) - rc3; 66.204 + u[1] = norm * Math.cos ((theta + 2.0 * Math.PI) / 3) - rc3; 66.205 + u[2] = norm * Math.cos ((theta - 2.0 * Math.PI) / 3) - rc3; 66.206 + } 66.207 + else 66.208 + { 66.209 + flag_realroots=false; 66.210 + final double A = -(R >= 0?1:-1)*Math.pow(Math.abs(R)+Math.sqrt(R2-Q3),1.0/3.0); 66.211 + final double B = Q / A; 66.212 + 66.213 + u[0] = A + B - rc3; 66.214 + u[1] = -0.5 * (A + B) - rc3; 66.215 + u[2] = -(SQRT3*0.5) * Math.abs (A - B); 66.216 + } 66.217 + if(PRINT_DEBUG) System.err.println("u[0]="+u[0]+" u[1]="+u[1]+" u[2]="+u[2]+" qq="+qq+" disc="+((CR2 - CQ3) / 2125764.0)); 66.218 + } 66.219 + /* End of solution to resolvent cubic */ 66.220 + 66.221 + /* Combine the square roots of the roots of the cubic 66.222 + * resolvent appropriately. Also, calculate 'mt' which 66.223 + * designates the nature of the roots: 66.224 + * mt=1 : 4 real roots 66.225 + * mt=2 : 0 real roots 66.226 + * mt=3 : 2 real roots 66.227 + */ 66.228 + 66.229 + 66.230 + final double w1_re,w1_im,w2_re,w2_im,w3_re,w3_im,mod_w1w2,mod_w1w2_squared; 66.231 + if (flag_realroots) 66.232 + { 66.233 + mod_w1w2=-1; 66.234 + mt = 2; 66.235 + int jmin=0; 66.236 + double vmin=Math.abs(u[jmin]); 66.237 + for(int j=1;j<3;j++) 66.238 + { 66.239 + final double vx=Math.abs(u[j]); 66.240 + if(vx<vmin) 66.241 + { 66.242 + vmin=vx; 66.243 + jmin=j; 66.244 + } 66.245 + } 66.246 + final double u1=u[(jmin+1)%3],u2=u[(jmin+2)%3]; 66.247 + mod_w1w2_squared=Math.abs(u1*u2); 66.248 + if(u1>=0) 66.249 + { 66.250 + w1_re=Math.sqrt(u1); 66.251 + w1_im=0; 66.252 + } 66.253 + else 66.254 + { 66.255 + w1_re=0; 66.256 + w1_im=Math.sqrt(-u1); 66.257 + } 66.258 + if(u2>=0) 66.259 + { 66.260 + w2_re=Math.sqrt(u2); 66.261 + w2_im=0; 66.262 + } 66.263 + else 66.264 + { 66.265 + w2_re=0; 66.266 + w2_im=Math.sqrt(-u2); 66.267 + } 66.268 + if(PRINT_DEBUG) System.err.println("u1="+u1+" u2="+u2+" jmin="+jmin); 66.269 + } 66.270 + else 66.271 + { 66.272 + mt = 3; 66.273 + final double w_mod2_sq=u[1]*u[1]+u[2]*u[2],w_mod2=Math.sqrt(w_mod2_sq),w_mod=Math.sqrt(w_mod2); 66.274 + if(w_mod2_sq<=0) 66.275 + { 66.276 + w1_re=w1_im=0; 66.277 + } 66.278 + else 66.279 + { 66.280 + // calculate square root of a complex number (u[1],u[2]) 66.281 + // the result is in the (w1_re,w1_im) 66.282 + final double absu1=Math.abs(u[1]),absu2=Math.abs(u[2]),w; 66.283 + if(absu1>=absu2) 66.284 + { 66.285 + final double t=absu2/absu1; 66.286 + w=Math.sqrt(absu1*0.5 * (1.0 + Math.sqrt(1.0 + t * t))); 66.287 + if(PRINT_DEBUG) System.err.println(" Path1 "); 66.288 + } 66.289 + else 66.290 + { 66.291 + final double t=absu1/absu2; 66.292 + w=Math.sqrt(absu2*0.5 * (t + Math.sqrt(1.0 + t * t))); 66.293 + if(PRINT_DEBUG) System.err.println(" Path1a "); 66.294 + } 66.295 + if(u[1]>=0) 66.296 + { 66.297 + w1_re=w; 66.298 + w1_im=u[2]/(2*w); 66.299 + if(PRINT_DEBUG) System.err.println(" Path2 "); 66.300 + } 66.301 + else 66.302 + { 66.303 + final double vi = (u[2] >= 0) ? w : -w; 66.304 + w1_re=u[2]/(2*vi); 66.305 + w1_im=vi; 66.306 + if(PRINT_DEBUG) System.err.println(" Path2a "); 66.307 + } 66.308 + } 66.309 + final double absu0=Math.abs(u[0]); 66.310 + if(w_mod2>=absu0) 66.311 + { 66.312 + mod_w1w2=w_mod2; 66.313 + mod_w1w2_squared=w_mod2_sq; 66.314 + w2_re=w1_re; 66.315 + w2_im=-w1_im; 66.316 + } 66.317 + else 66.318 + { 66.319 + mod_w1w2=-1; 66.320 + mod_w1w2_squared=w_mod2*absu0; 66.321 + if(u[0]>=0) 66.322 + { 66.323 + w2_re=Math.sqrt(absu0); 66.324 + w2_im=0; 66.325 + } 66.326 + else 66.327 + { 66.328 + w2_re=0; 66.329 + w2_im=Math.sqrt(absu0); 66.330 + } 66.331 + } 66.332 + if(PRINT_DEBUG) System.err.println("u[0]="+u[0]+"u[1]="+u[1]+" u[2]="+u[2]+" absu0="+absu0+" w_mod="+w_mod+" w_mod2="+w_mod2); 66.333 + } 66.334 + 66.335 + /* Solve the quadratic in order to obtain the roots 66.336 + * to the quartic */ 66.337 + if(mod_w1w2>0) 66.338 + { 66.339 + // a shorcut to reduce rounding error 66.340 + w3_re=qq/(-8)/mod_w1w2; 66.341 + w3_im=0; 66.342 + } 66.343 + else if(mod_w1w2_squared>0) 66.344 + { 66.345 + // regular path 66.346 + final double mqq8n=qq/(-8)/mod_w1w2_squared; 66.347 + w3_re=mqq8n*(w1_re*w2_re-w1_im*w2_im); 66.348 + w3_im=-mqq8n*(w1_re*w2_im+w2_re*w1_im); 66.349 + } 66.350 + else 66.351 + { 66.352 + // typically occur when qq==0 66.353 + w3_re=w3_im=0; 66.354 + } 66.355 + 66.356 + final double h = r4 * a; 66.357 + if(PRINT_DEBUG) System.err.println("w1_re="+w1_re+" w1_im="+w1_im+" w2_re="+w2_re+" w2_im="+w2_im+" w3_re="+w3_re+" w3_im="+w3_im+" h="+h); 66.358 + 66.359 + re_root[0]=w1_re+w2_re+w3_re-h; 66.360 + im_root[0]=w1_im+w2_im+w3_im; 66.361 + re_root[1]=-(w1_re+w2_re)+w3_re-h; 66.362 + im_root[1]=-(w1_im+w2_im)+w3_im; 66.363 + re_root[2]=w2_re-w1_re-w3_re-h; 66.364 + im_root[2]=w2_im-w1_im-w3_im; 66.365 + re_root[3]=w1_re-w2_re-w3_re-h; 66.366 + im_root[3]=w1_im-w2_im-w3_im; 66.367 + 66.368 + return 4; 66.369 +} 66.370 + 66.371 + 66.372 + 66.373 + static void setRandomP(final double [] p,final int n,java.util.Random r) 66.374 + { 66.375 + if(r.nextDouble()<0.1) 66.376 + { 66.377 + // integer coefficiens 66.378 + for(int j=0;j<p.length;j++) 66.379 + { 66.380 + if(j<=n) 66.381 + { 66.382 + p[j]=(r.nextInt(2)<=0?-1:1)*r.nextInt(10); 66.383 + } 66.384 + else 66.385 + { 66.386 + p[j]=0; 66.387 + } 66.388 + } 66.389 + } 66.390 + else 66.391 + { 66.392 + // real coefficiens 66.393 + for(int j=0;j<p.length;j++) 66.394 + { 66.395 + if(j<=n) 66.396 + { 66.397 + p[j]=-1+2*r.nextDouble(); 66.398 + } 66.399 + else 66.400 + { 66.401 + p[j]=0; 66.402 + } 66.403 + } 66.404 + } 66.405 + if(Math.abs(p[n])<1e-2) 66.406 + { 66.407 + p[n]=(r.nextInt(2)<=0?-1:1)*(0.1+r.nextDouble()); 66.408 + } 66.409 + } 66.410 + 66.411 + 66.412 + static void checkValues(final double [] p, 66.413 + final int n, 66.414 + final double rex, 66.415 + final double imx, 66.416 + final double eps, 66.417 + final String txt) 66.418 + { 66.419 + double res=0,ims=0,sabs=0; 66.420 + final double xabs=Math.abs(rex)+Math.abs(imx); 66.421 + for(int k=n;k>=0;k--) 66.422 + { 66.423 + final double res1=(res*rex-ims*imx)+p[k]; 66.424 + final double ims1=(ims*rex+res*imx); 66.425 + res=res1; 66.426 + ims=ims1; 66.427 + sabs+=xabs*sabs+p[k]; 66.428 + } 66.429 + sabs=Math.abs(sabs); 66.430 + if(false && sabs>1/eps? 66.431 + (!(Math.abs(res/sabs)<=eps)||!(Math.abs(ims/sabs)<=eps)) 66.432 + : 66.433 + (!(Math.abs(res)<=eps)||!(Math.abs(ims)<=eps))) 66.434 + { 66.435 + throw new RuntimeException( 66.436 + getPolinomTXT(p)+"\n"+ 66.437 + "\t x.r="+rex+" x.i="+imx+"\n"+ 66.438 + "res/sabs="+(res/sabs)+" ims/sabs="+(ims/sabs)+ 66.439 + " sabs="+sabs+ 66.440 + "\nres="+res+" ims="+ims+" n="+n+" eps="+eps+" "+ 66.441 + " sabs>1/eps="+(sabs>1/eps)+ 66.442 + " f1="+(!(Math.abs(res/sabs)<=eps)||!(Math.abs(ims/sabs)<=eps))+ 66.443 + " f2="+(!(Math.abs(res)<=eps)||!(Math.abs(ims)<=eps))+ 66.444 + " "+txt); 66.445 + } 66.446 + } 66.447 + 66.448 + static String getPolinomTXT(final double [] p) 66.449 + { 66.450 + final StringBuilder buf=new StringBuilder(); 66.451 + buf.append("order="+(p.length-1)+"\t"); 66.452 + for(int k=0;k<p.length;k++) 66.453 + { 66.454 + buf.append("p["+k+"]="+p[k]+";"); 66.455 + } 66.456 + return buf.toString(); 66.457 + } 66.458 + 66.459 + static String getRootsTXT(int nr,final double [] re,final double [] im) 66.460 + { 66.461 + final StringBuilder buf=new StringBuilder(); 66.462 + for(int k=0;k<nr;k++) 66.463 + { 66.464 + buf.append("x."+k+"("+re[k]+","+im[k]+")\n"); 66.465 + } 66.466 + return buf.toString(); 66.467 + } 66.468 + 66.469 + static void testRoots(final int n, 66.470 + final int n_tests, 66.471 + final java.util.Random rn, 66.472 + final double eps) 66.473 + { 66.474 + final double [] p=new double [n+1]; 66.475 + final double [] rex=new double [n],imx=new double [n]; 66.476 + for(int i=0;i<n_tests;i++) 66.477 + { 66.478 + for(int dg=n;dg-->-1;) 66.479 + { 66.480 + for(int dr=3;dr-->0;) 66.481 + { 66.482 + setRandomP(p,n,rn); 66.483 + for(int j=0;j<=dg;j++) 66.484 + { 66.485 + p[j]=0; 66.486 + } 66.487 + if(dr==0) 66.488 + { 66.489 + p[0]=-1+2.0*rn.nextDouble(); 66.490 + } 66.491 + else if(dr==1) 66.492 + { 66.493 + p[0]=p[1]=0; 66.494 + } 66.495 + 66.496 + findPolynomialRoots(n,p,rex,imx); 66.497 + 66.498 + for(int j=0;j<n;j++) 66.499 + { 66.500 + //System.err.println("j="+j); 66.501 + checkValues(p,n,rex[j],imx[j],eps," t="+i); 66.502 + } 66.503 + } 66.504 + } 66.505 + } 66.506 + System.err.println("testRoots(): n_tests="+n_tests+" OK, dim="+n); 66.507 + } 66.508 + 66.509 + 66.510 + 66.511 + 66.512 + static final double EPS=0; 66.513 + 66.514 + public static int root1(final double [] p,final double [] re_root,final double [] im_root) 66.515 + { 66.516 + if(!(Math.abs(p[1])>EPS)) 66.517 + { 66.518 + re_root[0]=im_root[0]=Double.NaN; 66.519 + return -1; 66.520 + } 66.521 + re_root[0]=-p[0]/p[1]; 66.522 + im_root[0]=0; 66.523 + return 1; 66.524 + } 66.525 + 66.526 + public static int root2(final double [] p,final double [] re_root,final double [] im_root) 66.527 + { 66.528 + if(!(Math.abs(p[2])>EPS)) 66.529 + { 66.530 + re_root[0]=re_root[1]=im_root[0]=im_root[1]=Double.NaN; 66.531 + return -1; 66.532 + } 66.533 + final double b2=0.5*(p[1]/p[2]),c=p[0]/p[2],d=b2*b2-c; 66.534 + if(d>=0) 66.535 + { 66.536 + final double sq=Math.sqrt(d); 66.537 + if(b2<0) 66.538 + { 66.539 + re_root[1]=-b2+sq; 66.540 + re_root[0]=c/re_root[1]; 66.541 + } 66.542 + else if(b2>0) 66.543 + { 66.544 + re_root[0]=-b2-sq; 66.545 + re_root[1]=c/re_root[0]; 66.546 + } 66.547 + else 66.548 + { 66.549 + re_root[0]=-b2-sq; 66.550 + re_root[1]=-b2+sq; 66.551 + } 66.552 + im_root[0]=im_root[1]=0; 66.553 + } 66.554 + else 66.555 + { 66.556 + final double sq=Math.sqrt(-d); 66.557 + re_root[0]=re_root[1]=-b2; 66.558 + im_root[0]=sq; 66.559 + im_root[1]=-sq; 66.560 + } 66.561 + return 2; 66.562 + } 66.563 + 66.564 + public static int root3(final double [] p,final double [] re_root,final double [] im_root) 66.565 + { 66.566 + final double vs=p[3]; 66.567 + if(!(Math.abs(vs)>EPS)) 66.568 + { 66.569 + re_root[0]=re_root[1]=re_root[2]= 66.570 + im_root[0]=im_root[1]=im_root[2]=Double.NaN; 66.571 + return -1; 66.572 + } 66.573 + final double a=p[2]/vs,b=p[1]/vs,c=p[0]/vs; 66.574 + /* zsolve_cubic.c - finds the complex roots of x^3 + a x^2 + b x + c = 0 66.575 + */ 66.576 + final double q = (a * a - 3 * b); 66.577 + final double r = (a*(2 * a * a - 9 * b) + 27 * c); 66.578 + 66.579 + final double Q = q / 9; 66.580 + final double R = r / 54; 66.581 + 66.582 + final double Q3 = Q * Q * Q; 66.583 + final double R2 = R * R; 66.584 + 66.585 + final double CR2 = 729 * r * r; 66.586 + final double CQ3 = 2916 * q * q * q; 66.587 + final double a3=a/3; 66.588 + 66.589 + if (R == 0 && Q == 0) 66.590 + { 66.591 + re_root[0]=re_root[1]=re_root[2]=-a3; 66.592 + im_root[0]=im_root[1]=im_root[2]=0; 66.593 + return 3; 66.594 + } 66.595 + else if (CR2 == CQ3) 66.596 + { 66.597 + /* this test is actually R2 == Q3, written in a form suitable 66.598 + for exact computation with integers */ 66.599 + 66.600 + /* Due to finite precision some double roots may be missed, and 66.601 + will be considered to be a pair of complex roots z = x +/- 66.602 + epsilon i close to the real axis. */ 66.603 + 66.604 + final double sqrtQ = Math.sqrt (Q); 66.605 + 66.606 + if (R > 0) 66.607 + { 66.608 + re_root[0] = -2 * sqrtQ - a3; 66.609 + re_root[1]=re_root[2]=sqrtQ - a3; 66.610 + im_root[0]=im_root[1]=im_root[2]=0; 66.611 + } 66.612 + else 66.613 + { 66.614 + re_root[0]=re_root[1] = -sqrtQ - a3; 66.615 + re_root[2]=2 * sqrtQ - a3; 66.616 + im_root[0]=im_root[1]=im_root[2]=0; 66.617 + } 66.618 + return 3; 66.619 + } 66.620 + else if (R2 < Q3) 66.621 + { 66.622 + final double sgnR = (R >= 0 ? 1 : -1); 66.623 + final double ratio = sgnR * Math.sqrt (R2 / Q3); 66.624 + final double theta = Math.acos (ratio); 66.625 + final double norm = -2 * Math.sqrt (Q); 66.626 + final double r0 = norm * Math.cos (theta/3) - a3; 66.627 + final double r1 = norm * Math.cos ((theta + 2.0 * Math.PI) / 3) - a3; 66.628 + final double r2 = norm * Math.cos ((theta - 2.0 * Math.PI) / 3) - a3; 66.629 + 66.630 + re_root[0]=r0; 66.631 + re_root[1]=r1; 66.632 + re_root[2]=r2; 66.633 + im_root[0]=im_root[1]=im_root[2]=0; 66.634 + return 3; 66.635 + } 66.636 + else 66.637 + { 66.638 + final double sgnR = (R >= 0 ? 1 : -1); 66.639 + final double A = -sgnR * Math.pow (Math.abs (R) + Math.sqrt (R2 - Q3), 1.0 / 3.0); 66.640 + final double B = Q / A; 66.641 + 66.642 + re_root[0]=A + B - a3; 66.643 + im_root[0]=0; 66.644 + re_root[1]=-0.5 * (A + B) - a3; 66.645 + im_root[1]=-(SQRT3*0.5) * Math.abs(A - B); 66.646 + re_root[2]=re_root[1]; 66.647 + im_root[2]=-im_root[1]; 66.648 + return 3; 66.649 + } 66.650 + 66.651 + } 66.652 + 66.653 + 66.654 + static void root3a(final double [] p,final double [] re_root,final double [] im_root) 66.655 + { 66.656 + if(Math.abs(p[3])>EPS) 66.657 + { 66.658 + final double v=p[3], 66.659 + a=p[2]/v,b=p[1]/v,c=p[0]/v, 66.660 + a3=a/3,a3a=a3*a, 66.661 + pd3=(b-a3a)/3, 66.662 + qd2=a3*(a3a/3-0.5*b)+0.5*c, 66.663 + Q=pd3*pd3*pd3+qd2*qd2; 66.664 + if(Q<0) 66.665 + { 66.666 + // three real roots 66.667 + final double SQ=Math.sqrt(-Q); 66.668 + final double th=Math.atan2(SQ,-qd2); 66.669 + im_root[0]=im_root[1]=im_root[2]=0; 66.670 + final double f=2*Math.sqrt(-pd3); 66.671 + re_root[0]=f*Math.cos(th/3)-a3; 66.672 + re_root[1]=f*Math.cos((th+2*Math.PI)/3)-a3; 66.673 + re_root[2]=f*Math.cos((th+4*Math.PI)/3)-a3; 66.674 + //System.err.println("3r"); 66.675 + } 66.676 + else 66.677 + { 66.678 + // one real & two complex roots 66.679 + final double SQ=Math.sqrt(Q); 66.680 + final double r1=-qd2+SQ,r2=-qd2-SQ; 66.681 + final double v1=Math.signum(r1)*Math.pow(Math.abs(r1),1.0/3), 66.682 + v2=Math.signum(r2)*Math.pow(Math.abs(r2),1.0/3), 66.683 + sv=v1+v2; 66.684 + // real root 66.685 + re_root[0]=sv-a3; 66.686 + im_root[0]=0; 66.687 + // complex roots 66.688 + re_root[1]=re_root[2]=-0.5*sv-a3; 66.689 + im_root[1]=(v1-v2)*(SQRT3*0.5); 66.690 + im_root[2]=-im_root[1]; 66.691 + //System.err.println("1r2c"); 66.692 + } 66.693 + } 66.694 + else 66.695 + { 66.696 + re_root[0]=re_root[1]=re_root[2]=im_root[0]=im_root[1]=im_root[2]=Double.NaN; 66.697 + } 66.698 + } 66.699 + 66.700 + 66.701 + static void printSpecialValues() 66.702 + { 66.703 + for(int st=0;st<6;st++) 66.704 + { 66.705 + //final double [] p=new double []{8,1,3,3.6,1}; 66.706 + final double [] re_root=new double [4],im_root=new double [4]; 66.707 + final double [] p; 66.708 + final int n; 66.709 + if(st<=3) 66.710 + { 66.711 + if(st<=0) 66.712 + { 66.713 + p=new double []{2,-4,6,-4,1}; 66.714 + //p=new double []{-6,6,-6,8,-2}; 66.715 + } 66.716 + else if(st==1) 66.717 + { 66.718 + p=new double []{0,-4,8,3,-9}; 66.719 + } 66.720 + else if(st==2) 66.721 + { 66.722 + p=new double []{-1,0,2,0,-1}; 66.723 + } 66.724 + else 66.725 + { 66.726 + p=new double []{-5,2,8,-2,-3}; 66.727 + } 66.728 + root4(p,re_root,im_root); 66.729 + n=4; 66.730 + } 66.731 + else 66.732 + { 66.733 + p=new double []{0,2,0,1}; 66.734 + if(st==4) 66.735 + { 66.736 + p[1]=-p[1]; 66.737 + } 66.738 + root3(p,re_root,im_root); 66.739 + n=3; 66.740 + } 66.741 + System.err.println("======== n="+n); 66.742 + for(int i=0;i<=n;i++) 66.743 + { 66.744 + if(i<n) 66.745 + { 66.746 + System.err.println(String.valueOf(i)+"\t"+ 66.747 + p[i]+"\t"+ 66.748 + re_root[i]+"\t"+ 66.749 + im_root[i]); 66.750 + } 66.751 + else 66.752 + { 66.753 + System.err.println(String.valueOf(i)+"\t"+p[i]+"\t"); 66.754 + } 66.755 + } 66.756 + } 66.757 + } 66.758 + 66.759 + 66.760 + 66.761 + public static void main(final String [] args) 66.762 + { 66.763 + final long t0=System.currentTimeMillis(); 66.764 + final double eps=1e-6; 66.765 + //checkRoots(); 66.766 + final java.util.Random r=new java.util.Random(-1381923); 66.767 + printSpecialValues(); 66.768 + 66.769 + final int n_tests=10000000; 66.770 + //testRoots(2,n_tests,r,eps); 66.771 + //testRoots(3,n_tests,r,eps); 66.772 + testRoots(4,n_tests,r,eps); 66.773 + final long t1=System.currentTimeMillis(); 66.774 + System.err.println("PolynomialRoot.main: "+n_tests+" tests OK done in "+(t1-t0)+" milliseconds. ver=$Id: PolynomialRoot.java,v 1.105 2012/08/18 00:00:05 mal Exp $"); 66.775 + } 66.776 + 66.777 + 66.778 + 66.779 +}
67.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 67.2 +++ b/test/gc/metaspace/TestMetaspaceMemoryPool.java Wed Jul 03 11:50:29 2013 -0700 67.3 @@ -0,0 +1,126 @@ 67.4 +/* 67.5 + * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. 67.6 + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 67.7 + * 67.8 + * This code is free software; you can redistribute it and/or modify it 67.9 + * under the terms of the GNU General Public License version 2 only, as 67.10 + * published by the Free Software Foundation. 67.11 + * 67.12 + * This code is distributed in the hope that it will be useful, but WITHOUT 67.13 + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 67.14 + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 67.15 + * version 2 for more details (a copy is included in the LICENSE file that 67.16 + * accompanied this code). 67.17 + * 67.18 + * You should have received a copy of the GNU General Public License version 67.19 + * 2 along with this work; if not, write to the Free Software Foundation, 67.20 + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 67.21 + * 67.22 + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 67.23 + * or visit www.oracle.com if you need additional information or have any 67.24 + * questions. 67.25 + */ 67.26 + 67.27 +import java.util.List; 67.28 +import java.lang.management.ManagementFactory; 67.29 +import java.lang.management.MemoryManagerMXBean; 67.30 +import java.lang.management.MemoryPoolMXBean; 67.31 +import java.lang.management.MemoryUsage; 67.32 + 67.33 +import java.lang.management.RuntimeMXBean; 67.34 +import java.lang.management.ManagementFactory; 67.35 + 67.36 +/* @test TestMetaspaceMemoryPool 67.37 + * @bug 8000754 67.38 + * @summary Tests that a MemoryPoolMXBeans is created for metaspace and that a 67.39 + * MemoryManagerMXBean is created. 67.40 + * @run main/othervm -XX:+IgnoreUnrecognizedVMOptions -XX:-UseCompressedOops TestMetaspaceMemoryPool 67.41 + * @run main/othervm -XX:+IgnoreUnrecognizedVMOptions -XX:-UseCompressedOops -XX:MaxMetaspaceSize=60m TestMetaspaceMemoryPool 67.42 + * @run main/othervm -XX:+IgnoreUnrecognizedVMOptions -XX:+UseCompressedOops -XX:+UseCompressedKlassPointers TestMetaspaceMemoryPool 67.43 + * @run main/othervm -XX:+IgnoreUnrecognizedVMOptions -XX:+UseCompressedOops -XX:+UseCompressedKlassPointers -XX:ClassMetaspaceSize=60m TestMetaspaceMemoryPool 67.44 + */ 67.45 +public class TestMetaspaceMemoryPool { 67.46 + public static void main(String[] args) { 67.47 + verifyThatMetaspaceMemoryManagerExists(); 67.48 + verifyMemoryPool(getMemoryPool("Metaspace"), isFlagDefined("MaxMetaspaceSize")); 67.49 + 67.50 + if (runsOn64bit()) { 67.51 + if (usesCompressedOops()) { 67.52 + MemoryPoolMXBean cksPool = getMemoryPool("Compressed Class Space"); 67.53 + verifyMemoryPool(cksPool, true); 67.54 + } 67.55 + } 67.56 + } 67.57 + 67.58 + private static boolean runsOn64bit() { 67.59 + return !System.getProperty("sun.arch.data.model").equals("32"); 67.60 + } 67.61 + 67.62 + private static boolean usesCompressedOops() { 67.63 + return isFlagDefined("+UseCompressedOops"); 67.64 + } 67.65 + 67.66 + private static boolean isFlagDefined(String name) { 67.67 + RuntimeMXBean runtimeMxBean = ManagementFactory.getRuntimeMXBean(); 67.68 + List<String> args = runtimeMxBean.getInputArguments(); 67.69 + for (String arg : args) { 67.70 + if (arg.startsWith("-XX:" + name)) { 67.71 + return true; 67.72 + } 67.73 + } 67.74 + return false; 67.75 + } 67.76 + 67.77 + private static void verifyThatMetaspaceMemoryManagerExists() { 67.78 + List<MemoryManagerMXBean> managers = ManagementFactory.getMemoryManagerMXBeans(); 67.79 + for (MemoryManagerMXBean manager : managers) { 67.80 + if (manager.getName().equals("Metaspace Manager")) { 67.81 + return; 67.82 + } 67.83 + } 67.84 + 67.85 + throw new RuntimeException("Expected to find a metaspace memory manager"); 67.86 + } 67.87 + 67.88 + private static MemoryPoolMXBean getMemoryPool(String name) { 67.89 + List<MemoryPoolMXBean> pools = ManagementFactory.getMemoryPoolMXBeans(); 67.90 + for (MemoryPoolMXBean pool : pools) { 67.91 + if (pool.getName().equals(name)) { 67.92 + return pool; 67.93 + } 67.94 + } 67.95 + 67.96 + throw new RuntimeException("Expected to find a memory pool with name " + name); 67.97 + } 67.98 + 67.99 + private static void verifyMemoryPool(MemoryPoolMXBean pool, boolean isMaxDefined) { 67.100 + MemoryUsage mu = pool.getUsage(); 67.101 + assertDefined(mu.getInit(), "init"); 67.102 + assertDefined(mu.getUsed(), "used"); 67.103 + assertDefined(mu.getCommitted(), "committed"); 67.104 + 67.105 + if (isMaxDefined) { 67.106 + assertDefined(mu.getMax(), "max"); 67.107 + } else { 67.108 + assertUndefined(mu.getMax(), "max"); 67.109 + } 67.110 + } 67.111 + 67.112 + private static void assertDefined(long value, String name) { 67.113 + assertTrue(value != -1, "Expected " + name + " to be defined"); 67.114 + } 67.115 + 67.116 + private static void assertUndefined(long value, String name) { 67.117 + assertEquals(value, -1, "Expected " + name + " to be undefined"); 67.118 + } 67.119 + 67.120 + private static void assertEquals(long actual, long expected, String msg) { 67.121 + assertTrue(actual == expected, msg); 67.122 + } 67.123 + 67.124 + private static void assertTrue(boolean condition, String msg) { 67.125 + if (!condition) { 67.126 + throw new RuntimeException(msg); 67.127 + } 67.128 + } 67.129 +}
68.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 68.2 +++ b/test/gc/parallelScavenge/AdaptiveGCBoundary.java Wed Jul 03 11:50:29 2013 -0700 68.3 @@ -0,0 +1,61 @@ 68.4 +/* 68.5 + * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. 68.6 + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 68.7 + * 68.8 + * This code is free software; you can redistribute it and/or modify it 68.9 + * under the terms of the GNU General Public License version 2 only, as 68.10 + * published by the Free Software Foundation. 68.11 + * 68.12 + * This code is distributed in the hope that it will be useful, but WITHOUT 68.13 + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 68.14 + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 68.15 + * version 2 for more details (a copy is included in the LICENSE file that 68.16 + * accompanied this code). 68.17 + * 68.18 + * You should have received a copy of the GNU General Public License version 68.19 + * 2 along with this work; if not, write to the Free Software Foundation, 68.20 + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 68.21 + * 68.22 + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 68.23 + * or visit www.oracle.com if you need additional information or have any 68.24 + * questions. 68.25 + */ 68.26 + 68.27 +/** 68.28 + * @test AdaptiveGCBoundary 68.29 + * @summary UseAdaptiveGCBoundary is broken 68.30 + * @bug 8014546 68.31 + * @key gc 68.32 + * @key regression 68.33 + * @library /testlibrary 68.34 + * @run main/othervm AdaptiveGCBoundary 68.35 + * @author jon.masamitsu@oracle.com 68.36 + */ 68.37 + 68.38 +import com.oracle.java.testlibrary.*; 68.39 + 68.40 +public class AdaptiveGCBoundary { 68.41 + public static void main(String args[]) throws Exception { 68.42 + 68.43 + ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( 68.44 + "-showversion", 68.45 + "-XX:+UseParallelGC", 68.46 + "-XX:+UseAdaptiveGCBoundary", 68.47 + "-XX:+PrintCommandLineFlags", 68.48 + SystemGCCaller.class.getName() 68.49 + ); 68.50 + 68.51 + OutputAnalyzer output = new OutputAnalyzer(pb.start()); 68.52 + 68.53 + output.shouldContain("+UseAdaptiveGCBoundary"); 68.54 + 68.55 + output.shouldNotContain("error"); 68.56 + 68.57 + output.shouldHaveExitValue(0); 68.58 + } 68.59 + static class SystemGCCaller { 68.60 + public static void main(String [] args) { 68.61 + System.gc(); 68.62 + } 68.63 + } 68.64 +}