Architectures/ARM/Performance

This page is a collection of tips and hacks that may increase the performance of your ARM platform, whether for interactive use or as a build platform. Please feel free to add your own findings to the list! Some of these tips are platform-specific, but please try to use platform-independent wordings for platform-independent tips.

= Storage =

Benchmark your tasks against SDcard, NFS, and SATA/USB to see which is fastest for your platform. Tweaks to /proc/sys/vm/dirty* may allow you to defer writes long enough to avoid delays.

= Builds =

If you have enough RAM, consider using a ramdisk for /tmp, using something like this in your /etc/fstab:

tmpfs /tmp tmpfs defaults 0 0

If you have a fast desktop machine available, and you aren't building for an official Fedora release, consider using a cross compiler on that machine in conjunction with distcc. Here's a patch you need to the server side, substitute your own paths of course:

diff -p -U 1 distcc-2.18.3/src/arg.c distcc-2.18.3-dj/src/arg.c --- distcc-2.18.3/src/arg.c    2004-11-30 07:13:53.000000000 -0500 +++ distcc-2.18.3-dj/src/arg.c 2011-05-16 16:12:58.000000000 -0400 @@ -149,2 +149,16 @@ int dcc_scan_args(char *argv[], char **i +#define ARMV5PATH "/home/dj/ges/arm/install/bin/armv5tel-redhat-linux-gnueabi-" +#define ARMPATH "/home/dj/ges/arm/hardfp/install/bin/armv7hl-redhat-linux-gnueabi-" +   if (strcmp (argv[0], "gcc") == 0 +       || strcmp (argv[0], "cc") == 0) { +        argv[0] = strdup( ARMPATH "gcc"); +    } +    if (strcmp (argv[0], "g++") == 0 +       || strcmp (argv[0], "c++") == 0) { +        argv[0] = strdup(ARMPATH "g++"); +    } +    if (strcmp (argv[0], "as") == 0) { +        argv[0] = strdup(ARMPATH "as"); +    } +     for (i = 0; (a = argv[i]); i++) {

I run the server side manually so I can tell when it's being used properly:

./distv5ccd.bin -p 3632 -a 192.168.42.0/24 --no-detach --log-stderr --daemon -j 12

You then configure the client as if the server were another ARM platform. Make sure you install a cross-compiler built with the same sources (or at least the same gcc version) and options (target) as the ARM platform. The client does the preprocessing and linking, while the server does the compilation and assembly. You may be able to increase the "make -j" factor as well.

= Computation =

= USB/Networking =

This is specific to the OMAP4 platforms, I found it on the pandaboard - the USB subsystem seems to be missing events! If you ping your platform from another machine, or otherwise cause events to happen on the USB port, these missed events are handled sooner, which can drastically improve performance of USB peripherals, such as ethernet gadgets or SATA docking ports.

sudo ping -i 0.01 -q armboard.localdomain