I recently bought a Cosina (Vivitar branded) 24mm 2.8, Sigma 24mm 2.8 macro, and Nikon E series 28mm 2.8 lens in the same set, all with Nikon mounts. I compared all of them and the Cosina was far superior in both contrast and sharpness. It wasn’t even close. That was good with me, as it was the least valuable of the bunch! I sold the other two and kept the Cosina and made a bit of profit.
I think it comes down to the individual lens, but I think my experience proves that Cosina did make at least a few good lenses, especially if you consider price. Still, I probably wouldn’t buy one outright without a bit of research, or the ability to try it out first. I’m sure there are a few duds out there as well.