294 @ForceInline 295 public void putDouble(Object o, long offset, double x) { 296 theInternalUnsafe.putDouble(o, offset, x); 297 } 298 299 300 // These read VM internal data. 301 302 /** 303 * Fetches an uncompressed reference value from a given native variable 304 * ignoring the VM's compressed references mode. 305 * 306 * @param address a memory address locating the variable 307 * @return the value fetched from the indicated native variable 308 */ 309 @ForceInline 310 public Object getUncompressedObject(long address) { 311 return theInternalUnsafe.getUncompressedObject(address); 312 } 313 314 /** 315 * Fetches the {@link java.lang.Class} Java mirror for the given native 316 * metaspace {@code Klass} pointer. 317 * 318 * @param metaspaceKlass a native metaspace {@code Klass} pointer 319 * @return the {@link java.lang.Class} Java mirror 320 */ 321 @ForceInline 322 public Class<?> getJavaMirror(long metaspaceKlass) { 323 return theInternalUnsafe.getJavaMirror(metaspaceKlass); 324 } 325 326 /** 327 * Fetches a native metaspace {@code Klass} pointer for the given Java 328 * object. 329 * 330 * @param o Java heap object for which to fetch the class pointer 331 * @return a native metaspace {@code Klass} pointer 332 */ 333 @ForceInline 334 public long getKlassPointer(Object o) { 335 return theInternalUnsafe.getKlassPointer(o); 336 } 337 338 // These work on values in the C heap. 339 340 /** 341 * Fetches a value from a given memory address. If the address is zero, or 342 * does not point into a block obtained from {@link #allocateMemory}, the 343 * results are undefined. 344 * 345 * @see #allocateMemory 346 */ 347 @ForceInline 348 public byte getByte(long address) { 349 return theInternalUnsafe.getByte(address); 350 } 351 352 /** 353 * Stores a value into a given memory address. If the address is zero, or 354 * does not point into a block obtained from {@link #allocateMemory}, the 355 * results are undefined. 356 * 357 * @see #getByte(long) | 294 @ForceInline 295 public void putDouble(Object o, long offset, double x) { 296 theInternalUnsafe.putDouble(o, offset, x); 297 } 298 299 300 // These read VM internal data. 301 302 /** 303 * Fetches an uncompressed reference value from a given native variable 304 * ignoring the VM's compressed references mode. 305 * 306 * @param address a memory address locating the variable 307 * @return the value fetched from the indicated native variable 308 */ 309 @ForceInline 310 public Object getUncompressedObject(long address) { 311 return theInternalUnsafe.getUncompressedObject(address); 312 } 313 314 // These work on values in the C heap. 315 316 /** 317 * Fetches a value from a given memory address. If the address is zero, or 318 * does not point into a block obtained from {@link #allocateMemory}, the 319 * results are undefined. 320 * 321 * @see #allocateMemory 322 */ 323 @ForceInline 324 public byte getByte(long address) { 325 return theInternalUnsafe.getByte(address); 326 } 327 328 /** 329 * Stores a value into a given memory address. If the address is zero, or 330 * does not point into a block obtained from {@link #allocateMemory}, the 331 * results are undefined. 332 * 333 * @see #getByte(long) |