LLVM Bugzilla is read-only and represents the historical archive of all LLVM issues filled before November 26, 2021. Use github to submit LLVM bugs

Bug 4067 - [Linux kernel] cannot aggregate codegen stmtexpr as lvalue
Summary: [Linux kernel] cannot aggregate codegen stmtexpr as lvalue
Status: RESOLVED FIXED
Alias: None
Product: clang
Classification: Unclassified
Component: -New Bugs (show other bugs)
Version: unspecified
Hardware: PC Linux
: P normal
Assignee: Unassigned Clang Bugs
URL:
Keywords:
Depends on:
Blocks: 4068
  Show dependency tree
 
Reported: 2009-04-25 13:58 PDT by Jeff Garzik
Modified: 2010-02-22 12:42 PST (History)
1 user (show)

See Also:
Fixed By Commit(s):


Attachments
pre-processed source code (90.74 KB, application/x-bzip)
2009-04-25 13:58 PDT, Jeff Garzik
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jeff Garzik 2009-04-25 13:58:09 PDT
Created attachment 2879 [details]
pre-processed source code

Building the Linux kernel yields the following error, on code that works with gcc:

clang -std=gnu89 -MD -MF fs/jbd/.transaction.o.d  -nostdinc -isystem include -Iinclude  -I/spare/tmp/linux-2.6.29/arch/x86/include -include include/linux/autoconf.h -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -O2 -m64 -march=core2 -mno-red-zone -mcmodel=kernel -funit-at-a-time -maccumulate-outgoing-args -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -Iarch/x86/include/asm/mach-default -Wframe-larger-than=2048 -fno-stack-protector -fno-omit-frame-pointer -fno-optimize-sibling-calls -pg -Wdeclaration-after-statement -Wno-pointer-sign -fwrapv -fno-dwarf2-cfi-asm -DMODULE -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(transaction)"  -D"KBUILD_MODNAME=KBUILD_STR(jbd)"  -c -o fs/jbd/transaction.o fs/jbd/transaction.c
clang: warning: the clang compiler does not yet support '-pg'
warning: unknown warning option: -Wframe-larger-than=2048
fs/jbd/transaction.c:1429:16: error: cannot compile this l-value expression yet
                trans_time = ktime_to_ns(ktime_sub(ktime_get(),
                             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
fs/jbd/transaction.c:1429:28: note: instantiated from:
                trans_time = ktime_to_ns(ktime_sub(ktime_get(),
                                         ^~~~~~~~~
1 diagnostic generated.