[Coco] Nitros9 C and maths lib

Walter zambotti at iinet.net.au
Mon Oct 21 11:39:08 EDT 2019


James

Sorry missed your reply way back in July.

Not sure what you mean about state but it currently is not multi tasking safe.

It uses a number of ports to set up pointers to the source and destination values and another port to trigger the required function.

As this requires several bytes written the execution could be interrupted at any time and this would cause issues if more than one FPU task was running at a time.

I suppose I could create a wrapper around the calls that turned off interrupts for the duration of the FPU call.

Walter

-----Original Message-----
From: Coco [mailto:coco-bounces at maltedmedia.com] On Behalf Of James Jones
Sent: Thursday, 4 July 2019 11:31 AM
To: CoCoList for Color Computer Enthusiasts
Subject: Re: [Coco] Nitros9 C and maths lib

Virtual FPU device? Is that documented? How much state information does it
keep around?

On Mon, Jun 10, 2019 at 2:24 AM Walter Zambotti <zambotti at iinet.net.au>
wrote:

> I have converted my raytrace program to use the virtual FPU device in OVCC.
>
>
>
> It improves performance by around 50 times.
>
>
>
> As I was no longer using any function (pow,sin,cos) from the standard
> mlib.l
> library I removed it from the link and it links without any issue however
> the floating point maths computations are all zero!!!
>
>
>
> This seems strange.  Why would I need to include a library that is no
> longer
> referenced?
>
>
>
> So if I use either of these two compile commands:
>
>
>
> cc -A raytrace.c -l=/dd/lib/mlib.l -m=8k
>
>
>
> or
>
>
>
> cc -A raytrace.c -m=8k
>
>
>
> Both compile and link without error however only the former produces
> correct
> output.
>
>
>
> Walter
>
>
> --
> Coco mailing list
> Coco at maltedmedia.com
> https://pairlist5.pair.net/mailman/listinfo/coco
>

-- 
Coco mailing list
Coco at maltedmedia.com
https://pairlist5.pair.net/mailman/listinfo/coco



More information about the Coco mailing list