I've only owned property in "Community Property" (CP) states, and Illinois is not one, so with that disclaimer out of the way I'll throw this out.
I believe non CP states go by "equitable distribution", in which a judge looks at all the assets, liabilities and ongoing expenses and apportions them "equitably". Usually when judges divide things this way my experience has been they consider their job done well if both sides are equally unhappy with the results. They can use just about any criteria they want, but significantly the way title to things was held is not all that important - for instance, if the house was bought at the beginning of the marriage and only the husband was on the deed, and he was the only one that brought in an income, upon divorce the judge could very well give the house to the wife as part of an equitable settlement of the assets and, say, relieve the husband of alimony in exchange.
Now there are usually provisions for allowing one spouse to acquire or retain sole title to an asset and have it not divided, but generally there needs to be some compelling reason shown, and more importantly the agreement cannot be overtly or covertly entered just to deprive a financially unsophisticated spouse of their interest. One example that comes to mind is if two people who own their own small businesses get married and they both agree that the ownership of each one's business will remain their own through the marriage. But such a scenario is fact dependent. If after 10 years they change their minds and she becomes a stay at home mom, shuts down her business and devotes herself to the family therefore allowing the husband additional time to grow his, and 10 years later they divorce, the original agreement would probably be ignored by the judge and the wife would be awarded compensation for the husband's business. Probably. But in front of a judge nothing is guaranteed.
Now awaiting an Illinois lawyer to sign up and tell me I've got it all wrong due to applying general concepts to Illinois law.