package o;

import java.util.Iterator;

/* compiled from: r8-map-id-3b7cc9102578c509342fa2f0fabed2bfc72239cd258d579fc679bfcbc198b048 */
/* loaded from: classes.dex */
public final class N50 implements Iterable, InterfaceC2989yJ {
    public final ZQ l;
    public EN m;
    public boolean n;

    /* renamed from: o, reason: collision with root package name */
    public boolean f250o;

    public N50() {
        long[] jArr = AbstractC3064z40.a;
        this.l = new ZQ();
    }

    /* JADX WARN: Removed duplicated region for block: B:14:0x0058  */
    /*
        Code decompiled incorrectly, please refer to instructions dump.
        To view partially-correct add '--show-bad-code' argument
    */
    public final o.N50 a() {
        /*
            r18 = this;
            r0 = r18
            o.N50 r1 = new o.N50
            r1.<init>()
            boolean r2 = r0.n
            r1.n = r2
            boolean r2 = r0.f250o
            r1.f250o = r2
            o.ZQ r2 = r1.l
            r2.getClass()
            o.ZQ r3 = r0.l
            java.lang.Object[] r4 = r3.b
            java.lang.Object[] r5 = r3.c
            long[] r3 = r3.a
            int r6 = r3.length
            int r6 = r6 + (-2)
            if (r6 < 0) goto L5d
            r7 = 0
            r8 = r7
        L23:
            r9 = r3[r8]
            long r11 = ~r9
            r13 = 7
            long r11 = r11 << r13
            long r11 = r11 & r9
            r13 = -9187201950435737472(0x8080808080808080, double:-2.937446524422997E-306)
            long r11 = r11 & r13
            int r11 = (r11 > r13 ? 1 : (r11 == r13 ? 0 : -1))
            if (r11 == 0) goto L58
            int r11 = r8 - r6
            int r11 = ~r11
            int r11 = r11 >>> 31
            r12 = 8
            int r11 = 8 - r11
            r13 = r7
        L3d:
            if (r13 >= r11) goto L56
            r14 = 255(0xff, double:1.26E-321)
            long r14 = r14 & r9
            r16 = 128(0x80, double:6.3E-322)
            int r14 = (r14 > r16 ? 1 : (r14 == r16 ? 0 : -1))
            if (r14 >= 0) goto L52
            int r14 = r8 << 3
            int r14 = r14 + r13
            r15 = r4[r14]
            r14 = r5[r14]
            r2.m(r15, r14)
        L52:
            long r9 = r9 >> r12
            int r13 = r13 + 1
            goto L3d
        L56:
            if (r11 != r12) goto L5d
        L58:
            if (r8 == r6) goto L5d
            int r8 = r8 + 1
            goto L23
        L5d:
            return r1
        */
        throw new UnsupportedOperationException("Method not decompiled: o.N50.a():o.N50");
    }

    public final Object b(Z50 z50) {
        Object objG = this.l.g(z50);
        if (objG != null) {
            return objG;
        }
        throw new IllegalStateException("Key not present: " + z50 + " - consider getOrElse or getOrNull");
    }

    public final void c(N50 n50) {
        ZQ zq = n50.l;
        Object[] objArr = zq.b;
        Object[] objArr2 = zq.c;
        long[] jArr = zq.a;
        int length = jArr.length - 2;
        if (length < 0) {
            return;
        }
        int i = 0;
        while (true) {
            long j = jArr[i];
            if ((((~j) << 7) & j & (-9187201950435737472L)) != -9187201950435737472L) {
                int i2 = 8 - ((~(i - length)) >>> 31);
                for (int i3 = 0; i3 < i2; i3++) {
                    if ((255 & j) < 128) {
                        int i4 = (i << 3) + i3;
                        Object obj = objArr[i4];
                        Object obj2 = objArr2[i4];
                        Z50 z50 = (Z50) obj;
                        ZQ zq2 = this.l;
                        Object objF = z50.b.f(zq2.g(z50), obj2);
                        if (objF != null) {
                            zq2.m(z50, objF);
                        }
                    }
                    j >>= 8;
                }
                if (i2 != 8) {
                    return;
                }
            }
            if (i == length) {
                return;
            } else {
                i++;
            }
        }
    }

    public final void d(Z50 z50, Object obj) {
        boolean z = obj instanceof C1726l0;
        ZQ zq = this.l;
        if (z && zq.c(z50)) {
            C1726l0 c1726l0 = (C1726l0) zq.g(z50);
            C1726l0 c1726l02 = (C1726l0) obj;
            String str = c1726l02.a;
            if (str == null) {
                str = c1726l0.a;
            }
            QC qc = c1726l02.b;
            if (qc == null) {
                qc = c1726l0.b;
            }
            zq.m(z50, new C1726l0(str, qc));
        } else {
            zq.m(z50, obj);
        }
        z50.getClass();
    }

