.class public final Lz5/mv1;
.super Ljava/lang/Object;
.source ""

# interfaces
.implements Lz5/kv1;


# instance fields
.field public final a:J

.field public final b:I

.field public final c:J

.field public final d:J

.field public final e:J

.field public final f:[J


# direct methods
.method public constructor <init>(JIJJ[J)V
    .registers 9

    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    iput-wide p1, p0, Lz5/mv1;->a:J

    iput p3, p0, Lz5/mv1;->b:I

    iput-wide p4, p0, Lz5/mv1;->c:J

    iput-object p8, p0, Lz5/mv1;->f:[J

    iput-wide p6, p0, Lz5/mv1;->d:J

    const-wide/16 p3, -0x1

    cmp-long p5, p6, p3

    if-nez p5, :cond_14

    goto :goto_16

    :cond_14
    add-long p3, p1, p6

    :goto_16
    iput-wide p3, p0, Lz5/mv1;->e:J

    return-void
.end method


# virtual methods
.method public final a(J)Lz5/ku1;
    .registers 15

    invoke-virtual {p0}, Lz5/mv1;->zze()Z

    move-result v0

    if-nez v0, :cond_19

    new-instance p1, Lz5/ku1;

    new-instance p2, Lz5/mu1;

    const-wide/16 v0, 0x0

    iget-wide v2, p0, Lz5/mv1;->a:J

    iget v4, p0, Lz5/mv1;->b:I

    int-to-long v4, v4

    add-long/2addr v2, v4

    invoke-direct {p2, v0, v1, v2, v3}, Lz5/mu1;-><init>(JJ)V

    invoke-direct {p1, p2, p2}, Lz5/ku1;-><init>(Lz5/mu1;Lz5/mu1;)V

    return-object p1

    :cond_19
    const-wide/16 v6, 0x0

    iget-wide v8, p0, Lz5/mv1;->c:J

    move-wide v4, p1

    invoke-static/range {v4 .. v9}, Lz5/r7;->w(JJJ)J

    move-result-wide p1

    long-to-double v0, p1

    const-wide/high16 v2, 0x4059000000000000L    # 100.0

    mul-double/2addr v0, v2

    iget-wide v4, p0, Lz5/mv1;->c:J

    long-to-double v4, v4

    div-double/2addr v0, v4

    const-wide/16 v4, 0x0

    cmpg-double v6, v0, v4

    const-wide/high16 v7, 0x4070000000000000L    # 256.0

    if-gtz v6, :cond_33

    goto :goto_54

    :cond_33
    cmpl-double v2, v0, v2

    if-ltz v2, :cond_39

    move-wide v4, v7

    goto :goto_54

    :cond_39
    double-to-int v2, v0

    iget-object v3, p0, Lz5/mv1;->f:[J

    invoke-static {v3}, Lcom/google/android/gms/internal/ads/d;->p(Ljava/lang/Object;)Ljava/lang/Object;

    check-cast v3, [J

    aget-wide v4, v3, v2

    long-to-double v4, v4

    const/16 v6, 0x63

    if-ne v2, v6, :cond_4a

    move-wide v9, v7

    goto :goto_4f

    :cond_4a
    add-int/lit8 v6, v2, 0x1

    aget-wide v9, v3, v6

    long-to-double v9, v9

    :goto_4f
    int-to-double v2, v2

    sub-double/2addr v0, v2

    sub-double/2addr v9, v4

    mul-double/2addr v9, v0

    add-double/2addr v4, v9

    :goto_54
    iget-wide v0, p0, Lz5/mv1;->d:J

    div-double/2addr v4, v7

    long-to-double v0, v0

    mul-double/2addr v4, v0

    invoke-static {v4, v5}, Ljava/lang/Math;->round(D)J

    move-result-wide v6

    iget v0, p0, Lz5/mv1;->b:I

    iget-wide v1, p0, Lz5/mv1;->d:J

    int-to-long v8, v0

    const-wide/16 v3, -0x1

    add-long v10, v1, v3

    invoke-static/range {v6 .. v11}, Lz5/r7;->w(JJJ)J

    move-result-wide v0

    new-instance v2, Lz5/ku1;

    new-instance v3, Lz5/mu1;

    iget-wide v4, p0, Lz5/mv1;->a:J

    add-long/2addr v4, v0

    invoke-direct {v3, p1, p2, v4, v5}, Lz5/mu1;-><init>(JJ)V

    invoke-direct {v2, v3, v3}, Lz5/ku1;-><init>(Lz5/mu1;Lz5/mu1;)V

    return-object v2
.end method

.method public final b(J)J
    .registers 16

    iget-wide v0, p0, Lz5/mv1;->a:J

    sub-long/2addr p1, v0

    invoke-virtual {p0}, Lz5/mv1;->zze()Z

    move-result v0

    if-eqz v0, :cond_51

    iget v0, p0, Lz5/mv1;->b:I

    int-to-long v0, v0

    cmp-long v0, p1, v0

    if-gtz v0, :cond_11

    goto :goto_51

    :cond_11
    iget-object v0, p0, Lz5/mv1;->f:[J

    invoke-static {v0}, Lcom/google/android/gms/internal/ads/d;->p(Ljava/lang/Object;)Ljava/lang/Object;

    long-to-double p1, p1

    const-wide/high16 v1, 0x4070000000000000L    # 256.0

    mul-double/2addr p1, v1

    iget-wide v1, p0, Lz5/mv1;->d:J

    long-to-double v1, v1

    div-double/2addr p1, v1

    double-to-long v1, p1

    const/4 v3, 0x1

    invoke-static {v0, v1, v2, v3, v3}, Lz5/r7;->b([JJZZ)I

    move-result v1

    .line 1
    iget-wide v2, p0, Lz5/mv1;->c:J

    int-to-long v4, v1

    mul-long/2addr v4, v2

    const-wide/16 v6, 0x64

    div-long/2addr v4, v6

    .line 2
    aget-wide v8, v0, v1

    add-int/lit8 v10, v1, 0x1

    int-to-long v11, v10

    mul-long/2addr v2, v11

    .line 3
    div-long/2addr v2, v6

    const/16 v6, 0x63

    if-ne v1, v6, :cond_39

    const-wide/16 v0, 0x100

    goto :goto_3c

    .line 4
    :cond_39
    aget-wide v6, v0, v10

    move-wide v0, v6

    :goto_3c
    cmp-long v6, v8, v0

    if-nez v6, :cond_43

    const-wide/16 p1, 0x0

    goto :goto_48

    :cond_43
    long-to-double v6, v8

    sub-double/2addr p1, v6

    sub-long/2addr v0, v8

    long-to-double v0, v0

    div-double/2addr p1, v0

    :goto_48
    sub-long/2addr v2, v4

    long-to-double v0, v2

    mul-double/2addr p1, v0

    invoke-static {p1, p2}, Ljava/lang/Math;->round(D)J

    move-result-wide p1

    add-long/2addr p1, v4

    return-wide p1

    :cond_51
    :goto_51
    const-wide/16 p1, 0x0

    return-wide p1
.end method

.method public final zzc()J
    .registers 3

    iget-wide v0, p0, Lz5/mv1;->e:J

    return-wide v0
.end method

.method public final zze()Z
    .registers 2

    iget-object v0, p0, Lz5/mv1;->f:[J

    if-eqz v0, :cond_6

    const/4 v0, 0x1

    return v0

    :cond_6
    const/4 v0, 0x0

    return v0
.end method

.method public final zzg()J
    .registers 3

    iget-wide v0, p0, Lz5/mv1;->c:J

    return-wide v0
.end method
