use patmos_preserve_tmp and patmos_preserve_ret attributes