From: Dibyendu Majumdar <mobile@majumdar.org.uk>
To: Linux-Sparse <linux-sparse@vger.kernel.org>
Subject: Re: sparse-llvm array size computation issue
Date: Tue, 28 Mar 2017 21:41:09 +0100 [thread overview]
Message-ID: <CACXZuxd5cgfdE-cPZ4mkLnzy=MNn5B9EJNAYaazV3VV9o1_QKQ@mail.gmail.com> (raw)
In-Reply-To: <CACXZuxdBRB+mvRJf3VGLK2Po8w9gvSXkjTnt3=UCfoa2Wqm5Ew@mail.gmail.com>
On 28 March 2017 at 21:25, Dibyendu Majumdar <mobile@majumdar.org.uk> wrote:
> I am investigating an issue with following test case:
>
> int main(void)
> {
> const char *names[] = {
> "dibyendu",
> "majumdar",
> NULL,
> };
> return 0;
> }
>
> The issue here is that sparse-llvm thinks the array size is zero:
>
> define i32 @main() {
> L0:
> %names_0000026DE9D2DDA8. = alloca [0 x i8*]
>
> It appears that sparse is correctly calculating the size of the array
> in examine_node_type() in symbol.c, but by the time the symbol gets to
> sparse-llvm the bit_size is somehow changed to -1. I haven't yet
> tracked down where this is happening.
>
Looks like the computed bit_size is being held on the SYM_NODE but
sparse-llvm looks as the bit_size field in the SYM_ARRAY node. Does
this sound like a problem - i.e. somehow the SYM_ARRAY is not getting
its size set?
Regards
Dibyendu
next prev parent reply other threads:[~2017-03-28 20:41 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-28 20:25 sparse-llvm array size computation issue Dibyendu Majumdar
2017-03-28 20:41 ` Dibyendu Majumdar [this message]
2017-03-28 20:49 ` Luc Van Oostenryck
2017-03-28 21:06 ` Dibyendu Majumdar
2017-03-28 21:14 ` Dibyendu Majumdar
2017-03-28 21:33 ` Luc Van Oostenryck
2017-03-28 21:43 ` Dibyendu Majumdar
2017-03-28 22:21 ` Luc Van Oostenryck
2017-03-29 11:32 ` Dibyendu Majumdar
2017-03-29 14:41 ` Dibyendu Majumdar
2017-03-29 15:10 ` Luc Van Oostenryck
2017-03-29 16:21 ` Dibyendu Majumdar
2017-03-29 16:41 ` Linus Torvalds
2017-03-29 18:12 ` Dibyendu Majumdar
2017-03-29 20:24 ` Dibyendu Majumdar
2017-12-28 21:30 ` Luc Van Oostenryck
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CACXZuxd5cgfdE-cPZ4mkLnzy=MNn5B9EJNAYaazV3VV9o1_QKQ@mail.gmail.com' \
--to=mobile@majumdar.org.uk \
--cc=linux-sparse@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.