> Mike Davis <[EMAIL PROTECTED]> wrote:
> > It's acting as
> > though fmod(i,6) is returning zero.
> 
> That's interesting...  and congratulations on the detective work.
> 
> The basic thing that comes to mind is that there are a lot of unnecessary
> fp conversions going on in there.  It would be very interesting to see the
> assembler code generated for that function.
> 
> 1. There is definitely a prototype in scope for fmod(), right?

Yes.

> 2. What does `m68k-palmos-objdump -h' on your multisection executable say?

The fmod() is a MathLib function.  If I did m68k-palmos-objdump -h it 
would return nothing to do with fmod(), since that function resides 
in a shared library.  Or have I missed something about multiple code 
resources not being able to access ANY shared library.  I know about 
Glib.

> (If the .text section (which contains fmod) has sneaked out past 32K, this
> could cause your problem.  See also Eugene Chin's similar thread on
> pilot.programmer.gcc entitled "Application bus error in non-fp
> arithmetic".)
> 
> 3. Er, why don't you just use `(i % 6)'?  Of course, probably this
> wouldn't
>    solve all the instances of your problem.  :-)

Well your suggestion about scope lead me to find an instance where I 
forgot to include my utilities.h header in one of my source files.  
That fixed some of my problems but that did not fix the problem with 
the MathLib function.  Now, everything seems to work except those 
functions that deal with MathLib.

I did substitute (i%6) just as a test and it did cause the text 
labels to be positioned correctly but that does not solve the problem 
of why I can't access MathLib funcitons, which I did not include in 
any section.  I DO have an include to the mathlib.h header that 
declares the fmod() function.

I should be able to access functions in a shared library like MathLib 
shouldn't I?

>     John
> 
> -- 
> For information on using the Palm Developer Forums, or to unsubscribe,
> please see http://www.palm.com/devzone/mailinglists.html
> 


--
-----------------------------------------------------------------
Discussion Group:        http://www.halcyon.com/ipscone/wwwboard/

Protect your constitutional rights. Your favorite one may be next!
-----------------------------------------------------------------

-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palm.com/devzone/mailinglists.html

Reply via email to