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 B07C36F3C8; Tue, 4 Oct 2022 11:26:05 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org B07C36F3C8 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1664871965; bh=+NQXCqtzdFKwkt6zujtKnuoWjDeMbYqbfS8s6AaoPxs=; h=In-Reply-To:Date:References:To:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=XRbU3Pc/rC7VKBEL6YpDPZFSTp1B5si9MH13AF+cjWYsNWP8K8/RWVHXd0LHYayob 2oe8pdCnwqR4SQJVlot2Nf5A/o86P0fCGimfLTcmDYwcqkhhDMWrWQ82CCaK6uZVPZ R24oP+A2TIRXvOerJgA2czAQR+Y4tgdD4KSCT03g= Received: from smtp33.i.mail.ru (smtp33.i.mail.ru [94.100.177.93]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id B27426F3C8 for ; Tue, 4 Oct 2022 11:26:03 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org B27426F3C8 Received: by smtp33.i.mail.ru with esmtpa (envelope-from ) id 1ofdFa-0006AT-TZ; Tue, 04 Oct 2022 11:26:03 +0300 Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3696.120.41.1.1\)) In-Reply-To: <1d15f0a9f3865b0ec374d66d01f38d055afc9eec.1664207262.git.max.kokryashkin@gmail.com> Date: Tue, 4 Oct 2022 11:26:02 +0300 Content-Transfer-Encoding: quoted-printable Message-Id: References: <1d15f0a9f3865b0ec374d66d01f38d055afc9eec.1664207262.git.max.kokryashkin@gmail.com> To: Maksim Kokryashkin X-Mailer: Apple Mail (2.3696.120.41.1.1) X-Mailru-Src: smtp X-4EC0790: 10 X-7564579A: 646B95376F6C166E X-77F55803: 4F1203BC0FB41BD9EA63AAA3C7549E8E13456840ACC6BCDAAAC571697DEAF68B00894C459B0CD1B952851B3FF37723CDF87D7670409C98DF180869308D9A9C2543C662A976723F50 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE7705F446BE41E38A1EA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F790063779018AFA06A12C538638F802B75D45FF36EB9D2243A4F8B5A6FCA7DBDB1FC311F39EFFDF887939037866D6147AF826D84D3BCA1343DB8ACC28ADDDD2AD89883B117882F4460429724CE54428C33FAD305F5C1EE8F4F765FCCF01C05423B8DB1BA471835C12D1D9774AD6D5ED66289B52BA9C0B312567BB23117882F44604297287769387670735201E561CDFBCA1751FE5D25F19253116ADD2E47CDBA5A96583BA9C0B312567BB2376E601842F6C81A19E625A9149C048EE4B6963042765DA4BE45489B29CB19804D8FC6C240DEA7642DBF02ECDB25306B2B78CF848AE20165D0A6AB1C7CE11FEE32A336C651863509103F1AB874ED89028C4224003CC836476E2F48590F00D11D6E2021AF6380DFAD1A18204E546F3947CA9FF340AA05FB58C2E808ACE2090B5E1725E5C173C3A84C3C5EA940A35A165FF2DBA43225CD8A89FB26E97DCB74E6252156CCFE7AF13BCA4B5C8C57E37DE458BEDA766A37F9254B7 X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D3454548929AF40B4288F5EA311F3FB1FAA392B5D51F92788BEEA31B25797BDBB461F94BBF28BA10BDC1D7E09C32AA3244C6CB3963075946EF62B64DCBFB8E90C6A63871F383B54D9B3FACE5A9C96DEB163 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojoN03fZs/02Omv0hzfJpesQ== X-Mailru-Sender: 5AA3D5B9D8C486465A7E7C48E78B605D185FD1A9F65EC5AE0A1BD708D2CD6A1B6ECF975C7BB2667F60D8632BEC246C7D55B4A2144138A8805FC805B5969CB4993EE16157CC7DAB4272D6B4FCE48DF648AE208404248635DF X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH luajit 3/6] OSX/ARM64: Disable external unwinding for now. 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: sergos via Tarantool-patches Reply-To: sergos Cc: tarantool-patches@dev.tarantool.org Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" Hi! Thanks for the patch! I would rephrase the original message, so that it=E2=80=99ll be clear = that changes are arm64-related only.=20 Otherwise LGTM. Sergos > On 26 Sep 2022, at 18:55, Maksim Kokryashkin = wrote: >=20 > From: Mike Pall >=20 > This reduces functionality, e.g. no handling of on-trace errors. > Someone with very deep knowledge about macOS and MACH-O/DWARF stack > unwinding internals is needed to fix this. See issue = LuaJIT/LuaJIT#698. >=20 > (cherry picked from commit 27ee3bcd79b12a0c71f00427ee1a2e486c684486) >=20 > ARM64 interpreter doesn't have unwind info for Mach-O assembler > format, which makes unwinding impossible. >=20 > For more info, see https://github.com/LuaJIT/LuaJIT/issues/698 >=20 > Maxim Kokryashkin: > * added the description for the problem >=20 > Needed for tarantool/tarantool#6096 > Needed for tarantool/tarantool#7230 > --- > cmake/SetTargetFlags.cmake | 4 +++- > src/Makefile.original | 5 ++++- > 2 files changed, 7 insertions(+), 2 deletions(-) >=20 > diff --git a/cmake/SetTargetFlags.cmake b/cmake/SetTargetFlags.cmake > index a5a3407f..d99e1f9a 100644 > --- a/cmake/SetTargetFlags.cmake > +++ b/cmake/SetTargetFlags.cmake > @@ -16,7 +16,9 @@ LuaJITTestArch(TESTARCH "${TARGET_C_FLAGS}") > LuaJITArch(LUAJIT_ARCH "${TESTARCH}") >=20 > if(CMAKE_SYSTEM_NAME STREQUAL "Darwin") > - AppendFlags(TARGET_C_FLAGS -DLUAJIT_UNWIND_EXTERNAL) > + if(NOT LUAJIT_ARCH STREQUAL "arm64") > + AppendFlags(TARGET_C_FLAGS -DLUAJIT_UNWIND_EXTERNAL) > + endif() > else() > string(FIND ${TARGET_C_FLAGS} "LJ_NO_UNWIND 1" UNWIND_POS) > if(UNWIND_POS EQUAL -1) > diff --git a/src/Makefile.original b/src/Makefile.original > index d1373b40..5826a56a 100644 > --- a/src/Makefile.original > +++ b/src/Makefile.original > @@ -325,7 +325,10 @@ ifeq (Darwin,$(TARGET_SYS)) > export MACOSX_DEPLOYMENT_TARGET=3D10.4 > endif > TARGET_STRIP+=3D -x > - TARGET_XCFLAGS+=3D -DLUAJIT_UNWIND_EXTERNAL > + # Ext. unwinding is broken on OSX/ARM64 until someone finds a fix. = See #698. > + ifneq (arm64,$(TARGET_LJARCH)) > + TARGET_XCFLAGS+=3D -DLUAJIT_UNWIND_EXTERNAL > + endif > TARGET_XSHLDFLAGS=3D -dynamiclib -single_module -undefined = dynamic_lookup -fPIC > TARGET_DYNXLDOPTS=3D > TARGET_XSHLDFLAGS+=3D -install_name $(TARGET_DYLIBPATH) = -compatibility_version $(MAJVER).$(MINVER) -current_version = $(MAJVER).$(MINVER).$(RELVER) > --=20 > 2.32.1 (Apple Git-133) >=20