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 OpenMP compatible with other SYS/BIOS modules?

Hello OpenMP Support Team!

I was going through the OpenMP example Configuration file posted here (LINK), and I read the OpenMP Wiki page (link).

My question is:  does SYS/BIOS OpenMP "play nice" with the other 'standard' SYS/BIOS Modules?  For example, SysMin, Task, Semaphore, Timestamp, Error, Diags, etc?

   

Earlier today I was trying to combine the Hello World OpenMP example and place it in a SYS/BIOS thread, to run that thread across 4 cores.  I ran into various roadblocks along the way, and as I think about how OpenMP works, it seems like the OpenMP SYS/BIOS Module is independent from the SYS/BIOS implementation found in, say, a CCS SYS/BIOS "typical" example project.

I'm hoping to learn here, I greatly appreciate any help!

P.s. I'm posting in the Compiler forum - not the RTOS forum - based on the suggestions of the OpenMP with C6000 Wiki.

  • Chris Jagielski said:
    does SYS/BIOS OpenMP "play nice" with the other 'standard' SYS/BIOS Modules?

    Unfortunately, no.

    -George

  • Thanks George.

    So, to make sure I understand the OpenMP functionality here... is using OpenMP almost like an "all or nothing" approach?

    In my application, my DSPs are acting as a sort of "accelerator" for my Host PC.  I need the RTOS capabilities from SYS/BIOS, mainly for real-time I/O between my DSP card and my PC (via PCIe).

    Does it make sense to use OpenMP in a real-time system?  Perhaps I need to rethink my overall software architecture.

    Thank you so much for your time and guidance!

  • Chris,

    The intent is for OpenMP to "play nice" with other BIOS modules. For example, run OpenMP on, say, 4 cores of the C6678 and other application code on the remaining cores. However, it's possible that the configuration of some of these BIOS/IPC modules within the OpenMP runtime interferes or conflicts with what is required by the application. For example, the OpenMP runtime executes the main function as a BIOS task.

    It would really help us if you could summarize the issues you faced integrating OpenMP into your example BIOS application.

    Thanks,

    Ajay

  • Ajay, thanks for your response.

    I believe the first (major) issue I encountered was attempting to "merge" the C6678 OpenMP Hello World example with the "typical" SYS/BIOS example.  So, I tried to put the OpenMP #pragma, etc. code inside a SYS/BIOS Thread.  Obviously that didn't work, and it makes sense based on what you're saying.

    Ajay Jayaraj said:

    For example, run OpenMP on, say, 4 cores of the C6678 and other application code on the remaining cores.

    This seems exactly what I would like to do.  Since both types of applications could easily use IPC, would IPC (i.e. "IPC Notify") be the communication method of choice for the different applications?

    How does this architecture idea look to you?

    • Core 0:   it will communicate (via PCIe) to my host PC ... (perhaps using Desktop Linux SDK?)
    • Core 1-5:  together they will run one algorithm, via OpenMP, and communicate to Core 0 via IPC
    • Core 6:  it will run another separate algorithm, on SYS/BIOS, and can communicate to Core 0 a number of different ways
    • Core 7-8:  together they will run one algorithm, via OpenMP and communicate via IPC
    • *Cores 9-31: much of the same.... my hardware is the Advantech 8681 with 4x C6678 => 32 total cores.  I have a number of different algorithms to implement and on each DSP device I will probably have a similar set-up as above

    Thank you again for your help!

  • Chris,

    The OpenMP runtime supports the partitioning of algorithms to cores you describe. I'm not an IPC expert - my reading of the IPC User Guide indicates that you'll have to set up multiple IPC clusters using MultiProc - for example, in your architecture, cores 1-5 are in one cluster and 7-8 in another cluster (See IPC User Guide, Section 3.3.1: Configuring Clusters With the MultiProc Module).

    Section 3.3.1 also indicates that notification is not supported between clusters and describes how a connection can be created between clusters.

    Ajay

  • Thank you Ajay & George.  This is all clear to me now.