[llvmlinux] Website: Manual_Build_Instructions

Daniel Sanders Daniel.Sanders at imgtec.com
Wed Mar 4 12:07:28 UTC 2015


> -----Original Message-----
> From: Sedat Dilek [mailto:sedat.dilek at gmail.com]
> Sent: 03 March 2015 06:50
> To: Daniel Sanders
> Cc: llvmlinux
> Subject: Re: [llvmlinux] Website: Manual_Build_Instructions
> 
> On Mon, Mar 2, 2015 at 10:59 AM, Daniel Sanders
> <Daniel.Sanders at imgtec.com> wrote:
> > Hi,
> >
> > I'm not 100% certain but I don't think the manual build instructions are
> intended to be a reflection of what the Makefiles do. They're just
> instructions that will get you a bootable kernel.
> >
> > Either way, the only difference between --enable-assertions and --disable-
> assertions is how debug-able the compiler is. It has no effect on the resulting
> kernel.
> >
> 
> Not sure if I understood you correct.
> 
> Which Makefile are you speaking of?
> llvmlinux, llvm, clang, linux, etc.?

I was referring to llvmlinux's makefiles that invoke run the configure commands for clang.

> I rely on what the experts recommend on the clang website [1].
> Why should llvmlinux go a different way?
> Not clear to me.

That link doesn't mention --enable-assertions, --disable-assertions. I should also mention that the configuration command isn't a recommendation. It's an example and users may need to adjust the command to suit their needs.

The question can equally be 'Why should they be the same?'. In this case, the chances of pushing up against bugs and corner cases is relatively high and the extra checking provided by --enable-assertions is useful. This is less true for targets like ARM and X86 who have been working on llvmlinux for a while but it's especially true for the targets that have joined llvmlinux more recently.

> In the early days before there was "llvmlinux" project I encouraged
> that team to provide one toolchain to users/customers.
> So, if interested party is building his/her toolchain we might have a
> problem outside of llvmlinux in the toolchain area.
> Normally, I like to play with upstream, but in the case of llvmlinux I
> would like to see "stable" toolchain releases against stable releases
> of toolchain and LTS Linux-kernels.
> 
> BTW, LLVM project is offering prebuilt-binaries for modern (Linux) OS
> on the download-page.
> Ubuntu/precise (12.04) is no more supported, but Ubuntu/trusty (14.04) [2].
> Both are Ubuntu LTS releases with 5 years support.

Indeed. I'm the person building and testing the Mips and Mipsel pre-built binary packages in those releases.

> Do you happen to know if LLVM/Clang has all bits to build a Linux-kernel
> now?
> This is more interesting to me.
> ( If this is the case, people can now focus on the Linux "clang" patches. )

In addition to Behan's answer, I'd also add that it depends on your target. AArch64, ARM, Mips, and X86 are generally in a good state but other targets may have issues.

> - Sedat -
> 
> [1] http://clang.llvm.org/get_started.html
> [2] http://llvm.org/releases/3.6.0/clang+llvm-3.6.0-x86_64-linux-gnu-
> ubuntu-14.04.tar.xz
> 
> >> -----Original Message-----
> >> From: llvmlinux-bounces at lists.linuxfoundation.org [mailto:llvmlinux-
> >> bounces at lists.linuxfoundation.org] On Behalf Of Sedat Dilek
> >> Sent: 27 February 2015 09:29
> >> To: llvmlinux
> >> Subject: Re: [llvmlinux] Website: Manual_Build_Instructions
> >>
> >> Ping!?
> >>
> >> - Sedat -
> >>
> >> On Wed, Feb 4, 2015 at 12:54 AM, Sedat Dilek <sedat.dilek at gmail.com>
> >> wrote:
> >> > Hi,
> >> >
> >> > I am planning to build a llvm-toolchain v3.6.0-rc2 on my own.
> >> >
> >> > Gasping at [1] shows a wrong configure-parameter...
> >> > ...
> >> > ./configure --prefix=$(echo ~/llvm4linux)/out/llvm --enable-optimized
> >> > --disable-assertions --targets=x86,x86_64,arm
> >> > ...
> >> >
> >> > Looking at the source of llvmlinux-git says...
> >> >
> >> > $ grep able-assertions -nr ./
> >> > ./toolchain/clang/clang-from-source.mk:99:LLVM_OPTIMIZED        =
> >> > --enable-optimized --enable-assertions
> >> > ./targets/x86_64/checkpoints/v3.14/config.mk:7:LLVM_OPTIMIZED
> >> >  = --enable-optimized --enable-assertions
> >> > ./targets/x86_64/checkpoints/kernel-3.10-
> >> rc7/config.mk:7:LLVM_OPTIMIZED
> >> >         = --enable-optimized --enable-assertions
> >> > ./targets/x86_64/checkpoints/kernel-3.13-
> >> rc4/config.mk:7:LLVM_OPTIMIZED
> >> >         = --enable-optimized --enable-assertions
> >> > ./targets/x86_64/checkpoints/v3.3/config.mk:7:LLVM_OPTIMIZED
> >> >  = --enable-optimized --enable-assertions
> >> > ./targets/nexus7/checkpoint/ckp1.mk:7:LLVM_OPTIMIZED            =
> >> > --enable-optimized --enable-assertions
> >> > ./targets/nexus7/checkpoint/ckp3.mk:8:LLVM_OPTIMIZED            =
> >> > --enable-optimized --enable-assertions
> >> > ./targets/nexus7/checkpoint/ckp2.mk:7:LLVM_OPTIMIZED            =
> >> > --enable-optimized --enable-assertions
> >> > ./targets/rpi/checkpoint/ckp1.mk:7:LLVM_OPTIMIZED               =
> >> > --enable-optimized --enable-assertions
> >> > ./targets/rpi/checkpoint/ckp3.mk:11:LLVM_OPTIMIZED              =
> >> > --enable-optimized --enable-assertions
> >> > ./targets/rpi/checkpoint/ckp4.mk:11:LLVM_OPTIMIZED              =
> >> > --enable-optimized --enable-assertions
> >> > ./targets/rpi/checkpoint/ckp2.mk:8:LLVM_OPTIMIZED               =
> >> > --enable-optimized --enable-assertions
> >> > ./targets/x86_64_tiny/checkpoints/llvm3.3-
> >> linux040a0a3/config.mk:7:LLVM_OPTIMIZED
> >> >               = --enable-optimized --enable-assertions
> >> >
> >> > So, this should be changed from "--disable-assertions" to
> >> > "--enable-assertions" on the website.
> >> >
> >> > Regards,
> >> > - Sedat -
> >> >
> >> > [1]
> http://llvm.linuxfoundation.org/index.php/Manual_Build_Instructions
> >> > -> "Checkout LLVM and clang"
> >> _______________________________________________
> >> LLVMLinux mailing list
> >> LLVMLinux at lists.linuxfoundation.org
> >> https://lists.linuxfoundation.org/mailman/listinfo/llvmlinux


More information about the LLVMLinux mailing list