package defpackage;

import java.util.Objects;
import kotlin.Metadata;
import kotlin.coroutines.Continuation;
import kotlin.coroutines.jvm.internal.DebugMetadata;
import kotlin.coroutines.jvm.internal.SuspendLambda;

/* JADX INFO: renamed from: vc1, reason: from Kotlin metadata and case insensitive filesystem */
/* JADX INFO: loaded from: classes.dex */
@Metadata(d1 = {"\u0000\u0012\n\u0000\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0002\b\u0002\u0010\u0004\u001a\u00020\u0003\"\u0004\b\u0000\u0010\u0000*\b\u0012\u0004\u0012\u00020\u00020\u0001H\u008a@¢\u0006\u0004\b\u0004\u0010\u0005"}, d2 = {"T", "Lyi7;", "Lhd1;", "Le6a;", "<anonymous>", "(Lyi7;)V"}, k = 3, mv = {1, 8, 0})
@DebugMetadata(c = "androidx.work.impl.constraints.controllers.ConstraintController$track$1", f = "ContraintControllers.kt", i = {}, l = {55}, m = "invokeSuspend", n = {}, s = {})
final class C0715vc1 extends SuspendLambda implements gr3<yi7<? super hd1>, Continuation<? super e6a>, Object> {
    public int a;
    public /* synthetic */ Object b;
    public final /* synthetic */ wc1 c;

    /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
    public C0715vc1(wc1 wc1Var, Continuation continuation) {
        super(2, continuation);
        this.c = wc1Var;
    }

    @Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl
    public final Continuation create(Object obj, Continuation continuation) {
        C0715vc1 c0715vc1 = new C0715vc1(this.c, continuation);
        c0715vc1.b = obj;
        return c0715vc1;
    }

    @Override // defpackage.gr3
    public final Object invoke(Object obj, Object obj2) {
        return ((C0715vc1) create((yi7) obj, (Continuation) obj2)).invokeSuspend(e6a.a);
    }

    @Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl
    public final Object invokeSuspend(Object obj) {
        ck1 ck1Var = ck1.a;
        int i = this.a;
        if (i == 0) {
            s38.b(obj);
            yi7 yi7Var = (yi7) this.b;
            wc1 wc1Var = this.c;
            uc1 uc1Var = new uc1(wc1Var, yi7Var);
            zc1 zc1Var = wc1Var.a;
            zc1Var.getClass();
            synchronized (zc1Var.c) {
                try {
                    if (zc1Var.d.add(uc1Var)) {
                        if (zc1Var.d.size() == 1) {
                            zc1Var.e = zc1Var.a();
                            eh5 eh5VarC = eh5.c();
                            int i2 = ad1.a;
                            Objects.toString(zc1Var.e);
                            eh5VarC.getClass();
                            zc1Var.c();
                        }
                        uc1Var.a(zc1Var.e);
                    }
                } catch (Throwable th) {
                    throw th;
                }
            }
            C0698tc1 c0698tc1 = new C0698tc1(this.c, uc1Var);
            this.a = 1;
            if (wi7.a(yi7Var, c0698tc1, this) == ck1Var) {
                return ck1Var;
            }
        } else {
            if (i != 1) {
                throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
            }
            s38.b(obj);
        }
        return e6a.a;
    }
}
