[llvm-dev] LLVM Build Error: Target object too big
Clint Banis via llvm-dev
llvm-dev at lists.llvm.org
Mon Jul 29 23:18:49 PDT 2019
While trying to assemble a particular input file, my build system failed because
the target object was too big. I calculated that the input source file after
preprocessing would be about 3.91Mb.
system: CYGWIN_NT-10.0 x86_64 Cygwin
file: llvm-master/lib/Passes/PassBuilder.cpp
build output:
Scanning dependencies of target LLVMPasses
[ 84%] Building CXX object
lib/Passes/CMakeFiles/LLVMPasses.dir/PassBuilder.cpp.o
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/../../../../x86_64-pc-cygwin/bin/as:
CMakeFiles/LLVMPasses.dir/PassBuilder.cpp.o: too many sections (55165)
/tmp/cc9ADbCA.s: Assembler messages:
/tmp/cc9ADbCA.s: Fatal error: can't write
CMakeFiles/LLVMPasses.dir/PassBuilder.cpp.o: File too big
/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/../../../../x86_64-pc-cygwin/bin/as:
CMakeFiles/LLVMPasses.dir/PassBuilder.cpp.o: too many sections (55165)
/tmp/cc9ADbCA.s: Fatal error: can't close
CMakeFiles/LLVMPasses.dir/PassBuilder.cpp.o: File too big
make[2]: *** [lib/Passes/CMakeFiles/LLVMPasses.dir/build.make:63:
lib/Passes/CMakeFiles/LLVMPasses.dir/PassBuilder.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:17896:
lib/Passes/CMakeFiles/LLVMPasses.dir/all] Error 2
make: *** [Makefile:150: all] Error 2
compiler version:
$ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/lto-wrapper.exe
Target: x86_64-pc-cygwin
Configured with:
/cygdrive/i/szsz/tmpp/gcc/gcc-5.4.0-1.x86_64/src/gcc-5.4.0/configure
--srcdir=/cygdrive/i/szsz/tmpp/gcc/gcc-5.4.0-1.x86_64/src/gcc-5.4.0
--prefix=/usr --exec-prefix=/usr --localstatedir=/var
--sysconfdir=/etc --docdir=/usr/share/doc/gcc
--htmldir=/usr/share/doc/gcc/html -C --build=x86_64-pc-cygwin
--host=x86_64-pc-cygwin --target=x86_64-pc-cygwin
--without-libiconv-prefix --without-libintl-prefix
--libexecdir=/usr/lib --enable-shared --enable-shared-libgcc
--enable-static --enable-version-specific-runtime-libs
--enable-bootstrap --enable-__cxa_atexit --with-dwarf2
--with-tune=generic
--enable-languages=ada,c,c++,fortran,lto,objc,obj-c++
--enable-graphite --enable-threads=posix --enable-libatomic
--enable-libcilkrts --enable-libgomp --enable-libitm
--enable-libquadmath --enable-libquadmath-support --enable-libssp
--enable-libada --enable-libgcj-sublibs --disable-java-awt
--disable-symvers --with-ecj-jar=/usr/share/java/ecj.jar --with-gnu-ld
--with-gnu-as --with-cloog-include=/usr/include/cloog-isl
--without-libiconv-prefix --without-libintl-prefix --with-system-zlib
--enable-linker-build-id --with-default-libstdcxx-abi=gcc4-compatible
Thread model: posix
gcc version 5.4.0 (GCC)
$ as -v
GNU assembler version 2.25.2 (x86_64-pc-cygwin) using BFD version
(GNU Binutils) 2.25.2
$ make -v
GNU Make 4.2.1
Built for x86_64-unknown-cygwin
Copyright (C) 1988-2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
<http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
$ cmake --version
cmake version 3.6.2
CMake suite maintained and supported by Kitware (kitware.com/cmake).
What I've tried so far:
CFLAGS="-Wa,-mbig-obj" make
But still same error.
I tried -Wa
More information about the llvm-dev
mailing list