This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Can't use fastrts64x.lib with CCSV4 and DSP/BIOS 5.40.02.22

Other Parts Discussed in Thread: CCSTUDIO, CODECOMPOSER

I have a legacy C6415 project that compiles and links without error or warning under CCS V3.3 using DSP/BIOS 5.33.03. I am migrating this project to CCS V4 which comes with DSP/BIOS 5.40.02.22. I am up to the final link step and I keep getting a multiply defined symbol error. The symbols __mpyf and __divf are defined both in rts6400.lib and fastrts64x.lib. According to the documentation that comes with fastrts64x.lib if this library is included first in the link phase then the linker will not try to load the slower functions from the default runtime system (e.g. rts6400.lib). I have tried every option I can think of to no avail. Can anyone tell me what is wrong here because the build tool version in both cases is the same (6.1.11).

 

Here is the link command from CCS V3.3:

--------------------------------------------

C:\Program Files\Texas Instruments\C6000 Code Generation Tools 6.1.11\bin\cl6x -z -a -c -m"./Debug/fm_dsp.map" -o"./Debug/fm_dsp.out" --symbol_map=CLK_F_gethtime=CLK_F_getshtime --verbose_diagnostics -w -x -i"C:/CCStudio_v3.3/C6000/csl/lib" -i"C:/CCStudio_v3.3/c6400/dsplib/lib" -i"C:/CCStudio_v3.3/c6400/mthlib/lib" -i"C:/CCStudio_v3.3/C6000/csl/lib" -i"C:/CCStudio_v3.3/C6000/xdais/lib" -i"C:/CCStudio_v3.3/bios_5_33_03/packages/ti/bios/lib" -i"C:/CCStudio_v3.3/bios_5_33_03/packages/ti/rtdx/lib/c6000" -i"C:/Program Files/Texas Instruments/C6000 Code Generation Tools 6.1.11/lib" -l"csl6415.lib" -l"dsp64x.lib" -l"fastrts64x.lib"

"C:\Storage\myprojects\fm_dsp_latest\fm_dsplnk.cmd"

"C:\Storage\myprojects\fm_dsp_latest\dave-c\Debug\dave.obj"

"C:\Storage\myprojects\fm_dsp_latest\dave-c\Debug\fir_fast.obj"

"C:\Storage\myprojects\fm_dsp_latest\Debug\dsp_absmax.obj"

"C:\Storage\myprojects\fm_dsp_latest\Debug\DSP_printf.obj"

"C:\Storage\myprojects\fm_dsp_latest\Debug\fm_dsp_main.obj"

"C:\Storage\myprojects\fm_dsp_latest\Debug\fm_dsp_params.obj"

"C:\Storage\myprojects\fm_dsp_latest\Debug\fm_dspcfg.obj"

"C:\Storage\myprojects\fm_dsp_latest\Debug\fm_dspcfg_c.obj"

"C:\Storage\myprojects\fm_dsp_latest\Debug\memtest.obj"

"C:\Storage\myprojects\fm_dsp_latest\Debug\sinet.obj"

"C:\Storage\myprojects\fm_dsp_latest\Debug\vec_mul.obj"

"C:\Storage\myprojects\fm_dsp_latest\host_ipc\Debug\fm_dsp_ipc.obj"

"C:\Storage\myprojects\fm_dsp_latest\host_ipc\Debug\fm_dsp_sharedmem.obj"

