Cool question. I think one assumption here is
that dinosaurs sat on their eggs. They didn’t
necessarily do that. Decomposing vegetation is
used be some species to provide heat for
incubation. More accurately, the bacteria
breaking down the vegetation produce heat. If
you have a compost pile, you may have noticed how
hot it can get. Some birds--like the megapodes
(turkey-like birds) of Australia—use this method.
Crocodiles also use decomposing plants for heat.
Like a gardener with a compost pile, mothers that
use this method move the vegetation around to
adjust the temperature. It seems likely that
dinosaurs used it too.
As for calculating the strength needed to avoid
being crushed, I’ll leave that to the engineers.
My guess is that it would be pretty tough for the
tiny dinosaur to break out of an egg strong enough
for a T. Rex to sit on.
Thanks for asking,