HomeSort by relevance Sort by last modified time
    Searched full:unsafe (Results 1 - 25 of 374) sorted by null

1 2 3 4 5 6 7 8 91011>>

  /dalvik/tests/067-preemptive-unpark/
info.txt 1 Test that Unsafe.unpark() operates as expected, in particular across a gc.
  /libcore/luni/src/main/java/java/util/concurrent/atomic/
UnsafeAccess.java 19 import sun.misc.Unsafe;
22 * Easy access to {@link Unsafe} for the rest of this package.
25 /** non-null; unique instance of {@link Unsafe} */
26 /*package*/ static final Unsafe THE_ONE = Unsafe.getUnsafe();
AtomicBoolean.java 8 import sun.misc.Unsafe;
23 // setup to use Unsafe.compareAndSwapInt for updates
24 private static final Unsafe unsafe = UnsafeAccess.THE_ONE; // android-changed field in class:AtomicBoolean
29 valueOffset = unsafe.objectFieldOffset
72 return unsafe.compareAndSwapInt(this, valueOffset, e, u);
90 return unsafe.compareAndSwapInt(this, valueOffset, e, u);
110 unsafe.putOrderedInt(this, valueOffset, v);
AtomicReference.java 8 import sun.misc.Unsafe;
21 private static final Unsafe unsafe = UnsafeAccess.THE_ONE; // android-changed field in class:AtomicReference
26 valueOffset = unsafe.objectFieldOffset
73 unsafe.putOrderedObject(this, valueOffset, newValue);
85 return unsafe.compareAndSwapObject(this, valueOffset, expect, update);
101 return unsafe.compareAndSwapObject(this, valueOffset, expect, update);
AtomicIntegerArray.java 9 import sun.misc.Unsafe;
22 private static final Unsafe unsafe = UnsafeAccess.THE_ONE; // android-changed field in class:AtomicIntegerArray
23 private static final int base = unsafe.arrayBaseOffset(int[].class);
24 private static final int scale = unsafe.arrayIndexScale(int[].class);
80 return unsafe.getIntVolatile(array, offset);
90 unsafe.putIntVolatile(array, checkedByteOffset(i), newValue);
101 unsafe.putOrderedInt(array, checkedByteOffset(i), newValue);
136 return unsafe.compareAndSwapInt(array, offset, expect, update);
AtomicLong.java 8 import sun.misc.Unsafe;
26 // setup to use Unsafe.compareAndSwapLong for updates
27 private static final Unsafe unsafe = UnsafeAccess.THE_ONE; // android-changed field in class:AtomicLong
32 * compareAndSwap for longs. While the Unsafe.compareAndSwapLong
48 valueOffset = unsafe.objectFieldOffset
104 unsafe.putOrderedLong(this, valueOffset, newValue);
131 return unsafe.compareAndSwapLong(this, valueOffset, expect, update);
147 return unsafe.compareAndSwapLong(this, valueOffset, expect, update);
AtomicLongArray.java 9 import sun.misc.Unsafe;
21 private static final Unsafe unsafe = UnsafeAccess.THE_ONE; // android-changed field in class:AtomicLongArray
22 private static final int base = unsafe.arrayBaseOffset(long[].class);
23 private static final int scale = unsafe.arrayIndexScale(long[].class);
79 return unsafe.getLongVolatile(array, offset);
89 unsafe.putLongVolatile(array, checkedByteOffset(i), newValue);
100 unsafe.putOrderedLong(array, checkedByteOffset(i), newValue);
136 return unsafe.compareAndSwapLong(array, offset, expect, update);
AtomicReferenceArray.java 9 import sun.misc.Unsafe;
23 private static final Unsafe unsafe = UnsafeAccess.THE_ONE; // android-changed field in class:AtomicReferenceArray
24 private static final int base = unsafe.arrayBaseOffset(Object[].class);
25 private static final int scale = unsafe.arrayIndexScale(Object[].class);
81 return (E) unsafe.getObjectVolatile(array, offset);
91 unsafe.putObjectVolatile(array, checkedByteOffset(i), newValue);
102 unsafe.putOrderedObject(array, checkedByteOffset(i), newValue);
138 return unsafe.compareAndSwapObject(array, offset, expect, update);
AtomicInteger.java 8 import sun.misc.Unsafe;
26 // setup to use Unsafe.compareAndSwapInt for updates
27 private static final Unsafe unsafe = UnsafeAccess.THE_ONE; // android-changed field in class:AtomicInteger
32 valueOffset = unsafe.objectFieldOffset
79 unsafe.putOrderedInt(this, valueOffset, newValue);
106 return unsafe.compareAndSwapInt(this, valueOffset, expect, update);
122 return unsafe.compareAndSwapInt(this, valueOffset, expect, update);
AtomicLongFieldUpdater.java 13 import sun.misc.Unsafe;
240 private static final Unsafe unsafe = UnsafeAccess.THE_ONE; // android-changed field in class:AtomicLongFieldUpdater.CASUpdater
281 offset = unsafe.objectFieldOffset(field);
293 return unsafe.compareAndSwapLong(obj, offset, expect, update);
298 return unsafe.compareAndSwapLong(obj, offset, expect, update);
303 unsafe.putLongVolatile(obj, offset, newValue);
308 unsafe.putOrderedLong(obj, offset, newValue);
313 return unsafe.getLongVolatile(obj, offset);
334 private static final Unsafe unsafe = UnsafeAccess.THE_ONE; // android-change field in class:AtomicLongFieldUpdater.LockedUpdater
    [all...]