    public final boolean equals(Object obj) {
        if (this == obj) {
            return true;
        }
        if (!(obj instanceof N50)) {
            return false;
        }
        N50 n50 = (N50) obj;
        return F3.c(this.l, n50.l) && this.n == n50.n && this.f250o == n50.f250o;
    }

    public final int hashCode() {
        return Boolean.hashCode(this.f250o) + Ag0.d(this.l.hashCode() * 31, this.n, 31);
    }

    @Override // java.lang.Iterable
    public final Iterator iterator() {
        EN en = this.m;
        if (en == null) {
            ZQ zq = this.l;
            zq.getClass();
            EN en2 = new EN(zq);
            this.m = en2;
            en = en2;
        }
        return ((C3145zw) en.entrySet()).iterator();
    }

    /* JADX WARN: Removed duplicated region for block: B:21:0x0078 A[PHI: r2
      0x0078: PHI (r2v6 java.lang.String) = (r2v5 java.lang.String), (r2v7 java.lang.String) binds: [B:13:0x003f, B:20:0x0076] A[DONT_GENERATE, DONT_INLINE]] */
    /*
        Code decompiled incorrectly, please refer to instructions dump.
        To view partially-correct add '--show-bad-code' argument
    */
    public final java.lang.String toString() {
        /*
            r19 = this;
            r0 = r19
            java.lang.StringBuilder r1 = new java.lang.StringBuilder
            r1.<init>()
            boolean r2 = r0.n
            java.lang.String r3 = ", "
            if (r2 == 0) goto L14
            java.lang.String r2 = "mergeDescendants=true"
            r1.append(r2)
            r2 = r3
            goto L16
        L14:
            java.lang.String r2 = ""
        L16:
            boolean r4 = r0.f250o
            if (r4 == 0) goto L23
            r1.append(r2)
            java.lang.String r2 = "isClearingSemantics=true"
            r1.append(r2)
            r2 = r3
        L23:
            o.ZQ r4 = r0.l
            java.lang.Object[] r5 = r4.b
            java.lang.Object[] r6 = r4.c
            long[] r4 = r4.a
            int r7 = r4.length
            int r7 = r7 + (-2)
            if (r7 < 0) goto L7d
            r9 = 0
        L31:
            r10 = r4[r9]
            long r12 = ~r10
            r14 = 7
            long r12 = r12 << r14
            long r12 = r12 & r10
            r14 = -9187201950435737472(0x8080808080808080, double:-2.937446524422997E-306)
            long r12 = r12 & r14
            int r12 = (r12 > r14 ? 1 : (r12 == r14 ? 0 : -1))
            if (r12 == 0) goto L78
            int r12 = r9 - r7
            int r12 = ~r12
            int r12 = r12 >>> 31
            r13 = 8
            int r12 = 8 - r12
            r14 = 0
        L4b:
            if (r14 >= r12) goto L76
            r15 = 255(0xff, double:1.26E-321)
            long r15 = r15 & r10
            r17 = 128(0x80, double:6.3E-322)
            int r15 = (r15 > r17 ? 1 : (r15 == r17 ? 0 : -1))
            if (r15 >= 0) goto L72
            int r15 = r9 << 3
            int r15 = r15 + r14
            r16 = r5[r15]
            r15 = r6[r15]
            r8 = r16
            o.Z50 r8 = (o.Z50) r8
            r1.append(r2)
            java.lang.String r2 = r8.a
            r1.append(r2)
            java.lang.String r2 = " : "
            r1.append(r2)
            r1.append(r15)
            r2 = r3
        L72:
            long r10 = r10 >> r13
            int r14 = r14 + 1
            goto L4b
        L76:
            if (r12 != r13) goto L7d
        L78:
            if (r9 == r7) goto L7d
            int r9 = r9 + 1
            goto L31
        L7d:
            java.lang.StringBuilder r2 = new java.lang.StringBuilder
            r2.<init>()
            java.lang.String r3 = o.AbstractC2798wI.w(r0)
            r2.append(r3)
            java.lang.String r3 = "{ "
            r2.append(r3)
            r2.append(r1)
            java.lang.String r1 = " }"
            r2.append(r1)
            java.lang.String r1 = r2.toString()
            return r1
        */
        throw new UnsupportedOperationException("Method not decompiled: o.N50.toString():java.lang.String");
    }
}
