The answer is fairly simple. When getting dental work, it's very common for small injuries to the gums. They are very vascular and doctors worry that bacteria can be introduced into the bloodstream. This is of course, is much more common in more involved procedures but could happen at any time. If bacteria does get into the bloodstream, and your body doesn't counter-man this, it could find a new home in the new joint replacement. The chances of this happening are low but not zero.
As above, every surgeon has their own protocol. My surgeons, even in the same practice, have ordered antibiotics for me before dental procedures ranging from two years to life time. This doesn't really bother me because it is only four antibiotic capsules 1 hour before the procedure. I figure four capsules every six months or so is not going to create a problem, so I don't hesitate in taking them. My dentist takes over the management of the antibiotics so it's very easy to make sure I have them before dental work. If this is a big issue for you, then I would discuss it with your surgeon and dentist, as you need to be comfortable with it as well.