Bug 26504 - [4.1/4.2 Regression] compute_frame_pointer_to_cfa_displacement error for avr target with --with-dwarf2
Summary: [4.1/4.2 Regression] compute_frame_pointer_to_cfa_displacement error for avr ...
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: target (show other bugs)
Version: 4.1.0
: P5 normal
Target Milestone: 4.1.2
Assignee: Not yet assigned to anyone
URL:
Keywords: build, ice-on-valid-code
: 28273 29409 29875 (view as bug list)
Depends on: 26015
Blocks:
  Show dependency treegraph
 
Reported: 2006-03-01 02:25 UTC by Wilbur Harvey
Modified: 2021-11-05 23:18 UTC (History)
8 users (show)

See Also:
Host:
Target: AVR
Build:
Known to work:
Known to fail:
Last reconfirmed: 2006-09-03 05:33:31


Attachments
compute_frame_pointer_to_cfa_displacement internal error source trigger (5.71 KB, text/plain)
2006-03-02 16:03 UTC, Ben Keen
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Wilbur Harvey 2006-03-01 02:25:23 UTC
When trying to compile gcc4.10 for the AVR processor under Ubuntu Dapper (gcc4.0.3) I get this error:

../../gcc/libgcc2.c: In function '__fixunssfsi':
../../gcc/libgcc2.c:1499: internal compiler error: in compute_frame_pointer_to_cfa_displacement, at dwarf2out.c:10445
Please submit a full bug report,

Config arguments
wilbur.harvey@shuttle1:~/avrtools/gcc-4.1.0/obj-avr$ ../configure --prefix=$PREFIX --target=avr --enable-languages=c,c++ --disable-nls --with-dwarf2

I previously compiled the binutils2.16 under the same environment without any problems.
Comment 1 Andrew Pinski 2006-03-01 02:31:04 UTC
Related to PR 26015.
Comment 2 Andrew Pinski 2006-03-02 12:29:51 UTC
Can you attach the preprocessed source?
Comment 3 Ben Keen 2006-03-02 16:03:39 UTC
Created attachment 10956 [details]
compute_frame_pointer_to_cfa_displacement internal error source trigger
Comment 4 Ben Keen 2006-03-02 16:06:06 UTC
I have this same problem, only with Fedora Core 2/x86, building the cross-compiler for AVR as well.  gcc4.1 and gcc 4.03 both stop with this error.

I have attached the preprocessed source file resulting from the following command.

bash-2.05b$ /scr/gcc41avrbld/./gcc/xgcc -B/scr/gcc41avrbld/./gcc/ -B/u03/bjkeen/local/avr/bin/ -B/u03/bjkeen/local/avr/lib/ -isystem /u03/bjkeen/local/avr/include -isystem /u03/bjkeen/local/avr/sys-include -O2  -O2 -g -O2  -DIN_GCC -DCROSS_COMPILE   -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include  -DDF=SF -Dinhibit_libc -mcall-prologues -g  -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc -I. -I. -I../../gcc-4.1.0/gcc -I../../gcc-4.1.0/gcc/. -I../../gcc-4.1.0/gcc/../include -I../../gcc-4.1.0/gcc/../libcpp/include  -DL_fixunssfsi -c ../../gcc-4.1.0/gcc/libgcc2.c -o libgcc/./_fixunssfsi.o -save-temps
../../gcc-4.1.0/gcc/libgcc2.c: In function '__fixunssfsi':
../../gcc-4.1.0/gcc/libgcc2.c:1499: internal compiler error: in compute_frame_pointer_to_cfa_displacement, at dwarf2out.c:10445
Comment 5 Wilbur Harvey 2006-03-02 20:01:00 UTC
Subject: Re:  compute_frame_pointer_to_cfa_displacement
 erro	r for avr target with --with-dwarf2

I gave up and deleted everything related.
I will see if I can re-create the environment again.
Wilbur

pinskia at gcc dot gnu dot org wrote:
> ------- Comment #2 from pinskia at gcc dot gnu dot org  2006-03-02 12:29
> -------
> Can you attach the preprocessed source?
>
>
>   

Comment 6 Andrew Pinski 2006-03-03 02:17:56 UTC
Can either one of you try the patch in PR 26015?
Comment 7 PODGORSKI 2006-03-21 16:08:13 UTC
Hi, I have the same error.

I use  : 
 - binutils-2.16.1,
 - gcc 4.1.0,
 - avr-libc 1.4.3
But it works with gcc 4.0.3.

I use the doc : www.nongnu.org/avr-libc/user-manual/install_tools.html


