/** * Padded variant of AtomicLong supporting only raw accesses plus CAS. * * JVM intrinsics note: It would be possible to use a release-only * form of CAS here, if it were provided. */ @sun.misc.Contended staticfinalclassCell { volatilelong value; Cell(long x) { value = x; } finalbooleancas(long cmp, long val) { return UNSAFE.compareAndSwapLong(this, valueOffset, cmp, val); }