package kotlinx.coroutines;

import java.util.concurrent.atomic.AtomicReferenceFieldUpdater;

/* JADX INFO: loaded from: classes.dex */
public class a1 extends g1 {

    /* JADX INFO: renamed from: c, reason: collision with root package name */
    public final boolean f29291c;

    /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
    public a1(y0 y0Var) {
        super(true);
        boolean z10 = true;
        K(y0Var);
        AtomicReferenceFieldUpdater atomicReferenceFieldUpdater = g1.f29434b;
        k kVar = (k) atomicReferenceFieldUpdater.get(this);
        l lVar = kVar instanceof l ? (l) kVar : null;
        if (lVar == null) {
            z10 = false;
            break;
        }
        g1 g1VarJ = lVar.j();
        while (!g1VarJ.C()) {
            k kVar2 = (k) atomicReferenceFieldUpdater.get(g1VarJ);
            l lVar2 = kVar2 instanceof l ? (l) kVar2 : null;
            if (lVar2 == null) {
                z10 = false;
                break;
            }
            g1VarJ = lVar2.j();
        }
        this.f29291c = z10;
    }

    @Override // kotlinx.coroutines.g1
    public final boolean C() {
        return this.f29291c;
    }

    @Override // kotlinx.coroutines.g1
    public final boolean D() {
        return true;
    }
}
