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.

Is the simulation status right?

Other Parts Discussed in Thread: SYSBIOS

Hi,

I am simulating the example Notify project on CCS v5.2, Windows 7, 64 bit. I have group and synchronize the 6 cores. When I go to the debug perspective, only core 0 shows main() and c_int0() while other cores are different. I have tried several options with no avail. Please see the picture below.

 

Becaues the run results are wrong, I suspect the program loading is incorrect. Thanks.

  • Hi,

    The automatic generated .cfg file is listed below. Hope it is helpful for my question.

     

     

    .................

    var MultiProc = xdc.useModule('ti.sdo.utils.MultiProc');

    switch (Program.platformName) {

    case "ti.sdo.ipc.examples.platforms.evm6472.core0":

    var nameList = ["CORE0", "CORE1", "CORE2", "CORE3", "CORE4", "CORE5"];

           

    /*

             *  NOTE: On c6472, region 0 needs to be placed SL2 RAM because of the

             *  requirement that all GateMP created on this device use SL2 RAM

             *  shared memory.

             */

           

    var sharedMem       = 0x00200000;

    var sharedMemSize   = 0x000C0000;

    /* SL2 memory uses a cache line size of 64 */

    var cacheLineSize   = 64;

    break;

    case "ti.sdo.ipc.examples.platforms.evm6474.core0":

    var nameList = ["CORE0", "CORE1", "CORE2"];

    var sharedMem       = 0x80000000;

    var sharedMemSize   = 0x00200000;

    var cacheLineSize   = 128;

    break;

    }

    /*

    *  Since this is a single-image example, we don't (at build-time) which

    *  processor we're building for.  We therefore supply 'null'

    *  as the local procName and allow IPC to set the local procId at runtime.

    */

    MultiProc.setConfig(

    null, nameList);

    var System   = xdc.useModule('xdc.runtime.System');

    var SysStd   = xdc.useModule('xdc.runtime.SysStd');

    System.SupportProxy = SysStd;

    /* Modules explicitly used in the application */

    var Notify      = xdc.useModule('ti.sdo.ipc.Notify');

    var Ipc         = xdc.useModule('ti.sdo.ipc.Ipc');

    var BIOS        = xdc.useModule('ti.sysbios.BIOS');

    BIOS.heapSize   = 0x8000;

    var Task        = xdc.useModule('ti.sysbios.knl.Task');

    var tsk0 = Task.create('&tsk0_func');

    tsk0.instance.name ="tsk0";

    /* To avoid wasting shared memory for MessageQ transports */

    for (var i = 0; i < MultiProc.numProcessors; i++) {

        Ipc.setEntryMeta({

            remoteProcId: i,

            setupMessageQ: false,

        });

    }

    /* Synchronize all processors (this will be done in Ipc_start) */

    Ipc.procSync = Ipc.ProcSync_ALL;

    /*

    *  Need to define the shared region. The IPC modules use this

    *  to make portable pointers. All processors need to add this

    *  call with their base address of the shared memory region.

    *  If the processor cannot access the memory, do not add it.

    */

    var SharedRegion = xdc.useModule('ti.sdo.ipc.SharedRegion');

    SharedRegion.setEntryMeta(0,

        { base: sharedMem,

          len:  sharedMemSize,

          ownerProcId: 0,

          isValid: true,

          cacheLineSize: cacheLineSize,

          name: "SHARED_RAM",

        });

    /* Create a semaphore with count 0 */

    var Semaphore = xdc.useModule('ti.sysbios.knl.Semaphore');

    Program.global.semHandle = Semaphore.create(0);

  • It seems that group and synchronose do not support loading function in simulator because it succeeds when I load the cores one by one.

    Now a new question arises. After loading, I run the cores one after one. There are messages in the control windows below. Why does it fail in the core 1 to core 2 sending message? BTW, yesterday it accidently gets the similar result (stopped at core 1 to core 2). How to dig deeper?

     

    Thanks.

    ..........

    [C64+_0] main: MultiProc id = 0

    [C64+_0] main: MultiProc name = CORE0

    [C64+_1] main: MultiProc id = 1

    [C64+_1] main: MultiProc name = CORE1

    [C64+_2] main: MultiProc id = 2

    [C64+_2] main: MultiProc name = CORE2

    [C64+_3] main: MultiProc id = 3

    [C64+_3] main: MultiProc name = CORE3

    [C64+_4] main: MultiProc id = 4

    [C64+_4] main: MultiProc name = CORE4

    [C64+_5] main: MultiProc id = 5

    [C64+_5] main: MultiProc name = CORE5

    [C64+_0] tsk1_func: Sent request #0 to CORE1

    [C64+_1] tsk1_func: Received request #1 from CORE0

    [C64+_1] sendEvent failed