Mohit Bhakkad
2015-Feb-13 08:24 UTC
[LLVMdev] [Compiler-rt] i386 is not supported in compiler-rt build
I am trying to build compiler-rt on a x86_64 machine using clang. Command used: CC=clang CXX=clang++ cmake <path to compiler-rt> -DLLVM_CONFIG_PATH=<Path to llvm toolchain>/bin/llvm-config -DCOMPILER_RT_INSTALL_PATH=<Path to llvm toolchain>/lib/clang/3.7.0 after this command on console it prints, -- Compiler-RT supported architectures: x86_64 Instead if I use gcc in above command, it supports both i386, x86_64 -- Compiler-RT supported architectures: x86_64;i386 I am curious about why its not supporting i386 with clang, as this clang can compile a simple program for i386. Looking into cmake file, it looks like i386 is failing this <https://github.com/llvm-mirror/compiler-rt/blob/master/cmake/config-ix.cmake#L76> test. I have checked variables for both the target, which looks fine to me: -- {CAN_TARGET_x86_64}: TRUE -- {CMAKE_BINARY_DIR}: /home/mohit/compiler-rt_build -- {SIMPLE_SOURCE}: /home/mohit/compiler-rt_build/CMakeFiles/simple.cc -- {TARGET_x86_64_CFLAGS}: -m64 -- TARGET_{arch}_OUTPUT: TARGET_x86_64_OUTPUT -- -DCMAKE_EXE_LINKER_FLAGS:STRING={argstring}:-DCMAKE_EXE_LINKER_FLAGS:STRING-m64 -- {CAN_TARGET_i386}: FALSE -- {CMAKE_BINARY_DIR}: /home/mohit/compiler-rt_build -- {SIMPLE_SOURCE}: /home/mohit/compiler-rt_build/CMakeFiles/simple.cc -- {TARGET_i386_CFLAGS}: -m32 -- TARGET_{arch}_OUTPUT: TARGET_i386_OUTPUT -- -DCMAKE_EXE_LINKER_FLAGS:STRING={argstring}:-DCMAKE_EXE_LINKER_FLAGS:STRING-m32 Regards, Mohit. *Mohit Bhakkad* Pune Institute of Computer Technology *Mobile:* 9422928202 *Email:* mohit.bhakkad at gmail.com *LinkedIn Profile <http://www.linkedin.com/in/mohitbhakkad>Github Profile <https://github.com/Mohit7>* -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150213/e83fb695/attachment.html>
Evgeniy Stepanov
2015-Feb-24 09:33 UTC
[LLVMdev] [Compiler-rt] i386 is not supported in compiler-rt build
Hi, this works for me on Ubuntu 14.04 LTS, but historically we had bugs with i386 multilib support (for example, http://llvm.org/bugs/show_bug.cgi?id=19289). I suggest digging deeper into the failing test and figuring out the exact failing command and output. On Fri, Feb 13, 2015 at 11:24 AM, Mohit Bhakkad <mohit.bhakkad at gmail.com> wrote:> I am trying to build compiler-rt on a x86_64 machine using clang. > > Command used: > CC=clang CXX=clang++ cmake <path to compiler-rt> -DLLVM_CONFIG_PATH=<Path > to llvm toolchain>/bin/llvm-config -DCOMPILER_RT_INSTALL_PATH=<Path to llvm > toolchain>/lib/clang/3.7.0 > > after this command on console it prints, > -- Compiler-RT supported architectures: x86_64 > > Instead if I use gcc in above command, it supports both i386, x86_64 > -- Compiler-RT supported architectures: x86_64;i386 > > I am curious about why its not supporting i386 with clang, as this clang > can compile a simple program for i386. > > Looking into cmake file, it looks like i386 is failing this > <https://github.com/llvm-mirror/compiler-rt/blob/master/cmake/config-ix.cmake#L76> > test. > > I have checked variables for both the target, which looks fine to me: > > -- {CAN_TARGET_x86_64}: TRUE > -- {CMAKE_BINARY_DIR}: /home/mohit/compiler-rt_build > -- {SIMPLE_SOURCE}: /home/mohit/compiler-rt_build/CMakeFiles/simple.cc > -- {TARGET_x86_64_CFLAGS}: -m64 > -- TARGET_{arch}_OUTPUT: TARGET_x86_64_OUTPUT > -- > -DCMAKE_EXE_LINKER_FLAGS:STRING={argstring}:-DCMAKE_EXE_LINKER_FLAGS:STRING> -m64 > > > -- {CAN_TARGET_i386}: FALSE > -- {CMAKE_BINARY_DIR}: /home/mohit/compiler-rt_build > -- {SIMPLE_SOURCE}: /home/mohit/compiler-rt_build/CMakeFiles/simple.cc > -- {TARGET_i386_CFLAGS}: -m32 > -- TARGET_{arch}_OUTPUT: TARGET_i386_OUTPUT > -- > -DCMAKE_EXE_LINKER_FLAGS:STRING={argstring}:-DCMAKE_EXE_LINKER_FLAGS:STRING> -m32 > > Regards, > Mohit. > > > *Mohit Bhakkad* > Pune Institute of Computer Technology *Mobile:* 9422928202 > *Email:* mohit.bhakkad at gmail.com > > *LinkedIn Profile <http://www.linkedin.com/in/mohitbhakkad>Github Profile > <https://github.com/Mohit7>* > > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev > >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150224/a230ce0f/attachment.html>
Mohit Bhakkad
2015-Feb-26 11:02 UTC
[LLVMdev] [Compiler-rt] i386 is not supported in compiler-rt build
Thanks Evgeniy, issue is solved, had to clean some extra/duplicate files for i386. *Mohit Bhakkad* Pune Institute of Computer Technology *Mobile:* 9422928202 *Email:* mohit.bhakkad at gmail.com *LinkedIn Profile <http://www.linkedin.com/in/mohitbhakkad>Github Profile <https://github.com/Mohit7>* On Tue, Feb 24, 2015 at 3:03 PM, Evgeniy Stepanov <eugeni.stepanov at gmail.com> wrote:> Hi, > > this works for me on Ubuntu 14.04 LTS, but historically we had bugs with > i386 multilib support (for example, > http://llvm.org/bugs/show_bug.cgi?id=19289). > I suggest digging deeper into the failing test and figuring out the exact > failing command and output. > > > On Fri, Feb 13, 2015 at 11:24 AM, Mohit Bhakkad <mohit.bhakkad at gmail.com> > wrote: > >> I am trying to build compiler-rt on a x86_64 machine using clang. >> >> Command used: >> CC=clang CXX=clang++ cmake <path to compiler-rt> -DLLVM_CONFIG_PATH=<Path >> to llvm toolchain>/bin/llvm-config -DCOMPILER_RT_INSTALL_PATH=<Path to llvm >> toolchain>/lib/clang/3.7.0 >> >> after this command on console it prints, >> -- Compiler-RT supported architectures: x86_64 >> >> Instead if I use gcc in above command, it supports both i386, x86_64 >> -- Compiler-RT supported architectures: x86_64;i386 >> >> I am curious about why its not supporting i386 with clang, as this clang >> can compile a simple program for i386. >> >> Looking into cmake file, it looks like i386 is failing this >> <https://github.com/llvm-mirror/compiler-rt/blob/master/cmake/config-ix.cmake#L76> >> test. >> >> I have checked variables for both the target, which looks fine to me: >> >> -- {CAN_TARGET_x86_64}: TRUE >> -- {CMAKE_BINARY_DIR}: /home/mohit/compiler-rt_build >> -- {SIMPLE_SOURCE}: /home/mohit/compiler-rt_build/CMakeFiles/simple.cc >> -- {TARGET_x86_64_CFLAGS}: -m64 >> -- TARGET_{arch}_OUTPUT: TARGET_x86_64_OUTPUT >> -- >> -DCMAKE_EXE_LINKER_FLAGS:STRING={argstring}:-DCMAKE_EXE_LINKER_FLAGS:STRING>> -m64 >> >> >> -- {CAN_TARGET_i386}: FALSE >> -- {CMAKE_BINARY_DIR}: /home/mohit/compiler-rt_build >> -- {SIMPLE_SOURCE}: /home/mohit/compiler-rt_build/CMakeFiles/simple.cc >> -- {TARGET_i386_CFLAGS}: -m32 >> -- TARGET_{arch}_OUTPUT: TARGET_i386_OUTPUT >> -- >> -DCMAKE_EXE_LINKER_FLAGS:STRING={argstring}:-DCMAKE_EXE_LINKER_FLAGS:STRING>> -m32 >> >> Regards, >> Mohit. >> >> >> *Mohit Bhakkad* >> Pune Institute of Computer Technology *Mobile:* 9422928202 >> *Email:* mohit.bhakkad at gmail.com >> >> *LinkedIn Profile <http://www.linkedin.com/in/mohitbhakkad>Github Profile >> <https://github.com/Mohit7>* >> >> _______________________________________________ >> LLVM Developers mailing list >> LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu >> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev >> >> >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150226/d137d1f8/attachment.html>