By 1985, the CIA's network of Soviet-bloc agents began disappearing at an alarming rate. The CIA realized something was wrong, but was reluctant to consider the possibility of an agency mole. Initial investigations focused on possible breaches caused by Soviet bugs or by a broken code.
The CIA then blamed asset losses on another former CIA agent, Edward Lee Howard, who had also been passing information to the Soviets. But when the CIA lost three other important sources of information about whom Howard could have known nothing, it was clear that the arrests (and executions) originated from another source.
Let's cut to the chase. The Soviet Union collapsed despite the USA, not because of it.