470 lines
7.7 KiB
Smali
470 lines
7.7 KiB
Smali
.class public abstract Lk0/a/n0;
|
|
.super Lk0/a/v;
|
|
.source "EventLoop.common.kt"
|
|
|
|
|
|
# instance fields
|
|
.field public d:J
|
|
|
|
.field public e:Z
|
|
|
|
.field public f:Lk0/a/r1/a;
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"Lk0/a/r1/a<",
|
|
"Lk0/a/i0<",
|
|
"*>;>;"
|
|
}
|
|
.end annotation
|
|
.end field
|
|
|
|
|
|
# direct methods
|
|
.method public constructor <init>()V
|
|
.locals 0
|
|
|
|
invoke-direct {p0}, Lk0/a/v;-><init>()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public final A()Z
|
|
.locals 6
|
|
|
|
iget-wide v0, p0, Lk0/a/n0;->d:J
|
|
|
|
const/4 v2, 0x1
|
|
|
|
invoke-virtual {p0, v2}, Lk0/a/n0;->v(Z)J
|
|
|
|
move-result-wide v3
|
|
|
|
cmp-long v5, v0, v3
|
|
|
|
if-ltz v5, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 v2, 0x0
|
|
|
|
:goto_0
|
|
return v2
|
|
.end method
|
|
|
|
.method public final C()Z
|
|
.locals 7
|
|
|
|
iget-object v0, p0, Lk0/a/n0;->f:Lk0/a/r1/a;
|
|
|
|
const/4 v1, 0x0
|
|
|
|
if-eqz v0, :cond_3
|
|
|
|
iget v2, v0, Lk0/a/r1/a;->b:I
|
|
|
|
iget v3, v0, Lk0/a/r1/a;->c:I
|
|
|
|
const/4 v4, 0x0
|
|
|
|
const/4 v5, 0x1
|
|
|
|
if-ne v2, v3, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
iget-object v3, v0, Lk0/a/r1/a;->a:[Ljava/lang/Object;
|
|
|
|
aget-object v6, v3, v2
|
|
|
|
aput-object v4, v3, v2
|
|
|
|
add-int/2addr v2, v5
|
|
|
|
array-length v3, v3
|
|
|
|
add-int/lit8 v3, v3, -0x1
|
|
|
|
and-int/2addr v2, v3
|
|
|
|
iput v2, v0, Lk0/a/r1/a;->b:I
|
|
|
|
if-eqz v6, :cond_2
|
|
|
|
move-object v4, v6
|
|
|
|
:goto_0
|
|
check-cast v4, Lk0/a/i0;
|
|
|
|
if-eqz v4, :cond_1
|
|
|
|
invoke-virtual {v4}, Lk0/a/i0;->run()V
|
|
|
|
return v5
|
|
|
|
:cond_1
|
|
return v1
|
|
|
|
:cond_2
|
|
new-instance v0, Lkotlin/TypeCastException;
|
|
|
|
const-string v1, "null cannot be cast to non-null type T"
|
|
|
|
invoke-direct {v0, v1}, Lkotlin/TypeCastException;-><init>(Ljava/lang/String;)V
|
|
|
|
throw v0
|
|
|
|
:cond_3
|
|
return v1
|
|
.end method
|
|
|
|
.method public final s(Z)V
|
|
.locals 8
|
|
|
|
iget-wide v0, p0, Lk0/a/n0;->d:J
|
|
|
|
invoke-virtual {p0, p1}, Lk0/a/n0;->v(Z)J
|
|
|
|
move-result-wide v2
|
|
|
|
sub-long/2addr v0, v2
|
|
|
|
iput-wide v0, p0, Lk0/a/n0;->d:J
|
|
|
|
const-wide/16 v2, 0x0
|
|
|
|
cmp-long p1, v0, v2
|
|
|
|
if-lez p1, :cond_0
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
sget-boolean p1, Lk0/a/b0;->a:Z
|
|
|
|
const/4 v4, 0x0
|
|
|
|
const/4 v5, 0x1
|
|
|
|
if-eqz p1, :cond_3
|
|
|
|
cmp-long p1, v0, v2
|
|
|
|
if-nez p1, :cond_1
|
|
|
|
const/4 p1, 0x1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_1
|
|
const/4 p1, 0x0
|
|
|
|
:goto_0
|
|
if-eqz p1, :cond_2
|
|
|
|
goto :goto_1
|
|
|
|
:cond_2
|
|
new-instance p1, Ljava/lang/AssertionError;
|
|
|
|
invoke-direct {p1}, Ljava/lang/AssertionError;-><init>()V
|
|
|
|
throw p1
|
|
|
|
:cond_3
|
|
:goto_1
|
|
iget-boolean p1, p0, Lk0/a/n0;->e:Z
|
|
|
|
if-eqz p1, :cond_b
|
|
|
|
move-object p1, p0
|
|
|
|
check-cast p1, Lk0/a/o0;
|
|
|
|
sget-object v0, Lk0/a/n1;->b:Lk0/a/n1;
|
|
|
|
sget-object v0, Lk0/a/n1;->a:Ljava/lang/ThreadLocal;
|
|
|
|
const/4 v1, 0x0
|
|
|
|
invoke-virtual {v0, v1}, Ljava/lang/ThreadLocal;->set(Ljava/lang/Object;)V
|
|
|
|
iput-boolean v5, p1, Lk0/a/o0;->isCompleted:Z
|
|
|
|
sget-boolean v0, Lk0/a/b0;->a:Z
|
|
|
|
if-eqz v0, :cond_5
|
|
|
|
iget-boolean v0, p1, Lk0/a/o0;->isCompleted:Z
|
|
|
|
if-eqz v0, :cond_4
|
|
|
|
goto :goto_2
|
|
|
|
:cond_4
|
|
new-instance p1, Ljava/lang/AssertionError;
|
|
|
|
invoke-direct {p1}, Ljava/lang/AssertionError;-><init>()V
|
|
|
|
throw p1
|
|
|
|
:cond_5
|
|
:goto_2
|
|
iget-object v0, p1, Lk0/a/o0;->_queue:Ljava/lang/Object;
|
|
|
|
if-nez v0, :cond_6
|
|
|
|
sget-object v0, Lk0/a/o0;->g:Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;
|
|
|
|
sget-object v6, Lk0/a/q0;->b:Lk0/a/r1/v;
|
|
|
|
invoke-virtual {v0, p1, v1, v6}, Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;->compareAndSet(Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;)Z
|
|
|
|
move-result v0
|
|
|
|
if-eqz v0, :cond_5
|
|
|
|
goto :goto_3
|
|
|
|
:cond_6
|
|
instance-of v6, v0, Lk0/a/r1/o;
|
|
|
|
if-eqz v6, :cond_7
|
|
|
|
check-cast v0, Lk0/a/r1/o;
|
|
|
|
invoke-virtual {v0}, Lk0/a/r1/o;->c()Z
|
|
|
|
goto :goto_3
|
|
|
|
:cond_7
|
|
sget-object v6, Lk0/a/q0;->b:Lk0/a/r1/v;
|
|
|
|
if-ne v0, v6, :cond_8
|
|
|
|
goto :goto_3
|
|
|
|
:cond_8
|
|
new-instance v6, Lk0/a/r1/o;
|
|
|
|
const/16 v7, 0x8
|
|
|
|
invoke-direct {v6, v7, v5}, Lk0/a/r1/o;-><init>(IZ)V
|
|
|
|
move-object v7, v0
|
|
|
|
check-cast v7, Ljava/lang/Runnable;
|
|
|
|
invoke-virtual {v6, v7}, Lk0/a/r1/o;->b(Ljava/lang/Object;)I
|
|
|
|
sget-object v7, Lk0/a/o0;->g:Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;
|
|
|
|
invoke-virtual {v7, p1, v0, v6}, Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;->compareAndSet(Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;)Z
|
|
|
|
move-result v0
|
|
|
|
if-eqz v0, :cond_5
|
|
|
|
:goto_3
|
|
invoke-virtual {p1}, Lk0/a/o0;->L()J
|
|
|
|
move-result-wide v5
|
|
|
|
cmp-long v0, v5, v2
|
|
|
|
if-gtz v0, :cond_9
|
|
|
|
goto :goto_3
|
|
|
|
:cond_9
|
|
invoke-static {}, Ljava/lang/System;->nanoTime()J
|
|
|
|
move-result-wide v2
|
|
|
|
:goto_4
|
|
iget-object v0, p1, Lk0/a/o0;->_delayed:Ljava/lang/Object;
|
|
|
|
check-cast v0, Lk0/a/o0$c;
|
|
|
|
if-eqz v0, :cond_b
|
|
|
|
monitor-enter v0
|
|
|
|
:try_start_0
|
|
iget v5, v0, Lk0/a/r1/y;->_size:I
|
|
|
|
if-lez v5, :cond_a
|
|
|
|
invoke-virtual {v0, v4}, Lk0/a/r1/y;->c(I)Lk0/a/r1/z;
|
|
|
|
move-result-object v5
|
|
:try_end_0
|
|
.catchall {:try_start_0 .. :try_end_0} :catchall_0
|
|
|
|
goto :goto_5
|
|
|
|
:cond_a
|
|
move-object v5, v1
|
|
|
|
:goto_5
|
|
monitor-exit v0
|
|
|
|
check-cast v5, Lk0/a/o0$b;
|
|
|
|
if-eqz v5, :cond_b
|
|
|
|
invoke-virtual {p1, v2, v3, v5}, Lk0/a/p0;->E(JLk0/a/o0$b;)V
|
|
|
|
goto :goto_4
|
|
|
|
:catchall_0
|
|
move-exception p1
|
|
|
|
monitor-exit v0
|
|
|
|
throw p1
|
|
|
|
:cond_b
|
|
return-void
|
|
.end method
|
|
|
|
.method public final v(Z)J
|
|
.locals 2
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
const-wide v0, 0x100000000L
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const-wide/16 v0, 0x1
|
|
|
|
:goto_0
|
|
return-wide v0
|
|
.end method
|
|
|
|
.method public final x(Lk0/a/i0;)V
|
|
.locals 12
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Lk0/a/i0<",
|
|
"*>;)V"
|
|
}
|
|
.end annotation
|
|
|
|
if-eqz p1, :cond_2
|
|
|
|
iget-object v0, p0, Lk0/a/n0;->f:Lk0/a/r1/a;
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
new-instance v0, Lk0/a/r1/a;
|
|
|
|
invoke-direct {v0}, Lk0/a/r1/a;-><init>()V
|
|
|
|
iput-object v0, p0, Lk0/a/n0;->f:Lk0/a/r1/a;
|
|
|
|
:goto_0
|
|
iget-object v1, v0, Lk0/a/r1/a;->a:[Ljava/lang/Object;
|
|
|
|
iget v2, v0, Lk0/a/r1/a;->c:I
|
|
|
|
aput-object p1, v1, v2
|
|
|
|
add-int/lit8 v2, v2, 0x1
|
|
|
|
array-length p1, v1
|
|
|
|
add-int/lit8 p1, p1, -0x1
|
|
|
|
and-int/2addr p1, v2
|
|
|
|
iput p1, v0, Lk0/a/r1/a;->c:I
|
|
|
|
iget v4, v0, Lk0/a/r1/a;->b:I
|
|
|
|
if-ne p1, v4, :cond_1
|
|
|
|
array-length p1, v1
|
|
|
|
shl-int/lit8 v2, p1, 0x1
|
|
|
|
new-array v11, v2, [Ljava/lang/Object;
|
|
|
|
const/4 v3, 0x0
|
|
|
|
const/4 v5, 0x0
|
|
|
|
const/16 v6, 0xa
|
|
|
|
move-object v2, v11
|
|
|
|
invoke-static/range {v1 .. v6}, Lj0/f;->copyInto$default([Ljava/lang/Object;[Ljava/lang/Object;IIII)[Ljava/lang/Object;
|
|
|
|
iget-object v5, v0, Lk0/a/r1/a;->a:[Ljava/lang/Object;
|
|
|
|
array-length v1, v5
|
|
|
|
iget v9, v0, Lk0/a/r1/a;->b:I
|
|
|
|
sub-int v7, v1, v9
|
|
|
|
const/4 v8, 0x0
|
|
|
|
const/4 v10, 0x4
|
|
|
|
move-object v6, v11
|
|
|
|
invoke-static/range {v5 .. v10}, Lj0/f;->copyInto$default([Ljava/lang/Object;[Ljava/lang/Object;IIII)[Ljava/lang/Object;
|
|
|
|
iput-object v11, v0, Lk0/a/r1/a;->a:[Ljava/lang/Object;
|
|
|
|
const/4 v1, 0x0
|
|
|
|
iput v1, v0, Lk0/a/r1/a;->b:I
|
|
|
|
iput p1, v0, Lk0/a/r1/a;->c:I
|
|
|
|
:cond_1
|
|
return-void
|
|
|
|
:cond_2
|
|
const-string p1, "task"
|
|
|
|
invoke-static {p1}, Lj0/o/c/h;->c(Ljava/lang/String;)V
|
|
|
|
const/4 p1, 0x0
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public final z(Z)V
|
|
.locals 4
|
|
|
|
iget-wide v0, p0, Lk0/a/n0;->d:J
|
|
|
|
invoke-virtual {p0, p1}, Lk0/a/n0;->v(Z)J
|
|
|
|
move-result-wide v2
|
|
|
|
add-long/2addr v2, v0
|
|
|
|
iput-wide v2, p0, Lk0/a/n0;->d:J
|
|
|
|
if-nez p1, :cond_0
|
|
|
|
const/4 p1, 0x1
|
|
|
|
iput-boolean p1, p0, Lk0/a/n0;->e:Z
|
|
|
|
:cond_0
|
|
return-void
|
|
.end method
|