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.

Task_Handle in bios 6.35.01.29

While evaluating CCS 5.4.0 I encountered a problem in our code (which works with CCS 5.1.1 and CCS 5.2.0) and traced it back to the handling of Task_Handle in bios 6.35.01.29

I have the following example code:


#include <ti/sysbios/knl/Task.h>

int main()
{
    Task_Handle tskhandle;
    
    int prio = tskhandle->priority;

    return 0;
}


When compiling this as main.cpp with CCS 5.4.0 (c6000 7.4.2 as example, xdctools 3.25.00.48, bios 6.35.01.29) it fails with the output

    "main.cpp", line 7: error: pointer to incomplete class type is not allowed
    "main.cpp", line 7: warning: variable "tskhandle" is used before its value is set
    1 error detected in the compilation of "main.cpp".

    >> Compilation failure

Command line I used:

/opt/ti_5.4.0/ccsv5/tools/compiler/c6000_7.4.2/bin/cl6x -mv6740 --gcc -I/opt/ti_5.4.0/ccsv5/tools/compiler/c6000_7.4.2/include -I/opt/ti_5.4.0/bios_6_35_01_29/packages/ -I /opt/ti_5.4.0/xdctools_3_25_00_48/packages/ --abi=eabi main.cpp

If I just switch to the bios from CCS 5.1.1(for example, version is 6.32.05.54) I can compile the code successfully. Output is just the warning:

"main.cpp", line 7: warning: variable "tskhandle" is used before its value is set

Here I used this command line:

/opt/ti_5.4.0/ccsv5/tools/compiler/c6000_7.4.2/bin/cl6x -mv6740 --gcc -I/opt/ti_5.4.0/ccsv5/tools/compiler/c6000_7.4.2/include -I/opt/ti_5.1.1/bios_6_32_05_54/packages/ -I /opt/ti_5.4.0/xdctools_3_25_00_48/packages/ --abi=eabi main.cpp