How long is a piece of string?
Which is to say, there’s no one answer.
The simplest answer regardless of any other factors is that they won’t “bail”. They can’t. It’s not like they can say “I’d like my investment money back” and go home. If for no other reason than if the investment is starting to fail then their money isn’t there to take back.
If you rewind right back to when they first make their investment - at that point, they are well aware that they may lose all their investment. This is why VCs will invest in lots of different companies and not just one. They’re spreading the risk, and the investments which succeed have to return enough to cover the others that have failed also (which is why there will be times when a VC will choose not to invest in a business that looks sound or that they believe in - it’s not that they think it will fail, it’s that the margin isn’t there for it to be worth them having a punt).
You may well get VCs who will look at a failing investment and think that it’s only a short-term blip - perhaps something as simple as a minor cash-flow issue - and that putting further investment to cover things in the meantime will be a good deal (particularly if they can leverage a better position through this - more equity for less money).
Most though will probably not want to throw good money after bad and will write off the failing investment and concentrate on maximising the successful ones instead.
tl;dr, a VC is effectively a gambler who bets on lots of companies to succeed and expects the ones who do to cover all their losses and more. They generally won’t throw good money after bad.