public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/63747] New: [5 regression] icf mis-compares switch gimple
@ 2014-11-05  9:46 joey.ye at arm dot com
  2014-11-05 11:28 ` [Bug tree-optimization/63747] " thopre01 at gcc dot gnu.org
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: joey.ye at arm dot com @ 2014-11-05  9:46 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63747

            Bug ID: 63747
           Summary: [5 regression] icf mis-compares switch gimple
           Product: gcc
           Version: 5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: joey.ye at arm dot com

ARM -Os bootstrap breaks. Root cause lies in ipa-icf-gimple.c where
compare_gimple_switch doesn't compare case numbers correctly. Will upload a
reduced test case soon.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug tree-optimization/63747] [5 regression] icf mis-compares switch gimple
  2014-11-05  9:46 [Bug tree-optimization/63747] New: [5 regression] icf mis-compares switch gimple joey.ye at arm dot com
@ 2014-11-05 11:28 ` thopre01 at gcc dot gnu.org
  2014-11-06  2:26 ` joey.ye at arm dot com
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: thopre01 at gcc dot gnu.org @ 2014-11-05 11:28 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63747

thopre01 at gcc dot gnu.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |thopre01 at gcc dot gnu.org

--- Comment #1 from thopre01 at gcc dot gnu.org ---
The description of the problem you make seems to point to commit r216913.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug tree-optimization/63747] [5 regression] icf mis-compares switch gimple
  2014-11-05  9:46 [Bug tree-optimization/63747] New: [5 regression] icf mis-compares switch gimple joey.ye at arm dot com
  2014-11-05 11:28 ` [Bug tree-optimization/63747] " thopre01 at gcc dot gnu.org
@ 2014-11-06  2:26 ` joey.ye at arm dot com
  2014-11-06  2:28 ` joey.ye at arm dot com
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: joey.ye at arm dot com @ 2014-11-06  2:26 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63747

--- Comment #2 from Joey Ye <joey.ye at arm dot com> ---
/* { dg-options "-O2" } */
/* { dg-do run } */

static int __attribute__((noinline))
foo(int i)
{
  switch (i)
  {
    case 0:
    case 1:
    case 2:
    case 3:
      return 0;
    default:
      return 1;
  }
}

static int __attribute__((noinline))
bar(int i)
{
  switch (i)
  {
    case 4:
    case 5:
    case 6:
    case 7:
      return 0;
    default:
      return 1;
  }
}

int main()
{
  return foo(0) + bar(4);
}


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug tree-optimization/63747] [5 regression] icf mis-compares switch gimple
  2014-11-05  9:46 [Bug tree-optimization/63747] New: [5 regression] icf mis-compares switch gimple joey.ye at arm dot com
  2014-11-05 11:28 ` [Bug tree-optimization/63747] " thopre01 at gcc dot gnu.org
  2014-11-06  2:26 ` joey.ye at arm dot com
@ 2014-11-06  2:28 ` joey.ye at arm dot com
  2014-11-06  2:33 ` joey.ye at arm dot com
  2014-11-06  3:14 ` pinskia at gcc dot gnu.org
  4 siblings, 0 replies; 6+ messages in thread
From: joey.ye at arm dot com @ 2014-11-06  2:28 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63747

--- Comment #3 from Joey Ye <joey.ye at arm dot com> ---
Created attachment 33906
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=33906&action=edit
/home/joeye01/patches/icf-switch-testcase-141105.patch

Test case patch


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug tree-optimization/63747] [5 regression] icf mis-compares switch gimple
  2014-11-05  9:46 [Bug tree-optimization/63747] New: [5 regression] icf mis-compares switch gimple joey.ye at arm dot com
                   ` (2 preceding siblings ...)
  2014-11-06  2:28 ` joey.ye at arm dot com
@ 2014-11-06  2:33 ` joey.ye at arm dot com
  2014-11-06  3:14 ` pinskia at gcc dot gnu.org
  4 siblings, 0 replies; 6+ messages in thread
From: joey.ye at arm dot com @ 2014-11-06  2:33 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63747

--- Comment #4 from Joey Ye <joey.ye at arm dot com> ---
It actually fails on all targets.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug tree-optimization/63747] [5 regression] icf mis-compares switch gimple
  2014-11-05  9:46 [Bug tree-optimization/63747] New: [5 regression] icf mis-compares switch gimple joey.ye at arm dot com
                   ` (3 preceding siblings ...)
  2014-11-06  2:33 ` joey.ye at arm dot com
@ 2014-11-06  3:14 ` pinskia at gcc dot gnu.org
  4 siblings, 0 replies; 6+ messages in thread
From: pinskia at gcc dot gnu.org @ 2014-11-06  3:14 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63747

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |build, wrong-code
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2014-11-06
     Ever confirmed|0                           |1

--- Comment #5 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Confirmed.


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2014-11-06  3:14 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-11-05  9:46 [Bug tree-optimization/63747] New: [5 regression] icf mis-compares switch gimple joey.ye at arm dot com
2014-11-05 11:28 ` [Bug tree-optimization/63747] " thopre01 at gcc dot gnu.org
2014-11-06  2:26 ` joey.ye at arm dot com
2014-11-06  2:28 ` joey.ye at arm dot com
2014-11-06  2:33 ` joey.ye at arm dot com
2014-11-06  3:14 ` pinskia at gcc dot gnu.org

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).