MontgomeryLadderMultiplier.smali
.class public Lorg/spongycastle/math/ec/MontgomeryLadderMultiplier;
.super Lorg/spongycastle/math/ec/AbstractECMultiplier;
.source "MontgomeryLadderMultiplier.java"
# direct methods
.method public constructor <init>()V
.registers 1
.prologue
.line 5
invoke-direct {p0}, Lorg/spongycastle/math/ec/AbstractECMultiplier;-><init>()V
return-void
.end method
# virtual methods
.method protected multiplyPositive(Lorg/spongycastle/math/ec/ECPoint;Ljava/math/BigInteger;)Lorg/spongycastle/math/ec/ECPoint;
.registers 11
.prologue
const/4 v1, 0x1
const/4 v2, 0x0
.line 12
const/4 v0, 0x2
new-array v4, v0, [Lorg/spongycastle/math/ec/ECPoint;
invoke-virtual {p1}, Lorg/spongycastle/math/ec/ECPoint;->getCurve()Lorg/spongycastle/math/ec/ECCurve;
move-result-object v0
invoke-virtual {v0}, Lorg/spongycastle/math/ec/ECCurve;->getInfinity()Lorg/spongycastle/math/ec/ECPoint;
move-result-object v0
aput-object v0, v4, v2
aput-object p1, v4, v1
.line 14
invoke-virtual {p2}, Ljava/math/BigInteger;->bitLength()I
move-result v0
.line 16
:goto_15
add-int/lit8 v3, v0, -0x1
if-ltz v3, :cond_38
.line 18
invoke-virtual {p2, v3}, Ljava/math/BigInteger;->testBit(I)Z
move-result v0
if-eqz v0, :cond_36
move v0, v1
.line 19
:goto_20
rsub-int/lit8 v5, v0, 0x1
.line 20
aget-object v6, v4, v5
aget-object v7, v4, v0
invoke-virtual {v6, v7}, Lorg/spongycastle/math/ec/ECPoint;->add(Lorg/spongycastle/math/ec/ECPoint;)Lorg/spongycastle/math/ec/ECPoint;
move-result-object v6
aput-object v6, v4, v5
.line 21
aget-object v5, v4, v0
invoke-virtual {v5}, Lorg/spongycastle/math/ec/ECPoint;->twice()Lorg/spongycastle/math/ec/ECPoint;
move-result-object v5
aput-object v5, v4, v0
move v0, v3
.line 22
goto :goto_15
:cond_36
move v0, v2
.line 18
goto :goto_20
.line 23
:cond_38
aget-object v0, v4, v2
return-object v0
.end method