smatch.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: John Levon <levon@movementarian.org>
Cc: smatch@vger.kernel.org, rm@fingolfin.org
Subject: Re: sval_type_max() sadness
Date: Thu, 12 Dec 2019 19:55:20 +0300	[thread overview]
Message-ID: <20191212165520.GC1895@kadam> (raw)
In-Reply-To: <20191211142430.GA17277@movementarian.org>

Thanks for the test case!

Of course, the history here is that the Linux kernel doesn't have floats
so I never added support for it.  I have this friend who is an expert
on floats and people consult him when they are designing chips.  He was
explaining his work to me and I realized that I don't have the foggiest
clue how floats work at all...

Anyway, I've tried to add floats to Smatch.  It turned out not so hard
as I imagined, but I know there are places that I missed.  Probably it
changes from a false positive into a crashing bug now.  :/  The fix is
almost always going to be to run valgrind to see which function crashes
and then add a check:

	if (type_is_fp(estate_type(state)))
		return false;

Do a pull and take a look.  Tell me what you think.  I will hack on this
tomorrow as well.

regards,
can carpenter

      reply	other threads:[~2019-12-12 16:55 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-11 14:24 sval_type_max() sadness John Levon
2019-12-12 16:55 ` Dan Carpenter [this message]

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=20191212165520.GC1895@kadam \
    --to=dan.carpenter@oracle.com \
    --cc=levon@movementarian.org \
    --cc=rm@fingolfin.org \
    --cc=smatch@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).