* sdk: Add get_instance_packed_len for variable-size types * Add comment for get_packed_len * Add more tests