public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
From: Andreas.Krakowczyk@fujitsu-siemens.com
To: gcc-gnats@gcc.gnu.org
Cc: Erwin.Unruh@fujitsu-siemens.com, Joachim.Canisius@fujitsu-siemens.com
Subject: optimization/3357: wrong optimization with option '-O3'
Date: Fri, 22 Jun 2001 03:06:00 -0000	[thread overview]
Message-ID: <20010622100518.675.qmail@sourceware.cygnus.com> (raw)

>Number:         3357
>Category:       optimization
>Synopsis:       wrong optimization with option '-O3'
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Jun 22 03:06:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator:     Andreas Krakowczyk
>Release:        gcc-3.0
>Organization:
>Environment:
sparc-sun-solaris2.8
>Description:
program gives incorrect result when compiled with option '-O3'
>How-To-Repeat:
gcc -O3 bug6.c && ./a.out
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: application/x-unknown-content-type-c_auto_file; name="bug6.c"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="bug6.c"

Y2hhciAqcDsKaW50IHQgPSAwLCBmYWlsLCBpOwppbnQgcHJpbnQoaW50IGxpbmUpIHsgaWYgKGZh
aWwgIT0gMCkgcHJpbnRmKCJsaW5lICVkOiBmYWlsZWQgYXQ6ICVzXG4iLCBsaW5lLCBwKTsgfQp1
bnNpZ25lZCBzaG9ydCBmKHVuc2lnbmVkIHNob3J0IHgsIHVuc2lnbmVkIHNob3J0IHkpIHsgcmV0
dXJuIHgreTsgfQoKaW50IG1haW4oaW50IGFyZ2MsIGNoYXIgKiphcmd2KQp7CiAgICAgICAgaSA9
IChpbnQpIGYoMjE0NzQ4MzY0NywgMjE0NzQ4MzY0OCk7CiAgICAgICAgcCA9ICJFeHByZXNzaW9u
IDEiOwogICAgICAgIHsgaWYgKHAgPT0gKGNoYXIgKikwIHx8ICpwID09IChjaGFyKTApIHAgPSAi
aSA9PSA2NTUzNSI7IGZhaWwgPSAhKGkgPT0gNjU1MzUpOyBwcmludCgxMik7IHQgKz0gZmFpbDsg
fTsKCiAgICAgICAgaSA9ICh1bnNpZ25lZCBjaGFyKSBmKDMyNzY3LCAzMjc2OCk7CiAgICAgICAg
cCA9ICJFeHByZXNzaW9uIDIiOwogICAgICAgIHsgaWYgKHAgPT0gKGNoYXIgKikwIHx8ICpwID09
IChjaGFyKTApIHAgPSAiaSA9PSAyNTUiOyBmYWlsID0gIShpID09IDI1NSk7IHByaW50KDE2KTsg
dCArPSBmYWlsOyB9OwoKICAgICAgICBpID0gKHVuc2lnbmVkIHNob3J0KSBmKDIxNDc0ODM2NDcs
IDIxNDc0ODM2NDgpOwogICAgICAgIHAgPSAiRXhwcmVzc2lvbiAzIjsKICAgICAgICB7IGlmIChw
ID09IChjaGFyICopMCB8fCAqcCA9PSAoY2hhcikwKSBwID0gImkgPT0gNjU1MzUiOyBmYWlsID0g
IShpID09IDY1NTM1KTsgcHJpbnQoMjApOyB0ICs9IGZhaWw7IH07CgogICAgICAgIGV4aXQodCk7
Cn0K


             reply	other threads:[~2001-06-22  3:06 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-06-22  3:06 Andreas.Krakowczyk [this message]
2002-04-02  2:12 rth

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=20010622100518.675.qmail@sourceware.cygnus.com \
    --to=andreas.krakowczyk@fujitsu-siemens.com \
    --cc=Erwin.Unruh@fujitsu-siemens.com \
    --cc=Joachim.Canisius@fujitsu-siemens.com \
    --cc=gcc-gnats@gcc.gnu.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).