This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

MinGW32 queries: 3dNOW support, profiling


I think this should probably go to a binutils mailing list, but I can't find
one. It may be that this is just a request to Dr Khan to put a newer version
of binutils into Mingw32 (I'm currently using 2.95-2).

The question is as in the title: if I try to assemble something like

void main(void)
{
  __asm__("pfadd %mm0,%mm1");
}

with g++ -o t3dn.exe t3dn.cpp, I get an error from as of the form 'no such
386 instruction'.

If I replace the PFADD (a 3DNow packed vector instruction) with PADDW (an
MMX instruction), everything assembles without a hitch, so this looks as if
the binutils in the version of MinGW32 I have doesn't believe in 3DNow.
Likewise if I try 'ADDPS %xm1,%xm7' (an SSE instruction).

I can't imagine that GNU as hasn't been modified to support 3DNow,
Athlon-extended 3DNow and SSE by now; does anyone know where I can get an
updated version for i386-mingw32msvc? I hope I'll need only to replace the
as.exe file.

I'm also having problems getting profiling of C++ programs to work with
MinGW32:

C:\PhD\covar>g++ -O9 -march=k6 -o foo.exe -pg test_sl2c.cpp sl2c.cpp
C:\WINDOWS\TEMP\ccwljcgb.o(.text$__tf11_ios_fields+0x0):sl2c.cpp: multiple
definition of `_ios_fields type_info function'
C:\WINDOWS\TEMP\ccfrlegb.o(.text$__tf11_ios_fields+0x0):test_sl2c.cpp: first
defined here
C:\WINDOWS\TEMP\ccwljcgb.o(.text$__tf8iostream+0x0):sl2c.cpp: multiple
definition of `iostream type_info function'
C:\WINDOWS\TEMP\ccfrlegb.o(.text$__tf8iostream+0x0):test_sl2c.cpp: first
defined here
C:\TOOLS\MINGW32\BIN\..\lib\gcc-lib\i386-mingw32msvc\2.95.2\libstdc++.a(dcom
io.o)(.text$__tf11_ios_fields+0x0): multiple definition of `_ios_fields
type_info function'
C:\WINDOWS\TEMP\ccfrlegb.o(.text$__tf11_ios_fields+0x0):test_sl2c.cpp: first
defined here
C:\TOOLS\MINGW32\BIN\..\lib\gcc-lib\i386-mingw32msvc\2.95.2\libstdc++.a(dcom
io.o)(.text$__tf8iostream+0x0): multiple definition of `iostream type_info
function'
C:\WINDOWS\TEMP\ccfrlegb.o(.text$__tf8iostream+0x0):test_sl2c.cpp: first
defined here

I haven't a clue what's going wrong here; if I concatenate the two files
into a single source file, I get an even longer stream of errors. Is
profiling even supported for C++ using the STL?

Tom



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]