Jpg files don't need to be lossy. But then they also lose most of the benefits. Even so, one can have a cmyk jpg file and cannot have a cmyk png. Even with a good degree of compression from an actual image editor, if the high quality option is used in conjunction and the image is not going to opened and resaved, jpg is still a decent option.