public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/11303] ICE in stor-layout.c:304 in int_mode_for_mode
  2003-06-24  5:41 [Bug target/11303] New: ICE in stor-layout.c:304 in int_mode_for_mode pinskia at physics dot uc dot edu
@ 2003-06-24  5:41 ` pinskia at physics dot uc dot edu
  2003-06-24  6:07 ` pinskia at physics dot uc dot edu
  2003-07-05 20:11 ` [Bug target/11303] [3.3/3.4 regression] " dhazeghi at yahoo dot com
  2 siblings, 0 replies; 8+ messages in thread
From: pinskia at physics dot uc dot edu @ 2003-06-24  5:41 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11303


pinskia at physics dot uc dot edu changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
OtherBugsDependingO|11026                       |
              nThis|                            |


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

* [Bug target/11303] New: ICE in stor-layout.c:304 in int_mode_for_mode
@ 2003-06-24  5:41 pinskia at physics dot uc dot edu
  2003-06-24  5:41 ` [Bug target/11303] " pinskia at physics dot uc dot edu
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: pinskia at physics dot uc dot edu @ 2003-06-24  5:41 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11303

           Summary: ICE in stor-layout.c:304 in int_mode_for_mode
           Product: gcc
           Version: 3.4
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P2
         Component: target
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: pinskia at physics dot uc dot edu
                CC: gcc-bugs at gcc dot gnu dot org
GCC target triplet: powerpc-apple-darwin6.6
OtherBugsDependingO 11026
             nThis:

