After more thought and analysis it turns out some advice on this link is not so good.
Enabling trim using discard in fstab turns out to harm performance since it trims after every delete and is unnecessary as trim is performed by a cron job weekly in Ubuntu 14.04 if you have and Intel or Samsung SSD (and can be enabled for other SSDs too). If weekly is not often enough for you then make it daily or on boot.
Moving /tmp to RAM if /tmp is your swap (the PI default) is the same as using a ram disk for swap: you trade speed for swap space. Most of us do not have enough RAM to make this a good trade. If I remember correctly you want 40-60 GB of swap.