java.lang.invoke.VarHandleLongs Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of qbicc-rt-java.base Show documentation
Show all versions of qbicc-rt-java.base Show documentation
The Qbicc builder for the java.base JDK module
/*
* Copyright (c) 2015, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package java.lang.invoke;
import jdk.internal.util.Preconditions;
import jdk.internal.vm.annotation.ForceInline;
import java.lang.invoke.VarHandle.VarHandleDesc;
import java.util.Objects;
import java.util.Optional;
import org.qbicc.rt.annotation.Tracking;
import static java.lang.invoke.MethodHandleStatics.UNSAFE;
// -- This file was mechanically generated: Do not edit! -- //
@Tracking("src/java.base/share/classes/java/lang/invoke/X-VarHandle.java.template")
final class VarHandleLongs {
static class FieldInstanceReadOnly extends VarHandle {
final long fieldOffset;
final Class> receiverType;
FieldInstanceReadOnly(Class> receiverType, long fieldOffset) {
this(receiverType, fieldOffset, FieldInstanceReadOnly.FORM, false);
}
protected FieldInstanceReadOnly(Class> receiverType, long fieldOffset,
VarForm form, boolean exact) {
super(form, exact);
this.fieldOffset = fieldOffset;
this.receiverType = receiverType;
}
@Override
public FieldInstanceReadOnly withInvokeExactBehavior() {
return hasInvokeExactBehavior()
? this
: new FieldInstanceReadOnly(receiverType, fieldOffset, vform, true);
}
@Override
public FieldInstanceReadOnly withInvokeBehavior() {
return !hasInvokeExactBehavior()
? this
: new FieldInstanceReadOnly(receiverType, fieldOffset, vform, false);
}
@Override
final MethodType accessModeTypeUncached(AccessType at) {
return at.accessModeType(receiverType, long.class);
}
@Override
public Optional describeConstable() {
var receiverTypeRef = receiverType.describeConstable();
var fieldTypeRef = long.class.describeConstable();
if (!receiverTypeRef.isPresent() || !fieldTypeRef.isPresent())
return Optional.empty();
// Reflect on this VarHandle to extract the field name
String name = VarHandles.getFieldFromReceiverAndOffset(
receiverType, fieldOffset, long.class).getName();
return Optional.of(VarHandleDesc.ofField(receiverTypeRef.get(), name, fieldTypeRef.get()));
}
@ForceInline
static long get(VarHandle ob, Object holder) {
FieldInstanceReadOnly handle = (FieldInstanceReadOnly)ob;
return UNSAFE.getLong(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset);
}
// @Override
public long get(Object holder) {
return UNSAFE.getLong(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset);
}
@ForceInline
static long getVolatile(VarHandle ob, Object holder) {
FieldInstanceReadOnly handle = (FieldInstanceReadOnly)ob;
return UNSAFE.getLongVolatile(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset);
}
// @Override
public long getVolatile(Object holder) {
return UNSAFE.getLongVolatile(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset);
}
@ForceInline
static long getOpaque(VarHandle ob, Object holder) {
FieldInstanceReadOnly handle = (FieldInstanceReadOnly)ob;
return UNSAFE.getLongOpaque(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset);
}
// @Override
public long getOpaque(Object holder) {
return UNSAFE.getLongOpaque(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset);
}
@ForceInline
static long getAcquire(VarHandle ob, Object holder) {
FieldInstanceReadOnly handle = (FieldInstanceReadOnly)ob;
return UNSAFE.getLongAcquire(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset);
}
// @Override
public long getAcquire(Object holder) {
return UNSAFE.getLongAcquire(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset);
}
static final VarForm FORM = new VarForm(FieldInstanceReadOnly.class, Object.class, long.class);
}
static final class FieldInstanceReadWrite extends FieldInstanceReadOnly {
FieldInstanceReadWrite(Class> receiverType, long fieldOffset) {
this(receiverType, fieldOffset, false);
}
private FieldInstanceReadWrite(Class> receiverType, long fieldOffset,
boolean exact) {
super(receiverType, fieldOffset, FieldInstanceReadWrite.FORM, exact);
}
@Override
public FieldInstanceReadWrite withInvokeExactBehavior() {
return hasInvokeExactBehavior()
? this
: new FieldInstanceReadWrite(receiverType, fieldOffset, true);
}
@Override
public FieldInstanceReadWrite withInvokeBehavior() {
return !hasInvokeExactBehavior()
? this
: new FieldInstanceReadWrite(receiverType, fieldOffset, false);
}
@ForceInline
static void set(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
UNSAFE.putLong(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public void set(Object holder, long value) {
UNSAFE.putLong(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset,
value);
}
@ForceInline
static void setVolatile(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
UNSAFE.putLongVolatile(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public void setVolatile(Object holder, long value) {
UNSAFE.putLongVolatile(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset,
value);
}
@ForceInline
static void setOpaque(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
UNSAFE.putLongOpaque(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public void setOpaque(Object holder, long value) {
UNSAFE.putLongOpaque(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset,
value);
}
@ForceInline
static void setRelease(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
UNSAFE.putLongRelease(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public void setRelease(Object holder, long value) {
UNSAFE.putLongRelease(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset,
value);
}
@ForceInline
static boolean compareAndSet(VarHandle ob, Object holder, long expected, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.compareAndSetLong(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
expected,
value);
}
// @Override
public boolean compareAndSet(Object holder, long expected, long value) {
return UNSAFE.compareAndSetLong(Objects.requireNonNull(receiverType.cast(holder)),
fieldOffset,
expected,
value);
}
@ForceInline
static long compareAndExchange(VarHandle ob, Object holder, long expected, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.compareAndExchangeLong(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
expected,
value);
}
// @Override
public long compareAndExchange(Object holder, long expected, long value) {
return UNSAFE.compareAndExchangeLong(Objects.requireNonNull(receiverType.cast(holder)),
fieldOffset,
expected,
value);
}
@ForceInline
static long compareAndExchangeAcquire(VarHandle ob, Object holder, long expected, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.compareAndExchangeLongAcquire(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
expected,
value);
}
// @Override
public long compareAndExchangeAcquire(Object holder, long expected, long value) {
return UNSAFE.compareAndExchangeLongAcquire(Objects.requireNonNull(receiverType.cast(holder)),
fieldOffset,
expected,
value);
}
@ForceInline
static long compareAndExchangeRelease(VarHandle ob, Object holder, long expected, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.compareAndExchangeLongRelease(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
expected,
value);
}
// @Override
public long compareAndExchangeRelease(Object holder, long expected, long value) {
return UNSAFE.compareAndExchangeLongRelease(Objects.requireNonNull(receiverType.cast(holder)),
fieldOffset,
expected,
value);
}
@ForceInline
static boolean weakCompareAndSetPlain(VarHandle ob, Object holder, long expected, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.weakCompareAndSetLongPlain(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
expected,
value);
}
// @Override
public boolean weakCompareAndSetPlain(Object holder, long expected, long value) {
return UNSAFE.weakCompareAndSetLongPlain(Objects.requireNonNull(receiverType.cast(holder)),
fieldOffset,
expected,
value);
}
@ForceInline
static boolean weakCompareAndSet(VarHandle ob, Object holder, long expected, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.weakCompareAndSetLong(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
expected,
value);
}
// @Override
public boolean weakCompareAndSet(Object holder, long expected, long value) {
return UNSAFE.weakCompareAndSetLong(Objects.requireNonNull(receiverType.cast(holder)),
fieldOffset,
expected,
value);
}
@ForceInline
static boolean weakCompareAndSetAcquire(VarHandle ob, Object holder, long expected, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.weakCompareAndSetLongAcquire(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
expected,
value);
}
// @Override
public boolean weakCompareAndSetAcquire(Object holder, long expected, long value) {
return UNSAFE.weakCompareAndSetLongAcquire(Objects.requireNonNull(receiverType.cast(holder)),
fieldOffset,
expected,
value);
}
@ForceInline
static boolean weakCompareAndSetRelease(VarHandle ob, Object holder, long expected, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.weakCompareAndSetLongRelease(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
expected,
value);
}
// @Override
public boolean weakCompareAndSetRelease(Object holder, long expected, long value) {
return UNSAFE.weakCompareAndSetLongRelease(Objects.requireNonNull(receiverType.cast(holder)),
fieldOffset,
expected,
value);
}
@ForceInline
static long getAndSet(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.getAndSetLong(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public long getAndSet(Object holder, long value) {
return UNSAFE.getAndSetLong(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset,
value);
}
@ForceInline
static long getAndSetAcquire(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.getAndSetLongAcquire(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public long getAndSetAcquire(Object holder, long value) {
return UNSAFE.getAndSetLongAcquire(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset,
value);
}
@ForceInline
static long getAndSetRelease(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.getAndSetLongRelease(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public long getAndSetRelease(Object holder, long value) {
return UNSAFE.getAndSetLongRelease(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset,
value);
}
@ForceInline
static long getAndAdd(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.getAndAddLong(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public long getAndAdd(Object holder, long value) {
return UNSAFE.getAndAddLong(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset, value);
}
@ForceInline
static long getAndAddAcquire(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.getAndAddLongAcquire(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public long getAndAddAcquire(Object holder, long value) {
return UNSAFE.getAndAddLongAcquire(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset, value);
}
@ForceInline
static long getAndAddRelease(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.getAndAddLongRelease(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public long getAndAddRelease(Object holder, long value) {
return UNSAFE.getAndAddLongRelease(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset, value);
}
@ForceInline
static long getAndBitwiseOr(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.getAndBitwiseOrLong(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseOr(Object holder, long value) {
return UNSAFE.getAndBitwiseOrLong(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset, value);
}
@ForceInline
static long getAndBitwiseOrRelease(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.getAndBitwiseOrLongRelease(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseOrRelease(Object holder, long value) {
return UNSAFE.getAndBitwiseOrLongRelease(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset, value);
}
@ForceInline
static long getAndBitwiseOrAcquire(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.getAndBitwiseOrLongAcquire(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseOrAcquire(Object holder, long value) {
return UNSAFE.getAndBitwiseOrLongAcquire(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset, value);
}
@ForceInline
static long getAndBitwiseAnd(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.getAndBitwiseAndLong(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseAnd(Object holder, long value) {
return UNSAFE.getAndBitwiseAndLong(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset, value);
}
@ForceInline
static long getAndBitwiseAndRelease(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.getAndBitwiseAndLongRelease(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseAndRelease(Object holder, long value) {
return UNSAFE.getAndBitwiseAndLongRelease(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset, value);
}
@ForceInline
static long getAndBitwiseAndAcquire(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.getAndBitwiseAndLongAcquire(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseAndAcquire(Object holder, long value) {
return UNSAFE.getAndBitwiseAndLongAcquire(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset, value);
}
@ForceInline
static long getAndBitwiseXor(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.getAndBitwiseXorLong(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseXor(Object holder, long value) {
return UNSAFE.getAndBitwiseXorLong(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset, value);
}
@ForceInline
static long getAndBitwiseXorRelease(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.getAndBitwiseXorLongRelease(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseXorRelease(Object holder, long value) {
return UNSAFE.getAndBitwiseXorLongRelease(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset, value);
}
@ForceInline
static long getAndBitwiseXorAcquire(VarHandle ob, Object holder, long value) {
FieldInstanceReadWrite handle = (FieldInstanceReadWrite)ob;
return UNSAFE.getAndBitwiseXorLongAcquire(Objects.requireNonNull(handle.receiverType.cast(holder)),
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseXorAcquire(Object holder, long value) {
return UNSAFE.getAndBitwiseXorLongAcquire(Objects.requireNonNull(receiverType.cast(holder)), fieldOffset, value);
}
static final VarForm FORM = new VarForm(FieldInstanceReadWrite.class, Object.class, long.class);
}
static class FieldStaticReadOnly extends VarHandle {
final Object base;
final long fieldOffset;
FieldStaticReadOnly(Object base, long fieldOffset) {
this(base, fieldOffset, FieldStaticReadOnly.FORM, false);
}
protected FieldStaticReadOnly(Object base, long fieldOffset,
VarForm form, boolean exact) {
super(form, exact);
this.base = base;
this.fieldOffset = fieldOffset;
}
@Override
public FieldStaticReadOnly withInvokeExactBehavior() {
return hasInvokeExactBehavior()
? this
: new FieldStaticReadOnly(base, fieldOffset, vform, true);
}
@Override
public FieldStaticReadOnly withInvokeBehavior() {
return !hasInvokeExactBehavior()
? this
: new FieldStaticReadOnly(base, fieldOffset, vform, false);
}
@Override
public Optional describeConstable() {
var fieldTypeRef = long.class.describeConstable();
if (!fieldTypeRef.isPresent())
return Optional.empty();
// Reflect on this VarHandle to extract the field name
var staticField = VarHandles.getStaticFieldFromBaseAndOffset(
base, fieldOffset, long.class);
var receiverTypeRef = staticField.getDeclaringClass().describeConstable();
if (!receiverTypeRef.isPresent())
return Optional.empty();
return Optional.of(VarHandleDesc.ofStaticField(receiverTypeRef.get(), staticField.getName(), fieldTypeRef.get()));
}
@Override
final MethodType accessModeTypeUncached(AccessType at) {
return at.accessModeType(null, long.class);
}
@ForceInline
static long get(VarHandle ob) {
FieldStaticReadOnly handle = (FieldStaticReadOnly)ob;
return UNSAFE.getLong(handle.base,
handle.fieldOffset);
}
// @Override
public long get() {
return UNSAFE.getLong(base, fieldOffset);
}
@ForceInline
static long getVolatile(VarHandle ob) {
FieldStaticReadOnly handle = (FieldStaticReadOnly)ob;
return UNSAFE.getLongVolatile(handle.base,
handle.fieldOffset);
}
// @Override
public long getVolatile() {
return UNSAFE.getLongVolatile(base, fieldOffset);
}
@ForceInline
static long getOpaque(VarHandle ob) {
FieldStaticReadOnly handle = (FieldStaticReadOnly)ob;
return UNSAFE.getLongOpaque(handle.base,
handle.fieldOffset);
}
// @Override
public long getOpaque() {
return UNSAFE.getLongOpaque(base, fieldOffset);
}
@ForceInline
static long getAcquire(VarHandle ob) {
FieldStaticReadOnly handle = (FieldStaticReadOnly)ob;
return UNSAFE.getLongAcquire(handle.base,
handle.fieldOffset);
}
// @Override
public long getAcquire() {
return UNSAFE.getLongAcquire(base, fieldOffset);
}
static final VarForm FORM = new VarForm(FieldStaticReadOnly.class, null, long.class);
}
static final class FieldStaticReadWrite extends FieldStaticReadOnly {
FieldStaticReadWrite(Object base, long fieldOffset) {
this(base, fieldOffset, false);
}
private FieldStaticReadWrite(Object base, long fieldOffset,
boolean exact) {
super(base, fieldOffset, FieldStaticReadWrite.FORM, exact);
}
@Override
public FieldStaticReadWrite withInvokeExactBehavior() {
return hasInvokeExactBehavior()
? this
: new FieldStaticReadWrite(base, fieldOffset, true);
}
@Override
public FieldStaticReadWrite withInvokeBehavior() {
return !hasInvokeExactBehavior()
? this
: new FieldStaticReadWrite(base, fieldOffset, false);
}
@ForceInline
static void set(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
UNSAFE.putLong(handle.base,
handle.fieldOffset,
value);
}
// @Override
public void set(long value) {
UNSAFE.putLong(base, fieldOffset, value);
}
@ForceInline
static void setVolatile(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
UNSAFE.putLongVolatile(handle.base,
handle.fieldOffset,
value);
}
// @Override
public void setVolatile(long value) {
UNSAFE.putLongVolatile(base, fieldOffset, value);
}
@ForceInline
static void setOpaque(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
UNSAFE.putLongOpaque(handle.base,
handle.fieldOffset,
value);
}
// @Override
public void setOpaque(long value) {
UNSAFE.putLongOpaque(base, fieldOffset, value);
}
@ForceInline
static void setRelease(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
UNSAFE.putLongRelease(handle.base,
handle.fieldOffset,
value);
}
// @Override
public void setRelease(long value) {
UNSAFE.putLongRelease(base, fieldOffset, value);
}
@ForceInline
static boolean compareAndSet(VarHandle ob, long expected, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.compareAndSetLong(handle.base,
handle.fieldOffset,
expected,
value);
}
// @Override
public boolean compareAndSet(long expected, long value) {
return UNSAFE.compareAndSetLong(base, fieldOffset,
expected,
value);
}
@ForceInline
static long compareAndExchange(VarHandle ob, long expected, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.compareAndExchangeLong(handle.base,
handle.fieldOffset,
expected,
value);
}
// @Override
public long compareAndExchange(long expected, long value) {
return UNSAFE.compareAndExchangeLong(base, fieldOffset,
expected,
value);
}
@ForceInline
static long compareAndExchangeAcquire(VarHandle ob, long expected, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.compareAndExchangeLongAcquire(handle.base,
handle.fieldOffset,
expected,
value);
}
// @Override
public long compareAndExchangeAcquire(long expected, long value) {
return UNSAFE.compareAndExchangeLongAcquire(base, fieldOffset,
expected,
value);
}
@ForceInline
static long compareAndExchangeRelease(VarHandle ob, long expected, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.compareAndExchangeLongRelease(handle.base,
handle.fieldOffset,
expected,
value);
}
// @Override
public long compareAndExchangeRelease(long expected, long value) {
return UNSAFE.compareAndExchangeLongRelease(base, fieldOffset,
expected,
value);
}
@ForceInline
static boolean weakCompareAndSetPlain(VarHandle ob, long expected, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.weakCompareAndSetLongPlain(handle.base,
handle.fieldOffset,
expected,
value);
}
// @Override
public boolean weakCompareAndSetPlain(long expected, long value) {
return UNSAFE.weakCompareAndSetLongPlain(base, fieldOffset,
expected,
value);
}
@ForceInline
static boolean weakCompareAndSet(VarHandle ob, long expected, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.weakCompareAndSetLong(handle.base,
handle.fieldOffset,
expected,
value);
}
// @Override
public boolean weakCompareAndSet(long expected, long value) {
return UNSAFE.weakCompareAndSetLong(base, fieldOffset,
expected,
value);
}
@ForceInline
static boolean weakCompareAndSetAcquire(VarHandle ob, long expected, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.weakCompareAndSetLongAcquire(handle.base,
handle.fieldOffset,
expected,
value);
}
// @Override
public boolean weakCompareAndSetAcquire(long expected, long value) {
return UNSAFE.weakCompareAndSetLongAcquire(base, fieldOffset,
expected,
value);
}
@ForceInline
static boolean weakCompareAndSetRelease(VarHandle ob, long expected, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.weakCompareAndSetLongRelease(handle.base,
handle.fieldOffset,
expected,
value);
}
// @Override
public boolean weakCompareAndSetRelease(long expected, long value) {
return UNSAFE.weakCompareAndSetLongRelease(base, fieldOffset,
expected,
value);
}
@ForceInline
static long getAndSet(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.getAndSetLong(handle.base,
handle.fieldOffset,
value);
}
// @Override
public long getAndSet(long value) {
return UNSAFE.getAndSetLong(base, fieldOffset, value);
}
@ForceInline
static long getAndSetAcquire(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.getAndSetLongAcquire(handle.base,
handle.fieldOffset,
value);
}
// @Override
public long getAndSetAcquire(long value) {
return UNSAFE.getAndSetLongAcquire(base, fieldOffset, value);
}
@ForceInline
static long getAndSetRelease(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.getAndSetLongRelease(handle.base,
handle.fieldOffset,
value);
}
// @Override
public long getAndSetRelease(long value) {
return UNSAFE.getAndSetLongRelease(base, fieldOffset, value);
}
@ForceInline
static long getAndAdd(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.getAndAddLong(handle.base,
handle.fieldOffset,
value);
}
// @Override
public long getAndAdd(long value) {
return UNSAFE.getAndAddLong(base, fieldOffset, value);
}
@ForceInline
static long getAndAddAcquire(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.getAndAddLongAcquire(handle.base,
handle.fieldOffset,
value);
}
// @Override
public long getAndAddAcquire(long value) {
return UNSAFE.getAndAddLongAcquire(base, fieldOffset, value);
}
@ForceInline
static long getAndAddRelease(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.getAndAddLongRelease(handle.base,
handle.fieldOffset,
value);
}
// @Override
public long getAndAddRelease(long value) {
return UNSAFE.getAndAddLongRelease(base, fieldOffset, value);
}
@ForceInline
static long getAndBitwiseOr(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.getAndBitwiseOrLong(handle.base,
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseOr(long value) {
return UNSAFE.getAndBitwiseOrLong(base, fieldOffset, value);
}
@ForceInline
static long getAndBitwiseOrRelease(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.getAndBitwiseOrLongRelease(handle.base,
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseOrRelease(long value) {
return UNSAFE.getAndBitwiseOrLongRelease(base, fieldOffset, value);
}
@ForceInline
static long getAndBitwiseOrAcquire(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.getAndBitwiseOrLongAcquire(handle.base,
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseOrAcquire(long value) {
return UNSAFE.getAndBitwiseOrLongAcquire(base, fieldOffset, value);
}
@ForceInline
static long getAndBitwiseAnd(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.getAndBitwiseAndLong(handle.base,
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseAnd(long value) {
return UNSAFE.getAndBitwiseAndLong(base, fieldOffset, value);
}
@ForceInline
static long getAndBitwiseAndRelease(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.getAndBitwiseAndLongRelease(handle.base,
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseAndRelease(long value) {
return UNSAFE.getAndBitwiseAndLongRelease(base, fieldOffset, value);
}
@ForceInline
static long getAndBitwiseAndAcquire(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.getAndBitwiseAndLongAcquire(handle.base,
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseAndAcquire(long value) {
return UNSAFE.getAndBitwiseAndLongAcquire(base, fieldOffset, value);
}
@ForceInline
static long getAndBitwiseXor(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.getAndBitwiseXorLong(handle.base,
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseXor(long value) {
return UNSAFE.getAndBitwiseXorLong(base, fieldOffset, value);
}
@ForceInline
static long getAndBitwiseXorRelease(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.getAndBitwiseXorLongRelease(handle.base,
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseXorRelease(long value) {
return UNSAFE.getAndBitwiseXorLongRelease(base, fieldOffset, value);
}
@ForceInline
static long getAndBitwiseXorAcquire(VarHandle ob, long value) {
FieldStaticReadWrite handle = (FieldStaticReadWrite)ob;
return UNSAFE.getAndBitwiseXorLongAcquire(handle.base,
handle.fieldOffset,
value);
}
// @Override
public long getAndBitwiseXorAcquire(long value) {
return UNSAFE.getAndBitwiseXorLongAcquire(base, fieldOffset, value);
}
static final VarForm FORM = new VarForm(FieldStaticReadWrite.class, null, long.class);
}
static final class Array extends VarHandle {
final int abase;
final int ashift;
Array(int abase, int ashift) {
this(abase, ashift, false);
}
private Array(int abase, int ashift, boolean exact) {
super(Array.FORM, exact);
this.abase = abase;
this.ashift = ashift;
}
@Override
public Array withInvokeExactBehavior() {
return hasInvokeExactBehavior()
? this
: new Array(abase, ashift, true);
}
@Override
public Array withInvokeBehavior() {
return !hasInvokeExactBehavior()
? this
: new Array(abase, ashift, false);
}
@Override
public Optional describeConstable() {
var arrayTypeRef = long[].class.describeConstable();
if (!arrayTypeRef.isPresent())
return Optional.empty();
return Optional.of(VarHandleDesc.ofArray(arrayTypeRef.get()));
}
@Override
final MethodType accessModeTypeUncached(AccessType at) {
return at.accessModeType(long[].class, long.class, int.class);
}
@ForceInline
static long get(VarHandle ob, Object oarray, int index) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return array[index];
}
// @Override
public long get(Object oarray, int index) {
long[] array = (long[]) oarray;
return array[index];
}
@ForceInline
static void set(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
array[index] = value;
}
// @Override
public void set(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
array[index] = value;
}
@ForceInline
static long getVolatile(VarHandle ob, Object oarray, int index) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getLongVolatile(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase);
}
// @Override
public long getVolatile(Object oarray, int index) {
long[] array = (long[]) oarray;
return UNSAFE.getLongVolatile(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase);
}
@ForceInline
static void setVolatile(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
UNSAFE.putLongVolatile(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public void setVolatile(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
UNSAFE.putLongVolatile(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getOpaque(VarHandle ob, Object oarray, int index) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getLongOpaque(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase);
}
// @Override
public long getOpaque(Object oarray, int index) {
long[] array = (long[]) oarray;
return UNSAFE.getLongOpaque(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase);
}
@ForceInline
static void setOpaque(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
UNSAFE.putLongOpaque(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public void setOpaque(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
UNSAFE.putLongOpaque(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getAcquire(VarHandle ob, Object oarray, int index) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase);
}
// @Override
public long getAcquire(Object oarray, int index) {
long[] array = (long[]) oarray;
return UNSAFE.getLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase);
}
@ForceInline
static void setRelease(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
UNSAFE.putLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public void setRelease(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
UNSAFE.putLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static boolean compareAndSet(VarHandle ob, Object oarray, int index, long expected, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.compareAndSetLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
expected,
value);
}
// @Override
public boolean compareAndSet(Object oarray, int index, long expected, long value) {
long[] array = (long[]) oarray;
return UNSAFE.compareAndSetLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
expected,
value);
}
@ForceInline
static long compareAndExchange(VarHandle ob, Object oarray, int index, long expected, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.compareAndExchangeLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
expected,
value);
}
// @Override
public long compareAndExchange(Object oarray, int index, long expected, long value) {
long[] array = (long[]) oarray;
return UNSAFE.compareAndExchangeLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
expected,
value);
}
@ForceInline
static long compareAndExchangeAcquire(VarHandle ob, Object oarray, int index, long expected, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.compareAndExchangeLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
expected,
value);
}
// @Override
public long compareAndExchangeAcquire(Object oarray, int index, long expected, long value) {
long[] array = (long[]) oarray;
return UNSAFE.compareAndExchangeLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
expected,
value);
}
@ForceInline
static long compareAndExchangeRelease(VarHandle ob, Object oarray, int index, long expected, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.compareAndExchangeLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
expected,
value);
}
// @Override
public long compareAndExchangeRelease(Object oarray, int index, long expected, long value) {
long[] array = (long[]) oarray;
return UNSAFE.compareAndExchangeLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
expected,
value);
}
@ForceInline
static boolean weakCompareAndSetPlain(VarHandle ob, Object oarray, int index, long expected, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.weakCompareAndSetLongPlain(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
expected,
value);
}
// @Override
public boolean weakCompareAndSetPlain(Object oarray, int index, long expected, long value) {
long[] array = (long[]) oarray;
return UNSAFE.weakCompareAndSetLongPlain(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
expected,
value);
}
@ForceInline
static boolean weakCompareAndSet(VarHandle ob, Object oarray, int index, long expected, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.weakCompareAndSetLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
expected,
value);
}
// @Override
public boolean weakCompareAndSet(Object oarray, int index, long expected, long value) {
long[] array = (long[]) oarray;
return UNSAFE.weakCompareAndSetLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
expected,
value);
}
@ForceInline
static boolean weakCompareAndSetAcquire(VarHandle ob, Object oarray, int index, long expected, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.weakCompareAndSetLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
expected,
value);
}
// @Override
public boolean weakCompareAndSetAcquire(Object oarray, int index, long expected, long value) {
long[] array = (long[]) oarray;
return UNSAFE.weakCompareAndSetLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
expected,
value);
}
@ForceInline
static boolean weakCompareAndSetRelease(VarHandle ob, Object oarray, int index, long expected, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.weakCompareAndSetLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
expected,
value);
}
// @Override
public boolean weakCompareAndSetRelease(Object oarray, int index, long expected, long value) {
long[] array = (long[]) oarray;
return UNSAFE.weakCompareAndSetLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
expected,
value);
}
@ForceInline
static long getAndSet(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getAndSetLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public long getAndSet(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
return UNSAFE.getAndSetLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getAndSetAcquire(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getAndSetLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public long getAndSetAcquire(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
return UNSAFE.getAndSetLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getAndSetRelease(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getAndSetLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public long getAndSetRelease(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
return UNSAFE.getAndSetLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getAndAdd(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getAndAddLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public long getAndAdd(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
return UNSAFE.getAndAddLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getAndAddAcquire(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getAndAddLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public long getAndAddAcquire(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
return UNSAFE.getAndAddLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getAndAddRelease(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getAndAddLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public long getAndAddRelease(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
return UNSAFE.getAndAddLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getAndBitwiseOr(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseOrLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public long getAndBitwiseOr(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseOrLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getAndBitwiseOrRelease(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseOrLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public long getAndBitwiseOrRelease(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseOrLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getAndBitwiseOrAcquire(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseOrLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public long getAndBitwiseOrAcquire(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseOrLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getAndBitwiseAnd(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseAndLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public long getAndBitwiseAnd(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseAndLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getAndBitwiseAndRelease(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseAndLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public long getAndBitwiseAndRelease(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseAndLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getAndBitwiseAndAcquire(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseAndLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public long getAndBitwiseAndAcquire(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseAndLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getAndBitwiseXor(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseXorLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public long getAndBitwiseXor(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseXorLong(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getAndBitwiseXorRelease(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseXorLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public long getAndBitwiseXorRelease(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseXorLongRelease(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
@ForceInline
static long getAndBitwiseXorAcquire(VarHandle ob, Object oarray, int index, long value) {
Array handle = (Array)ob;
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseXorLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << handle.ashift) + handle.abase,
value);
}
// @Override
public long getAndBitwiseXorAcquire(Object oarray, int index, long value) {
long[] array = (long[]) oarray;
return UNSAFE.getAndBitwiseXorLongAcquire(array,
(((long) Preconditions.checkIndex(index, array.length, AIOOBE_SUPPLIER)) << ashift) + abase,
value);
}
static final VarForm FORM = new VarForm(Array.class, long[].class, long.class, int.class);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy