[llvm-commits] [PATCH] [X86] Add {l} suffix to cvtsi2ss (and similar) mnemonics.

Kuperstein, Michael M michael.m.kuperstein at intel.com
Sat Jan 5 22:59:40 PST 2013


Thanks, Craig!

My main reason for the patch was to accept 'l' for si2ss and si2sd. I added the rest for (possibly misguided) completeness.
Matching gas behavior sounds like a good idea to me.

Michael

From: Craig Topper [mailto:craig.topper at gmail.com]
Sent: Sunday, January 06, 2013 05:20
To: Kuperstein, Michael M; Nadav Rotem
Cc: llvm-commits at cs.uiuc.edu
Subject: Re: [PATCH] [X86] Add {l} suffix to cvtsi2ss (and similar) mnemonics.

I started looking at what gas does here.

For si2ss/si2sd, gas will treat 'q' at 64-bit and 'l' or no suffix as 32-bit. When disassembling it always prints with the suffix.
For ss2si/sd2si, gas will accept 'l' or 'q' or it will use the size of the destination register if no suffix is supplied. Disassembly doesn't print a suffix.

I've attached a patch that should match gas behavior. Not sure which way we want to go on this. Nadav, any thoughts?

~Craig
On Tue, Jan 1, 2013 at 4:58 AM, Kuperstein, Michael M <michael.m.kuperstein at intel.com<mailto:michael.m.kuperstein at intel.com>> wrote:
Hi,
The attached patch adds {l} suffixes to the mnemonics of all 32-bit X86 scalar integer <=> float convert instructions, e.g. cvtsi2ss => cvtsi2ss{l}.  The {q} versions were already present, added by ctopper in r160775.
I haven't really touched this area before so I'm not at all sure I'm doing the right thing by adding the suffix, as opposed to having aliases. Can anyone (Craig? :-) ) review?

Thanks,
   Michael

---------------------------------------------------------------------
Intel Israel (74) Limited

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.



--
~Craig
---------------------------------------------------------------------
Intel Israel (74) Limited

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20130106/620824c1/attachment.html>


More information about the llvm-commits mailing list