package o;

import java.util.Collection;
import java.util.Iterator;
import java.util.Set;

/* compiled from: r8-map-id-3b7cc9102578c509342fa2f0fabed2bfc72239cd258d579fc679bfcbc198b048 */
/* renamed from: o.cR, reason: case insensitive filesystem */
/* loaded from: classes.dex */
public final class C0904cR implements BJ, Set, InterfaceC2989yJ {
    public final C0713aR l;
    public final C0713aR m;

    public C0904cR(C0713aR c0713aR) {
        this.l = c0713aR;
        this.m = c0713aR;
    }

    @Override // java.util.Set, java.util.Collection
    public final boolean add(Object obj) {
        return this.m.a(obj);
    }

    @Override // java.util.Set, java.util.Collection
    public final boolean addAll(Collection collection) {
        C0713aR c0713aR = this.m;
        int i = c0713aR.d;
        Iterator it = collection.iterator();
        while (it.hasNext()) {
            c0713aR.i(it.next());
        }
        return i != c0713aR.d;
    }

    @Override // java.util.Set, java.util.Collection
    public final void clear() {
        this.m.b();
    }

    @Override // java.util.Set, java.util.Collection
    public final boolean contains(Object obj) {
        return this.l.c(obj);
    }

    @Override // java.util.Set, java.util.Collection
    public final boolean containsAll(Collection collection) {
        Iterator it = collection.iterator();
        while (it.hasNext()) {
            if (!this.l.c(it.next())) {
                return false;
            }
        }
        return true;
    }

    @Override // java.util.Set, java.util.Collection
    public final boolean equals(Object obj) {
        if (this == obj) {
            return true;
        }
        if (obj == null || C0904cR.class != obj.getClass()) {
            return false;
        }
        return F3.c(this.l, ((C0904cR) obj).l);
    }

    @Override // java.util.Set, java.util.Collection
    public final int hashCode() {
        return this.l.hashCode();
    }

    @Override // java.util.Set, java.util.Collection
    public final boolean isEmpty() {
        return this.l.g();
    }

    @Override // java.util.Set, java.util.Collection, java.lang.Iterable
    public final Iterator iterator() {
        return new FD(this);
    }

    @Override // java.util.Set, java.util.Collection
    public final boolean remove(Object obj) {
        return this.m.k(obj);
    }

    /* JADX WARN: Code restructure failed: missing block: B:18:0x008b, code lost:
    
        if (((r5 & ((~r5) << 6)) & r12) == 0) goto L22;
     */
    /* JADX WARN: Code restructure failed: missing block: B:19:0x008d, code lost:
    
        r14 = -1;
     */
    @Override // java.util.Set, java.util.Collection
    /*
        Code decompiled incorrectly, please refer to instructions dump.
        To view partially-correct add '--show-bad-code' argument
    */
    public final boolean removeAll(java.util.Collection r21) {
        /*
            r20 = this;
            r0 = r21
            java.lang.Iterable r0 = (java.lang.Iterable) r0
            r1 = r20
            o.aR r2 = r1.m
            int r3 = r2.d
            java.util.Iterator r0 = r0.iterator()
        Le:
            boolean r4 = r0.hasNext()
            r5 = 1
            r6 = 0
            if (r4 == 0) goto L9c
            java.lang.Object r4 = r0.next()
            if (r4 == 0) goto L21
            int r7 = r4.hashCode()
            goto L22
        L21:
            r7 = r6
        L22:
            r8 = -862048943(0xffffffffcc9e2d51, float:-8.293031E7)
            int r7 = r7 * r8
            int r8 = r7 << 16
            r7 = r7 ^ r8
            r8 = r7 & 127(0x7f, float:1.78E-43)
            int r9 = r2.c
            int r7 = r7 >>> 7
            r7 = r7 & r9
        L30:
            long[] r10 = r2.a
            int r11 = r7 >> 3
            r12 = r7 & 7
            int r12 = r12 << 3
            r13 = r10[r11]
            long r13 = r13 >>> r12
            int r11 = r11 + r5
            r15 = r10[r11]
            int r10 = 64 - r12
            long r10 = r15 << r10
            r21 = r5
            r15 = r6
            long r5 = (long) r12
            long r5 = -r5
            r12 = 63
            long r5 = r5 >> r12
            long r5 = r5 & r10
            long r5 = r5 | r13
            long r10 = (long) r8
            r12 = 72340172838076673(0x101010101010101, double:7.748604185489348E-304)
            long r10 = r10 * r12
            long r10 = r10 ^ r5
            long r12 = r10 - r12
            long r10 = ~r10
            long r10 = r10 & r12
            r12 = -9187201950435737472(0x8080808080808080, double:-2.937446524422997E-306)
            long r10 = r10 & r12
        L5e:
            r16 = 0
            int r14 = (r10 > r16 ? 1 : (r10 == r16 ? 0 : -1))
            if (r14 == 0) goto L81
            int r14 = java.lang.Long.numberOfTrailingZeros(r10)
            int r14 = r14 >> 3
            int r14 = r14 + r7
            r14 = r14 & r9
            r18 = r12
            java.lang.Object[] r12 = r2.b
            r12 = r12[r14]
            boolean r12 = o.F3.c(r12, r4)
            if (r12 == 0) goto L79
            goto L8e
        L79:
            r12 = 1
            long r12 = r10 - r12
            long r10 = r10 & r12
            r12 = r18
            goto L5e
        L81:
            r18 = r12
            long r10 = ~r5
            r12 = 6
            long r10 = r10 << r12
            long r5 = r5 & r10
            long r5 = r5 & r18
            int r5 = (r5 > r16 ? 1 : (r5 == r16 ? 0 : -1))
            if (r5 == 0) goto L95
            r14 = -1
        L8e:
            if (r14 < 0) goto Le
            r2.l(r14)
            goto Le
        L95:
            int r6 = r15 + 8
            int r7 = r7 + r6
            r7 = r7 & r9
            r5 = r21
            goto L30
        L9c:
            r21 = r5
            int r0 = r2.d
            if (r3 == r0) goto La3
            return r21
        La3:
            return r6
        */
        throw new UnsupportedOperationException("Method not decompiled: o.C0904cR.removeAll(java.util.Collection):boolean");
    }

