From nobody Wed Sep 21 09:30:07 2022 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4MXY6S25Mvz4crvw; Wed, 21 Sep 2022 09:30:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4MXY6S1byxz3Ztb; Wed, 21 Sep 2022 09:30:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1663752608; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8NQ3e+/oIuCpRQRXL/gk2pPcCWh2IYORKeONSRuxYbY=; b=ZKZfa/q+XgVBuK+4Kk1npNcwjT/hUS+tufAuUeECqKqEcoMG6DiuH+thkD7gSyF1GGv2Es P5M/GyxaJY6ZlKOJZBAvx2iFAJCZ7v//GzyiAQvXZhO5TkfAXkkSjbVZsPL65m0ahvP+J8 uVwQ7AgSnWTngqo9eDQheJyF2ZjSJ8GG53RrHZ3n+OCln5MeNv0wi0fX2h7dB9l5ffHL9U hXJOdLbw0ffp0TKda/W8hQF3qJFWJl/4mT7WzhYRokUNlpPzg66g36Awvr5L6x+r/QbzfG rgNeqkJ4ktWIbULrmzS/jrCgatHdzgZHbkf8WbP7jBNr8GNEMDsJqj0sN2WXFw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4MXY6S0dk3z11gP; Wed, 21 Sep 2022 09:30:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 28L9U7nF054699; Wed, 21 Sep 2022 09:30:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 28L9U7N1054696; Wed, 21 Sep 2022 09:30:07 GMT (envelope-from git) Date: Wed, 21 Sep 2022 09:30:07 GMT Message-Id: <202209210930.28L9U7N1054696@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 4bba531ad15a - stable/13 - i386: lower register's pressure on copyout_fast List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 4bba531ad15a5b8a7bbbdc17338b837a2339d733 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1663752608; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8NQ3e+/oIuCpRQRXL/gk2pPcCWh2IYORKeONSRuxYbY=; b=uIjqqzbVNSZztEqncLE+hXV39PRycNbEy+r7yviSnSKTwU5zmM0rAPjecOnhXukIQe7aky XSweaikgrM00BHXwLXXBZ9XFm+XmCTWdz+a77bR5PtCwzudGRiLJG33YcT4pSy4I8jT67B 9y8GQrSy4g78BRBnVuwobpZic7XXLqFZ0z8uiU8aubTjzSO5c0vlowPRAihJbYcxvMaOlU zZ+KekzSWpqYBcWYuloyBtidXesgqRzyuM7M56R3SdFVAH1KhuohEQaF2tOueEj0p1byPo EFSkaOk06/rPuDIKg/e5ZwPEtPJB9Rr+E1N1XeA76Hs6Y1vuMJFbb9Q9VwlKPA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1663752608; a=rsa-sha256; cv=none; b=bjgk5+aHuJsAweCXhPiIqGBml5wvRf0oA6uz3AwUYinw+SgTm+K37ZwxBzWA2HFRMf1Bir vQUIfWBpzHVDOVqePRrrgTlRsGxeCZLwsx/4OODPneKl6wnXOR16h1jiT0CQBeyK/UjJjd OsZyNssFtDwp/JbjwEZugFJ5CPMn82PYLG5pJW3HPErAVdwGvsGtYGh4X6p0v/NwRNr9Ij 2EA9OZjbwhtNRDbHVUtOeQCjewldr/9vtV4xtYZkRgBGZBx0JSREg/6hR9O1tuXJC8JB1P enABTB0oNll2j9fwB6AfUqFjO//2w4j5w5wl2+uNShVFRAN3JYkj2loNJt6uSw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=4bba531ad15a5b8a7bbbdc17338b837a2339d733 commit 4bba531ad15a5b8a7bbbdc17338b837a2339d733 Author: Konstantin Belousov AuthorDate: 2022-09-09 20:38:57 +0000 Commit: Konstantin Belousov CommitDate: 2022-09-21 09:29:02 +0000 i386: lower register's pressure on copyout_fast (cherry picked from commit cbbf5227955d871d74556d4e83656a003aa9e334) --- sys/i386/i386/exception.s | 30 ++++++++++++++++++------------ 1 file changed, 18 insertions(+), 12 deletions(-) diff --git a/sys/i386/i386/exception.s b/sys/i386/i386/exception.s index 8a2194038af6..73d77e289e7a 100644 --- a/sys/i386/i386/exception.s +++ b/sys/i386/i386/exception.s @@ -133,15 +133,15 @@ IDTVEC(prot) jmp irettraps IDTVEC(page) testl $PSL_VM, TF_EFLAGS-TF_ERR(%esp) - jnz 5f + jnz 6f testb $SEL_RPL_MASK, TF_CS-TF_ERR(%esp) - jnz 5f + jnz 6f cmpl $PMAP_TRM_MIN_ADDRESS, TF_EIP-TF_ERR(%esp) - jb 5f + jb 6f pushl %eax movl TF_EIP-TF_ERR+4(%esp), %eax addl $1f, %eax - call 6f + call 7f 1: cmpl $pf_x1, %eax je 2f cmpl $pf_x2, %eax @@ -159,19 +159,25 @@ IDTVEC(page) cmpl $pf_x8, %eax je 2f cmpl $pf_y1, %eax - je 3f + je 4f cmpl $pf_y2, %eax - je 3f - jmp 4f -2: movl %ebx, %cr3 -3: popl %eax + je 4f + jmp 5f +2: movl $tramp_idleptd, %eax + subl $3f, %eax + call 8f +3: movl (%eax), %eax + movl %eax, %cr3 +4: popl %eax movl %edx, TF_EIP-TF_ERR(%esp) addl $4, %esp iret -4: popl %eax -5: pushl $T_PAGEFLT +5: popl %eax +6: pushl $T_PAGEFLT jmp alltraps -6: subl (%esp), %eax +7: subl (%esp), %eax + retl +8: addl (%esp), %eax retl IDTVEC(rsvd_pti) IDTVEC(rsvd)