cl implementation of dg mass