I think Young Lochinvar has a good take on Spain and Portugal and the problems of constant warfare in the 17th and 18th centuries. It also helps to isolate those states that had situational problems, bad finances caused by exigent circumstances such as being invaded multiple times, from those that had systemic problems, bad finances from the way the state was governed.
In the former group I would say its fair to put many of the smaller states like Baden, Modena and Parma. The Netherlands could arguably go here or in the other group. My understanding, and I admit I'm no expert on 18th century economics so I could well be wrong, was that the Dutch economy and thus the strength of the Dutch state declined vis a vis Britain and others mainly because the Dutch lost their dominance over international trade. To a certain extent this is due to circumstances beyond their control, namely the actions of foreign states, but because they are economically dependent upon trade, its also a matter of how their state functioned and regulated its economy.
In the latter group I would say we could find France, Spain and Tuscany. This is why I referenced Tuscany. It fought in none of the Wars of the late 17th early 18th centuries not even in the War of Polish Succession that decided its fate, though it undoubtedly was indirectly affected by them. Rather it was the poor quality of the last of the Medici, notably Gian Gastone, that lead to severe decline and a moribund economy. So in some respects it makes a better example than Spain. Spain's bankruptcies were uniquely linked to the massive influx of Silver from the America's that was used to prop up the Spanish state but ultimately lead to inflation and repeated bankruptcies in the 16th and 17th centuries. Portugal has similar issues but in the 18th century it was masked by the influx of Gold from Brazil which was fortunately spent not on foreign wars but domestic expenditures like building palaces or art collections. Thus for this discussion Portugal is something of an outlier.
At any rate the states with systemic problems provide the best instruction for France. Part of Philip's success in the War of Spanish Succession was his ability to implement a series of reforms that resuscitated the state's finances. I remember reading that the Bourbon administration was able to collect more revenue during war time with parts of the country occupied by foreign powers than the previous Habsburg kings had been able to do in peace. This was part of why the allies failed to dislodge him. And as I said before Philip was able to carry out many reforms by simply suppressing institutions that would oppose him like the traditionally autonomous region of Catalonia. Philip's son Charles III would later continue these efforts at centralization in the later half of the 18th century. It was also easier to raise revenues during wartime when one could rally the nation together. Indeed France faced bankruptcy during the War of Spanish Succession forcing Louis XIV to melt down the silver at Versailles but ultimately he was able to rally the nation to his cause and to continue the war.
In Tuscany the economic problems were more serious but the opportunities greater. Unlike Spain it wasn't plagued by inflation or living beyond its means by fighting foreign wars. It was simply, fundamentally poor to the point of being nationally broke. On the plus side there were no major legislative or judicial bodies to oppose Francesco Leopoldo. The nobility was limited in size and scope and was primarily urban, descended from the old elite of the Florentine Republic. The peasantry also wasn't as abjectly poor as their French counterparts. The non-Florentine parts of the state, namely Siena, had been acquired through conquest which saw them utterly defeated and thus they were accorded no special rights. Thus the only place in which he seriously failed as a reformer was in his religious reforms when he ran into a powerful adversary in the form of the Catholic Church.
For as much as the French King was an absolute monarch there still existed in France a series of institutions that could and sometimes did prove to be obstacles. Namely the Parlements which in the 18th century saw themselves as a check on the Kings power. While the King could override a Remonstrance (refusal of the Parlement to register a royal edict) with a Lit de Justice it was a cumbersome procedure. Often the Kings resorted to exiling members of Parlement to the countryside but this only bred sympathy for the institution and resentment of the King. France also face the decentralized system of Spain in that there were multiple regional Parlement's with different jurisdictions and prerogatives. There were also institutions like the Ferme Generale that had a vested interest in preventing reforms. While FL was able to eliminate its Tuscan equivalent French Kings relied more and more upon the Tax farmers for stop gap measures to shore up French finances making the Ferme more and more powerful. One should also be careful not to discount the nobility. Encroaching on their traditional privileges is can derail reforms even when that's what's most necessary.
Joseph I ran into this in Hungary. The Hungarian nobility owned massive estates with the peasantry bound to them in serfdom but despite this they were actually quite poor in many cases. And their lands were often alloidial meaning that they could not be mortgaged or otherwise alienated from the noble who possessed them. Thus it was hard to find capital for improvements like roads, dams, mills, draining swamps, etc that would improve the productivity of the land. Yet the Hungarian nobility jealously guarded their rights and refused to countenance any reforms in that area. Admittedly there was a nationalist component to the opposition in Hungary but there are nevertheless parallels to the French nobility. Many of the old Sword Nobility of France were quite poor and relied upon traditional perks like military appointments even if they proved to be a drain on the French state.
Thus the King could have complete power in foreign affairs, could control the army and even keep most of the nobility under his thumb but reforming the fundamentals of the French state unilaterally was beyond his power. If it wasn't there wouldn't have been a French revolution because Louis XVI could have simply imposed new taxes or modest reforms by Royal fiat. So France had the problem of support massive new national state institutions like the French standing army, the royal court at Versailles and the centralized royal administration of intendants but had little way of instituting national reforms to secure adequate revenues for them. The Spanish Bourbons, by breaking down traditional regional institutions in the name of rational enlightened absolutism ensured that the Spanish state functioned economically as a single unit with fewer internal barriers to trade and administration and thus was more capable of financially supporting centralized state institutions. It probably also helped that Spain discarded its outsized role in international affairs for a more manageable stature, thus curtailing the crippling military expenditures of the Spanish Habsburgs.
So in some ways France had all the problems of Spain (decentralized institutions, traditional rights, massive military expenditures) and Tuscany (macroeconomic problems, poor tax collection system) with its only advantage being that it economic and demographic fundamentals are stronger, ie its a relatively wealthy country if it could be made to function efficiently. So unlike Spain France was never really living beyond its means per se but there was a growing disconnect between the way the state was administered and the way it functioned. At any rate its not really possible to say that 'If France had only done what State X did it could have avoided the whole mess of the Revolution'. That's not to say that there aren't some instructive examples out there of what to and what not to try.
Sorry for the essay. And of course as I said I'm not an economist but this is my understanding of the period. But if any one has more expertise in a particular area please feel free to critique, I'm always interested in learning more.