[llvmlinux] cannot compile kernel module by Clang
Jan-Simon Möller
dl9pf at gmx.de
Sat May 4 09:54:06 UTC 2013
On Saturday 04 May 2013 13:12:31 Jovi Zhang wrote:
> Hi,
>
> I'm trying to compile kernel module by Clang, note that
> the kernel is compiled by GCC.
> (I know that there have some problem to compile kernel without any patches,
> that's why I only want to compile kernel module here, not kernel)
>
> As we known, Clang/llvm doesn't support global register variable at present,
> when the kernel module C file include <linux/module.h>, it report that
> error,
>
> arch/x86/include/asm/thread_info.h:
>
> register unsigned long current_stack_pointer asm("esp") __used;
>
> so is there have any workaround to handle this problem? I just want to
> compile kernel module only by Clang. Thanks.
Look in our patchset. There's a workaround there.
git.linuxfoundation.org -> llvmlinux
> _______________________________________________
> LLVMLinux mailing list
> LLVMLinux at lists.linuxfoundation.org
> https://lists.linuxfoundation.org/mailman/listinfo/llvmlinux
--
Dipl.-Ing.
Jan-Simon Möller
jansimon.moeller at gmx.de
More information about the LLVMLinux
mailing list