AtomicReferenceFieldUpdater.java 13 import sun.misc.Unsafe;
158 private static final Unsafe unsafe = Unsafe.getUnsafe(); field in class:AtomicReferenceFieldUpdater.AtomicReferenceFieldUpdaterImpl
219 offset = unsafe.objectFieldOffset(field);
242 return unsafe.compareAndSwapObject(obj, offset, expect, update);
251 return unsafe.compareAndSwapObject(obj, offset, expect, update);
259 unsafe.putObjectVolatile(obj, offset, newValue);
267 unsafe.putOrderedObject(obj, offset, newValue);
273 return (V)unsafe.getObjectVolatile(obj, offset)
    [all...]
AtomicIntegerFieldUpdater.java 13 import sun.misc.Unsafe;
241 private static final Unsafe unsafe = UnsafeAccess.THE_ONE; // android-changed field in class:AtomicIntegerFieldUpdater.AtomicIntegerFieldUpdaterImpl
286 offset = unsafe.objectFieldOffset(field);
298 return unsafe.compareAndSwapInt(obj, offset, expect, update);
303 return unsafe.compareAndSwapInt(obj, offset, expect, update);
308 unsafe.putIntVolatile(obj, offset, newValue);
313 unsafe.putOrderedInt(obj, offset, newValue);
318 return unsafe.getIntVolatile(obj, offset);
  /libcore/luni/src/main/java/java/util/concurrent/locks/
UnsafeAccess.java 19 import sun.misc.Unsafe;
22 * Easy access to {@link Unsafe} for the rest of this package.
25 /** non-null; unique instance of {@link Unsafe} */
26 /*package*/ static final Unsafe THE_ONE = Unsafe.getUnsafe();
LockSupport.java 9 import sun.misc.Unsafe;
95 private static final Unsafe unsafe = UnsafeAccess.THE_ONE; // android-changed field in class:LockSupport
100 parkBlockerOffset = unsafe.objectFieldOffset
107 unsafe.putObject(t, parkBlockerOffset, arg);
123 unsafe.unpark(thread);
157 unsafe.park(false, 0L);
197 unsafe.park(false, nanos);
238 unsafe.park(true, deadline);
253 return unsafe.getObjectVolatile(t, parkBlockerOffset)
    [all...]
  /external/clearsilver/csharp/
