From nobody Tue Feb 28 16:10:23 2023 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 4PR2QS2XS4z3tdCn; Tue, 28 Feb 2023 16:10:24 +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 4PR2QS1smLz3Fcv; Tue, 28 Feb 2023 16:10:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1677600624; 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=CaTxlEl3EQlQpPf2FK50h/UlPlRsuOqp4WiM/zAftUc=; b=hl76o0oxAR5pNcUvk+Q1y44hnl08569ie3XVkaV4wplG1A8zW1jYQHxX3b02NdUXCDvCGY gPgvyyMvGIA/XGf+IucdIzYoAOwv4zmGOFjLhkNRWUpdW4CDGD12efn/tOEJsZnfodzBs6 MIUl6J1kg40NPu/HK8YDtBvhGId5BY0M9Uc9mYrVFs+KIOIHjbDMpC85l/ZHX5QDhDmOO2 AS4qslAYHrHfKOfLYeF7RaiHEtAwQK/BCPF+5h8DQf/PBBG4dk2lgQg0tKzpTkPBQr7bWT C+zdSVjms0uwSZZdTOScOYpSl0A2+fUZpMgkurBCqJPfa2bT+p9ltVU4uVxJMg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1677600624; 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=CaTxlEl3EQlQpPf2FK50h/UlPlRsuOqp4WiM/zAftUc=; b=H3TDJQ6hv77NrCDLhgYIeQP4onbWtXnD6jkV+K1PyvP3CQXThXEQtbk9c3+ai9drrwzjn9 QEVnzTf3vJL1x0HXhCkEVapPwGnoPBJa+9YhtcrBNvdgwPcoYadzbKtBfrZOTjlXiGurcH A/1UiobFz8Ir31Rsrd9M1RXHUHFKFF9O6sbANnnRdJcoPMagAh0tlcVnn0mkPKq9wY1dDW 4twqws2VNFOrD6Z7iny96QWaO0Io63faeRVMlV9R2pIlWwOjQkepgD+lzDB0/nmUF3Uamb 7WGw0NMdeJnH4x8QbK4HUiC59BjQ6StIg7HnxuQLryzosLgtRyOSTbUDZJDTfQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1677600624; a=rsa-sha256; cv=none; b=FcoLtm4N9DfgdUMkdyNVSol6CBKHSh/j8YuIKOtTtTT+drv/WbsHQ6H6hRsbHDU72D/v/4 TsXcM0C5bWJww7Qy2QogfPy7ucDwJvS1IClpWqyQii5mDvHZpkih6pptd5i4law1PQjRvJ CXhZraOx0ZiMgRDETdFs+q/NxZT0q0Tbc/Eyejp27Eg19QUy0uWrfgkhwDJPZdhksvDC6k k4qc2V2oQug3JPT9hqZJ8RW3SoArb6ceYUOyGac1Fhe6yr9Fgis2ed9Sq8df+/TXqL2rVl Sg2RizeW/7MquA0hn0r4nI9qm+Jg3Fd5rZVGg18pJAQeSkXJnx5pCNb4p1kFuA== 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 4PR2QS0pslz1DHK; Tue, 28 Feb 2023 16:10:24 +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 31SGANoS096423; Tue, 28 Feb 2023 16:10:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 31SGANW3096422; Tue, 28 Feb 2023 16:10:23 GMT (envelope-from git) Date: Tue, 28 Feb 2023 16:10:23 GMT Message-Id: <202302281610.31SGANW3096422@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mark Johnston Subject: git: 092a543ec3d2 - main - dtrace_kinst.4: Demonstrate usage of the "regs" variable 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 092a543ec3d276e48da09538ae29c736fdce4631 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=092a543ec3d276e48da09538ae29c736fdce4631 commit 092a543ec3d276e48da09538ae29c736fdce4631 Author: Mark Johnston AuthorDate: 2023-02-28 16:09:26 +0000 Commit: Mark Johnston CommitDate: 2023-02-28 16:10:04 +0000 dtrace_kinst.4: Demonstrate usage of the "regs" variable Suggested by: Mina Galić Reviewed by: christos Differential Revision: https://reviews.freebsd.org/D38823 --- share/man/man4/dtrace_kinst.4 | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/share/man/man4/dtrace_kinst.4 b/share/man/man4/dtrace_kinst.4 index 0987ba493e55..349cb1aab1dd 100644 --- a/share/man/man4/dtrace_kinst.4 +++ b/share/man/man4/dtrace_kinst.4 @@ -57,7 +57,7 @@ The provider is currently implemented only for amd64. .Sh EXAMPLES Find the offset corresponding to the third instruction in .Fn vm_fault -and trace it: +and trace it, printing the contents of the RSI register: .Bd -literal -offset indent # kgdb (kgdb) disas /r vm_fault @@ -66,12 +66,12 @@ Dump of assembler code for function vm_fault: 0xffffffff80876df1 <+1>: 48 89 e5 mov %rsp,%rbp 0xffffffff80876df4 <+4>: 41 57 push %r15 -# dtrace -n 'kinst::vm_fault:4' - 2 81500 vm_fault:4 - 2 81500 vm_fault:4 - 2 81500 vm_fault:4 - 2 81500 vm_fault:4 - 0 81500 vm_fault:4 +# dtrace -n 'kinst::vm_fault:4 {printf("%#x", regs[R_RSI]);}' + 2 81500 vm_fault:4 0x827c56000 + 2 81500 vm_fault:4 0x827878000 + 2 81500 vm_fault:4 0x1fab9bef0000 + 2 81500 vm_fault:4 0xe16cf749000 + 0 81500 vm_fault:4 0x13587c366000 ... .Ed .Pp