A Godement-type decomposition for positive definite functions