public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libc/10118] New: GLIBC fails to build on POWER6 after binutils change
@ 2009-04-30 19:27 cseo at linux dot vnet dot ibm dot com
2009-04-30 19:29 ` [Bug libc/10118] " cseo at linux dot vnet dot ibm dot com
` (9 more replies)
0 siblings, 10 replies; 13+ messages in thread
From: cseo at linux dot vnet dot ibm dot com @ 2009-04-30 19:27 UTC (permalink / raw)
To: glibc-bugs
Recently, a change in binutils introduced a build failure on Power systems.
Jakub Jelinek fixed the problem for POWER5+ and below with this patch
http://sources.redhat.com/ml/libc-hacker/2009-03/msg00000.html
but the problem remains for POWER6, since ARCH_PWR6 doesn't define '.machine
"power6"', so the same has to be done in the #ifdef ARCH_PWR6 part of those asm
files.
I'm attaching a patch that fixes this on POWER6 systems.
--
Summary: GLIBC fails to build on POWER6 after binutils change
Product: glibc
Version: 2.9
Status: NEW
Severity: normal
Priority: P2
Component: libc
AssignedTo: drepper at redhat dot com
ReportedBy: cseo at linux dot vnet dot ibm dot com
CC: glibc-bugs at sources dot redhat dot com
GCC build triplet: powerpc64-linux-gnu
GCC host triplet: powerpc64-linux-gnu
GCC target triplet: powerpc64-linux-gnu
http://sourceware.org/bugzilla/show_bug.cgi?id=10118
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug libc/10118] GLIBC fails to build on POWER6 after binutils change
2009-04-30 19:27 [Bug libc/10118] New: GLIBC fails to build on POWER6 after binutils change cseo at linux dot vnet dot ibm dot com
2009-04-30 19:29 ` [Bug libc/10118] " cseo at linux dot vnet dot ibm dot com
@ 2009-04-30 19:29 ` cseo at linux dot vnet dot ibm dot com
2009-05-03 15:25 ` drepper at redhat dot com
` (7 subsequent siblings)
9 siblings, 0 replies; 13+ messages in thread
From: cseo at linux dot vnet dot ibm dot com @ 2009-04-30 19:29 UTC (permalink / raw)
To: glibc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |2.10
http://sourceware.org/bugzilla/show_bug.cgi?id=10118
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug libc/10118] GLIBC fails to build on POWER6 after binutils change
2009-04-30 19:27 [Bug libc/10118] New: GLIBC fails to build on POWER6 after binutils change cseo at linux dot vnet dot ibm dot com
@ 2009-04-30 19:29 ` cseo at linux dot vnet dot ibm dot com
2009-04-30 19:29 ` cseo at linux dot vnet dot ibm dot com
` (8 subsequent siblings)
9 siblings, 0 replies; 13+ messages in thread
From: cseo at linux dot vnet dot ibm dot com @ 2009-04-30 19:29 UTC (permalink / raw)
To: glibc-bugs
------- Additional Comments From cseo at linux dot vnet dot ibm dot com 2009-04-30 19:28 -------
Created an attachment (id=3920)
--> (http://sourceware.org/bugzilla/attachment.cgi?id=3920&action=view)
Patch for fixing the use of 4-operand mtfsf instruction in *context functions
on POWER6
--
http://sourceware.org/bugzilla/show_bug.cgi?id=10118
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug libc/10118] GLIBC fails to build on POWER6 after binutils change
2009-04-30 19:27 [Bug libc/10118] New: GLIBC fails to build on POWER6 after binutils change cseo at linux dot vnet dot ibm dot com
2009-04-30 19:29 ` [Bug libc/10118] " cseo at linux dot vnet dot ibm dot com
2009-04-30 19:29 ` cseo at linux dot vnet dot ibm dot com
@ 2009-05-03 15:25 ` drepper at redhat dot com
2009-05-07 0:38 ` rsa at us dot ibm dot com
` (6 subsequent siblings)
9 siblings, 0 replies; 13+ messages in thread
From: drepper at redhat dot com @ 2009-05-03 15:25 UTC (permalink / raw)
To: glibc-bugs
------- Additional Comments From drepper at redhat dot com 2009-05-03 15:25 -------
The patch really is bogus:
# ifdef _ARCH_PWR6
+ .machine push
+ .machine "power6"
/* Use the extended four-operand version of the mtfsf insn. */
mtfsf 0xff,fp31,1,0
+ .machine pop
# else
.machine push
.machine "power6"
The if and else branch both start with the same pseudo ops.
The reason why Jakub probably didn't add it outside the #if is because if
_ARCH_PWR6 is defined the assembler should be in power6 mode.
Investigate why this isn't the case.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |WAITING
http://sourceware.org/bugzilla/show_bug.cgi?id=10118
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug libc/10118] GLIBC fails to build on POWER6 after binutils change
2009-04-30 19:27 [Bug libc/10118] New: GLIBC fails to build on POWER6 after binutils change cseo at linux dot vnet dot ibm dot com
` (2 preceding siblings ...)
2009-05-03 15:25 ` drepper at redhat dot com
@ 2009-05-07 0:38 ` rsa at us dot ibm dot com
2009-05-07 1:16 ` rsa at us dot ibm dot com
` (5 subsequent siblings)
9 siblings, 0 replies; 13+ messages in thread
From: rsa at us dot ibm dot com @ 2009-05-07 0:38 UTC (permalink / raw)
To: glibc-bugs
------- Additional Comments From rsa at us dot ibm dot com 2009-05-07 00:38 -------
I found that the GLIBC target rules for .S files don't include $(CFLAGS) and the
submachine target from --with-cpu=CPU isn't propagated to $(ASFLAGS).
Makerule:
...
compile-command.S = $(compile.S) $(OUTPUT_OPTION) $(compile-mkdep-flags)
compile.S = $(CC) $< -c $(CPPFLAGS) $(S-CPPFLAGS) \
$(ASFLAGS) $(ASFLAGS-$(suffix $@))
The --with-cpu=CPU switch only propagates to $CFLAGS via configure's
`@libc_cv_cc_submachine@' to config.make.in's $(cflags-cpu) to Makeconfig's
$(+cflags) to OVERRIDE CFLAGS.
When compiling a .S file with GCC the switch -mcpu=CPU should be used as well
such that the assembler can be invoked against the CPU insn set (implicit
equivalent to .machine "CPU"). The same thing can be accomplished by passing
-Wa,-mCPU but -mcpu=CPU is less error prone. In the case of this bug, this fix
should result in _ARCH_PWR6 1 being emitted and the assembler in power6 insn
mode intrinsically.
I'll post a patch shortly.
--
http://sourceware.org/bugzilla/show_bug.cgi?id=10118
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug libc/10118] GLIBC fails to build on POWER6 after binutils change
2009-04-30 19:27 [Bug libc/10118] New: GLIBC fails to build on POWER6 after binutils change cseo at linux dot vnet dot ibm dot com
` (3 preceding siblings ...)
2009-05-07 0:38 ` rsa at us dot ibm dot com
@ 2009-05-07 1:16 ` rsa at us dot ibm dot com
2009-05-07 1:17 ` rsa at us dot ibm dot com
` (4 subsequent siblings)
9 siblings, 0 replies; 13+ messages in thread
From: rsa at us dot ibm dot com @ 2009-05-07 1:16 UTC (permalink / raw)
To: glibc-bugs
------- Additional Comments From rsa at us dot ibm dot com 2009-05-07 01:16 -------
Created an attachment (id=3927)
--> (http://sourceware.org/bugzilla/attachment.cgi?id=3927&action=view)
asflags.diff : patch to propagate -mcpu=CPU to the compiler for --with-cpu=CPU
when compiling .S files.
When GLIBC is configured using --with-cpu=CPU this patch set will cause -mcpu=
CPU to be emitted to the compiler when compiling .S files. Currently -mcpu-CPU
is only emitted for .c files.
I chose -mcpu=CPU vs. -Wa,-mCPU because -mcpu=CPU causes TARGET_CMPB to be set
in the compiler and it will then emit an _ARCH_CPU definition as well as set
the assembler in CPU insn mode. -Wa,-mCPU will only set the assembler into CPU
isns mode.
I've tested this for a --with-cpu=power6 build and it fixes the problem.
The reason we didn't catch this until recently is because the assembler was
recently changed to only recognize power6 instructions when in power6 mode.
--
What |Removed |Added
----------------------------------------------------------------------------
Attachment #3920 is|0 |1
obsolete| |
http://sourceware.org/bugzilla/show_bug.cgi?id=10118
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug libc/10118] GLIBC fails to build on POWER6 after binutils change
2009-04-30 19:27 [Bug libc/10118] New: GLIBC fails to build on POWER6 after binutils change cseo at linux dot vnet dot ibm dot com
` (4 preceding siblings ...)
2009-05-07 1:16 ` rsa at us dot ibm dot com
@ 2009-05-07 1:17 ` rsa at us dot ibm dot com
2009-05-07 1:19 ` rsa at us dot ibm dot com
` (3 subsequent siblings)
9 siblings, 0 replies; 13+ messages in thread
From: rsa at us dot ibm dot com @ 2009-05-07 1:17 UTC (permalink / raw)
To: glibc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Status|WAITING |ASSIGNED
http://sourceware.org/bugzilla/show_bug.cgi?id=10118
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug libc/10118] GLIBC fails to build on POWER6 after binutils change
2009-04-30 19:27 [Bug libc/10118] New: GLIBC fails to build on POWER6 after binutils change cseo at linux dot vnet dot ibm dot com
` (5 preceding siblings ...)
2009-05-07 1:17 ` rsa at us dot ibm dot com
@ 2009-05-07 1:19 ` rsa at us dot ibm dot com
2009-05-07 6:58 ` jakub at redhat dot com
` (2 subsequent siblings)
9 siblings, 0 replies; 13+ messages in thread
From: rsa at us dot ibm dot com @ 2009-05-07 1:19 UTC (permalink / raw)
To: glibc-bugs
------- Additional Comments From rsa at us dot ibm dot com 2009-05-07 01:19 -------
Comments on the patch?
Can someone test this on x86[_64]?
I'd like to pass it through a few more runs on Power as well.
Btw, we still need the .machine push; .machine "power6"; ... ; .machine pop from
Jakub in the non-Power6 leg of the .S files since in those cases _ARCH_PWR6
isn't defined and the assembler is in power6 insn mode.
--
http://sourceware.org/bugzilla/show_bug.cgi?id=10118
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug libc/10118] GLIBC fails to build on POWER6 after binutils change
2009-04-30 19:27 [Bug libc/10118] New: GLIBC fails to build on POWER6 after binutils change cseo at linux dot vnet dot ibm dot com
` (6 preceding siblings ...)
2009-05-07 1:19 ` rsa at us dot ibm dot com
@ 2009-05-07 6:58 ` jakub at redhat dot com
2009-05-07 15:00 ` rsa at us dot ibm dot com
2009-05-09 16:00 ` drepper at redhat dot com
9 siblings, 0 replies; 13+ messages in thread
From: jakub at redhat dot com @ 2009-05-07 6:58 UTC (permalink / raw)
To: glibc-bugs
------- Additional Comments From jakub at redhat dot com 2009-05-07 06:58 -------
Ah, that explains why power6 glibc builds just fine for me.
I have -mcpu=power6 setting in CC and CXX env vars at configure time.
--
http://sourceware.org/bugzilla/show_bug.cgi?id=10118
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug libc/10118] GLIBC fails to build on POWER6 after binutils change
2009-04-30 19:27 [Bug libc/10118] New: GLIBC fails to build on POWER6 after binutils change cseo at linux dot vnet dot ibm dot com
` (7 preceding siblings ...)
2009-05-07 6:58 ` jakub at redhat dot com
@ 2009-05-07 15:00 ` rsa at us dot ibm dot com
2009-05-09 16:00 ` drepper at redhat dot com
9 siblings, 0 replies; 13+ messages in thread
From: rsa at us dot ibm dot com @ 2009-05-07 15:00 UTC (permalink / raw)
To: glibc-bugs
------- Additional Comments From rsa at us dot ibm dot com 2009-05-07 15:00 -------
Jakub, in the case where you pass -mcpu=power6 in CC and configuring using
--with-cpu=power6 are you getting -mcpu=power6 twice for the GCC invocations?
Does this patch look complete to you?
--
http://sourceware.org/bugzilla/show_bug.cgi?id=10118
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug libc/10118] GLIBC fails to build on POWER6 after binutils change
2009-04-30 19:27 [Bug libc/10118] New: GLIBC fails to build on POWER6 after binutils change cseo at linux dot vnet dot ibm dot com
` (8 preceding siblings ...)
2009-05-07 15:00 ` rsa at us dot ibm dot com
@ 2009-05-09 16:00 ` drepper at redhat dot com
9 siblings, 0 replies; 13+ messages in thread
From: drepper at redhat dot com @ 2009-05-09 16:00 UTC (permalink / raw)
To: glibc-bugs
------- Additional Comments From drepper at redhat dot com 2009-05-09 15:59 -------
I applied the patch.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://sourceware.org/bugzilla/show_bug.cgi?id=10118
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug libc/10118] GLIBC fails to build on POWER6 after binutils change
[not found] <bug-10118-131@http.sourceware.org/bugzilla/>
2014-06-30 9:15 ` fweimer at redhat dot com
@ 2015-06-01 19:21 ` cvs-commit at gcc dot gnu.org
1 sibling, 0 replies; 13+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2015-06-01 19:21 UTC (permalink / raw)
To: glibc-bugs
https://sourceware.org/bugzilla/show_bug.cgi?id=10118
--- Comment #9 from cvs-commit at gcc dot gnu.org <cvs-commit at gcc dot gnu.org> ---
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".
The branch, master has been updated
via db8fed87d9741b6b3da6c2257f01d63ef2fe407c (commit)
from 0cd2828695cc328aa1b48379436d15c39d433076 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=db8fed87d9741b6b3da6c2257f01d63ef2fe407c
commit db8fed87d9741b6b3da6c2257f01d63ef2fe407c
Author: Martin Sebor <msebor@redhat.com>
Date: Mon Jun 1 14:12:09 2015 -0300
powerpc: setcontext.S uses power6 mtfsf when not supported [BZ #18116]
The attached patch fixes a glibc build failure with gcc 5 on powerpc64le
caused by a recent change in gcc where the compiler defines the
_ARCH_PWR6 macro when processing assembly files but doesn't invoke the
assembler in the corresponding machine mode (unless it has been
explicitly configured to target POWER 6 or later). A bug had been filed
with gcc for this (65341) but was closed as won't fix. Glibc relies on
the _ARCH_PWR6 macro in a few .S files to make use of Power ISA 2.5
instructions (specifically, the four-argument form of the mtfsf insn).
A similar problem had occurred in the past (bug 10118) but the fix that
was committed for it didn't anticipate this new problem.
-----------------------------------------------------------------------
Summary of changes:
ChangeLog | 9 +++++
.../unix/sysv/linux/powerpc/powerpc64/setcontext.S | 30 +++++++++++++---
.../sysv/linux/powerpc/powerpc64/swapcontext.S | 36 +++++++++++++++----
3 files changed, 61 insertions(+), 14 deletions(-)
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug libc/10118] GLIBC fails to build on POWER6 after binutils change
[not found] <bug-10118-131@http.sourceware.org/bugzilla/>
@ 2014-06-30 9:15 ` fweimer at redhat dot com
2015-06-01 19:21 ` cvs-commit at gcc dot gnu.org
1 sibling, 0 replies; 13+ messages in thread
From: fweimer at redhat dot com @ 2014-06-30 9:15 UTC (permalink / raw)
To: glibc-bugs
https://sourceware.org/bugzilla/show_bug.cgi?id=10118
Florian Weimer <fweimer at redhat dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Flags| |security-
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 13+ messages in thread
end of thread, other threads:[~2015-06-01 19:21 UTC | newest]
Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-04-30 19:27 [Bug libc/10118] New: GLIBC fails to build on POWER6 after binutils change cseo at linux dot vnet dot ibm dot com
2009-04-30 19:29 ` [Bug libc/10118] " cseo at linux dot vnet dot ibm dot com
2009-04-30 19:29 ` cseo at linux dot vnet dot ibm dot com
2009-05-03 15:25 ` drepper at redhat dot com
2009-05-07 0:38 ` rsa at us dot ibm dot com
2009-05-07 1:16 ` rsa at us dot ibm dot com
2009-05-07 1:17 ` rsa at us dot ibm dot com
2009-05-07 1:19 ` rsa at us dot ibm dot com
2009-05-07 6:58 ` jakub at redhat dot com
2009-05-07 15:00 ` rsa at us dot ibm dot com
2009-05-09 16:00 ` drepper at redhat dot com
[not found] <bug-10118-131@http.sourceware.org/bugzilla/>
2014-06-30 9:15 ` fweimer at redhat dot com
2015-06-01 19:21 ` cvs-commit 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).