I’m working with a 28335 FPU processor and CCS5. I have some intense computations to perform in a brief period of time, so I want to get the math functions and tables into RAM to maximize throughput.
I am utilizing rts2800_fpu32.lib and rts2800_fpu32_fast_supplement.lib. The latter is loaded first; this is verified in the .map file.
My problem is that I don’t know how to get these .lib functions (_acos, _atan, _isqrt) into RAM. I have found scant and scattered information about how to use/modify .cmd files.
In sprca75 is verbiage about the FPUmathTables, telling you what to do if you “do not wish to load a copy of these tables into the device” (unclear if that means Flash or RAM) but it says nothing about getting them into RAM. I tried some experiments with the FPUmathTables directives in the F28335_nonBIOS_flash.cmd file. This line already existed there in the MEMORY area:
FPUTABLES (R) : origin = 0x3FEBDC, length = 0x0006A0 /* Part of Boot ROM */
I added this line to the SECTIONS area:
FPUmathTables : > FPUTABLES, PAGE = 0, TYPE = NOLOAD
After building, the map file informed me that all the utilized library functions were mapped to Flash. The associated tables were also mapped to Flash.
I changed the line in SECTIONS, removing the TYPE = NOLOAD part.
FPUmathTables : > FPUTABLES, PAGE = 0
After building, the map file informed me that nothing had changed. Everything was the same as when the TYPE = NOLOAD part was included.
Finally, I removed the line in the SECTIONS area and built. I got a warning that said
#10247-D creating output section “FPUmathTables” without a SECTIONS
Now all the tables were mapped to RAM (!) . The utilized library functions remained in Flash.
SO:
- How do I amend the .cmd file to properly put the utilized library functions in RAM?
- How do I amend the .cmd file to properly put the trig tables in RAM? (granted, I achieved this, but only by not including it in the .cmd file. Surely there’s a better, more assertive and correct way.)
- Where will I find better documentation about using and changing .cmd files?
Thanks in advance.