public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/50305] New: Inline asm reload failure when building Linux kernel
@ 2011-09-06 17:07 uweigand at gcc dot gnu.org
2011-09-06 17:10 ` [Bug target/50305] " uweigand at gcc dot gnu.org
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: uweigand at gcc dot gnu.org @ 2011-09-06 17:07 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50305
Bug #: 50305
Summary: Inline asm reload failure when building Linux kernel
Classification: Unclassified
Product: gcc
Version: 4.7.0
Status: UNCONFIRMED
Keywords: ice-on-valid-code
Severity: normal
Priority: P3
Component: target
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: uweigand@gcc.gnu.org
Target: arm-linux-gnueabi
Created attachment 25204
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=25204
Reduced test case
Building the Linux kernel with current mainline fails with certain sets of
options due to a reload failure on an atomic.h inline asm.
The attached test case reproduces the problem when compiled with
-O2 -fno-omit-frame-pointer -marm -march=armv7-a
core.i: In function ‘event_alloc’:
core.i:34:2: error: ‘asm’ operand requires impossible reload
core.i:34:2: error: ‘asm’ operand requires impossible reload
Note that while the inline asm may be somewhat inefficient (enforcing a "+Qo"
constraint on an operand that is never used in the assembly), there is nothing
invalid about the set of constraints (and there are enough registers
available).
The problem seems instead to be caused by unfortunate interactions between
ARM's legitimize_reload_address routine and subsequent iterations through
find_reloads common code.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug target/50305] Inline asm reload failure when building Linux kernel
2011-09-06 17:07 [Bug target/50305] New: Inline asm reload failure when building Linux kernel uweigand at gcc dot gnu.org
@ 2011-09-06 17:10 ` uweigand at gcc dot gnu.org
2011-09-11 22:11 ` michael.hope at linaro dot org
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: uweigand at gcc dot gnu.org @ 2011-09-06 17:10 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50305
Ulrich Weigand <uweigand at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2011-09-06
AssignedTo|unassigned at gcc dot |uweigand at gcc dot gnu.org
|gnu.org |
Ever Confirmed|0 |1
--- Comment #1 from Ulrich Weigand <uweigand at gcc dot gnu.org> 2011-09-06 17:06:45 UTC ---
Created attachment 25205
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=25205
Possible fix
I'm currently testing this patch to fix the problem.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug target/50305] Inline asm reload failure when building Linux kernel
2011-09-06 17:07 [Bug target/50305] New: Inline asm reload failure when building Linux kernel uweigand at gcc dot gnu.org
2011-09-06 17:10 ` [Bug target/50305] " uweigand at gcc dot gnu.org
@ 2011-09-11 22:11 ` michael.hope at linaro dot org
2011-10-06 11:51 ` uweigand at gcc dot gnu.org
2011-10-06 11:53 ` uweigand at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: michael.hope at linaro dot org @ 2011-09-11 22:11 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50305
Michael Hope <michael.hope at linaro dot org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |michael.hope at linaro dot
| |org
--- Comment #2 from Michael Hope <michael.hope at linaro dot org> 2011-09-11 21:47:59 UTC ---
Note that the fault goes away with -mfpu=neon and returns with -mfpu=vfpv3.
You might want to add an explicit fpu to the dg-options.
For reference, I could reproduce the fault in r177688, r178025, r178624, and
gcc-linaro-4.5-2011.08. It does not exist in 4.5.3, 4.6.1, or
gcc-linaro-4.6-2011.08.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug target/50305] Inline asm reload failure when building Linux kernel
2011-09-06 17:07 [Bug target/50305] New: Inline asm reload failure when building Linux kernel uweigand at gcc dot gnu.org
2011-09-06 17:10 ` [Bug target/50305] " uweigand at gcc dot gnu.org
2011-09-11 22:11 ` michael.hope at linaro dot org
@ 2011-10-06 11:51 ` uweigand at gcc dot gnu.org
2011-10-06 11:53 ` uweigand at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: uweigand at gcc dot gnu.org @ 2011-10-06 11:51 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50305
--- Comment #3 from Ulrich Weigand <uweigand at gcc dot gnu.org> 2011-10-06 11:50:35 UTC ---
Author: uweigand
Date: Thu Oct 6 11:50:26 2011
New Revision: 179603
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=179603
Log:
gcc/
PR target/50305
* config/arm/arm.c (arm_legitimize_reload_address): Recognize
output of a previous pass through legitimize_reload_address.
Do not attempt to optimize addresses if the base register is
equivalent to a constant.
gcc/testsuite/
PR target/50305
* gcc.target/arm/pr50305.c: New test.
Added:
trunk/gcc/testsuite/gcc.target/arm/pr50305.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/config/arm/arm.c
trunk/gcc/testsuite/ChangeLog
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug target/50305] Inline asm reload failure when building Linux kernel
2011-09-06 17:07 [Bug target/50305] New: Inline asm reload failure when building Linux kernel uweigand at gcc dot gnu.org
` (2 preceding siblings ...)
2011-10-06 11:51 ` uweigand at gcc dot gnu.org
@ 2011-10-06 11:53 ` uweigand at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: uweigand at gcc dot gnu.org @ 2011-10-06 11:53 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50305
Ulrich Weigand <uweigand at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
--- Comment #4 from Ulrich Weigand <uweigand at gcc dot gnu.org> 2011-10-06 11:53:26 UTC ---
Fixed.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2011-10-06 11:53 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-09-06 17:07 [Bug target/50305] New: Inline asm reload failure when building Linux kernel uweigand at gcc dot gnu.org
2011-09-06 17:10 ` [Bug target/50305] " uweigand at gcc dot gnu.org
2011-09-11 22:11 ` michael.hope at linaro dot org
2011-10-06 11:51 ` uweigand at gcc dot gnu.org
2011-10-06 11:53 ` uweigand at gcc dot gnu.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).