Further optimized serialization