From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from [87.239.111.99] (localhost [127.0.0.1]) by dev.tarantool.org (Postfix) with ESMTP id 99C7A372536; Tue, 14 Mar 2023 15:03:55 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 99C7A372536 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1678795435; bh=z8CSOrZ0/PTmVcjf9kY7lrwY5UkNDUzx17wR11opiNY=; h=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=yZ/0Mz6hbzfodjcotnj2+x1Y8woIgu8CH62m8cZecJ/7/1/cSKLa54N9bOyfi8jHE XexaG9V82sci8EuN9j5EidLW818QtSddrNGwdg+lsz9TlVVAKlQMQGLZfDoWeMhRFn sCMR+gTuBhu+UHxY5B6GopVUMkqb8eWBkOUFSE58= Received: from mail-lf1-f47.google.com (mail-lf1-f47.google.com [209.85.167.47]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id 0DC95372538 for ; Tue, 14 Mar 2023 15:02:12 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 0DC95372538 Received: by mail-lf1-f47.google.com with SMTP id r27so19656248lfe.10 for ; Tue, 14 Mar 2023 05:02:12 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678795331; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=NV6ixt3DnhXIg/5QlqyOJXJjBCbVf3soKTlmpzaEKic=; b=jOx8WInNdTrfeoHYFxxmkeGkllejVfKe9EFUpb1GSETWPQZnxn3N1QmnF/DE6oXTcm /jIWLcgiYXrx3VS1FR64cRaI4U+zDdoNNndC3V7ISPdSUMWOl0fLqSQ5/LL6fvvXj9ya 4spt++zD7YXr6kPl8rNJP9FJGRJF4I1Vrhin97RvgxQZvfpCX1Vpt3V85CQ+tdoI5o5l o59xJMVH15uuLA8i2JkZuJn7kg+AisD4paWw36Uw0NBon+ytstmSFU9/luOIauZ7kn4o ngzfptjTGh1x3L7n2v8d6gfsjbVI8uPjjNYa+6MtKvC3g2Iz/OwkGCHv6e/zxtqG8OyO qaWw== X-Gm-Message-State: AO0yUKXEEJFC/Upi2QCcCyUPLAsaliSPT/ycqtWg56Pn117XgzAO5d8v id4BXmHcBttQWgwKXeqrkAefuNkx+L9MqA== X-Google-Smtp-Source: AK7set+t7/WkT40ZbLfzXrAPuzFuF2JSXWF3wrt8yV/7YpQSpA+g6Vdf8OjZ69jLEEG9kJiVS4+RGQ== X-Received: by 2002:ac2:4c91:0:b0:4b4:a460:c995 with SMTP id d17-20020ac24c91000000b004b4a460c995mr857972lfl.5.1678795331223; Tue, 14 Mar 2023 05:02:11 -0700 (PDT) Received: from localhost.localdomain (128-69-253-162.broadband.corbina.ru. [128.69.253.162]) by smtp.gmail.com with ESMTPSA id n5-20020ac242c5000000b004db51387ad6sm375106lfl.129.2023.03.14.05.02.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 14 Mar 2023 05:02:10 -0700 (PDT) X-Google-Original-From: Maxim Kokryashkin To: tarantool-patches@dev.tarantool.org, skaplun@tarantool.org, sergos@tarantool.org Date: Tue, 14 Mar 2023 15:01:46 +0300 Message-Id: <85a088262f5c33f94afa1d134efe00ee1ff7661c.1678794695.git.m.kokryashkin@tarantool.org> X-Mailer: git-send-email 2.39.0 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [Tarantool-patches] [PATCH luajit v2 4/5] OSX: Disable unreliable assertion for external frame unwinding. X-BeenThere: tarantool-patches@dev.tarantool.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Maxim Kokryashkin via Tarantool-patches Reply-To: Maxim Kokryashkin Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" From: Mike Pall (cherry-picked from commit be251d9149b386ca0d4b51106be14366c5dbdf14) `_Unwind_Find_FDE()` will locate the FDE if the pc is in some function that has an associated FDE. Note, Mac OS X 10.6 and later, introduces "compact unwind info" which the runtime uses in preference to DWARF unwind info. This function will only work if the target function has an FDE but no compact unwind info. The LuaJIT VM produces compact unwind info entries, so DWARF's FDE is not found and that assertion fails. Maxim Kokryashkin: * added the description for the problem Part of tarantool/tarantool#7745 Part of tarantool/tarantool#8069 --- src/lj_err.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/lj_err.c b/src/lj_err.c index f6200233..975b5621 100644 --- a/src/lj_err.c +++ b/src/lj_err.c @@ -479,6 +479,8 @@ extern const void *_Unwind_Find_FDE(void *pc, struct dwarf_eh_bases *bases); /* Verify that external error handling actually has a chance to work. */ void lj_err_verify(void) { +#if !LJ_TARGET_OSX + /* Check disabled on MacOS due to brilliant software engineering at Apple. */ struct dwarf_eh_bases ehb; /* ** FIXME: The following assertions were replaced with @@ -488,6 +490,7 @@ void lj_err_verify(void) ** lj_assertX(_Unwind_Find_FDE((void *)_Unwind_RaiseException, &ehb), "broken build: external frame unwinding enabled, but system libraries have no unwind tables"); */ lua_assert(_Unwind_Find_FDE((void *)lj_err_throw, &ehb)); +#endif /* Check disabled, because of broken Fedora/ARM64. See #722. lua_assert(_Unwind_Find_FDE((void *)_Unwind_RaiseException, &ehb)); */ -- 2.39.0