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 44074642389; Thu, 28 Sep 2023 20:09:59 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 44074642389 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1695920999; bh=Wb6F3gqMPqOninvZYFOLXVu0bgB5XyFN5MJ3lmdxexY=; 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=ROhUKVx7OMRb5pQVOafW8ILRhJ0gdaiqQPLnhCblg3qTAXDRnwZ05p3u+EzMb504K I3pQYWeP3ibk2sOzPOLBwbOmWf8AvGKmxnTG6UuMldFp+Ejo9BPmrGLKtFHOB7MKQg dtrq/u0n+JtQvu3P4Awc1R9HoIcCKOqfJlgiYdDg= Received: from mail-lf1-f43.google.com (mail-lf1-f43.google.com [209.85.167.43]) (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 97FDD64238E for ; Thu, 28 Sep 2023 20:09:01 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 97FDD64238E Received: by mail-lf1-f43.google.com with SMTP id 2adb3069b0e04-50307759b65so21214571e87.0 for ; Thu, 28 Sep 2023 10:09:01 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695920940; x=1696525740; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=TslL25+C4ammFhfLtI4q6ov0oiCxGUoBYh7k02THEuc=; b=TnpInT0EVEnTofjIyhDa/SDl71X7CKQguYn15+bURSg8TFsfaMkM9bYD/NE5cCRUK9 3cgGTAuGJRsaqEdfqV5EFMv0SyPMmp8oIFUGICBDP465dBGQmc1zYiN7oasNFzYou7U9 NsiSaYAL04q+nMM+gslfdV5hldqUfhpd+QBvNTo+zGVLM6tdpoMH0gytBFcK8507vJ7Y Q8idiXovyCnhNVvMm/56fODM9ErDM76Ggp4o5Apqbh7xeRgm6Gx7f3pfdnfhTD/QxSyE +diLrMOCjDkDHMI0eNHPur9Fo6S6qrBpwsAfvxuHnPpXsruLtj9riTIl83/A4/U5WznL WV3Q== X-Gm-Message-State: AOJu0YzlEgZhF83NUM63Lt3b/BFAozkKPjMCJJzoJ+FyXH9Uk6s+bvUU 5obqOQJ37pY3FPq8i0gZOxWnT39/ykc= X-Google-Smtp-Source: AGHT+IEB7HKaYG7V2Ikz+VBgOqunYHvxKJNWqmNfr9+xD4Ud+WCvtCFmYOOARqFuu98+gmHsg0Huww== X-Received: by 2002:a19:f60b:0:b0:500:9a29:bcb8 with SMTP id x11-20020a19f60b000000b005009a29bcb8mr1749781lfe.4.1695920940067; Thu, 28 Sep 2023 10:09:00 -0700 (PDT) Received: from localhost.localdomain (95-24-2-172.broadband.corbina.ru. [95.24.2.172]) by smtp.gmail.com with ESMTPSA id bi4-20020a0565120e8400b005044911b328sm2301792lfb.218.2023.09.28.10.08.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 Sep 2023 10:08:59 -0700 (PDT) X-Google-Original-From: Maxim Kokryashkin To: tarantool-patches@dev.tarantool.org, skaplun@tarantool.org, sergeyb@tarantool.org Date: Thu, 28 Sep 2023 20:08:47 +0300 Message-ID: <962014531f23bc9fdad79fbf9b7064a75a6a6c5d.1695920642.git.m.kokryashkin@tarantool.org> X-Mailer: git-send-email 2.42.0 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Subject: [Tarantool-patches] [PATCH luajit 2/4] Revert "Update cur_L on exceptional path" 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" This reverts commit ed412cd9f55fe87fd32a69c86e1732690fc5c1b0. As was mentioned in tarantool/tarantool#6189, throwing an error not on the currently executed coroutine is a violation of the Lua/C API. This patch is a part of the patchset that supports this violation and is reverted because of it. Part of tarantool/tarantool#6323 --- src/vm_x64.dasc | 1 - src/vm_x86.dasc | 2 -- 2 files changed, 3 deletions(-) diff --git a/src/vm_x64.dasc b/src/vm_x64.dasc index 116716ac..399dfcbf 100644 --- a/src/vm_x64.dasc +++ b/src/vm_x64.dasc @@ -535,7 +535,6 @@ static void build_subroutines(BuildCtx *ctx) |->vm_unwind_c_eh: // Landing pad for external unwinder. | mov L:RB, SAVE_L | mov GL:RB, L:RB->glref - | mov [GL:RB->cur_L], L:RB | mov dword GL:RB->vmstate, ~LJ_VMST_CFUNC | mov DISPATCH, GL:RB // Setup pointer to dispatch table. | add DISPATCH, GG_G2DISP diff --git a/src/vm_x86.dasc b/src/vm_x86.dasc index e3fbf751..9fa9a3f7 100644 --- a/src/vm_x86.dasc +++ b/src/vm_x86.dasc @@ -683,7 +683,6 @@ static void build_subroutines(BuildCtx *ctx) |->vm_unwind_c_eh: // Landing pad for external unwinder. | mov L:RB, SAVE_L | mov GL:RB, L:RB->glref - | mov dword GL:RB->cur_L, L:RB | mov dword GL:RB->vmstate, ~LJ_VMST_CFUNC | mov DISPATCH, GL:RB // Setup pointer to dispatch table. | add DISPATCH, GG_G2DISP @@ -719,7 +718,6 @@ static void build_subroutines(BuildCtx *ctx) | add DISPATCH, GG_G2DISP | mov PC, [BASE-4] // Fetch PC of previous frame. | mov dword [BASE-4], LJ_TFALSE // Prepend false to error message. - | mov [DISPATCH+DISPATCH_GL(cur_L)], L:RB | // INTERP until jump to BC_RET* or return to C. | set_vmstate INTERP | jmp ->vm_returnc // Increments RD/MULTRES and returns. -- 2.42.0