From: Josh Poimboeuf <jpoimboe@kernel.org>
To: Chen Zhongjin <chenzhongjin@huawei.com>
Cc: linux-kernel@vger.kernel.org, x86@kernel.org,
linux-arch@vger.kernel.org, peterz@infradead.org,
tglx@linutronix.de, mingo@redhat.com, bp@alien8.de,
dave.hansen@linux.intel.com, hpa@zytor.com, mbenes@suse.cz
Subject: Re: [PATCH] Revert "x86/unwind/orc: Don't skip the first frame for inactive tasks"
Date: Fri, 14 Oct 2022 15:44:53 -0700 [thread overview]
Message-ID: <20221014224453.5upiioslqjzo2bow@treble> (raw)
In-Reply-To: <a3d754f7-5dde-4adc-205a-c4c380a30372@huawei.com>
On Sun, Oct 09, 2022 at 11:14:05AM +0800, Chen Zhongjin wrote:
> Hi Josh,
>
> On 2022/8/5 6:06, Josh Poimboeuf wrote:
> > On Thu, Aug 04, 2022 at 03:27:39PM +0800, Chen Zhongjin wrote:
> > > I believe disassemble show_stack in vmlinux and if we have:
> > >
> > > push %rbp
> > >
> > > mov %rsp,%rbp
> > >
> > > ... (no regs pushed to stack)
> > >
> > > callq <show_trace_log_lvl>
> > >
> > > This can be reproduced.
> > Weird, that's what I have. This is GCC 12.1.
> >
> > ffffffff81056de0 <show_stack>:
> > ffffffff81056de0: e8 0b 43 05 00 call ffffffff810ab0f0 <__fentry__>
> > ffffffff81056de5: 55 push %rbp
> > ffffffff81056de6: 48 83 05 b2 0f c9 02 01 addq $0x1,0x2c90fb2(%rip) # ffffffff83ce7da0 <__gcov0.show_stack>
> > ffffffff81056dee: 48 89 e5 mov %rsp,%rbp
> > ffffffff81056df1: 48 85 ff test %rdi,%rdi
> > ffffffff81056df4: 74 41 je ffffffff81056e37 <show_stack+0x57>
> > ffffffff81056df6: 48 85 f6 test %rsi,%rsi
> > ffffffff81056df9: 0f 85 c2 24 15 01 jne ffffffff821a92c1 <show_stack.cold+0xd>
> > ffffffff81056dff: 65 48 8b 04 25 c0 bd 01 00 mov %gs:0x1bdc0,%rax
> > ffffffff81056e08: 48 39 c7 cmp %rax,%rdi
> > ffffffff81056e0b: 0f 85 a3 24 15 01 jne ffffffff821a92b4 <show_stack.cold>
> > ffffffff81056e11: 48 83 05 af 0f c9 02 01 addq $0x1,0x2c90faf(%rip) # ffffffff83ce7dc8 <__gcov0.show_stack+0x28>
> > ffffffff81056e19: 48 89 ee mov %rbp,%rsi
> > ffffffff81056e1c: 48 89 d1 mov %rdx,%rcx
> > ffffffff81056e1f: 48 89 f2 mov %rsi,%rdx
> > ffffffff81056e22: 31 f6 xor %esi,%esi
> > ffffffff81056e24: e8 8e 20 15 01 call ffffffff821a8eb7 <show_trace_log_lvl>
> > ffffffff81056e29: 48 83 05 9f 0f c9 02 01 addq $0x1,0x2c90f9f(%rip) # ffffffff83ce7dd0 <__gcov0.show_stack+0x30>
> > ffffffff81056e31: 5d pop %rbp
> > ffffffff81056e32: e9 49 b2 5a 01 jmp ffffffff82602080 <__x86_return_thunk>
> > ffffffff81056e37: 48 83 05 69 0f c9 02 01 addq $0x1,0x2c90f69(%rip) # ffffffff83ce7da8 <__gcov0.show_stack+0x8>
> > ffffffff81056e3f: 65 48 8b 3c 25 c0 bd 01 00 mov %gs:0x1bdc0,%rdi
> > ffffffff81056e48: eb ac jmp ffffffff81056df6 <show_stack+0x16>
> > ffffffff81056e4a: 66 0f 1f 44 00 00 nopw 0x0(%rax,%rax,1)
>
> This problem still exist on my machine:
>
> CONFIG: defconfig + CONFIG_GCOV_PROFILE_ALL
>
> GCC: gcc 7.5.0 & 12.1.0
>
> TRIGGER:
>
> # echo l > /proc/sysrq-trigger
Hi Chen,
Thanks for your patience. I'm able to recreate now. I still have no
idea why I couldn't recreate before.
Anyway the patch looks good. I'll run it through some more testing.
--
Josh
prev parent reply other threads:[~2022-10-14 22:45 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-27 3:15 [PATCH] Revert "x86/unwind/orc: Don't skip the first frame for inactive tasks" Chen Zhongjin
2022-08-04 4:55 ` Josh Poimboeuf
2022-08-04 7:27 ` Chen Zhongjin
2022-08-04 22:06 ` Josh Poimboeuf
2022-10-09 3:14 ` Chen Zhongjin
2022-10-14 22:44 ` Josh Poimboeuf [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20221014224453.5upiioslqjzo2bow@treble \
--to=jpoimboe@kernel.org \
--cc=bp@alien8.de \
--cc=chenzhongjin@huawei.com \
--cc=dave.hansen@linux.intel.com \
--cc=hpa@zytor.com \
--cc=linux-arch@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mbenes@suse.cz \
--cc=mingo@redhat.com \
--cc=peterz@infradead.org \
--cc=tglx@linutronix.de \
--cc=x86@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).