comparison jvmci/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MemoryAccessProvider.java @ 24111:8abcd8e1285d

missing checks in HotSpotMemoryAccessProviderImpl can cause VM assertions to fail (JDK-8177673)
author Doug Simon <doug.simon@oracle.com>
date Thu, 30 Mar 2017 21:18:43 +0200
parents c9993da505a0
children 8cf4cf3f9f2a
comparison
equal deleted inserted replaced
24110:a8378ff1936d 24111:8abcd8e1285d
33 * @param kind the {@link JavaKind} of the returned {@link JavaConstant} object 33 * @param kind the {@link JavaKind} of the returned {@link JavaConstant} object
34 * @param base the base address from which the value is read 34 * @param base the base address from which the value is read
35 * @param displacement the displacement within the object in bytes 35 * @param displacement the displacement within the object in bytes
36 * @param bits the number of bits to read from memory 36 * @param bits the number of bits to read from memory
37 * @return the read value encapsulated in a {@link JavaConstant} object of {@link JavaKind} kind 37 * @return the read value encapsulated in a {@link JavaConstant} object of {@link JavaKind} kind
38 * or {@code null} if {@code base} is a boxed object and the read address does not
39 * denote a location holding an {@code kind} value
38 * @throws IllegalArgumentException if {@code kind} is {@link JavaKind#Void} or not 40 * @throws IllegalArgumentException if {@code kind} is {@link JavaKind#Void} or not
39 * {@linkplain JavaKind#isPrimitive() primitive} kind or {@code bits} is not 8, 16, 41 * {@linkplain JavaKind#isPrimitive() primitive} kind or {@code bits} is not 8, 16,
40 * 32 or 64 42 * 32 or 64
41 */ 43 */
42 JavaConstant readPrimitiveConstant(JavaKind kind, Constant base, long displacement, int bits) throws IllegalArgumentException; 44 JavaConstant readPrimitiveConstant(JavaKind kind, Constant base, long displacement, int bits) throws IllegalArgumentException;