CS.cs 8 public unsafe struct HDF {};
9 public unsafe struct NEOERR {};
11 public unsafe class Hdf {
14 private static extern unsafe NEOERR* hdf_init(HDF **foo);
18 private static unsafe extern NEOERR* hdf_set_value(HDF *hdf,
28 private static unsafe extern string hdf_get_value(HDF *hdf,
83 unsafe struct CSPARSE {};
86 unsafe CSPARSE *csp;
87 unsafe public CSTContext(Hdf hdf) {
94 extern static unsafe NEOERR *cs_init (CSPARSE **parse, HDF *hdf)
    [all...]
cstest.cs 7 public static unsafe int Main(string[] argv) {
Makefile 22 $(CSHARP_CC) -target:library -unsafe CS.cs -out:clearsilver.dll
25 $(CSHARP_CC) -r:clearsilver.dll -unsafe cstest.cs
28 $(CSHARP_CC) -r:clearsilver.dll -unsafe csperftest.cs
README 17 merely access the structure members directly from C# unsafe code, just
csperftest.cs 21 public static unsafe int Main(string[] argv) {
  /dalvik/tests/067-preemptive-unpark/src/
Main.java 1 import sun.misc.Unsafe;
6 private static Unsafe UNSAFE;
16 UNSAFE.unpark(test);
40 * Set up {@link #UNSAFE}.
44 * Subvert the access check to get the unique Unsafe instance.
49 Field field = Unsafe.class.getDeclaredField("THE_ONE");
52 UNSAFE = (Unsafe) field.get(null);
95 UNSAFE.park(false, 500 * 1000000); // 500 mse
    [all...]
  /libcore/luni/src/test/java/tests/api/org/apache/harmony/kernel/dalvik/
ThreadsTest.java 23 import sun.misc.Unsafe;
26 * Tests for the <code>park()</code> functionality of {@link Unsafe}.
29 private static Unsafe UNSAFE = null;
34 * Set up {@link #UNSAFE}. This subverts the access check to
35 * get the unique Unsafe instance. We can do this because
40 Field field = Unsafe.class.getDeclaredField("THE_ONE");
43 UNSAFE = (Unsafe) field.get(null);
80 UNSAFE.unpark(parkerThread)
    [all...]
  /libcore/luni/src/test/java/sun/misc/
UnsafeTest.java 28 Unsafe.getUnsafe();
41 Unsafe.getUnsafe();
  /libcore/luni/src/main/java/java/util/concurrent/
ConcurrentLinkedQueue.java 148 return UNSAFE.compareAndSwapObject(this, itemOffset, cmp, val);
156 UNSAFE.putOrderedObject(this, itemOffset, val);
160 UNSAFE.putOrderedObject(this, nextOffset, val);
168 return UNSAFE.compareAndSwapObject(this, nextOffset, cmp, val);
171 // Unsafe mechanics
173 private static final sun.misc.Unsafe UNSAFE =
174 sun.misc.Unsafe.getUnsafe();
176 objectFieldOffset(UNSAFE, "next", Node.class);
178 objectFieldOffset(UNSAFE, "item", Node.class)
    [all...]
ConcurrentLinkedDeque.java 217 return UNSAFE.compareAndSwapObject(this, itemOffset, cmp, val);
221 UNSAFE.putOrderedObject(this, itemOffset, val);
225 UNSAFE.putOrderedObject(this, nextOffset, val);
229 return UNSAFE.compareAndSwapObject(this, nextOffset, cmp, val);
233 UNSAFE.putOrderedObject(this, prevOffset, val);
237 return UNSAFE.compareAndSwapObject(this, prevOffset, cmp, val);
240 // Unsafe mechanics
242 private static final sun.misc.Unsafe UNSAFE =
243 sun.misc.Unsafe.getUnsafe()
    [all...]
  /libcore/luni/src/main/java/sun/misc/
Unsafe.java 30 public final class Unsafe {
32 private static final Unsafe THE_ONE = new Unsafe();
40 private Unsafe() {
48 public static Unsafe getUnsafe() {
51 * Unsafe instance.
54 if ((calling != null) && (calling != Unsafe.class.getClassLoader())) {
55 throw new SecurityException("Unsafe access denied");

Completed in 172 milliseconds

1 2 3 4 5 6 7 8 91011>>