2019-11-12 22:37:07

by Jeffrin Thalakkottoor

[permalink] [raw]
Subject: PROBLEM: objtool: __x64_sys_exit_group()+0x14: unreachable instruction

hello all,

i found a warning during kernel build (5.3.11-rc1+).
-----------------x----------x-----------------
kernel/exit.o: warning: objtool: __x64_sys_exit_group()+0x14: unreachable instruction
-------------------x---------------x-----------

Related details:
---------------

$uname -a
Linux debian 5.3.11-rc1+ #6 SMP Tue Nov 12 01:23:06 IST 2019 x86_64 GNU/Linux
$

$gcc --version
gcc (Debian 9.2.1-14) 9.2.1 20191025
------x---has-been-cut-here--x------



(gdb) l __x64_sys_exit_group
987 /*
988 * this kills every thread in the thread group. Note that any externally
989 * wait4()-ing process will get the correct exit code - even if this
990 * thread is not the thread group leader.
991 */
992 SYSCALL_DEFINE1(exit_group, int, error_code)
993 {
994 do_group_exit((error_code & 0xff) << 8);
995 /* NOTREACHED */
996 return 0;
(gdb)

(gdb) l *__x64_sys_exit_group+0x14
0xffffffff81085404 is in __x64_sys_exit_group (kernel/exit.c:996).
991 */
992 SYSCALL_DEFINE1(exit_group, int, error_code)
993 {
994 do_group_exit((error_code & 0xff) << 8);
995 /* NOTREACHED */
996 return 0;
997 }
998
999 struct waitid_info {
1000 pid_t pid;
(gdb)


(gdb) l *__x64_sys_exit_group
0xffffffff810853f0 is in __x64_sys_exit_group (kernel/exit.c:992).
987 /*
988 * this kills every thread in the thread group. Note that any externally
989 * wait4()-ing process will get the correct exit code - even if this
990 * thread is not the thread group leader.
991 */
992 SYSCALL_DEFINE1(exit_group, int, error_code)
993 {
994 do_group_exit((error_code & 0xff) << 8);
995 /* NOTREACHED */
996 return 0;
(gdb)

--------------------x-------------x-----------------------------

objdump -r -S -l --disassemble kernel/exit.o output is attached

--
software engineer
rajagiri school of engineering and technology







Attachments:
(No filename) (1.85 kB)
objoutput.txt (263.51 kB)
Download all attachments

2019-11-13 01:31:33

by Sasha Levin

[permalink] [raw]
Subject: Re: PROBLEM: objtool: __x64_sys_exit_group()+0x14: unreachable instruction

On Wed, Nov 13, 2019 at 04:03:00AM +0530, Jeffrin Jose wrote:
>hello all,
>
>i found a warning during kernel build (5.3.11-rc1+).
>-----------------x----------x-----------------
>kernel/exit.o: warning: objtool: __x64_sys_exit_group()+0x14: unreachable instruction
>-------------------x---------------x-----------

Could you bisect it please? I'm not seeing the warning here, and
kernel/exit.c wasn't touched during the life of the 5.3 stable tree.

--
Thanks,
Sasha

2019-11-13 21:42:17

by Jeffrin Thalakkottoor

[permalink] [raw]
Subject: Re: PROBLEM: objtool: __x64_sys_exit_group()+0x14: unreachable instruction

On Wed, Nov 13, 2019 at 7:00 AM Sasha Levin <[email protected]> wrote:
> Could you bisect it please? I'm not seeing the warning here, and
> kernel/exit.c wasn't touched during the life of the 5.3 stable tree.


I tried using related to "git bisect" and managed to check based
on kernel revision related. The warning existed even on 5.3.5 and
may be even back . i think may be it is a compiler issue which creates
the warning and not the kernel.


--
software engineer
rajagiri school of engineering and technology

2019-11-15 17:06:16

by Jeffrin Thalakkottoor

[permalink] [raw]
Subject: Re: PROBLEM: objtool: __x64_sys_exit_group()+0x14: unreachable instruction

On Thu, Nov 14, 2019 at 3:07 AM Jeffrin Thalakkottoor
<[email protected]> wrote:
>
> On Wed, Nov 13, 2019 at 7:00 AM Sasha Levin <[email protected]> wrote:
> > Could you bisect it please? I'm not seeing the warning here, and
> > kernel/exit.c wasn't touched during the life of the 5.3 stable tree.
>
>
> I tried using related to "git bisect" and managed to check based
> on kernel revision related. The warning existed even on 5.3.5 and
> may be even back . i think may be it is a compiler issue which creates
> the warning and not the kernel.

i saw a link related to our issue:
https://lore.kernel.org/lkml/20170726191008.jk2cdqr4wqnc33es@treble/
please see the above link.





--
software engineer
rajagiri school of engineering and technology