All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dibyendu Majumdar <mobile@majumdar.org.uk>
To: Linux-Sparse <linux-sparse@vger.kernel.org>
Subject: Cast to double being removed
Date: Fri, 17 Mar 2017 00:00:00 +0000	[thread overview]
Message-ID: <CACXZuxdNCM5wWvnYhvt65WaX6hSR_fTnaqd7=pv8O81NWoYQ_w@mail.gmail.com> (raw)

Hi,

In this simple example:

extern int printf(const char *, ...);
int main(void)
{
    printf("%f\n", (double)-1);
    return 0;
}

The linearized output is:

main:
.L0:
        <entry-point>
        symaddr.64  %r1 <- <anon symbol:000001BAAB487258>
        call.32     %r2 <- printf, %r1, $-1
        ret.32      $0

The cast to double has been removed. I am trying to understand where
this is happening as it seems to happen quite early on. Any tips on
where I should look?

Thanks and Regards
Dibyendu

             reply	other threads:[~2017-03-17  0:06 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-17  0:00 Dibyendu Majumdar [this message]
2017-03-17  0:24 ` Cast to double being removed Linus Torvalds
2017-03-17  9:31   ` [PATCH] fix: expansion of integers to floats Luc Van Oostenryck
2017-03-17 10:38   ` Cast to double being removed Dibyendu Majumdar
2017-03-18  1:30     ` Dibyendu Majumdar
2017-03-19 15:22 ` Luc Van Oostenryck
2017-03-19 15:43   ` Dibyendu Majumdar
2017-03-19 15:54     ` Luc Van Oostenryck
2017-03-19 15:59       ` Dibyendu Majumdar

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='CACXZuxdNCM5wWvnYhvt65WaX6hSR_fTnaqd7=pv8O81NWoYQ_w@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.