First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 16430
Product:  
Component:  
Status: RESOLVED
Resolution: FIXED
Assigned To: Eric Botcazou <ebotcazou@gcc.gnu.org>
Host:
Reported against  
Priority:  
Severity:  
Target Milestone:  
 
 
Target:
Reporter: Eric Botcazou <ebotcazou@gcc.gnu.org>
Add CC:
CC:
Remove selected CCs
Build:
URL:
Summary:
Keywords:
Known to work:
Known to fail:

Attachment Description Type Created Size Actions
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 16430 depends on: Show dependency tree
Show dependency graph
Bug 16430 blocks:

Additional Comments:






View Bug Activity   |   Format For Printing   |   Clone This Bug


Description:   Last confirmed: 2004-07-08 07:06 Opened: 2004-07-08 07:05
For the Ada testcase:

procedure P is

  type my_array is array (1..6) of Integer;
  A : my_array;

  function Q return my_array is
  begin
    return A;
  end;

begin
  A := Q;
end P;

I get with gcc -m64 on sparc-sun-solaris2.8:

+===========================GNAT BUG DETECTED==============================+
| 3.4.1 (sparc-sun-solaris2.8) in hard_function_value, at explow.c:1565    |
| Error detected at p.adb:6:3                                              |
| Please submit a bug report; see http://gcc.gnu.org/bugs.html.            |
| Include the entire contents of this bug box in the report.               |
| Include the exact gcc or gnatmake command that you entered.              |
| Also include sources listed below in gnatchop format                     |
| (concatenated together with no headers between files).                   |
+==========================================================================+


The problem comes from the removing of OImode after GCC 3.2.x.

------- Comment #1 From Eric Botcazou 2004-07-08 07:06 -------
Testing a fix.

------- Comment #2 From CVS Commits 2004-07-08 14:33 -------
Subject: Bug 16430

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	ebotcazou@gcc.gnu.org	2004-07-08 14:33:21

Modified files:
	gcc            : ChangeLog 
	gcc/config/sparc: sparc.c 

Log message:
	PR target/16430
	* config/sparc/sparc.c (function_value): In 64-bit mode,
	return the aggregates larger than 16 bytes like unions.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&r1=2.4377&r2=2.4378
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/config/sparc/sparc.c.diff?cvsroot=gcc&r1=1.313&r2=1.314


------- Comment #3 From CVS Commits 2004-07-08 14:36 -------
Subject: Bug 16430

CVSROOT:	/cvs/gcc
Module name:	gcc
Branch: 	gcc-3_4-branch
Changes by:	ebotcazou@gcc.gnu.org	2004-07-08 14:36:52

Modified files:
	gcc            : ChangeLog 
	gcc/config/sparc: sparc.c 

Log message:
	PR target/16430
	* config/sparc/sparc.c (function_value): In 64-bit mode,
	return the aggregates larger than 16 bytes like unions.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=2.2326.2.541&r2=2.2326.2.542
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/config/sparc/sparc.c.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=1.271.4.16&r2=1.271.4.17


------- Comment #4 From Eric Botcazou 2004-07-08 14:38 -------
See http://gcc.gnu.org/ml/gcc-patches/2004-07/msg00782.html

First Last Prev Next    No search results available      Search page      Enter new bug