  We study the evolution of Low Mass X-ray Binaries (LMXBs) and of millisecond
binary radio pulsars (MSPs), with numerical simulations that keep into account
the evolution of the companion, of the binary system and of the neutron star.
According to general relativity, when energy is released, the system loses
gravitational mass. Moreover, the neutron star can collapse to a black hole if
its mass exceeds a critical limit, that depends on the equation of state. These
facts have some interesting consequences: 1) In a MSP the mass-energy is lost
with a specific angular momentum that is smaller than the one of the system,
resulting in a positive contribution to the orbital period derivative. If this
contribution is dominant and can be measured, we can extract information about
the moment of inertia of the neutron star, since the energy loss rate depends
on it. Such a measurement can therefore help to put constraints on the equation
of state of ultradense matter. 2) In LMXBs below the bifurcation period (\sim
18 h), the neutron star survives the period gap only if its mass is smaller
than the maximum non-rotating mass when the companion becomes fully convective
and accretion pauses. Therefore short period (P < 2h) millisecond X-ray pulsar
like SAX J1808.4-3658 can be formed only if either a large part of the
accreting matter has been ejected from the system, or the equation of state of
ultradense matter is very stiff. 3) In Low Mass X-ray binaries above the
bifurcation period, the mass-energy loss lowers the mass transfer rate. As side
effect, the inner core of the companion star becomes 1% bigger than in a system
with a non-collapsed primary. Due to this difference, the final orbital period
of the system becomes 20% larger than what is obtained if the mass-energy loss
effect is not taken into account.