    /* JADX WARN: Removed duplicated region for block: B:16:0x004e  */
    @Override // java.util.Set, java.util.Collection
    /*
        Code decompiled incorrectly, please refer to instructions dump.
        To view partially-correct add '--show-bad-code' argument
    */
    public final boolean retainAll(java.util.Collection r18) {
        /*
            r17 = this;
            r0 = r17
            o.aR r1 = r0.m
            java.lang.Object[] r2 = r1.b
            int r3 = r1.d
            long[] r4 = r1.a
            int r5 = r4.length
            int r5 = r5 + (-2)
            r6 = 0
            if (r5 < 0) goto L53
            r7 = r6
        L11:
            r8 = r4[r7]
            long r10 = ~r8
            r12 = 7
            long r10 = r10 << r12
            long r10 = r10 & r8
            r12 = -9187201950435737472(0x8080808080808080, double:-2.937446524422997E-306)
            long r10 = r10 & r12
            int r10 = (r10 > r12 ? 1 : (r10 == r12 ? 0 : -1))
            if (r10 == 0) goto L4e
            int r10 = r7 - r5
            int r10 = ~r10
            int r10 = r10 >>> 31
            r11 = 8
            int r10 = 8 - r10
            r12 = r6
        L2b:
            if (r12 >= r10) goto L4c
            r13 = 255(0xff, double:1.26E-321)
            long r13 = r13 & r8
            r15 = 128(0x80, double:6.3E-322)
            int r13 = (r13 > r15 ? 1 : (r13 == r15 ? 0 : -1))
            if (r13 >= 0) goto L48
            int r13 = r7 << 3
            int r13 = r13 + r12
            r14 = r18
            java.lang.Iterable r14 = (java.lang.Iterable) r14
            r15 = r2[r13]
            boolean r14 = o.AbstractC3117zi.b0(r14, r15)
            if (r14 != 0) goto L48
            r1.l(r13)
        L48:
            long r8 = r8 >> r11
            int r12 = r12 + 1
            goto L2b
        L4c:
            if (r10 != r11) goto L53
        L4e:
            if (r7 == r5) goto L53
            int r7 = r7 + 1
            goto L11
        L53:
            int r1 = r1.d
            if (r3 == r1) goto L59
            r1 = 1
            return r1
        L59:
            return r6
        */
        throw new UnsupportedOperationException("Method not decompiled: o.C0904cR.retainAll(java.util.Collection):boolean");
    }

    @Override // java.util.Set, java.util.Collection
    public final int size() {
        return this.l.d;
    }

    @Override // java.util.Set, java.util.Collection
    public final Object[] toArray() {
        return AbstractC1692kh0.P(this);
    }

    public final String toString() {
        return this.l.toString();
    }

    @Override // java.util.Set, java.util.Collection
    public final Object[] toArray(Object[] objArr) {
        return AbstractC1692kh0.Q(this, objArr);
    }
}
