<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hi,<br><br>Short:&nbsp;<br>Does anyone know offhand of pitfalls trying to make system calls through pipes via FFI from Squeak on Linux (Ubuntu 14.04 on ARM if it makes a difference)?<br><br>Long:<br>I’ve been having fun playing with the Parallella board [1]. The Parallella board has a Xilinx dual-core ARMv7 with a small FPGA, and an Epiphany coprocessor which has 16 RISC cores.<br><br>I managed to get a CogStackVM running on (one of the) ARM cores. Based on Tim’s CogStackVM for the RPi (ARMv6), I made some hacks to get it working on the BeagleBoneBlack (ARMv7). This ARMv7 version was compiled on a Chromebook by Ken Dickey where it magically worked, and now by me on the Parallella where it also “just works”.&nbsp;<br><br>So I wanted to see if I could fire up any of the Epiphany cores. I loaded Squeak OpenCL FFI bindings [2] (very cool) and have been able to do some very simple things such as query the Epiphany capabilities, and create Epiphany buffers and write/read them. So far so good.<br><br>If you want to induce any of the Epiphany’s cores to do some actual work, you have to provide some code (kernel in OpenCL-speak). These can be compiled and loaded on the fly by an OpenCL library API. This is where I am stuck.<br><br>The OpenCL library for the Parallella is open source so I can see exactly where things go wrong. When the kernel compile API is called, it performs its work by making a bunch of system calls via popen(&lt;cmd&gt;, “r”). None of these works; both Squeak and the command are deadlocked once the first popen() call is made. I rebuilt the OpenCL library from sources with debug enabled, as well as added some additional debug prints.&nbsp;<br><br>In order to communicate with the Epiphany, processes need to be run as root, thus I am running Squeak as root for these tests. And since Squeak is running as root I don’t suspect permission problems getting access to commands and files.<br><br>The OpenCL library for Parallella compiles kernels successfully for test programs written in C, so /it/ should be ok. And the Squeak OpenCL bindings seem to work fine (insofar as I have played with them;&nbsp;that alone is a lot of fun :)) on a Mac with GPU.<br><br>I know the question is vague, and I’m sure I haven’t provided nearly enough info, but thought I would throw it out there :)&nbsp;<br><br>Thanks!<br>Doug<br><br>[1]&nbsp;<a href="http://www.parallella.org/">http://www.parallella.org</a><br>[2]&nbsp;<a href="https://sites.google.com/site/schwaj/home/opencl-binding-for-squeak">https://sites.google.com/site/schwaj/home/opencl-binding-for-squeak</a><br></body></html>