If so, then what do they do when you present a newly issued passport that has zero passport stamps? All sins forgiven (hidden)?
You have to make a distinction between your legal position and how enforcement works in practice. Getting a new passport only changes how likely border guards are to realize that you have overstayed but it doesn't mean you have a right to stay longer.
Border guards can still look up information about your comings and goings in any computer system they might have. As explained in the answers to your other questions, passports are not used for that and this scenario provides a very good reason why it would be a bad idea: You don't want to make the retention of this information dependent on random actions by foreign countries like a renewing a passport.
If there is a formal ban, you're very likely to be found out based on your name and date of birth (that's kind of the point of a ban and one difference with simply being denied entry).
Outside of these situations, it's entirely possible that border guards fail to notice, say, an earlier stay or even a violation or overstay after you changed your passport. It doesn't mean that you have the right to stay longer than you would with your old passport but simply that you're getting away with something that would otherwise have resulted in being denied entry. Think of it like speeding in a place where there is no speed camera or parking illegally.
All this is especially relevant in the Schengen area. Since the borders between member countries are open and there is limited information shared between countries, the Schengen Borders Code traditionally relied primarily on passport stamps to enforce maximum stay rules. A border guard can easily be unaware of an earlier stay in another country in the area. This has been bothering people for a long time and that's the reason why the EU is rolling out the Entry-Exit System.