All of lore.kernel.org
 help / color / mirror / Atom feed
* [parisc-linux] Glibc 2.2.4-2 No Optimizations = No Compliation
@ 2001-10-11 11:31 Carlos O'Donell Jr.
  2001-10-11 13:47 ` Matthew Wilcox
  0 siblings, 1 reply; 5+ messages in thread
From: Carlos O'Donell Jr. @ 2001-10-11 11:31 UTC (permalink / raw)
  To: parisc-linux

pa-list,

I was working on glibc once again last night.

With the hopes of compiling the library with less optimizations
and tracing through some saner PARISC assembly.

I've noticed that glibc-2.2.4/config.h.in (eventually becomes
config.h) throws an error if glibc is compiled wihtout 
optimizations.

"#error glibc cannot be compiled without optimizations"

Why?

I've trolled the glibc lists, and the faq, hunted through gcc
manuals and referance documentation... to no avail.

As of last year, Drepper made -02 the stable glibc 
compilation standard.

I've compiled glibc with -O1 and it looks like saner assembly.
I have yet to do a full trace through again.

I would like to compile with -O0, but I'm not quite sure of
the ramifications. 

Any reasons why I can't? Any ideas?

c.

Note: This is only for the sake of debugging :)

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [parisc-linux] Glibc 2.2.4-2 No Optimizations = No Compliation
  2001-10-11 11:31 [parisc-linux] Glibc 2.2.4-2 No Optimizations = No Compliation Carlos O'Donell Jr.
@ 2001-10-11 13:47 ` Matthew Wilcox
  2001-10-11 13:59   ` Carlos O'Donell Jr.
  0 siblings, 1 reply; 5+ messages in thread
From: Matthew Wilcox @ 2001-10-11 13:47 UTC (permalink / raw)
  To: Carlos O'Donell Jr., parisc-linux

On Thu, Oct 11, 2001 at 07:31:01AM -0400, Carlos O'Donell Jr. wrote:
> With the hopes of compiling the library with less optimizations
> and tracing through some saner PARISC assembly.

I dunno... I oftn find optimised easier to read.

> I've noticed that glibc-2.2.4/config.h.in (eventually becomes
> config.h) throws an error if glibc is compiled wihtout 
> optimizations.
> 
> "#error glibc cannot be compiled without optimizations"

I don't know.  But I guess glibc needs to inline something, and this doesn't
happen below -O1.

-- 
Revolutions do not require corporate support.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [parisc-linux] Glibc 2.2.4-2 No Optimizations = No Compliation
  2001-10-11 13:47 ` Matthew Wilcox
@ 2001-10-11 13:59   ` Carlos O'Donell Jr.
  2001-10-11 14:03     ` Matthew Wilcox
  0 siblings, 1 reply; 5+ messages in thread
From: Carlos O'Donell Jr. @ 2001-10-11 13:59 UTC (permalink / raw)
  To: Matthew Wilcox, parisc-linux; +Cc: baldric-exec

> 
> I dunno... I oftn find optimised easier to read.
> 

Really?
How about unrolled loops? ;)

In this case with GCC 3.0 being so fresh, there might
be some issues with -O2... so I'd like to see what 
happend at -O0.  I've patched, and I'm currently 
recompiling with -O0... so we'll see.

> 
> I don't know.  But I guess glibc needs to inline something, and this doesn't
> happen below -O1.
> 

True. But that really shouldn't make much difference since
AFAIK inlining doesn't happen until -O2, but config.h just says...
"You must have atleast -O1"

Those inlines, if they aren't there, would cause the build to fail...
and I still haven't seen any indication of this.

We shall see. If -O0 still segfaults, I'll trace that asm and
see what I can see... damn this all sounds so much like voodoo
magic.

c.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [parisc-linux] Glibc 2.2.4-2 No Optimizations = No Compliation
  2001-10-11 13:59   ` Carlos O'Donell Jr.
@ 2001-10-11 14:03     ` Matthew Wilcox
  2001-10-11 14:19       ` Carlos O'Donell Jr.
  0 siblings, 1 reply; 5+ messages in thread
From: Matthew Wilcox @ 2001-10-11 14:03 UTC (permalink / raw)
  To: Carlos O'Donell Jr., Matthew Wilcox, parisc-linux,
	baldric-exec

On Thu, Oct 11, 2001 at 09:59:13AM -0400, Carlos O'Donell Jr. wrote:
> Really?
> How about unrolled loops? ;)

Sometimes.  More importantly, gcc stops doing stupid things with -O1,
particulalry shifting registers backwards and forwards with no net effect.

> True. But that really shouldn't make much difference since
> AFAIK inlining doesn't happen until -O2, but config.h just says...
> "You must have atleast -O1"

Not the case.  gcc will inline functions marked as such at -O1.  At -O3,
it decides for itself to inline some things.

-- 
Revolutions do not require corporate support.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [parisc-linux] Glibc 2.2.4-2 No Optimizations = No Compliation
  2001-10-11 14:03     ` Matthew Wilcox
@ 2001-10-11 14:19       ` Carlos O'Donell Jr.
  0 siblings, 0 replies; 5+ messages in thread
From: Carlos O'Donell Jr. @ 2001-10-11 14:19 UTC (permalink / raw)
  To: parisc-linux, baldric-exec; +Cc: willy

> 
> Sometimes.  More importantly, gcc stops doing stupid things with -O1,
> particulalry shifting registers backwards and forwards with no net effect.
> 

I've not seen such mischieviously deviant behaviour from gcc :}

> 
> Not the case.  gcc will inline functions marked as such at -O1.  At -O3,
> it decides for itself to inline some things.
>

Ok.

Compiled with -O0 and I get undefined referancs to try_lock...
curse those inlined functions.

Back to -O1 and some debugging.

c.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2001-10-11 14:18 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-10-11 11:31 [parisc-linux] Glibc 2.2.4-2 No Optimizations = No Compliation Carlos O'Donell Jr.
2001-10-11 13:47 ` Matthew Wilcox
2001-10-11 13:59   ` Carlos O'Donell Jr.
2001-10-11 14:03     ` Matthew Wilcox
2001-10-11 14:19       ` Carlos O'Donell Jr.

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.