--------------------------
Here is the link command and resulting error under CCS V4
"C:/Program Files/Texas Instruments/C6000 Code Generation Tools 6.1.11/bin/cl6x" -z -m"fm_dsp_scratch.map" --warn_sections -i"C:/Program Files/Texas Instruments/C6000 Code Generation Tools 6.1.11/c6400/dsplib/lib" -i"C:/Program Files/Texas Instruments/C6000 Code Generation Tools 6.1.11/csl/lib_3x" -i"C:/Program Files/Texas Instruments/C6000 Code Generation Tools 6.1.11/c6400/mthlib/lib" -i"C:/Program Files/Texas Instruments/C6000 Code Generation Tools 6.1.11/lib" -i"C:/Program Files/Texas Instruments/C6000 Code Generation Tools 6.1.11/include" -i"C:/Program Files/Texas Instruments/bios_5_40_02_22/packages/ti/rtdx/lib/c6000" -i"C:/Program Files/Texas Instruments/bios_5_40_02_22/packages/ti/bios/lib" --priority --disable_auto_rts --rom_model -o "fm_dsp_scratch.out" -l"./fm_dspcfg.cmd"  "./host_ipc/fm_dsp_sharedmem.obj" "./host_ipc/fm_dsp_ipc.obj" "./taylor_exp.obj" "./sinet.obj" "./memtest.obj" "./fm_dsp_params.obj" "./fm_dsp_main.obj" "./fm_dspcfg_c.obj" "./fm_dspcfg.obj" "./fir_fast.obj" "./dsp_absmax.obj" "./dave.obj" "./DSP_printf.obj" -l"fastrts64x.lib" -l"dsp64x.lib" -l"csl6415.lib" -l"rts6400.lib" "../fm_dsp_lnk_debug.cmd" 
<Linking>
error: symbol "__divf" redefined: first defined in "C:/Program Files/Texas
   Instruments/C6000 Code Generation Tools 6.1.11/lib/rts6400.lib<divf.obj>";
   redefined in "C:/Program Files/Texas Instruments/C6000 Code Generation Tools
   6.1.11/c6400/mthlib/lib/fastrts64x.lib<divsp.obj>"
error: symbol "__mpyf" redefined: first defined in "C:/Program Files/Texas
   Instruments/C6000 Code Generation Tools 6.1.11/lib/rts6400.lib<mpyf.obj>";
   redefined in "C:/Program Files/Texas Instruments/C6000 Code Generation Tools
   6.1.11/c6400/mthlib/lib/fastrts64x.lib<mpysp.obj>"
warning: conservatively using trampoline for call destination "CLK_F_gethtime";
   generation and use of this trampoline can potentially be avoided if the
   --symbol_map option is used to re-direct symbol references instead of using
   symbol assignments
