dspguy This might be off-topic, but do you have a good tip on measuring cycles / performance or profiling in general on the bbb/bela? I've found a thread about cycle counting on ARM on SO, but activating it on the cpu requires you to build a module for the kernel, and I have tried to do so, but I can't fit the kernel on my bbb's sd card, so I'm going to struggle trying to build that on my mac with the cross-compiler unless there is an alternative.
I have not tried any of that yet. When I need to measure the execution time of a piece of code I tend to toggle memory mapped GPIOs and look at the result on a scope. However, as far as I can understand from the page you linked, you need to build a kernel module (not necessarily the whole kernel). So I would recommend you install a slightly more updated kernel I compiled a while ago which comes with kernel headers:
- download the zip archive
- copy it to the board
unzip xenomai-r81-interrupts-virmidi.zip && rm xenomai-r81-interrupts-virmidi.zip
- needless to say, backup your important files before doing the following
(may take a few minutes, especially when installing the headers)
for a in linux-*3.8.13xenomai-xenomai-r81_1cross_armhf.deb;
dpkg -i $a;
rm $a; done;
mv /boot/uboot/zImage /boot/uboot/zImage.bak
cp /boot/vmlinuz-3.8.13xenomai-xenomai-r81 /boot/uboot/zImage
- if you are lucky enough that it reboots (lol), you can check you are running the new kernel:
root@bela ~$ uname -a
Linux bela 3.8.13xenomai-xenomai-r81 #4 Wed Oct 26 20:25:54 BST 2016 armv7l GNU/Linux
Once the above is done, you will have a slightly more recent kernel and its kernel headers, so you should be able to compile a kernel module that enables the cycle counter as you need.
I'd be happy to hear back if you get it to work.