Comparative Study on Dynamical Heterogeneity of Ring and Linear Polymers