Le 07-05-11 à 20:50, David Liontooth a écrit :
In packaging transcode for macports, Chuck Remes noticed Apple's
assembler is based on an outdated GNU assembler that doesn't
support all
the modern MMX, SSE2, SSE3, etc. extensions in open source
applications.
On OSX I have this:
$ as -v
Apple Computer, Inc. version cctools-622.5.obj~13, GNU assembler
version 1.38
In contrast, Debian sid uses:
# as -v
GNU assembler version 2.17.50 (x86_64-linux-gnu) using BFD version
(GNU Binutils for Debian) 2.17.50.20070426
The assembler is part of the binutils package, which is ported, but
gas,
the GNU assembler, is left out.
Of course the Apple assembler supports all the modern extensions in
their own software, but after GNU v1.28, Apple made the decision to
move
these binaries into their 'Accelerate framework'
(http://developer.apple.com/performance/accelerateframework.html)
-- as
far as I understand as a part of their incremental moves to close the
Darwin source.
In the short run, and perhaps the long, this likely means we're not
going to see free software's assembly code compile at all on OSX.
I'm not sure how the assembler can be affected by higher-level
frameworks ? IMHO, that is the linker's job and appropriate flags
will do it.
What I know is that the assembler syntax on darwin is different from
GNU. When I patched the gimp 2.x to enable assembler / altivec
functions, I had to modify the syntax :
--- app/base/cpu-accel.c.orig 2005-06-18 12:37:55.000000000 -0400
+++ app/base/cpu-accel.c 2005-06-18 13:19:30.000000000 -0400
@@ -361,7 +361,7 @@
#endif /* ARCH_X86 && USE_MMX && __GNUC__ */
-#if defined (ARCH_PPC) && defined (USE_ALTIVEC) && defined(__GNUC__)
+#if defined (ARCH_PPC) && defined (USE_ALTIVEC)
#define HAVE_ACCEL 1
@@ -395,7 +395,7 @@
canjump = 1;
asm volatile ("mtspr 256, %0\n\t"
- "vand %%v0, %%v0, %%v0"
+ "vand v0,v0,v0\n\t"
:
: "r" (-1));
http://bugzilla.gnome.org/show_bug.cgi?id=325180
yves
_______________________________________________
macports-users mailing list
macports-users@lists.macosforge.org
http://lists.macosforge.org/mailman/listinfo/macports-users