There is a formula to calculate damage, a pokemon deals. It can be found here.
https://pokemongo.gamepress.gg/damage-mechanics
If you just ignore
- rounding
- moveset
- stab
- type-bonus
you can deduce, that a plain multiplication of att, def and sta stat is the measure to compare damage a pokemon deals until it faints.
This is not exactly CP, because in CP, Def and Sta are square rooted before multiplication.
This means, attack stat is evaluated higher in CP than it should be from a "damage done until pkm faints" point of view.
Nevertheless, i like CPs to evaluate attackers, because this formula takes into account that "damage done until pkm faints" is not everything, killspeed matters too, and the higher evaluation of att-stat in CP takes this into account.
Maybe, for defenders there should be another measure, like "defensive CP" to find a pkms position in a gym.
It is annoying and takes long to kill snorlax in comparison to dragonite, whereas dragonite has higher (and from a defensive point of view) overrated attack-stat that gives him really high CP.
Other extreme durable defenders (wigglytuff and chansey) have low CP and therefore are at the botton of gyms what is sonehow unfair and makes training of those gyms harder.