You can completely dump the algorithm and render the attackers ineffective
This is possible in theory, but it was historically proven to be unsuccessful in practice. Each altcoin, which stopped using SHA-256, even though nobody broke this hash function, ended up in a worse position. For example: some developers wanted to stick with "1 CPU = 1 vote" principle, and changed the mining algorithm each time, when GPUs or ASICs were built for it. And of course, such coin could work, and provide some level of security, but it would be much worse than Bitcoin. Meanwhile, altcoins, which maintained a fraction of BTCs hashrate, but stayed with SHA-256, were much more successful.
You are mistaking reasons for change in other coins and then using that as precedence. Historical changing of the algorithm has never occurred under the situation that I was describing. It would have to have happened to Bitcoin and under the same circumstance for us to be able to say that there is historical precedence for an outcome. To date there have been no such changes in Bitcoin, and definitely not under an attack scenario. We can't use the consensus in shitcoins as an example especially when those decisions were made because people thought they were "smarter" or because they are greedy, those are wishes/desires and not at all comparable to a situation where something must be done to protect Bitcoin.
and in billions of losses in assets
I am not so sure about that. If there are many devices in use, which can mine a given coin, in a given way, then it will often find a group of people, which would do that. All new features and upgrades have to be backward-compatible, at least to some extent, otherwise they will be just altcoins. And many users can simply reject new version, and stay with the old one, as long as it is not fully broken. Which means, that if transactions can be processed, then many miners will keep mining even highly-centralized chains, as long as they will be worth some money. In practice, chains can die, if there are exactly zero users, otherwise they can be kept alive as long as needed.
Why would users reject an upgrade that is saving Bitcoin from destruction? Your argument works in general, but not under the attack scenario. It is either embrace the change with massive losses inflicted to the miners or let Bitcoin die. Why would anyone with a working brain choose the second option?
Do not expect a solution of a kind that is not possible for computers.
Sidechains can provide additional revenue for miners, but decentralized ones were rejected, so we have only some centralized federations, like RSK or Liquid, which are still very far from reaching the full potential. Currently, Bitcoin is harder and harder to change, and soon, it can reach a point of being unchangeable, which is called as "
ossification" by some people. And then, the only new changes will be completely outside of consensus rules, and will happen only in second layers and subnetworks, because nobody would successfully reach any consensus for changing the main layer anymore.
This is not good, while I admit that there is a risk of "ossification" it can not happen as there are many consensus cleanups to do. While developers may be hesitant to push for these changes individually or as a group for different reasons, we have to do it.
You are talking about a very specific kind of attack, which is renting hashrate. This can be easily fought off with rudimentary measures such as increasing the coin maturity, making it extremely uneconomical to even try to do this as you would burn up resources before you are able to sell any Bitcoin to continue financing the attack.
I believe the problem is that the attacker would build his economic profit model on the idea to short-sell Bitcoin. I think currently there would be too few Bitcoins available on lending platforms to make this attack profitable, and it would come with a lot of complexities (on lending platforms you have to hide your identity for example).
That is a good extension to the attack model, I do admit that I forget about that at times. However, at that point I would also bring up the legality of the attack. No regulated miner anywhere in the developed world can do this attack, they would be sued to the ground and shut down before anything can happen. It is questionable even if attacking Bitcoin by renting hashrate would even be feasible if the hashrate is located in the west, similarly how you can't rent out servers to run attacks on western companies (well you can, until you are stopped/caught). The attack vector is really only a possibility for nation states in practice, but the implications of that are more complicated for a topic on technical aspects. I will put just a small note. Depending on how well spread and integrated Bitcoin is in the US, any country even scheming to attack Bitcoin can be seen as a declaration of economic war -- and aside from superpowers, everyone can be crushed easily economically or militarily and the attack can be stopped (almost trivially in non-superpower cases). The chance that someone will attempt this is very low, the risks are too high and the reward too low.
Regarding a finality measure, yes there could be an addition of PoS-voted checkpoints, which can be even added "after the fact", i.e. after the attack. It would however be fine if we didn't even come close to that.
I am confident that we would get many innovative ideas and solutions should we reach a time where research focus has to be on this topic. Since the attack vector is slim, it is mostly being ignored.
Shower thought: Has adaptive block size already been discussed for that problem? I.e. one could determine an "ideal" percentage of block filling for fees to stay high, e.g. 90%. And then if the blocks of a difficulty period are significantly below that number, decrease the maximum block size for the next period by 1% and so on (i.e. very gradually, but eventually the blocks should become fuller again).
This would of course mean to think also about the effects of the fee level. For example, currently many Bitcoiners would still pay 5 sat/vByte without problems (I think the compllains started when in 2023/23 they went over 10 sat/vByte) and 5 sat/vByte with full blocks would still lead to significant fee income for miners. above all if Bitcoin rose again to 100k $+. And the fee level should be intimately tied to the percentage of the block space filled with transactions.
There are BIPs for that, but they were unsuccessful:
https://github.com/bitcoin/bips/blob/master/bip-0100.mediawikiThis BIP is not the same thing. General adaptive block size =/= adaptive block size based on fees. Furthermore, the BIP was started by a scammer during a contentious time, of course it had no chance. AFAIK @d5000 it has not been discussed, at least not not in recent times. You can try Delving Bitcoin since I know you do not want to try to write a BIP yourself, perhaps you can get the attention of someone who is interested in pursuing the idea.