[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4688: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4690: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4691: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4692: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
Parallella Community • View topic - Data transfer between epiphany cores

Data transfer between epiphany cores

Discussion about Parallella (and Epiphany) Software Development

Moderators: amylaar, jeremybennett, simoncook

Data transfer between epiphany cores

Postby gordon » Mon Jun 05, 2017 6:56 am

I am writing a program for eigenvalue decomposition of a matrix. For this case I am dividing the work to the 16 epiphany cores using eSDK. But by algorithm involves the data transfer between the cores. I am first running a device program say "epipany_task1" only on the diagonal cores of the epiphany module. The program returns four float values each from one core. Now I need to send these float values to other non diagonal cores to be inputted for another function say "epiphany_task2" which runs on the non diagonal cores after "wpiphany_task1" has finished running on all four diagonal cores.Each non diagonal core gets two float values, one from the row diagonal core and other from column diagonal core.Is there an external memory accessible to the epiphany cores from where I can write these float values and later read them. Or can I read the float values to host processor and then write them to the non diagonal cores in the host code?

Thanks in advance! :)
gordon
 
Posts: 24
Joined: Mon May 29, 2017 10:37 am

Re: Data transfer between epiphany cores

Postby sebraa » Mon Jun 05, 2017 9:53 am

All cores share the same address space, so you can just generate a pointer to some other core's memory and write your values there (make sure you understand the special properties of such accesses, and where you may need a 'volatile' keyword).

You can use shared memory to communicate data between the cores, but the performance is extremely bad. Don't do it.
sebraa
 
Posts: 495
Joined: Mon Jul 21, 2014 7:54 pm

Re: Data transfer between epiphany cores

Postby gordon » Tue Jun 06, 2017 4:24 am

What special accesses are you exactly referring to? Since each core has its own 32KB of memory, how do I specify a pointer say *a to a particular core say with core_id(2,0). I can e_write the pointer to the memory address in host program, but how do I use it in the device program? Can you please elaborate a little. Thanks!
gordon
 
Posts: 24
Joined: Mon May 29, 2017 10:37 am

Re: Data transfer between epiphany cores

Postby sebraa » Tue Jun 06, 2017 9:09 pm

sebraa
 
Posts: 495
Joined: Mon Jul 21, 2014 7:54 pm


Return to Programming Q & A

Who is online

Users browsing this forum: No registered users and 11 guests

cron