A fall out from 11026:
Here is the shortest test case I could come up with that causes this ICE (fixing 
s_callbacks by adding & fixes the ICE:
template <class T>
struct test
{
  int run(int);

  typedef int (test<T>::*callback_type)(int);

  int c1(int);
  int c2(int);

  static callback_type s_callbacks[];
};

template <class T>
int test<T>::run(int i)
{
  callback_type c = s_callbacks[i];
  return (this->*c)(i);
}

template <class T>
typename test<T>::callback_type test<T>::s_callbacks[] =
{
  test<T>::c1,
  test<T>::c2,
};


int main()
{
  test<int> i;
  i.run(0);
  return 0;
}


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

* [Bug target/11303] ICE in stor-layout.c:304 in int_mode_for_mode
  2003-06-24  5:41 [Bug target/11303] New: ICE in stor-layout.c:304 in int_mode_for_mode pinskia at physics dot uc dot edu
  2003-06-24  5:41 ` [Bug target/11303] " pinskia at physics dot uc dot edu
@ 2003-06-24  6:07 ` pinskia at physics dot uc dot edu
  2003-07-05 20:11 ` [Bug target/11303] [3.3/3.4 regression] " dhazeghi at yahoo dot com
  2 siblings, 0 replies; 8+ messages in thread
From: pinskia at physics dot uc dot edu @ 2003-06-24  6:07 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11303


pinskia at physics dot uc dot edu changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
OtherBugsDependingO|                            |11026
              nThis|                            |


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

* [Bug target/11303] [3.3/3.4 regression] ICE in stor-layout.c:304 in int_mode_for_mode
  2003-06-24  5:41 [Bug target/11303] New: ICE in stor-layout.c:304 in int_mode_for_mode pinskia at physics dot uc dot edu
  2003-06-24  5:41 ` [Bug target/11303] " pinskia at physics dot uc dot edu
  2003-06-24  6:07 ` pinskia at physics dot uc dot edu
@ 2003-07-05 20:11 ` dhazeghi at yahoo dot com
  2 siblings, 0 replies; 8+ messages in thread
From: dhazeghi at yahoo dot com @ 2003-07-05 20:11 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11303


dhazeghi at yahoo dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|                            |1
   Last reconfirmed|0000-00-00 00:00:00         |2003-07-05 20:11:50
               date|                            |
            Summary|ICE in stor-layout.c:304 in |[3.3/3.4 regression] ICE in
                   |int_mode_for_mode           |stor-layout.c:304 in
                   |                            |int_mode_for_mode


------- Additional Comments From dhazeghi at yahoo dot com  2003-07-05 20:11 -------
Question: is this code valid? On i686-linux (mainline and branch), I get:
 int test<T>::run(int) int main() int test<T>::run(int) [with T = int]
foo.cc: At global scope:
foo.cc: In instantiation of `int (test<int>::*test<int>::s_callbacks[2])(int)':
foo.cc:17:   instantiated from `int test<T>::run(int) [with T = int]'
foo.cc:32:   instantiated from here
foo.cc:22: error: invalid use of non-static member function

gcc 3.2.3 and earlier (on powerpc-darwin and i686-linux) give:
foo.cc: In instantiation of `int (test<int>::*test<int>::s_callbacks[])(int)':
foo.cc:17:   instantiated from `int test<T>::run(int) [with T = int]'
foo.cc:32:   instantiated from here
foo.cc:22: assuming pointer to member `int test<T>::c1(int) [with T = int]'
foo.cc:22: (a pointer to member can only be formed with `&test<T>::c1(int) 
   [with T = int]')

I can confirm the ICE with mainline and branch on powerpc-darwin (20030705).


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

* [Bug target/11303] [3.3/3.4 regression] ICE in stor-layout.c:304 in int_mode_for_mode
       [not found] <20030624053547.11303.pinskia@gcc.gnu.org>
                   ` (2 preceding siblings ...)
  2003-12-05  2:33 ` bangerth at dealii dot org
@ 2003-12-05 16:59 ` gdr at integrable-solutions dot net
  3 siblings, 0 replies; 8+ messages in thread
From: gdr at integrable-solutions dot net @ 2003-12-05 16:59 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From gdr at integrable-solutions dot net  2003-12-05 16:59 -------
Subject: Re:  [3.3/3.4 regression] ICE in stor-layout.c:304 in int_mode_for_mode

"bangerth at dealii dot org" <gcc-bugzilla@gcc.gnu.org> writes:

| Has this been fixed? I don't get any ICE with my mainline snapshot from 
| 2003-12-02. Do I have to give some special flags? The only thing I get is 
|  
| g/x> /home/bangerth/bin/gcc-3.4-pre/bin/c++ x.cc 
| x.cc: In instantiation of `int (test<int>::*test<int>::s_callbacks[2])(int)': 
| x.cc:13:   instantiated from `int test<T>::run(int) [with T = int]' 
| x.cc:26:   instantiated from here 
| x.cc:18: error: argument of type `int (test<int>::)(int)' does not match `int 
| (test<int>::*)(int)' 
|  
| and from the branch: 
| g/x> /home/bangerth/bin/gcc-3.3.3-pre/bin/c++ x.cc 
| x.cc: In instantiation of `int (test<int>::*test<int>::s_callbacks[2])(int)': 
| x.cc:13:   instantiated from `int test<T>::run(int) [with T = int]' 
| x.cc:26:   instantiated from here 
| x.cc:18: error: assuming pointer to member `int test<T>::c1(int) [with T = 
| int] 
|    ' 
| x.cc:18: error: (a pointer to member can only be formed with `&test<T>::c1  
|    [with T = int]') 

The pretty-printing we have in 3.4 is better, but the hint we have in
3.3.x is lost. That worries me.

-- Gaby


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11303


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

* [Bug target/11303] [3.3/3.4 regression] ICE in stor-layout.c:304 in int_mode_for_mode
       [not found] <20030624053547.11303.pinskia@gcc.gnu.org>
  2003-12-05  2:17 ` pinskia at gcc dot gnu dot org
  2003-12-05  2:32 ` bangerth at dealii dot org
@ 2003-12-05  2:33 ` bangerth at dealii dot org
  2003-12-05 16:59 ` gdr at integrable-solutions dot net
  3 siblings, 0 replies; 8+ messages in thread
From: bangerth at dealii dot org @ 2003-12-05  2:33 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From bangerth at dealii dot org  2003-12-05 02:33 -------
Oh, never mind: I was testing on x86-linux, but I now see that this 
is a target-bug. Sorry... 
  W. 

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11303


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

* [Bug target/11303] [3.3/3.4 regression] ICE in stor-layout.c:304 in int_mode_for_mode
       [not found] <20030624053547.11303.pinskia@gcc.gnu.org>
  2003-12-05  2:17 ` pinskia at gcc dot gnu dot org
@ 2003-12-05  2:32 ` bangerth at dealii dot org
  2003-12-05  2:33 ` bangerth at dealii dot org
  2003-12-05 16:59 ` gdr at integrable-solutions dot net
  3 siblings, 0 replies; 8+ messages in thread
From: bangerth at dealii dot org @ 2003-12-05  2:32 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From bangerth at dealii dot org  2003-12-05 02:32 -------
Has this been fixed? I don't get any ICE with my mainline snapshot from 
2003-12-02. Do I have to give some special flags? The only thing I get is 
 
g/x> /home/bangerth/bin/gcc-3.4-pre/bin/c++ x.cc 
x.cc: In instantiation of `int (test<int>::*test<int>::s_callbacks[2])(int)': 
x.cc:13:   instantiated from `int test<T>::run(int) [with T = int]' 
x.cc:26:   instantiated from here 
x.cc:18: error: argument of type `int (test<int>::)(int)' does not match `int 
(test<int>::*)(int)' 
 
and from the branch: 
g/x> /home/bangerth/bin/gcc-3.3.3-pre/bin/c++ x.cc 
x.cc: In instantiation of `int (test<int>::*test<int>::s_callbacks[2])(int)': 
x.cc:13:   instantiated from `int test<T>::run(int) [with T = int]' 
x.cc:26:   instantiated from here 
x.cc:18: error: assuming pointer to member `int test<T>::c1(int) [with T = 
int] 
   ' 
x.cc:18: error: (a pointer to member can only be formed with `&test<T>::c1  
   [with T = int]') 
 
W. 

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11303


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

* [Bug target/11303] [3.3/3.4 regression] ICE in stor-layout.c:304 in int_mode_for_mode
       [not found] <20030624053547.11303.pinskia@gcc.gnu.org>
@ 2003-12-05  2:17 ` pinskia at gcc dot gnu dot org
  2003-12-05  2:32 ` bangerth at dealii dot org
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-12-05  2:17 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2003-12-05 02:17 -------
The code is invalid.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|ice-on-valid-code           |ice-on-invalid-code
   Last reconfirmed|2003-11-03 04:13:36         |2003-12-05 02:17:38
               date|                            |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11303


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

end of thread, other threads:[~2003-12-05 16:59 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-06-24  5:41 [Bug target/11303] New: ICE in stor-layout.c:304 in int_mode_for_mode pinskia at physics dot uc dot edu
2003-06-24  5:41 ` [Bug target/11303] " pinskia at physics dot uc dot edu
2003-06-24  6:07 ` pinskia at physics dot uc dot edu
2003-07-05 20:11 ` [Bug target/11303] [3.3/3.4 regression] " dhazeghi at yahoo dot com
     [not found] <20030624053547.11303.pinskia@gcc.gnu.org>
2003-12-05  2:17 ` pinskia at gcc dot gnu dot org
2003-12-05  2:32 ` bangerth at dealii dot org
2003-12-05  2:33 ` bangerth at dealii dot org
2003-12-05 16:59 ` gdr at integrable-solutions dot net

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