[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150326092712.GA27751@pd.tnic>
Date: Thu, 26 Mar 2015 10:27:12 +0100
From: Borislav Petkov <bp@...en8.de>
To: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: "H. Peter Anvin" <hpa@...or.com>,
Denys Vlasenko <dvlasenk@...hat.com>,
Ingo Molnar <mingo@...nel.org>,
Steven Rostedt <rostedt@...dmis.org>,
Andy Lutomirski <luto@...capital.net>,
Oleg Nesterov <oleg@...hat.com>,
Frederic Weisbecker <fweisbec@...il.com>,
Alexei Starovoitov <ast@...mgrid.com>,
Will Drewry <wad@...omium.org>,
Kees Cook <keescook@...omium.org>,
the arch/x86 maintainers <x86@...nel.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 3/4] x86/asm/entry/64: use smaller insns
On Wed, Mar 25, 2015 at 05:05:50PM -0700, Linus Torvalds wrote:
> so 'as' is clearly just stupid. It already takes the size of the
> constant into account and generates different instructions. Why not
> for the common 32-bit case too?
I think the destination register mandates which insn to use:
mov $0x12345678, %rdi
mov $0x12345678, %edi
...
15: 48 c7 c7 78 56 34 12 mov $0x12345678,%rdi
1c: bf 78 56 34 12 mov $0x12345678,%edi
and 'as' is perhaps not insolent enough to go and change it when seeing
the 32-bit constant.
--
Regards/Gruss,
Boris.
ECO tip #101: Trim your mails when you reply.
--
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists