diff options
author | Richard Henderson <rth@twiddle.net> | 2016-11-18 17:02:59 +0100 |
---|---|---|
committer | Richard Henderson <rth@twiddle.net> | 2017-01-10 08:47:48 -0800 |
commit | 4ac76910734209dab83ddd3795f08fc7889ef463 (patch) | |
tree | 294ec14a5508d99b315cedff08f4717caf028060 /target/arm/helper-a64.c | |
parent | bbf25f90ba802a286fd72be9175a860ae5fec726 (diff) |
tcg/i386: Rely on undefined/undocumented behaviour of BSF/BSR
The ISA manual documents the output is undefined if the input was zero.
However, we document in target-i386 that the behavior of real silicon
is to preserve the contents of the output register. We also mention
that there are real applications that depend on this. That this is
baked into silicon is mentioned as a potential cause for some false
sharing behaviour wrt lzcnt/tzcnt.
Taking advantage of this allows us to save 2 insns in the normal case,
and 4 insns for i686 emulating a 64-bit clz.
Signed-off-by: Richard Henderson <rth@twiddle.net>
Diffstat (limited to 'target/arm/helper-a64.c')
0 files changed, 0 insertions, 0 deletions