lkml.org 
[lkml]   [2015]   [May]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH] x86/asm/entry/64: Use shorter MOVs from segmers registers
From
On Thu, May 14, 2015 at 9:55 AM, Denys Vlasenko <dvlasenk@redhat.com> wrote:
> "movw %ds,%cx" insn needs a 0x66 prefix, while "movw %ds,%ecx" does not.
> The difference is that it overwrite entire %ecx, not only its low half,
> but subsequent code doesn't depend on the value of top half of %ecx,
> we can safely use the shorter insn.

I don't object to the patch, but did we actually confirm that it
always overwrites all of %ecx? The segment move instructions are
schizofrenic when it comes to sizes, and sometimes write just 16 bits
even when the instruction size is 32.

Was that just for push and/or move-to-memory?

Linus


\
 
 \ /
  Last update: 2015-05-14 19:21    [W:0.033 / U:2.644 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site