use st_add and st_mult for allocation size computation