This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: PACTH: Enable Intel AVX
On Mon, Apr 07, 2008 at 03:25:56PM +0100, Jan Beulich wrote:
> >>> "H.J. Lu" <hjl.tools@gmail.com> 07.04.08 15:03 >>>
> >On Mon, Apr 07, 2008 at 09:29:30AM +0100, Jan Beulich wrote:
> >> There's one oversight in the gas part: parse_real_register() shouldn't
> >> return ymm registers without the according feature(s) enabled.
> >
> >Here is a patch to check it.
>
> It only adds a check for the positive cases, not for the negative
> ones (i.e. where ymmX does *not* reference a register)...
I am checking in the enclosed patch.
>
> >>
> >> Besides that I wonder whether AES and PCLMUL really imply MMX
> >> support? I don't think CPUID documentation allows any such
> >> implication.
> >>
> >
> >AES/PCLMUL don't support MMX. But they do imply at least SSE2.
>
> That would be what I expected (and you could thus imply SSE, too,
> I would think). My concern is that with MMX becoming all the less
> supported over time, it may be desirable to have a way to entirely
> disable MMX support, and in that case .avx could needlessly turn it
> (back) on.
>
That may happen in the future. Another possibility is both SSE and
MMX may be removed in favor of AVX. We can add a new switch when
needed.
H.J.
---
--- gas/i386/att-regs.d.ymm 2008-04-07 06:07:28.000000000 -0700
+++ gas/i386/att-regs.d 2008-04-07 07:33:29.000000000 -0700
@@ -31,6 +31,7 @@ Disassembly of section \.text:
.*:[ ]+0f 24 c0[ ]+mov[ ]+%tr0,%eax
.*[ ]+R_386_32[ ]+mm0
.*[ ]+R_386_32[ ]+xmm0
+.*[ ]+R_386_32[ ]+ymm0
.*:[ ]+dd c0[ ]+ffree[ ]+%st(\(0\))?
.*:[ ]+0f ef c0[ ]+pxor[ ]+%mm0,%mm0
.*:[ ]+0f 57 c0[ ]+xorps[ ]+%xmm0,%xmm0
--- gas/i386/att-regs.s.ymm 2008-04-07 06:07:28.000000000 -0700
+++ gas/i386/att-regs.s 2008-04-07 07:32:55.000000000 -0700
@@ -32,6 +32,7 @@
mov tr0, eax
mov mm0, eax
mov xmm0, eax
+ mov ymm0, eax
#todo .arch i387
ffree st
--- gas/i386/intel-regs.d.ymm 2008-04-07 06:07:28.000000000 -0700
+++ gas/i386/intel-regs.d 2008-04-07 07:33:37.000000000 -0700
@@ -31,6 +31,7 @@ Disassembly of section \.text:
.*:[ ]+0f 24 c0[ ]+mov[ ]+%tr0,%eax
.*[ ]+R_386_32[ ]+mm0
.*[ ]+R_386_32[ ]+xmm0
+.*[ ]+R_386_32[ ]+ymm0
.*:[ ]+dd c0[ ]+ffree[ ]+%st(\(0\))?
.*:[ ]+0f ef c0[ ]+pxor[ ]+%mm0,%mm0
.*:[ ]+0f 57 c0[ ]+xorps[ ]+%xmm0,%xmm0
--- gas/i386/intel-regs.s.ymm 2008-04-07 06:07:28.000000000 -0700
+++ gas/i386/intel-regs.s 2008-04-07 07:33:03.000000000 -0700
@@ -32,6 +32,7 @@
mov eax, tr0
mov eax, mm0
mov eax, xmm0
+ mov eax, ymm0
#todo .arch i387
ffree st