This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: What happens during optimization
- From: Gary Thomas <gthomas at ecoscentric dot com>
- To: Grant Edwards <grante at visi dot com>
- Cc: Daniel Lidsten <Daniel dot Lidsten at combitechsystems dot com>,eCos Discussion <ecos-discuss at sources dot redhat dot com>
- Date: 15 Nov 2002 10:04:40 -0700
- Subject: Re: [ECOS] What happens during optimization
- References: <1037372000.2213.171.camel@hermes.chez-thomas.org> <20021115094053.A11332@visi.com>
On Fri, 2002-11-15 at 08:40, Grant Edwards wrote:
> On Fri, Nov 15, 2002 at 07:53:20AM -0700, Gary Thomas wrote:
>
> > Did you rebuild everything after you added the optimization option?
>
> Is it required that eCos and the app be compiled with the same
> level of optimization?
It all depends, but in general I would go for that.
The quoted example was apt; the guy built his program and the
eCos kernel with no optimization. Thus Cyg_Thread::self was a
real function. When he rebuilt the kernel with optimization,
all of the uses of Cyg_Thread::self were inlined, thus there
was no copy for his code to link against.
Mixed optimized/not-optimized code can run into these sort
of problems where inline functions simply disappear.
--
------------------------------------------------------------
Gary Thomas |
eCosCentric, Ltd. |
+1 (970) 229-1963 | eCos & RedBoot experts
gthomas@ecoscentric.com |
http://www.ecoscentric.com/ |
------------------------------------------------------------
--
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss