846 lines
21 KiB
Smali
846 lines
21 KiB
Smali
.class public final Lrx/internal/util/a/f;
|
|
.super Ljava/lang/Object;
|
|
.source "SpscLinkedArrayQueue.java"
|
|
|
|
# interfaces
|
|
.implements Ljava/util/Queue;
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"<T:",
|
|
"Ljava/lang/Object;",
|
|
">",
|
|
"Ljava/lang/Object;",
|
|
"Ljava/util/Queue<",
|
|
"TT;>;"
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# static fields
|
|
.field private static final bNA:Ljava/lang/Object;
|
|
|
|
.field static final bNu:I
|
|
|
|
|
|
# instance fields
|
|
.field bNs:J
|
|
|
|
.field bNv:I
|
|
|
|
.field bNw:I
|
|
|
|
.field bNx:Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"Ljava/util/concurrent/atomic/AtomicReferenceArray<",
|
|
"Ljava/lang/Object;",
|
|
">;"
|
|
}
|
|
.end annotation
|
|
.end field
|
|
|
|
.field bNy:I
|
|
|
|
.field bNz:Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"Ljava/util/concurrent/atomic/AtomicReferenceArray<",
|
|
"Ljava/lang/Object;",
|
|
">;"
|
|
}
|
|
.end annotation
|
|
.end field
|
|
|
|
.field final consumerIndex:Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
.field final producerIndex:Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
|
|
# direct methods
|
|
.method static constructor <clinit>()V
|
|
.locals 2
|
|
|
|
const-string v0, "jctools.spsc.max.lookahead.step"
|
|
|
|
const/16 v1, 0x1000
|
|
|
|
invoke-static {v0, v1}, Ljava/lang/Integer;->getInteger(Ljava/lang/String;I)Ljava/lang/Integer;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0}, Ljava/lang/Integer;->intValue()I
|
|
|
|
move-result v0
|
|
|
|
sput v0, Lrx/internal/util/a/f;->bNu:I
|
|
|
|
new-instance v0, Ljava/lang/Object;
|
|
|
|
invoke-direct {v0}, Ljava/lang/Object;-><init>()V
|
|
|
|
sput-object v0, Lrx/internal/util/a/f;->bNA:Ljava/lang/Object;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(I)V
|
|
.locals 3
|
|
|
|
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
|
|
|
|
invoke-static {p1}, Lrx/internal/util/b/h;->dV(I)I
|
|
|
|
move-result p1
|
|
|
|
add-int/lit8 v0, p1, -0x1
|
|
|
|
new-instance v1, Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
add-int/lit8 v2, p1, 0x1
|
|
|
|
invoke-direct {v1, v2}, Ljava/util/concurrent/atomic/AtomicReferenceArray;-><init>(I)V
|
|
|
|
iput-object v1, p0, Lrx/internal/util/a/f;->bNx:Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
iput v0, p0, Lrx/internal/util/a/f;->bNw:I
|
|
|
|
div-int/lit8 p1, p1, 0x4
|
|
|
|
sget v2, Lrx/internal/util/a/f;->bNu:I
|
|
|
|
invoke-static {p1, v2}, Ljava/lang/Math;->min(II)I
|
|
|
|
move-result p1
|
|
|
|
iput p1, p0, Lrx/internal/util/a/f;->bNv:I
|
|
|
|
iput-object v1, p0, Lrx/internal/util/a/f;->bNz:Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
iput v0, p0, Lrx/internal/util/a/f;->bNy:I
|
|
|
|
add-int/lit8 v0, v0, -0x1
|
|
|
|
int-to-long v0, v0
|
|
|
|
iput-wide v0, p0, Lrx/internal/util/a/f;->bNs:J
|
|
|
|
new-instance p1, Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
invoke-direct {p1}, Ljava/util/concurrent/atomic/AtomicLong;-><init>()V
|
|
|
|
iput-object p1, p0, Lrx/internal/util/a/f;->producerIndex:Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
new-instance p1, Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
invoke-direct {p1}, Ljava/util/concurrent/atomic/AtomicLong;-><init>()V
|
|
|
|
iput-object p1, p0, Lrx/internal/util/a/f;->consumerIndex:Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private static a(Ljava/util/concurrent/atomic/AtomicReferenceArray;)Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
.locals 1
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/util/concurrent/atomic/AtomicReferenceArray<",
|
|
"Ljava/lang/Object;",
|
|
">;)",
|
|
"Ljava/util/concurrent/atomic/AtomicReferenceArray<",
|
|
"Ljava/lang/Object;",
|
|
">;"
|
|
}
|
|
.end annotation
|
|
|
|
invoke-virtual {p0}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->length()I
|
|
|
|
move-result v0
|
|
|
|
add-int/lit8 v0, v0, -0x1
|
|
|
|
invoke-virtual {p0, v0}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->get(I)Ljava/lang/Object;
|
|
|
|
move-result-object p0
|
|
|
|
check-cast p0, Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method private static a(Ljava/util/concurrent/atomic/AtomicReferenceArray;Ljava/util/concurrent/atomic/AtomicReferenceArray;)V
|
|
.locals 1
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/util/concurrent/atomic/AtomicReferenceArray<",
|
|
"Ljava/lang/Object;",
|
|
">;",
|
|
"Ljava/util/concurrent/atomic/AtomicReferenceArray<",
|
|
"Ljava/lang/Object;",
|
|
">;)V"
|
|
}
|
|
.end annotation
|
|
|
|
invoke-virtual {p0}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->length()I
|
|
|
|
move-result v0
|
|
|
|
add-int/lit8 v0, v0, -0x1
|
|
|
|
invoke-virtual {p0, v0, p1}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->lazySet(ILjava/lang/Object;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private a(Ljava/util/concurrent/atomic/AtomicReferenceArray;Ljava/lang/Object;JI)Z
|
|
.locals 0
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/util/concurrent/atomic/AtomicReferenceArray<",
|
|
"Ljava/lang/Object;",
|
|
">;TT;JI)Z"
|
|
}
|
|
.end annotation
|
|
|
|
invoke-virtual {p1, p5, p2}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->lazySet(ILjava/lang/Object;)V
|
|
|
|
const-wide/16 p1, 0x1
|
|
|
|
add-long/2addr p3, p1
|
|
|
|
invoke-direct {p0, p3, p4}, Lrx/internal/util/a/f;->aT(J)V
|
|
|
|
const/4 p1, 0x1
|
|
|
|
return p1
|
|
.end method
|
|
|
|
.method private aT(J)V
|
|
.locals 1
|
|
|
|
iget-object v0, p0, Lrx/internal/util/a/f;->producerIndex:Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
invoke-virtual {v0, p1, p2}, Ljava/util/concurrent/atomic/AtomicLong;->lazySet(J)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private aU(J)V
|
|
.locals 1
|
|
|
|
iget-object v0, p0, Lrx/internal/util/a/f;->consumerIndex:Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
invoke-virtual {v0, p1, p2}, Ljava/util/concurrent/atomic/AtomicLong;->lazySet(J)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public final add(Ljava/lang/Object;)Z
|
|
.locals 0
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(TT;)Z"
|
|
}
|
|
.end annotation
|
|
|
|
new-instance p1, Ljava/lang/UnsupportedOperationException;
|
|
|
|
invoke-direct {p1}, Ljava/lang/UnsupportedOperationException;-><init>()V
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public final addAll(Ljava/util/Collection;)Z
|
|
.locals 0
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/util/Collection<",
|
|
"+TT;>;)Z"
|
|
}
|
|
.end annotation
|
|
|
|
new-instance p1, Ljava/lang/UnsupportedOperationException;
|
|
|
|
invoke-direct {p1}, Ljava/lang/UnsupportedOperationException;-><init>()V
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public final clear()V
|
|
.locals 1
|
|
|
|
:cond_0
|
|
invoke-virtual {p0}, Lrx/internal/util/a/f;->poll()Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
invoke-virtual {p0}, Lrx/internal/util/a/f;->isEmpty()Z
|
|
|
|
move-result v0
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public final contains(Ljava/lang/Object;)Z
|
|
.locals 0
|
|
|
|
new-instance p1, Ljava/lang/UnsupportedOperationException;
|
|
|
|
invoke-direct {p1}, Ljava/lang/UnsupportedOperationException;-><init>()V
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public final containsAll(Ljava/util/Collection;)Z
|
|
.locals 0
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/util/Collection<",
|
|
"*>;)Z"
|
|
}
|
|
.end annotation
|
|
|
|
new-instance p1, Ljava/lang/UnsupportedOperationException;
|
|
|
|
invoke-direct {p1}, Ljava/lang/UnsupportedOperationException;-><init>()V
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public final element()Ljava/lang/Object;
|
|
.locals 1
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"()TT;"
|
|
}
|
|
.end annotation
|
|
|
|
new-instance v0, Ljava/lang/UnsupportedOperationException;
|
|
|
|
invoke-direct {v0}, Ljava/lang/UnsupportedOperationException;-><init>()V
|
|
|
|
throw v0
|
|
.end method
|
|
|
|
.method public final isEmpty()Z
|
|
.locals 5
|
|
|
|
iget-object v0, p0, Lrx/internal/util/a/f;->producerIndex:Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
invoke-virtual {v0}, Ljava/util/concurrent/atomic/AtomicLong;->get()J
|
|
|
|
move-result-wide v0
|
|
|
|
iget-object v2, p0, Lrx/internal/util/a/f;->consumerIndex:Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
invoke-virtual {v2}, Ljava/util/concurrent/atomic/AtomicLong;->get()J
|
|
|
|
move-result-wide v2
|
|
|
|
cmp-long v4, v0, v2
|
|
|
|
if-nez v4, :cond_0
|
|
|
|
const/4 v0, 0x1
|
|
|
|
return v0
|
|
|
|
:cond_0
|
|
const/4 v0, 0x0
|
|
|
|
return v0
|
|
.end method
|
|
|
|
.method public final iterator()Ljava/util/Iterator;
|
|
.locals 1
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"()",
|
|
"Ljava/util/Iterator<",
|
|
"TT;>;"
|
|
}
|
|
.end annotation
|
|
|
|
new-instance v0, Ljava/lang/UnsupportedOperationException;
|
|
|
|
invoke-direct {v0}, Ljava/lang/UnsupportedOperationException;-><init>()V
|
|
|
|
throw v0
|
|
.end method
|
|
|
|
.method public final k(Ljava/lang/Object;Ljava/lang/Object;)Z
|
|
.locals 8
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(TT;TT;)Z"
|
|
}
|
|
.end annotation
|
|
|
|
iget-object v0, p0, Lrx/internal/util/a/f;->bNx:Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
iget-object v1, p0, Lrx/internal/util/a/f;->producerIndex:Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
invoke-virtual {v1}, Ljava/util/concurrent/atomic/AtomicLong;->get()J
|
|
|
|
move-result-wide v1
|
|
|
|
iget v3, p0, Lrx/internal/util/a/f;->bNw:I
|
|
|
|
const-wide/16 v4, 0x2
|
|
|
|
add-long/2addr v4, v1
|
|
|
|
long-to-int v6, v4
|
|
|
|
and-int/2addr v6, v3
|
|
|
|
invoke-virtual {v0, v6}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->get(I)Ljava/lang/Object;
|
|
|
|
move-result-object v6
|
|
|
|
if-nez v6, :cond_0
|
|
|
|
long-to-int v2, v1
|
|
|
|
and-int v1, v2, v3
|
|
|
|
add-int/lit8 v2, v1, 0x1
|
|
|
|
invoke-virtual {v0, v2, p2}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->lazySet(ILjava/lang/Object;)V
|
|
|
|
invoke-virtual {v0, v1, p1}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->lazySet(ILjava/lang/Object;)V
|
|
|
|
invoke-direct {p0, v4, v5}, Lrx/internal/util/a/f;->aT(J)V
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
invoke-virtual {v0}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->length()I
|
|
|
|
move-result v6
|
|
|
|
new-instance v7, Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
invoke-direct {v7, v6}, Ljava/util/concurrent/atomic/AtomicReferenceArray;-><init>(I)V
|
|
|
|
iput-object v7, p0, Lrx/internal/util/a/f;->bNx:Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
long-to-int v2, v1
|
|
|
|
and-int v1, v2, v3
|
|
|
|
add-int/lit8 v2, v1, 0x1
|
|
|
|
invoke-virtual {v7, v2, p2}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->lazySet(ILjava/lang/Object;)V
|
|
|
|
invoke-virtual {v7, v1, p1}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->lazySet(ILjava/lang/Object;)V
|
|
|
|
invoke-static {v0, v7}, Lrx/internal/util/a/f;->a(Ljava/util/concurrent/atomic/AtomicReferenceArray;Ljava/util/concurrent/atomic/AtomicReferenceArray;)V
|
|
|
|
sget-object p1, Lrx/internal/util/a/f;->bNA:Ljava/lang/Object;
|
|
|
|
invoke-virtual {v0, v1, p1}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->lazySet(ILjava/lang/Object;)V
|
|
|
|
invoke-direct {p0, v4, v5}, Lrx/internal/util/a/f;->aT(J)V
|
|
|
|
:goto_0
|
|
const/4 p1, 0x1
|
|
|
|
return p1
|
|
.end method
|
|
|
|
.method public final offer(Ljava/lang/Object;)Z
|
|
.locals 12
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(TT;)Z"
|
|
}
|
|
.end annotation
|
|
|
|
iget-object v1, p0, Lrx/internal/util/a/f;->bNx:Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
iget-object v0, p0, Lrx/internal/util/a/f;->producerIndex:Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
invoke-virtual {v0}, Ljava/util/concurrent/atomic/AtomicLong;->get()J
|
|
|
|
move-result-wide v3
|
|
|
|
iget v0, p0, Lrx/internal/util/a/f;->bNw:I
|
|
|
|
long-to-int v2, v3
|
|
|
|
and-int v5, v2, v0
|
|
|
|
iget-wide v6, p0, Lrx/internal/util/a/f;->bNs:J
|
|
|
|
cmp-long v2, v3, v6
|
|
|
|
if-gez v2, :cond_0
|
|
|
|
move-object v0, p0
|
|
|
|
move-object v2, p1
|
|
|
|
invoke-direct/range {v0 .. v5}, Lrx/internal/util/a/f;->a(Ljava/util/concurrent/atomic/AtomicReferenceArray;Ljava/lang/Object;JI)Z
|
|
|
|
move-result p1
|
|
|
|
return p1
|
|
|
|
:cond_0
|
|
iget v2, p0, Lrx/internal/util/a/f;->bNv:I
|
|
|
|
int-to-long v6, v2
|
|
|
|
add-long/2addr v6, v3
|
|
|
|
long-to-int v2, v6
|
|
|
|
and-int/2addr v2, v0
|
|
|
|
invoke-virtual {v1, v2}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->get(I)Ljava/lang/Object;
|
|
|
|
move-result-object v2
|
|
|
|
const-wide/16 v8, 0x1
|
|
|
|
if-nez v2, :cond_1
|
|
|
|
sub-long/2addr v6, v8
|
|
|
|
iput-wide v6, p0, Lrx/internal/util/a/f;->bNs:J
|
|
|
|
move-object v0, p0
|
|
|
|
move-object v2, p1
|
|
|
|
invoke-direct/range {v0 .. v5}, Lrx/internal/util/a/f;->a(Ljava/util/concurrent/atomic/AtomicReferenceArray;Ljava/lang/Object;JI)Z
|
|
|
|
move-result p1
|
|
|
|
return p1
|
|
|
|
:cond_1
|
|
add-long v6, v3, v8
|
|
|
|
long-to-int v2, v6
|
|
|
|
and-int/2addr v2, v0
|
|
|
|
invoke-virtual {v1, v2}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->get(I)Ljava/lang/Object;
|
|
|
|
move-result-object v2
|
|
|
|
if-nez v2, :cond_2
|
|
|
|
move-object v0, p0
|
|
|
|
move-object v2, p1
|
|
|
|
invoke-direct/range {v0 .. v5}, Lrx/internal/util/a/f;->a(Ljava/util/concurrent/atomic/AtomicReferenceArray;Ljava/lang/Object;JI)Z
|
|
|
|
move-result p1
|
|
|
|
return p1
|
|
|
|
:cond_2
|
|
int-to-long v10, v0
|
|
|
|
invoke-virtual {v1}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->length()I
|
|
|
|
move-result v0
|
|
|
|
new-instance v2, Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
invoke-direct {v2, v0}, Ljava/util/concurrent/atomic/AtomicReferenceArray;-><init>(I)V
|
|
|
|
iput-object v2, p0, Lrx/internal/util/a/f;->bNx:Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
add-long/2addr v3, v10
|
|
|
|
sub-long/2addr v3, v8
|
|
|
|
iput-wide v3, p0, Lrx/internal/util/a/f;->bNs:J
|
|
|
|
invoke-virtual {v2, v5, p1}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->lazySet(ILjava/lang/Object;)V
|
|
|
|
invoke-static {v1, v2}, Lrx/internal/util/a/f;->a(Ljava/util/concurrent/atomic/AtomicReferenceArray;Ljava/util/concurrent/atomic/AtomicReferenceArray;)V
|
|
|
|
sget-object p1, Lrx/internal/util/a/f;->bNA:Ljava/lang/Object;
|
|
|
|
invoke-virtual {v1, v5, p1}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->lazySet(ILjava/lang/Object;)V
|
|
|
|
invoke-direct {p0, v6, v7}, Lrx/internal/util/a/f;->aT(J)V
|
|
|
|
const/4 p1, 0x1
|
|
|
|
return p1
|
|
.end method
|
|
|
|
.method public final peek()Ljava/lang/Object;
|
|
.locals 4
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"()TT;"
|
|
}
|
|
.end annotation
|
|
|
|
iget-object v0, p0, Lrx/internal/util/a/f;->bNz:Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
iget-object v1, p0, Lrx/internal/util/a/f;->consumerIndex:Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
invoke-virtual {v1}, Ljava/util/concurrent/atomic/AtomicLong;->get()J
|
|
|
|
move-result-wide v1
|
|
|
|
iget v3, p0, Lrx/internal/util/a/f;->bNy:I
|
|
|
|
long-to-int v2, v1
|
|
|
|
and-int v1, v2, v3
|
|
|
|
invoke-virtual {v0, v1}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->get(I)Ljava/lang/Object;
|
|
|
|
move-result-object v2
|
|
|
|
sget-object v3, Lrx/internal/util/a/f;->bNA:Ljava/lang/Object;
|
|
|
|
if-ne v2, v3, :cond_0
|
|
|
|
invoke-static {v0}, Lrx/internal/util/a/f;->a(Ljava/util/concurrent/atomic/AtomicReferenceArray;)Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lrx/internal/util/a/f;->bNz:Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
invoke-virtual {v0, v1}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->get(I)Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
return-object v0
|
|
|
|
:cond_0
|
|
return-object v2
|
|
.end method
|
|
|
|
.method public final poll()Ljava/lang/Object;
|
|
.locals 9
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"()TT;"
|
|
}
|
|
.end annotation
|
|
|
|
iget-object v0, p0, Lrx/internal/util/a/f;->bNz:Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
iget-object v1, p0, Lrx/internal/util/a/f;->consumerIndex:Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
invoke-virtual {v1}, Ljava/util/concurrent/atomic/AtomicLong;->get()J
|
|
|
|
move-result-wide v1
|
|
|
|
iget v3, p0, Lrx/internal/util/a/f;->bNy:I
|
|
|
|
long-to-int v4, v1
|
|
|
|
and-int/2addr v3, v4
|
|
|
|
invoke-virtual {v0, v3}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->get(I)Ljava/lang/Object;
|
|
|
|
move-result-object v4
|
|
|
|
sget-object v5, Lrx/internal/util/a/f;->bNA:Ljava/lang/Object;
|
|
|
|
if-ne v4, v5, :cond_0
|
|
|
|
const/4 v5, 0x1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 v5, 0x0
|
|
|
|
:goto_0
|
|
const-wide/16 v6, 0x1
|
|
|
|
const/4 v8, 0x0
|
|
|
|
if-eqz v4, :cond_1
|
|
|
|
if-nez v5, :cond_1
|
|
|
|
invoke-virtual {v0, v3, v8}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->lazySet(ILjava/lang/Object;)V
|
|
|
|
add-long/2addr v1, v6
|
|
|
|
invoke-direct {p0, v1, v2}, Lrx/internal/util/a/f;->aU(J)V
|
|
|
|
return-object v4
|
|
|
|
:cond_1
|
|
if-eqz v5, :cond_3
|
|
|
|
invoke-static {v0}, Lrx/internal/util/a/f;->a(Ljava/util/concurrent/atomic/AtomicReferenceArray;)Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lrx/internal/util/a/f;->bNz:Ljava/util/concurrent/atomic/AtomicReferenceArray;
|
|
|
|
invoke-virtual {v0, v3}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->get(I)Ljava/lang/Object;
|
|
|
|
move-result-object v4
|
|
|
|
if-nez v4, :cond_2
|
|
|
|
return-object v8
|
|
|
|
:cond_2
|
|
invoke-virtual {v0, v3, v8}, Ljava/util/concurrent/atomic/AtomicReferenceArray;->lazySet(ILjava/lang/Object;)V
|
|
|
|
add-long/2addr v1, v6
|
|
|
|
invoke-direct {p0, v1, v2}, Lrx/internal/util/a/f;->aU(J)V
|
|
|
|
return-object v4
|
|
|
|
:cond_3
|
|
return-object v8
|
|
.end method
|
|
|
|
.method public final remove()Ljava/lang/Object;
|
|
.locals 1
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"()TT;"
|
|
}
|
|
.end annotation
|
|
|
|
new-instance v0, Ljava/lang/UnsupportedOperationException;
|
|
|
|
invoke-direct {v0}, Ljava/lang/UnsupportedOperationException;-><init>()V
|
|
|
|
throw v0
|
|
.end method
|
|
|
|
.method public final remove(Ljava/lang/Object;)Z
|
|
.locals 0
|
|
|
|
new-instance p1, Ljava/lang/UnsupportedOperationException;
|
|
|
|
invoke-direct {p1}, Ljava/lang/UnsupportedOperationException;-><init>()V
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public final removeAll(Ljava/util/Collection;)Z
|
|
.locals 0
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/util/Collection<",
|
|
"*>;)Z"
|
|
}
|
|
.end annotation
|
|
|
|
new-instance p1, Ljava/lang/UnsupportedOperationException;
|
|
|
|
invoke-direct {p1}, Ljava/lang/UnsupportedOperationException;-><init>()V
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public final retainAll(Ljava/util/Collection;)Z
|
|
.locals 0
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/util/Collection<",
|
|
"*>;)Z"
|
|
}
|
|
.end annotation
|
|
|
|
new-instance p1, Ljava/lang/UnsupportedOperationException;
|
|
|
|
invoke-direct {p1}, Ljava/lang/UnsupportedOperationException;-><init>()V
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public final size()I
|
|
.locals 7
|
|
|
|
iget-object v0, p0, Lrx/internal/util/a/f;->consumerIndex:Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
invoke-virtual {v0}, Ljava/util/concurrent/atomic/AtomicLong;->get()J
|
|
|
|
move-result-wide v0
|
|
|
|
:goto_0
|
|
iget-object v2, p0, Lrx/internal/util/a/f;->producerIndex:Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
invoke-virtual {v2}, Ljava/util/concurrent/atomic/AtomicLong;->get()J
|
|
|
|
move-result-wide v2
|
|
|
|
iget-object v4, p0, Lrx/internal/util/a/f;->consumerIndex:Ljava/util/concurrent/atomic/AtomicLong;
|
|
|
|
invoke-virtual {v4}, Ljava/util/concurrent/atomic/AtomicLong;->get()J
|
|
|
|
move-result-wide v4
|
|
|
|
cmp-long v6, v0, v4
|
|
|
|
if-nez v6, :cond_0
|
|
|
|
sub-long/2addr v2, v4
|
|
|
|
long-to-int v0, v2
|
|
|
|
return v0
|
|
|
|
:cond_0
|
|
move-wide v0, v4
|
|
|
|
goto :goto_0
|
|
.end method
|
|
|
|
.method public final toArray()[Ljava/lang/Object;
|
|
.locals 1
|
|
|
|
new-instance v0, Ljava/lang/UnsupportedOperationException;
|
|
|
|
invoke-direct {v0}, Ljava/lang/UnsupportedOperationException;-><init>()V
|
|
|
|
throw v0
|
|
.end method
|
|
|
|
.method public final toArray([Ljava/lang/Object;)[Ljava/lang/Object;
|
|
.locals 0
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"<E:",
|
|
"Ljava/lang/Object;",
|
|
">([TE;)[TE;"
|
|
}
|
|
.end annotation
|
|
|
|
new-instance p1, Ljava/lang/UnsupportedOperationException;
|
|
|
|
invoke-direct {p1}, Ljava/lang/UnsupportedOperationException;-><init>()V
|
|
|
|
throw p1
|
|
.end method
|