On 2017/11/26 14:00, Sebastien Marie wrote: > Hi, > > The following diff makes i386 to be compiled without --enable-rust-simd. > simd is "Single instruction, multiple data" (aka MMX, SSE, SSE2...). > > rustc when compiled with external LLVM doesn't export target_features as > compilation variable, making firefox building to fail. > > I workarounded the problem on amd64 by manually exported SSE2 symbol > (always present on amd64). But for i386, same hack isn't possible (as > not all i386 processors have such extensions). So it is preferable to > not enable simd on i386. > > I tested the diff with rustc 1.22.1 and firefox still build well (but no > runtime test).
Is it actually needed? I can't imagine anything that can actually *run* firefox (RAM-wise) that doesn't at least have SSE. Due to the serious lack of registers on i386 (especially with PIE) I think it needs all the help it can get... > Index: Makefile > =================================================================== > RCS file: /cvs/ports/www/mozilla-firefox/Makefile,v > retrieving revision 1.333 > diff -u -p -r1.333 Makefile > --- Makefile 16 Nov 2017 23:20:40 -0000 1.333 > +++ Makefile 26 Nov 2017 11:42:39 -0000 > @@ -8,6 +8,7 @@ ONLY_FOR_ARCHS = amd64 i386 > MOZILLA_VERSION = 57.0 > MOZILLA_PROJECT = firefox > MOZILLA_CODENAME = browser > +REVISION = 0 > > SO_VERSION = 75.0 > # NOTE: Must bump minor version if any shlib's are removed from the > @@ -54,11 +55,14 @@ CONFIGURE_ENV = CPPFLAGS="-I${LOCALBASE > # bug 857628 > CONFIGURE_ARGS += --enable-pie > CONFIGURE_ARGS += --enable-release #1386371 > -CONFIGURE_ARGS += --enable-rust-simd #1261841 > CONFIGURE_ARGS += --enable-webrender=build > # bug 1409680 > .if ${MACHINE_ARCH} == "i386" > CONFIGURE_ARGS += --disable-debug-symbols > +.endif > +# bug 1261841 > +.if ${MACHINE_ARCH} == "amd64" > +CONFIGURE_ARGS += --enable-rust-simd > .endif > #CONFIGURE_ARGS += --enable-linker=lld >