qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paulo Cezar <pcacjr@gmail.com>
To: Bug 696834 <696834@bugs.launchpad.net>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [Bug 696834] [NEW] FP exception reporting not working on NetBSD host
Date: Mon, 3 Jan 2011 12:27:58 -0300	[thread overview]
Message-ID: <AANLkTi=MJDNfCPPgsVV9Mus3Af8ffXCmYLv997=26z0U@mail.gmail.com> (raw)
In-Reply-To: <20110103151427.20128.15402.malonedeb@soybean.canonical.com>

[-- Attachment #1: Type: text/plain, Size: 2621 bytes --]

On Mon, Jan 3, 2011 at 12:14 PM, Paul Goyette <696834@bugs.launchpad.net>wrote:

> Public bug reported:
>
> I recognize that NetBSD is not one of the officially supported host OS.
> However, qemu 0.13.0 is available in the NetBSD pkgsrc collection, and
> works quite well.  Well, with one exception (pun intended): It seems
> that Floating Point exceptions don't get reported properly.
>
> The following code-snippet demonstrates the problem:
>
>
> volatile int flt_signal = 0;
>
> static sigjmp_buf sigfpe_flt_env;
> static void
> sigfpe_flt_action(int signo, siginfo_t *info, void *ptr)
> {
>        flt_signal++;
> }
>
> void trigger(void)
> {
>        struct sigaction sa;
>        double d = strtod("0", NULL);
>
>        if (sigsetjmp(sigfpe_flt_env, 0) == 0) {
>                sa.sa_flags = SA_SIGINFO;
>                sa.sa_sigaction = sigfpe_flt_action;
>                sigemptyset(&sa.sa_mask);
>                sigaction(SIGFPE, &sa, NULL);
>                fpsetmask(FP_X_INV|FP_X_DZ|FP_X_OFL|FP_X_UFL|FP_X_IMP);
>                printf("%g\n", 1 / d);
>        }
>        printf("FPE signal handler invoked %d times.\n");
>

this printf() does miss an argument :-)


> }
>
> ** Affects: qemu
>     Importance: Undecided
>         Status: New
>
> --
> You received this bug notification because you are a member of qemu-
> devel-ml, which is subscribed to QEMU.
> https://bugs.launchpad.net/bugs/696834
>
> Title:
>  FP exception reporting not working on NetBSD host
>
> Status in QEMU:
>  New
>
> Bug description:
>  I recognize that NetBSD is not one of the officially supported host OS.
>  However, qemu 0.13.0 is available in the NetBSD pkgsrc collection, and
> works quite well.  Well, with one exception (pun intended): It seems that
> Floating Point exceptions don't get reported properly.
>
> The following code-snippet demonstrates the problem:
>
>
> volatile int flt_signal = 0;
>
> static sigjmp_buf sigfpe_flt_env;
> static void
> sigfpe_flt_action(int signo, siginfo_t *info, void *ptr)
> {
>        flt_signal++;
> }
>
> void trigger(void)
> {
>        struct sigaction sa;
>        double d = strtod("0", NULL);
>
>        if (sigsetjmp(sigfpe_flt_env, 0) == 0) {
>                sa.sa_flags = SA_SIGINFO;
>                sa.sa_sigaction = sigfpe_flt_action;
>                sigemptyset(&sa.sa_mask);
>                sigaction(SIGFPE, &sa, NULL);
>                fpsetmask(FP_X_INV|FP_X_DZ|FP_X_OFL|FP_X_UFL|FP_X_IMP);
>                printf("%g\n", 1 / d);
>        }
>        printf("FPE signal handler invoked %d times.\n");
>

this printf() does miss an argument :-)


> }
>
>
>
>

[-- Attachment #2: Type: text/html, Size: 3601 bytes --]

  reply	other threads:[~2011-01-03 15:28 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-03 15:14 [Qemu-devel] [Bug 696834] [NEW] FP exception reporting not working on NetBSD host Paul Goyette
2011-01-03 15:27 ` Paulo Cezar [this message]
2011-01-03 15:45   ` Paul Goyette
2011-01-03 16:03     ` Paul Goyette
2011-05-23 12:27 ` [Qemu-devel] [Bug 696834] Invitation to connect on LinkedIn Paulo Cezar A Junior
2017-01-10  9:14 ` [Qemu-devel] [Bug 696834] Re: FP exception reporting not working on NetBSD host Thomas Huth
2017-01-10 23:30   ` Paul Goyette
2017-01-11  6:50 ` Thomas Huth

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='AANLkTi=MJDNfCPPgsVV9Mus3Af8ffXCmYLv997=26z0U@mail.gmail.com' \
    --to=pcacjr@gmail.com \
    --cc=696834@bugs.launchpad.net \
    --cc=qemu-devel@nongnu.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 NNTP newsgroup(s).