make[3]: Entering directory `/home/avrdev-4/gcc-4.1.0/obj-avr/gcc'
/home/avrdev-4/gcc-4.1.0/obj-avr/./gcc/xgcc -B/home/avrdev-4/gcc-4.1.0/obj-avr/./gcc/ -B/home/avrdev-4//avr/bin/ -B/home/avrdev-4//avr/lib/ -isystem /home/avrdev-4//avr/include -isystem /home/avrdev-4//avr/sys-include -O2  -O2 -g -O2  -DIN_GCC -DCROSS_COMPILE   -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include  -DDF=SF -Dinhibit_libc -mcall-prologues -g  -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc -I. -I. -I../../gcc -I../../gcc/. -I../../gcc/../include -I../../gcc/../libcpp/include  -DL_fixunssfsi -c ../../gcc/libgcc2.c -o libgcc/./_fixunssfsi.o
../../gcc/libgcc2.c: In function '__fixunssfsi':
../../gcc/libgcc2.c:1499: internal compiler error: in compute_frame_pointer_to_cfa_displacement, at dwarf2out.c:10445
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
make[3]: *** [libgcc/./_fixunssfsi.o] Erreur 1
make[3]: Leaving directory `/home/avrdev-4/gcc-4.1.0/obj-avr/gcc'
make[2]: *** [stmp-multilib] Erreur 2
make[2]: Leaving directory `/home/avrdev-4/gcc-4.1.0/obj-avr/gcc'
make[1]: *** [all-gcc] Erreur 2
make[1]: Leaving directory `/home/avrdev-4/gcc-4.1.0/obj-avr'
make: *** [all] Erreur 2


Thanks a lot.
Comment 8 Ben Keen 2006-04-05 20:11:15 UTC
(In reply to comment #6)
> Can either one of you try the patch in PR 26015?
> 

Putting

#define FRAME_POINTER_CFA_OFFSET(FNDECL) 0

as indicated in that patch, into config/avr.h seems to work, but it is also necessary to specify
--disable-libssp
to configure.

Perhaps libssp should by default be disabled for avr targets?
Comment 9 Andrew Pinski 2006-07-05 17:31:53 UTC
*** Bug 28273 has been marked as a duplicate of this bug. ***
Comment 10 Andreas Fink 2006-07-09 21:33:54 UTC
Getting the same error when compiling gcc-4.1.1 on MacOSX for target avr. It was compiled with apple's XCode version of gcc which is gcc 4.0.1.

../configure --prefix=$PREFIX --target=avr --enable-languages=c,c++     --disable-nls --with-dwarf2
Comment 11 Clemens Koller 2006-08-28 15:37:58 UTC
Same bug occures with 4.1.1 too, verified on an x86 and ppc host, cross compiling for Atmel AVR:
configure --target=avr --with-dwarf2
triggers the bug.
Comment 12 Andrew Pinski 2006-09-03 05:33:31 UTC
Confirmed.
Comment 13 Mark Mitchell 2006-09-07 01:13:29 UTC
AVR is not a primary or secondary platform.
Comment 14 aesok 2006-09-14 21:11:43 UTC
Subject: Bug 26504

Author: aesok
Date: Thu Sep 14 21:11:33 2006
New Revision: 116950

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=116950
Log:
	PR target/26504
	* config/avr/avr.h (FRAME_POINTER_CFA_OFFSET): Define.

Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/config/avr/avr.h

Comment 15 aesok 2006-09-14 21:19:19 UTC
Subject: Bug 26504

Author: aesok
Date: Thu Sep 14 21:19:10 2006
New Revision: 116952

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=116952
Log:
	PR target/26504
	* config/avr/avr.h (FRAME_POINTER_CFA_OFFSET): Define.

Modified:
    branches/gcc-4_1-branch/gcc/ChangeLog
    branches/gcc-4_1-branch/gcc/config/avr/avr.h

Comment 16 aesok 2006-09-14 21:39:00 UTC
Change Status to FIXED.
Comment 17 Andrew Pinski 2006-10-10 16:27:41 UTC
*** Bug 29409 has been marked as a duplicate of this bug. ***
Comment 18 aesok 2006-10-10 22:18:16 UTC
Subject: Bug 26504

Author: aesok
Date: Tue Oct 10 22:18:06 2006
New Revision: 117616

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=117616
Log:
	* config/avr/predicates.md: New file.
	* config/avr/avr.md: Include it.
	(REG_SP): New constant.
	(peepholes): Use predicates.
	(sbrx_branch, sbrx_and_branchhi, sbrx_and_branchsi, branch, rvbranch,
	difficult_branch,  difficult_rvbranch, cbi, sbi, sbix_branch,
	sbix_branch_bit7, sbix_branch_tmp, sbix_branch_tmp_bit7): Ditto.
	PR target/26504
	* config/avr/avr.h (FRAME_POINTER_CFA_OFFSET): Define.

Added:
    trunk/gcc/config/avr/predicates.md   (with props)
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/config/avr/avr.md

Propchange: trunk/gcc/config/avr/predicates.md
            ('svn:executable' added)


Comment 19 Andrew Pinski 2006-11-17 01:41:30 UTC
*** Bug 29875 has been marked as a duplicate of this bug. ***
Comment 20 Tim Turner 2021-11-05 23:18:59 UTC Comment hidden (spam)