Bug 17377 - cris.md bug in "return" pattern trigged by __builtin_return_address
Summary: cris.md bug in "return" pattern trigged by __builtin_return_address
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: target (show other bugs)
Version: 4.0.0
: P2 normal
Target Milestone: 4.0.0
Assignee: Hans-Peter Nilsson
URL:
Keywords: wrong-code
Depends on:
Blocks:
 
Reported: 2004-09-09 14:29 UTC by Hans-Peter Nilsson
Modified: 2004-09-09 20:40 UTC (History)
1 user (show)

See Also:
Host:
Target: cris-*
Build:
Known to work:
Known to fail:
Last reconfirmed: 2004-09-09 14:31:13


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Hans-Peter Nilsson 2004-09-09 14:29:26 UTC
Bug in cris.md "return" pattern causes miscompilation of some functions
using __builtin_return_address.
Comment 1 GCC Commits 2004-09-09 20:31:14 UTC
Subject: Bug 17377

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	hp@gcc.gnu.org	2004-09-09 20:31:11

Modified files:
	gcc/testsuite  : ChangeLog 
Added files:
	gcc/testsuite/gcc.c-torture/execute: pr17377.c 

Log message:
	PR target/17377
	* gcc.c-torture/execute/pr17377.c: New test.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.4252&r2=1.4253
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.c-torture/execute/pr17377.c.diff?cvsroot=gcc&r1=NONE&r2=1.1

Comment 2 GCC Commits 2004-09-09 20:36:33 UTC
Subject: Bug 17377

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	hp@gcc.gnu.org	2004-09-09 20:36:31

Modified files:
	gcc            : ChangeLog 
	gcc/config/cris: cris-protos.h cris.c cris.md 

Log message:
	PR target/17377
	* config/cris/cris-protos.h (cris_return_address_on_stack): Declare.
	* config/cris/cris.c (cris_return_address_on_stack): New function.
	* config/cris/cris.md ("return"): For location of return address,
	also check cris_return_address_on_stack.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&r1=2.5334&r2=2.5335
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/config/cris/cris-protos.h.diff?cvsroot=gcc&r1=1.11&r2=1.12
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/config/cris/cris.c.diff?cvsroot=gcc&r1=1.58&r2=1.59
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/config/cris/cris.md.diff?cvsroot=gcc&r1=1.17&r2=1.18

Comment 3 Hans-Peter Nilsson 2004-09-09 20:40:55 UTC
See <URL:http://gcc.gnu.org/ml/gcc-patches/2004-09/msg00869.html>.