aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/validation/backend
diff options
authorPekka Enberg <penberg@kernel.org>2012-06-08 14:58:02 +0300
committerPekka Enberg <penberg@kernel.org>2012-06-08 23:31:40 +0300
commit9084e55561e9aa11d291c1a9acaf1a7584651b73 (patch)
tree5e7ecd7ab225fe582acc9582d7419c7db5e6e96c /validation/backend
parentee2ca87d9bd18850518c8bca95d61df6010d9351 (diff)
downloadsparse-dev-9084e55561e9aa11d291c1a9acaf1a7584651b73.tar.gz
sparse, llvm: Fix string initializer code generation
This fixes code generation for string initializer such as: static char *foo = "Foo !\n"; It's the same fix Ben proposed earlier with the small difference that we now use LLVMTypeOf() instead of symbol_type() to resolve the type. The generated LLVM IR looks as follows: [penberg@tux sparse]$ ./sparse-llvm foo.c |llvm-dis ; ModuleID = '<stdin>' @"<noident>" = private global [7 x i8] c"Foo !\0A\00" @foo = private global [7 x i8]* @"<noident>" Reported-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Christopher Li <sparse@chrisli.org> Acked-by: Jeff Garzik <jgarzik@redhat.com> Signed-off-by: Pekka Enberg <penberg@kernel.org>
Diffstat (limited to 'validation/backend')
0 files changed, 0 insertions, 0 deletions