store spl_num_atoms in global