[Valgrind-developers] [PATCH 1/2] x86: optimize XCHG to MOV for same-register forms
H.J. Lu
hjl.tools@gmail.com
Tue Jul 7 06:54:04 GMT 2026
On Tue, Jul 7, 2026 at 1:53 PM Jan Beulich <jbeulich@suse.com> wrote:
>
> On 06.07.2026 23:12, H.J. Lu wrote:
> > We should consider benefits vs drawbacks for this optimization. Do we have
> > a list of applications which benefit from this optimization?
>
> This question was raised before (in different words), and the answer is still
> the same - how could we possibly know? The same is true though for about any
> other of the optimizations we meanwhile have. IOW to me that's _still_ not a
> viable criteria to work from.
For assembler optimizations, we can give them benefits of doubt. Since we
now know there is a significant drawback, its benefits should outweigh its
drawbacks to enable this optimization. We can't assume that this optimization
improves anything without evidence.
--
H.J.
More information about the Binutils
mailing list