amd64-gcc question
William A. Mahaffey III
wam at hiwaay.net
Sun Nov 15 16:45:54 UTC 2015
On 11/14/15 18:36, William A. Mahaffey III wrote:
> On 11/12/15 08:20, William A. Mahaffey III wrote:
>>
>>
>> Howdy, new to this list. I posted this to FreeBSD-users & was advised
>> to try this list or the GNU GCC list, so here goes:
>>
>>
>> I pkg-installed amd64-gcc over the weekend hoping for Graphite
>> (auto-loop parallelization) support, but no go. I looked around over
>> the weekend & found that there was no port for that package, only the
>> pkg. I just did a 'portsnap fetch upgrade' & there is now a port for
>> amd64-gcc, but it includes no files & no pkg-descr file. I determined
>> over the weekend that the gcc's from about V4.3 on can indeed be
>> built w/ Graphite support, but you need to do it manually. I found a
>> post dated 2010 from someone who did it under linux:
>> http://openwall.info/wiki/internal/gcc-local-build. I see no
>> configure files for any of the gcc ports (I have the entire ports
>> tree downloaded & local, & freshly updated as of a few min. ago).
>> What is the canonical/BPP (FreeBSD 9.3R) way of recompiling a port
>> with different config flags ?
>>
>>
>> I did find ports/pkgs for the 2 main components apparently needed for
>> Graphite support (cloog & ppl) & pkg-installed them over the weekend,
>> so I am ready to go on that front.
>>
>>
>> I have gotten as far as running 'make showconfig' in the various gcc*
>> & amd64-gcc directories to see what info I could get on default
>> config options. In all cases they gave options & said to run 'make
>> config' to change options. I didn't even see a 'config:' entry in the
>> Makefiles (probably included from elsewhere, but I didn't chase it).
>> I only want to make the minimum # of config mods necessary (trusting
>> that pkg/port maintainers probably know more than I about their
>> various pkg's & ports) to add the cloog & ppl support & recompile.
>>
>>
>> I have been using pkg almost exclusively to maintain my (now 3)
>> FreeBSD 9.3R boxen, except for recompiling the linux-c6 flash plugin
>> for this box whenever it get upgraded, so I have *no* experience with
>> getting more nitty-gritty w/ FreeBSD ports than that :-/. TIA & have
>> a good one.
>>
>>
>> BTW:
>>
>> [wam at devbox, pre, 8:19:58am] 676 % uname -a
>> FreeBSD devbox 9.3-RELEASE-p24 FreeBSD 9.3-RELEASE-p24 #0: Sat Aug 22
>> 01:54:44 UTC 2015
>> root at amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC amd64
>> [wam at devbox, pre, 8:20:00am] 677 % sysctl -A | grep -A1 -B1 model
>> hw.machine: amd64
>> hw.model: AMD A8-6500 APU with Radeon(tm) HD Graphics
>> hw.ncpu: 4
>> --
>> dev.rgephy.0.%location: phyno=1
>> dev.rgephy.0.%pnpinfo: oui=0xe04c model=0x0 rev=0x0
>> dev.rgephy.0.%parent: miibus0
>> [wam at devbox, pre, 8:20:12am] 678 %
>>
>>
>
>
> Updated info & a question or 2:
>
> [wam at devbox, pre, 1:07:58pm] 876 % ^8^9^
> gcc49 -v --help
> Using built-in specs.
> COLLECT_GCC=gcc49
> COLLECT_LTO_WRAPPER=/usr/local/libexec/gcc49/gcc/x86_64-portbld-freebsd9.3/4.9.4/lto-wrapper
>
> Usage: gcc49 [options] file...
> Options:
> -pass-exit-codes Exit with highest error code from a phase
> --help Display this information
> --target-help Display target specific command line options
> --help={common|optimizers|params|target|warnings|[^]{joined|separate|undocumented}}[,...]
>
> Display specific types of command line options
> --version Display compiler version information
> -dumpspecs Display all of the built in spec strings
> -dumpversion Display the version of the compiler
> -dumpmachine Display the compiler's target processor
> -print-search-dirs Display the directories in the compiler's
> search path
> -print-libgcc-file-name Display the name of the compiler's
> companion library
> -print-file-name=<lib> Display the full path to library <lib>
> -print-prog-name=<prog> Display the full path to compiler component
> <prog>
> -print-multiarch Display the target's normalized GNU
> triplet, used as
> a component in the library path
> -print-multi-directory Display the root directory for versions of
> libgcc
> -print-multi-lib Display the mapping between command line
> options and
> multiple library search directories
> -print-multi-os-directory Display the relative path to OS libraries
> -print-sysroot Display the target libraries directory
> -print-sysroot-headers-suffix Display the sysroot suffix used to
> find headers
> -Wa,<options> Pass comma-separated <options> on to the
> assembler
> -Wp,<options> Pass comma-separated <options> on to the
> preprocessor
> -Wl,<options> Pass comma-separated <options> on to the
> linker
> -Xassembler <arg> Pass <arg> on to the assembler
> -Xpreprocessor <arg> Pass <arg> on to the preprocessor
> -Xlinker <arg> Pass <arg> on to the linker
> -save-temps Do not delete intermediate files
> -save-temps=<arg> Do not delete intermediate files
> -no-canonical-prefixes Do not canonicalize paths when building
> relative
> prefixes to other gcc components
> -pipe Use pipes rather than intermediate files
> -time Time the execution of each subprocess
> -specs=<file> Override built-in specs with the contents
> of <file>
> -std=<standard> Assume that the input sources are for
> <standard>
> --sysroot=<directory> Use <directory> as the root directory for
> headers
> and libraries
> -B <directory> Add <directory> to the compiler's search paths
> -v Display the programs invoked by the compiler
> -### Like -v but options quoted and commands not
> executed
> -E Preprocess only; do not compile, assemble
> or link
> -S Compile only; do not assemble or link
> -c Compile and assemble, but do not link
> -o <file> Place the output into <file>
> -pie Create a position independent executable
> -shared Create a shared library
> -x <language> Specify the language of the following input
> files
> Permissible languages include: c c++
> assembler none
> 'none' means revert to the default behavior of
> guessing the language based on the file's
> extension
>
> Options starting with -g, -f, -m, -O, -W, or --param are automatically
> passed on to the various sub-processes invoked by gcc49. In order to
> pass
> other options on to these processes the -W<letter> options must be used.
>
> Target: x86_64-portbld-freebsd9.3
> Configured with: ./../gcc-4.9-20151028/configure
> --with-build-config=bootstrap-debug --disable-nls
> --enable-gnu-indirect-function --libdir=/usr/local/lib/gcc49
> --libexecdir=/usr/local/libexec/gcc49 --program-suffix=49
> --with-as=/usr/local/bin/as --with-gmp=/usr/local
> --with-gxx-include-dir=/usr/local/lib/gcc49/include/c++/
> --with-ld=/usr/local/bin/ld --with-ppl=/usr/local/lib
> --with-cloog=/usr/local/lib --with-libiconv-prefix=/usr/local
> --with-pkgversion='FreeBSD Ports Collection' --with-system-zlib
> --disable-libgcj --enable-languages=c,c++,objc,fortran
> --prefix=/usr/local --localstatedir=/var --mandir=/usr/local/man
> --infodir=/usr/local/info/gcc49 --build=x86_64-portbld-freebsd9.3
> Thread model: posix
> gcc version 4.9.4 20151028 (prerelease) (FreeBSD Ports Collection)
> COLLECT_GCC_OPTIONS='-v' '--help' '-mtune=generic' '-march=x86-64'
>
> /usr/local/libexec/gcc49/gcc/x86_64-portbld-freebsd9.3/4.9.4/cc1
> -quiet -v help-dummy -quiet -dumpbase help-dummy -mtune=generic
> -march=x86-64 -auxbase help-dummy -version --help -o /tmp//cc0bsC4i.s
> The following options are specific to just the language Ada:
> None found. Use --help=Ada to show *all* the options supported by
> the Ada front-end
>
>
> .... & many more lines snipped. Observe that the config shows
> --with-ppl & --with-cloog, req'd for Graphite
> (auto-loop-parallelization), yet my compiles still fail out w/ the
> following:
>
>
> Beginning background make WAMGCC=49 all
> Initiated at 06:30:01 PM MCST on Saturday, November 14, 2015
>
> MakeMPI: both ---
> MakeMPI: ../lib/R4/opteron/libmpi.a ---
> gcc49 -DNDEBUG -DUNDER_SCORE_SYS -DLOSE_GAMMAL -I../include -I~/inc
> -I../Properties -I../TEST -I../pre -march=opteron -mtune=opteron -O3
> -fprefetch-loop-arrays -floo
> p-parallelize-all -ftree-parallelize-loops=4 -fopt-info -c mpi.c
> mpprime.c
> mpi.c:1:0: sorry, unimplemented: Graphite loop optimizations cannot be
> used (-fgraphite, -fgraphite-identity, -floop-block,
> -floop-interchange, -floop-strip-mine, -fl
> oop-parallelize-all, and -ftree-loop-linear)
> /*
> ^
> mpprime.c:1:0: sorry, unimplemented: Graphite loop optimizations
> cannot be used (-fgraphite, -fgraphite-identity, -floop-block,
> -floop-interchange, -floop-strip-mine,
> -floop-parallelize-all, and -ftree-loop-linear)
> /*
> ^
> *** [../lib/R4/opteron/libmpi.a] Error code 1
> 1 error
> `usual' not remade because of errors.
>
>
> i.e. no Graphite support. A few questions:
>
> 1. Is this list the proper forum for these questions :-) ?
> 2. Are ppl & cloog (both pkg-installed last wqeekend & ready to go) in
> fact all that is req'd for Graphite support to work ?
> 3. Did the port of gcc4.9 wind up removing the req'd code internally
> for Graphite support, so that even w/ the config properly setup, I
> still get no Graphite support ?
>
>
> This identical code (accessed via VPATH macro from Makefile over
> there) compiles elsewhere on my LAN under Intel icc/ifort &
> parallelizes where expected AOK. *Any* clues much appreciated. TIA &
> have a good one.
more new info: I pkg-upgraded to gcc49-4.9.4.s20151111 this A.M. &
retried my compile, still nogo, same messages as above :-/ ....
[wam at devbox, pre, 10:48:19am] 463 % which gcc49
/usr/local/bin/gcc49
[wam at devbox, pre, 10:48:25am] 464 % ll `!!`
ll `which gcc49`
-r-xr-xr-x 3 root wheel 846360 Nov 14 03:50 /usr/local/bin/gcc49*
[wam at devbox, pre, 10:48:29am] 465 % uname -a
FreeBSD devbox 9.3-RELEASE-p24 FreeBSD 9.3-RELEASE-p24 #0: Sat Aug 22
01:54:44 UTC 2015
root at amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC amd64
[wam at devbox, pre, 10:48:37am] 466 % sysctl -a | grep -A8 -B1 hw.model
hw.machine: amd64
hw.model: AMD A8-6500 APU with Radeon(tm) HD Graphics
hw.ncpu: 4
hw.byteorder: 1234
hw.physmem: 33464279040
hw.usermem: 32952082432
hw.pagesize: 4096
hw.floatingpoint: 1
hw.machine_arch: amd64
hw.realmem: 35416702976
[wam at devbox, pre, 10:50:00am] 467 %
*Any* clues appreciated :-). TIA & have a good one.
--
William A. Mahaffey III
----------------------------------------------------------------------
"The M1 Garand is without doubt the finest implement of war
ever devised by man."
-- Gen. George S. Patton Jr.
More information about the freebsd-toolchain
mailing list