public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/18160] New: ICE on taking register variable address
@ 2004-10-26 13:17 alex dot neyman at auriga dot ru
  2004-10-26 13:20 ` [Bug c/18160] " alex dot neyman at auriga dot ru
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: alex dot neyman at auriga dot ru @ 2004-10-26 13:17 UTC (permalink / raw)
  To: gcc-bugs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1283 bytes --]

I know this is invalid, but: 
- it produces a warning, not an error; 
- reliable compilers never crash, do they? 
 
Testcase: 
-------------------------- 
void f(void) 
{ 
        register int x asm("eax"); 
        g(&x); 
} 
-------------------------- 
objdir/gcc/xgcc -Bobjdir/gcc -c f.c 
f.c: In function ‘f’: 
f.c:5: warning: address of register variable ‘x’ requested 
f.c:5: warning: address of register variable ‘x’ requested 
f.c:5: internal compiler error: in expand_expr_addr_expr_1, at expr.c:5975 
Please submit a full bug report, 
with preprocessed source if appropriate. 
See <URL:http://gcc.gnu.org/bugs.html> for instructions. 
 
Sources checked out as of today morning (about 6 hours ago).

-- 
           Summary: ICE on taking register variable address
           Product: gcc
           Version: 4.0.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: alex dot neyman at auriga dot ru
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu


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


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

* [Bug c/18160] ICE on taking register variable address
  2004-10-26 13:17 [Bug c/18160] New: ICE on taking register variable address alex dot neyman at auriga dot ru
@ 2004-10-26 13:20 ` alex dot neyman at auriga dot ru
  2004-10-26 13:22 ` [Bug middle-end/18160] [4.0 Regression] " pinskia at gcc dot gnu dot org
                   ` (7 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: alex dot neyman at auriga dot ru @ 2004-10-26 13:20 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From alex dot neyman at auriga dot ru  2004-10-26 13:20 -------
Sorry, an empty line disappeared when I cut&pasted the code. f.c:5 is actually 
the line "g(&x);". 

-- 


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


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

* [Bug middle-end/18160] [4.0 Regression] ICE on taking register variable address
  2004-10-26 13:17 [Bug c/18160] New: ICE on taking register variable address alex dot neyman at auriga dot ru
  2004-10-26 13:20 ` [Bug c/18160] " alex dot neyman at auriga dot ru
@ 2004-10-26 13:22 ` pinskia at gcc dot gnu dot org
  2004-10-26 21:24 ` nemet at gcc dot gnu dot org
                   ` (6 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-10-26 13:22 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-10-26 13:22 -------
Confirmed, a regression.
: Search converges between 2004-08-30-trunk (#529) and 2004-08-31-trunk (#530).

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
          Component|c                           |middle-end
     Ever Confirmed|                            |1
           Keywords|                            |ice-on-valid-code
   Last reconfirmed|0000-00-00 00:00:00         |2004-10-26 13:22:11
               date|                            |
            Summary|ICE on taking register      |[4.0 Regression] ICE on
                   |variable address            |taking register variable
                   |                            |address
   Target Milestone|---                         |4.0.0


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


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

* [Bug middle-end/18160] [4.0 Regression] ICE on taking register variable address
  2004-10-26 13:17 [Bug c/18160] New: ICE on taking register variable address alex dot neyman at auriga dot ru
  2004-10-26 13:20 ` [Bug c/18160] " alex dot neyman at auriga dot ru
  2004-10-26 13:22 ` [Bug middle-end/18160] [4.0 Regression] " pinskia at gcc dot gnu dot org
@ 2004-10-26 21:24 ` nemet at gcc dot gnu dot org
  2004-10-28 15:16 ` steven at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: nemet at gcc dot gnu dot org @ 2004-10-26 21:24 UTC (permalink / raw)
  To: gcc-bugs



-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |nemet at gcc dot gnu dot org
                   |dot org                     |
             Status|NEW                         |ASSIGNED


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


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

* [Bug middle-end/18160] [4.0 Regression] ICE on taking register variable address
  2004-10-26 13:17 [Bug c/18160] New: ICE on taking register variable address alex dot neyman at auriga dot ru
                   ` (2 preceding siblings ...)
  2004-10-26 21:24 ` nemet at gcc dot gnu dot org
@ 2004-10-28 15:16 ` steven at gcc dot gnu dot org
  2004-10-28 19:30 ` cvs-commit at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: steven at gcc dot gnu dot org @ 2004-10-28 15:16 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From steven at gcc dot gnu dot org  2004-10-28 15:16 -------
http://gcc.gnu.org/ml/gcc-patches/2004-10/msg02437.html 

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |patch


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


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

* [Bug middle-end/18160] [4.0 Regression] ICE on taking register variable address
  2004-10-26 13:17 [Bug c/18160] New: ICE on taking register variable address alex dot neyman at auriga dot ru
                   ` (3 preceding siblings ...)
  2004-10-28 15:16 ` steven at gcc dot gnu dot org
@ 2004-10-28 19:30 ` cvs-commit at gcc dot gnu dot org
  2004-10-28 19:31 ` cvs-commit at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-10-28 19:30 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From cvs-commit at gcc dot gnu dot org  2004-10-28 19:30 -------
Subject: Bug 18160

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	nemet@gcc.gnu.org	2004-10-28 19:30:50

Modified files:
	gcc            : ChangeLog c-typeck.c 

Log message:
	PR middle-end/18160
	* c-typeck.c (c_mark_addressable): Issue error if address of a
	register variable is taken.  Use "%qD" to print DECL_NAME.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&r1=2.6080&r2=2.6081
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/c-typeck.c.diff?cvsroot=gcc&r1=1.392&r2=1.393



-- 


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


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

* [Bug middle-end/18160] [4.0 Regression] ICE on taking register variable address
  2004-10-26 13:17 [Bug c/18160] New: ICE on taking register variable address alex dot neyman at auriga dot ru
                   ` (4 preceding siblings ...)
  2004-10-28 19:30 ` cvs-commit at gcc dot gnu dot org
@ 2004-10-28 19:31 ` cvs-commit at gcc dot gnu dot org
  2004-10-28 19:32 ` nemet at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-10-28 19:31 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From cvs-commit at gcc dot gnu dot org  2004-10-28 19:31 -------
Subject: Bug 18160

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	nemet@gcc.gnu.org	2004-10-28 19:31:26

Modified files:
	gcc/testsuite  : ChangeLog 
	gcc/testsuite/gcc.dg: asm-7.c 
Added files:
	gcc/testsuite/gcc.dg: register-var-1.c register-var-2.c 

Log message:
	PR middle-end/18160
	* gcc.dg/register-var-1.c: New test.
	* gcc.dg/register-var-2.c: New test.
	* gcc.dg/asm-7.c: Taking the address of a register variable is an
	error now.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.4512&r2=1.4513
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.dg/register-var-1.c.diff?cvsroot=gcc&r1=NONE&r2=1.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.dg/register-var-2.c.diff?cvsroot=gcc&r1=NONE&r2=1.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.dg/asm-7.c.diff?cvsroot=gcc&r1=1.4&r2=1.5



-- 


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


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

* [Bug middle-end/18160] [4.0 Regression] ICE on taking register variable address
  2004-10-26 13:17 [Bug c/18160] New: ICE on taking register variable address alex dot neyman at auriga dot ru
                   ` (5 preceding siblings ...)
  2004-10-28 19:31 ` cvs-commit at gcc dot gnu dot org
@ 2004-10-28 19:32 ` nemet at gcc dot gnu dot org
  2004-11-10 21:11 ` cvs-commit at gcc dot gnu dot org
  2004-11-10 21:11 ` cvs-commit at gcc dot gnu dot org
  8 siblings, 0 replies; 10+ messages in thread
From: nemet at gcc dot gnu dot org @ 2004-10-28 19:32 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From nemet at gcc dot gnu dot org  2004-10-28 19:31 -------
Fixed.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED


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


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

* [Bug middle-end/18160] [4.0 Regression] ICE on taking register variable address
  2004-10-26 13:17 [Bug c/18160] New: ICE on taking register variable address alex dot neyman at auriga dot ru
                   ` (6 preceding siblings ...)
  2004-10-28 19:32 ` nemet at gcc dot gnu dot org
@ 2004-11-10 21:11 ` cvs-commit at gcc dot gnu dot org
  2004-11-10 21:11 ` cvs-commit at gcc dot gnu dot org
  8 siblings, 0 replies; 10+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-11-10 21:11 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From cvs-commit at gcc dot gnu dot org  2004-11-10 21:10 -------
Subject: Bug 18160

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	nemet@gcc.gnu.org	2004-11-10 21:09:30

Modified files:
	gcc/cp         : ChangeLog typeck.c 

Log message:
	PR middle-end/18160
	* typeck.c (cxx_mark_addressable): Issue an error if address of an
	explicit register variable is requested.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/ChangeLog.diff?cvsroot=gcc&r1=1.4478&r2=1.4479
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/typeck.c.diff?cvsroot=gcc&r1=1.594&r2=1.595


------- Additional Comments From cvs-commit at gcc dot gnu dot org  2004-11-10 21:10 -------
Subject: Bug 18160

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	nemet@gcc.gnu.org	2004-11-10 21:09:59

Modified files:
	gcc/testsuite  : ChangeLog 
Added files:
	gcc/testsuite/g++.dg/warn: register-var-1.C register-var-2.C 

Log message:
	PR middle-end/18160
	* g++.dg/warn/register-var-1.C: New test.
	* g++.dg/warn/register-var-2.C: New test.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.4572&r2=1.4573
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/warn/register-var-1.C.diff?cvsroot=gcc&r1=NONE&r2=1.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/warn/register-var-2.C.diff?cvsroot=gcc&r1=NONE&r2=1.1



-- 


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


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

* [Bug middle-end/18160] [4.0 Regression] ICE on taking register variable address
  2004-10-26 13:17 [Bug c/18160] New: ICE on taking register variable address alex dot neyman at auriga dot ru
                   ` (7 preceding siblings ...)
  2004-11-10 21:11 ` cvs-commit at gcc dot gnu dot org
@ 2004-11-10 21:11 ` cvs-commit at gcc dot gnu dot org
  8 siblings, 0 replies; 10+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-11-10 21:11 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From cvs-commit at gcc dot gnu dot org  2004-11-10 21:10 -------
Subject: Bug 18160

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	nemet@gcc.gnu.org	2004-11-10 21:09:30

Modified files:
	gcc/cp         : ChangeLog typeck.c 

Log message:
	PR middle-end/18160
	* typeck.c (cxx_mark_addressable): Issue an error if address of an
	explicit register variable is requested.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/ChangeLog.diff?cvsroot=gcc&r1=1.4478&r2=1.4479
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/typeck.c.diff?cvsroot=gcc&r1=1.594&r2=1.595



-- 


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


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

end of thread, other threads:[~2004-11-10 21:11 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-10-26 13:17 [Bug c/18160] New: ICE on taking register variable address alex dot neyman at auriga dot ru
2004-10-26 13:20 ` [Bug c/18160] " alex dot neyman at auriga dot ru
2004-10-26 13:22 ` [Bug middle-end/18160] [4.0 Regression] " pinskia at gcc dot gnu dot org
2004-10-26 21:24 ` nemet at gcc dot gnu dot org
2004-10-28 15:16 ` steven at gcc dot gnu dot org
2004-10-28 19:30 ` cvs-commit at gcc dot gnu dot org
2004-10-28 19:31 ` cvs-commit at gcc dot gnu dot org
2004-10-28 19:32 ` nemet at gcc dot gnu dot org
2004-11-10 21:11 ` cvs-commit at gcc dot gnu dot org
2004-11-10 21:11 ` cvs-commit at gcc dot gnu dot 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).