error: errors encountered during linking; "fm_dsp_scratch.out" not built

  • It's not clear to me what exactly the issue is.  Here's something to try though.  I saw an issue related to code gen 6.1.11 where it was pulling in more pieces of a library than truly necessary.  Perhaps in your case this same issue is happening, but because the same function names are being used it ends up causing an error.

    This wiki page tells how to update your compiler/linker for CCS 4:

    http://wiki.davincidsp.com/index.php/Compiler_Installation_and_Selection

  • Just to be clear, the issue I mention above was fixed in 6.1.12 so I'm suggesting you update to 6.1.12 to see if the error disappears.

  • The issue is that when CCS V3 creates the command line for the linker the link process works. But when CCS V4 creates the command line the link process fails. In both cases the linker executable is the same program. There are two possibilies in my mind. The first is that the command line which is significantly different is in some non-obvious way causing the library to be included incorrectly. The second is that there is something within the DSP/BIOS header or library files that is causing the linker to misbehave.

    I will try the V6.1.12 tool set as soon as I can get a fix for the installer problem which first appeared in V6.1.11. Under XP on my computer the installer starts and exits immediately without any message or hint as to why it doesn't run.

    Regards,

    Dan

     

  • I don't think v6.1.12 will fix this problem.  If it doesn't, please build again, but add the linker option -scanlibs.  That option causes the linker to issue messages which indicate, for every symbol found in multiple libraries, which library is used.  Then please post the linker messages, along with the map files, here.

    Thanks and regards,

    -George

     

  • I think you are right that 6.1.12 will not help. I'm sorry for not mentioning earlier that I had already tried that linker option. The results are puzzling (see below). It always pulls the function from the wrong library (rts6400) but only generates an error for two of the functions. Under CCSV3 it works correctly but I cannot figure out what it is about the command line that makes it work. The map file from the successful link is attached but unfortunately the linker does not produce a map file when it fails. Could it be some registry entry that is making the linker behave differently? My suspicion is something to do with the DSP/BIOS library up to now.

    Dan

    From link step under CCSV4:

    "C:/Program Files/Texas Instruments/C6000 Code Generation Tools 6.1.11/bin/cl6x" -z -m"fm_dsp_scratch.map" --warn_sections -i"C:/Program Files/Texas Instruments/C6000 Code Generation Tools 6.1.11/c6400/dsplib/lib" -i"C:/Program Files/Texas Instruments/C6000 Code Generation Tools 6.1.11/csl/lib_3x" -i"C:/Program Files/Texas Instruments/C6000 Code Generation Tools 6.1.11/c6400/mthlib/lib" -i"C:/Program Files/Texas Instruments/C6000 Code Generation Tools 6.1.11/lib" -i"C:/Program Files/Texas Instruments/C6000 Code Generation Tools 6.1.11/include" -i"C:/Program Files/Texas Instruments/bios_5_40_02_22/packages/ti/rtdx/lib/c6000" -i"C:/Program Files/Texas Instruments/bios_5_40_02_22/packages/ti/bios/lib" --priority --reread_libs --symbol_map=CLK_F_gethtime=CLK_F_getshtime --scan_libraries --rom_model -o "fm_dsp_scratch.out" -l"./fm_dspcfg.cmd"  "./host_ipc/fm_dsp_sharedmem.obj" "./host_ipc/fm_dsp_ipc.obj" "./taylor_exp.obj" "./sinet.obj" "./memtest.obj" "./fm_dsp_params.obj" "./fm_dsp_main.obj" "./fm_dspcfg_c.obj" "./fm_dspcfg.obj" "./fir_fast.obj" "./dsp_absmax.obj" "./dave.obj" "./DSP_printf.obj" -l"fastrts64x.lib" -l"dsp64x.lib" -l"csl6415.lib" "../fm_dsp_lnk_debug.cmd" 

    <Linking>

    error: symbol "__divf" redefined: first defined in "C:/Program Files/Texas

       Instruments/C6000 Code Generation Tools 6.1.11/lib/rts6400.lib<divf.obj>";

       redefined in "C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<divsp.obj>"

    error: symbol "__mpyf" redefined: first defined in "C:/Program Files/Texas

       Instruments/C6000 Code Generation Tools 6.1.11/lib/rts6400.lib<mpyf.obj>";

       redefined in "C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<mpysp.obj>"

    warning: Symbol "__addd" (pulled from "C:/Program Files/Texas Instruments/C6000

       Code Generation Tools 6.1.11/lib/rts6400.lib<addd.obj>") defined in 2

       places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<addd.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<adddp.obj>

     

    warning: Symbol "__addf" (pulled from "C:/Program Files/Texas Instruments/C6000

       Code Generation Tools 6.1.11/lib/rts6400.lib<addf.obj>") defined in 2

       places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<addf.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<addsp.obj>

     

    warning: Symbol "__auto_init" (pulled from "C:/Program Files/Texas

       Instruments/bios_5_40_02_22/packages/ti/bios/lib/bios.a64<autoinit.o64>")

       defined in 2 places: 

       C:/Program Files/Texas

       Instruments/bios_5_40_02_22/packages/ti/bios/lib/bios.a64<autoinit.o64>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<autoinit.obj>

     

    warning: Symbol "__cvtfd" (pulled from "C:/Program Files/Texas

       Instruments/C6000 Code Generation Tools 6.1.11/lib/rts6400.lib<cvtfd.obj>")

       defined in 2 places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<cvtfd.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<spdp.obj>

     

    warning: Symbol "__divd" (pulled from "C:/Program Files/Texas Instruments/C6000

       Code Generation Tools 6.1.11/lib/rts6400.lib<divd.obj>") defined in 2

       places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<divd.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<divdp.obj>

     

    warning: Symbol "__divf" (pulled from "C:/Program Files/Texas Instruments/C6000

       Code Generation Tools 6.1.11/lib/rts6400.lib<divf.obj>") defined in 2

       places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<divf.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<divsp.obj>

     

    warning: Symbol "__fixdi" (pulled from "C:/Program Files/Texas

       Instruments/C6000 Code Generation Tools 6.1.11/lib/rts6400.lib<fixdi.obj>")

       defined in 2 places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<fixdi.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<dpint.obj>

     

    warning: Symbol "__fixdli" (pulled from "C:/Program Files/Texas

       Instruments/C6000 Code Generation Tools 6.1.11/lib/rts6400.lib<fixdli.obj>")

       defined in 2 places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<fixdli.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<dplong.obj>

     

    warning: Symbol "__fixfi" (pulled from "C:/Program Files/Texas

       Instruments/C6000 Code Generation Tools 6.1.11/lib/rts6400.lib<fixfi.obj>")

       defined in 2 places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<fixfi.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<spint.obj>

     

    warning: Symbol "__fixfu" (pulled from "C:/Program Files/Texas

       Instruments/C6000 Code Generation Tools 6.1.11/lib/rts6400.lib<fixfu.obj>")

       defined in 2 places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<fixfu.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<spuint.obj>

     

    warning: Symbol "__fltif" (pulled from "C:/Program Files/Texas

       Instruments/C6000 Code Generation Tools 6.1.11/lib/rts6400.lib<fltif.obj>")

       defined in 2 places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<fltif.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<intsp.obj>

     

    warning: Symbol "__fltlid" (pulled from "C:/Program Files/Texas

       Instruments/C6000 Code Generation Tools 6.1.11/lib/rts6400.lib<fltlid.obj>")

       defined in 2 places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<fltlid.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<longdp.obj>

     

    warning: Symbol "__fltuf" (pulled from "C:/Program Files/Texas

       Instruments/C6000 Code Generation Tools 6.1.11/lib/rts6400.lib<fltuf.obj>")

       defined in 2 places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<fltuf.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<uintsp.obj>

     

    warning: Symbol "__mpyd" (pulled from "C:/Program Files/Texas Instruments/C6000

       Code Generation Tools 6.1.11/lib/rts6400.lib<mpyd.obj>") defined in 2

       places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<mpyd.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<mpydp.obj>

     

    warning: Symbol "__mpyf" (pulled from "C:/Program Files/Texas Instruments/C6000

       Code Generation Tools 6.1.11/lib/rts6400.lib<mpyf.obj>") defined in 2

       places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<mpyf.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<mpysp.obj>

     

    warning: Symbol "__stack" (pulled from "C:/Program Files/Texas

       Instruments/bios_5_40_02_22/packages/ti/bios/lib/bios.a64<boot.o64>")

       defined in 2 places: 

       C:/Program Files/Texas

       Instruments/bios_5_40_02_22/packages/ti/bios/lib/bios.a64<boot.o64>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<boot.obj>

     

    warning: Symbol "__subd" (pulled from "C:/Program Files/Texas Instruments/C6000

       Code Generation Tools 6.1.11/lib/rts6400.lib<subd.obj>") defined in 2

       places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<subd.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<adddp.obj>

     

    warning: Symbol "__subf" (pulled from "C:/Program Files/Texas Instruments/C6000

       Code Generation Tools 6.1.11/lib/rts6400.lib<subf.obj>") defined in 2

       places: 

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<subf.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/c6400/mthlib/lib/fastrts64x.lib<addsp.obj>

     

    warning: Symbol "_c_int00" (pulled from "C:/Program Files/Texas

       Instruments/bios_5_40_02_22/packages/ti/bios/lib/bios.a64<boot.o64>")

       defined in 2 places: 

       C:/Program Files/Texas

       Instruments/bios_5_40_02_22/packages/ti/bios/lib/bios.a64<boot.o64>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<boot.obj>

     

    error: errors encountered during linking; "fm_dsp_scratch.out" not built

    --------------------------------

    From link step under CCS V3

    <Linking>

    warning: Symbol "__addd" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<adddp.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<adddp.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<addd.obj>

     

    warning: Symbol "__addf" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<addsp.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<addsp.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<addf.obj>

     

    warning: Symbol "__auto_init" (pulled from

       "C:/CCStudio_v3.3/bios_5_33_03/packages/ti/bios/lib/bios.a64<autoinit.o64>")

       defined in 2 places:

       C:/CCStudio_v3.3/bios_5_33_03/packages/ti/bios/lib/bios.a64<autoinit.o64>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<autoinit.obj>

     

    warning: Symbol "__cvtfd" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<spdp.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<spdp.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<cvtfd.obj>

     

    warning: Symbol "__divd" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<divdp.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<divdp.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<divd.obj>

     

    warning: Symbol "__divf" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<divsp.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<divsp.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<divf.obj>

     

    warning: Symbol "__fixdi" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<dpint.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<dpint.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<fixdi.obj>

     

    warning: Symbol "__fixdli" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<dplong.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<dplong.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<fixdli.obj>

     

    warning: Symbol "__fixfi" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<spint.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<spint.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<fixfi.obj>

     

    warning: Symbol "__fixfu" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<spuint.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<spuint.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<fixfu.obj>

     

    warning: Symbol "__fltif" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<intsp.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<intsp.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<fltif.obj>

     

    warning: Symbol "__fltlid" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<longdp.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<longdp.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<fltlid.obj>

     

    warning: Symbol "__fltuf" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<uintsp.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<uintsp.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<fltuf.obj>

     

    warning: Symbol "__mpyd" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<mpydp.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<mpydp.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<mpyd.obj>

     

    warning: Symbol "__mpyf" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<mpysp.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<mpysp.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<mpyf.obj>

     

    warning: Symbol "__stack" (pulled from

       "C:/CCStudio_v3.3/bios_5_33_03/packages/ti/bios/lib/bios.a64<boot.o64>")

       defined in 2 places:

       C:/CCStudio_v3.3/bios_5_33_03/packages/ti/bios/lib/bios.a64<boot.o64>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<boot.obj>

     

    warning: Symbol "__subd" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<adddp.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<adddp.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<subd.obj>

     

    warning: Symbol "__subf" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<addsp.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<addsp.obj>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<subf.obj>

     

    warning: Symbol "_c_int00" (pulled from

       "C:/CCStudio_v3.3/bios_5_33_03/packages/ti/bios/lib/bios.a64<boot.o64>")

       defined in 2 places:

       C:/CCStudio_v3.3/bios_5_33_03/packages/ti/bios/lib/bios.a64<boot.o64>

       C:/Program Files/Texas Instruments/C6000 Code Generation Tools

       6.1.11/lib/rts6400.lib<boot.obj>

     

    warning: Symbol "_divc30" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<divdp.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<divdp.obj>

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<divc30.obj>

     

    warning: Symbol "_flt64" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<divdp.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<divdp.obj>

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<flt64.obj>

     

    warning: Symbol "_mpy62" (pulled from

       "C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<divdp.obj>") defined in 2

       places: 

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<divdp.obj>

       C:/CCStudio_v3.3/c6400/mthlib/lib/fastrts64x.lib<mpy62.obj>

     

     

    Build Complete,

      0 Errors, 22 Warnings, 0 Remarks.

      Please view the build output for errors and warnings for any custom steps.

    fm_dsp.zip
  • I was able to install the 6.1.12 version of the tools. The same problem exists. This has to be either something with the way that CCSV4 builds the command line, or it has to be something in the DSP/BIOS 5.40 library files that case the linker behavior to be different.

    Dan

     

  • I think you have found an esoteric bug in the linker.  The bug is exposed by some difference in how CCSv4 invokes the linker.  I have failed to reproduce what you see.  At this point, the idea is to somehow reproduce the problem without requiring you to send in everything, because that's hard to do.  Please post the linker command files referenced when you link.  That may help me reproduce it.  Note that the CCSv4 build refers to two different link command files, while the CCSv3.3 build only refers to one. 

    Sorry for all the trouble.

    Thanks and regards,

    -George

     

  • Attached you will find all the make files and .cmd files I readily identified. Some come from the "Debug" folder and some come from the project root folder. Hopefully you will know which is which.

    Regards,

    Dan

     

    linker_bug.zip
  • Hi George,

    Like you I could not reproduce this exact problem in a small project. However, I was able to reproduce at least part of the problem. I have attached a small project that builds "incorrectly" in that it refuses to use the duplicate symbols from the fastrts64x.lib file. Instead it always favors the rts6400.lib versions of the objects which is "incorrect". This may in fact be the same bug. I hope it helps.

    Regards,

    Dan

     

    fastrts.zip
  • This doesn't show the problem.  Though it does hint at it.  In this simple example, your final link statement does the equivalent of the following ...

    --reread_libs
    *.obj
    fastrts64x.lib
    rts6400.lib

    Check the attachment to see what happens in this case.  That is an old set of slides about how symbolic references are resolved in libraries.  Note -x is the same as --reread_libs.  Kinda confusing, isn't it?  In this case, _divsp is referenced in one of the .obj files, so it comes from fastrts64x.lib.  The __add routine, however, is only referenced (through many other layers) from printf.  printf comes in only when rts6400.lib is being searched.  According to the rules of -x, if rts6400.lib contains an implementation of __add (which it does), then that is the one that is used. 

    Note that -priority works as you expect.  If you use -priority, then __add, even though referenced only from rts6400.lib, comes from fastrts64x.lib.  -priority is the only one I don't have to think about.  All the others give me headaches.

    In your bigger examples, much more is going on.  And one of those extra still unidentified things is causing the problem.  I notice that the BIOS auto-generated link command file uses the -priority option.  So, try this.  Change the project level link options to use neither --reread_libs or -priority.  I think there is a good chance that will work.  No promises!

    Thanks and regards,

    -George

     

    lib_ref_order.pdf
  • George,

    This answer was very helpful. I was able to find a workaround. The problem first appears in the file ./debug/fm_dspcfg.cmd where there is a reference to the rts6400.lib file. The offending line was at the end of this sequence:

    -priority

    --trampolines

    -llnkrtdx.a64

    -ldrivers.a64 /* device drivers support */

    -lsioboth.a64 /* supports both SIO models */

    -lbiosC6000.a64 /* BIOS clock specific library */

    -lbios.a64 /* DSP/BIOS support */

    -lrtdxsim.lib /* RTDX support */

    -lrts6400.lib /* C and C++ run-time library support */

     

     

    As I understand it "./debug/fm_dspcfg.cmd" is created from "fm_dsp.tcf". Within the TCF file the following line appears (with no opposing line later):

     

    bios.GBL.SPECIFYRTSLIB = 0;

    This line exists because in the "Global Settings" property sheet of the .TCF file the option "specify runtime library" is not checked.

    Therefore, I think that this line should prevent the TCF compiler from including the line "-lrts6400.lib" in fm_dspcfg.cmd. Or is there some other option selected that causes the TCF compiler to include this line by default? If there is I could not find it. I believe this is the "bug" we have been looking for.

    There is a workaround as follows:

    Check the "Global Settings" in the property sheet of the .TCF file and specify the runtime library explicitly as "fastrts64x.lib". This is a "white lie" but we fix it later by making sure that the real runtime library "rts6400.lib" is specified as the last library in the "Tool Settings->C6000 Linker->File Search Path" in the "Include library file" list. Using this workaround the project builds with no errors. Even better, the linker pulls all of the floating point code from fastrts64x.lib instead of rts6400.lib just as it did under CCSV3.3.

    I feel fairly sure this is a bug related to CCSv4 but I cannot tell you which element of the build process is at fault. Something happens on the way from "./fm_dsp.tcf" to "./debug/fm_dspcfg.cmd" and the default library gets inserted incorrectly into the auto-generated .cmd file. Because the library name appears first to the linker it overrides any duplicate symbols that might come later.

    Your persistence has paid off for me and I thank you. For me this problem is "solved".

     

     

  • I had another customer mention a very similar issue.  They weren't getting the linker errors (nor could I reproduce that issue) but were having issues getting the fastrts functions linked into the final build.  This issue resolves around the order in which the libraries are passed to the linker.  Back in your initial post I see that in CCS 3.3 the fastrts library was being passed to the linker prior to the generated linker command file from BIOS.  That's the key step.

    In CCS 4 you can specify the link order as follows:

    • Right-click on the project and click Properties
    • Click on CCS Build
    • Click Link Order
    • Click "Add" and then add the fastrts library.
    • Click "Add" again and add "Generated Linker Command Files"

     

    Now the resulting build will be something like this:

    'Building target: dm6437_bios_hello_world.out'
    'Invoking: Linker'
    "C:/Program Files/Texas Instruments/ccsv4/ccsv4/tools/compiler/C6000 Code Generation Tools 6.1.14/bin/cl6x" -mv64+ -g --diag_warning=225 -z -m"dm6437_bios_hello_world.map" --warn_sections -i"C:/Program Files/Texas Instruments/ccsv4/ccsv4/tools/compiler/C6000 Code Generation Tools 6.1.14/lib" -i"C:/ti/c6000/62x64xfastrts/c6400/mthlib/lib" -i"C:/Program Files/Texas Instruments/ccsv4/ccsv4/tools/compiler/C6000 Code Generation Tools 6.1.14/include" -i"C:/Program Files/Texas Instruments/ccsv4/bios_5_41_00_06/packages/ti/rtdx/lib/c6000" -i"C:/Program Files/Texas Instruments/ccsv4/bios_5_41_00_06/packages/ti/bios/lib" --reread_libs --rom_model -o "dm6437_bios_hello_world.out" -l"fastrts64x.lib" -l"./bioscfg.cmd"  "./main.obj" "./bioscfg_c.obj" "./bioscfg.obj"

    I hope perhaps that clarifies for some other people in the future!  To the original poster, sorry I didn't try this out a little sooner though I'm glad you figured out a suitable solution even if it was a bit of a hack! ;)

     

     

     

     

  • Older version of CodeComposer 4 installed on my machine had this option and I could build the project with BIOS 5.4.xx.

    New installation just does not have the option to specify "Generated Linker Command Files". It does not exists in "Link Order"-"Add" dialog. Was it removed in recent versions?

    If so, how can I resolve this issue now?

    Thank you in advance

  • What version of CCS are you using?  I just checked in CCS 4.2.0 and the ability to use "Generated Linker Command FIles" still exists.  I'm updating to 4.2.1 right now.

  • I just updated to 4.2.1 and I still see the option.  Please attach a screenshot of what you see when you click "Add".

  • Now, that TI's auth mechanism is back up, I may post a response.

    After additional testing, I undrestood that I was wrong and the CC that does not have "Generated Linker Command Files" is the CC 4.0 and not 4.2.

    And it does not want to upgrade itself via the "Help"-"Software Updates". Was this option present in some form in 4.0?

    Thank you in advance,

  • I'm not sure if that was present in CCS 4.0 in some other form.  I assume that if it's not where you're looking that it's not there at all in CCS 4.0.  Your best bet is definitely to upgrade to the latest.  There have been MANY fixes and improvements.  In terms of your upgrade issues, when the box comes up asking if you want to search for updates to currently installed products or look for new products, make sure you click the "new" products.  When you choose "currently installed" it will only show you 4.0.x updates but if you select "new" then you should see an option for 4.2.x.  I can't remember if it will update you directly to 4.2.1 or if it goes first to 4.2.0 and then you have to do another update to 4.2.1.  If that's the case it's probably faster/better to just download and install the latest (4.2.1) directly.

    http://processors.wiki.ti.com/index.php/Download_CCS