There isn't necessarily an upper limit, and an unbroken line of 10 generations is certainly possible, but the game does have more to process when you have sims with long family trees. Plus, family trees can and often do break. My own dynasty has a fractured tree due to some bad traveling bugs.