Fix libpayload alloc() size and gcc pointer optimization problems.