This is the mail archive of the ecos-discuss@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: Re: libm use in kernel


Using FP in either DSR or ISR context is not something I have ever
thought of doing or looked into. I assumed the original post was meant
to use math functions during some initialization process. 
FP are saved / restored during context switch or exception handling
therefore I think it is technically possible to use FP in DSR context
(or?). What you are mentioning about deferring context swapping until a
FP instruction is completed is puzzling me. Does not all HW handle this?
I will check that for the processor architecture I use.

Christophe

-----Original Message-----
From: ecos-discuss-owner@ecos.sourceware.org
[mailto:ecos-discuss-owner@ecos.sourceware.org] On Behalf Of Paul D.
DeRocco
Sent: 15. november 2010 20:25
To: 'eCos Discuss'
Subject: RE: [ECOS] Re: libm use in kernel

> From: Christophe Coutand
> 
> I doubt there is any limitation that prevent LIBM to be used 
> in driver code. 

On the x86, how does eCos deal with the FP context? Does it include it
as
part of every thread and DSR context, or just thread context? Does it
rely
on the chip mechanism to defer FP context swapping until an actual FP
instruction is made following a thread switch? I can imagine a kernel
implementation that would assume that no DSR (let alone ISR) would ever
use
FP, and which would crash and burn if one ever did. But I've never
looked at
the x86 HAL.

-- 

Ciao,               Paul D. DeRocco
Paul                mailto:pderocco@ix.netcom.com 


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]