The mining algorithm can just be changed with a hard fork.
The only think that would irrevocably kill Bitcoin is breaking private keys (ie discovering others private keys, or signing transactions without private keys). A fork could not solve it as there'd be no way to prove which coins you actually owned before the fork.
Wrong. IF there exists a general purpose formula (which isn't known yet) for all quantum problems, so secp256k1 is broken, then it would only reduce the complexity sqrt(N), from 2^256 down to 2^128. Which is unsolvable. (source: Stanford cryptography I course on coursera).
AND even if the elliptic curve cryptography of bitcoin is broken, say you can solve it in a year/month/week/day, the fact is most BTC unspent transaction outputs (UTXO's) are scripted "pay to public key hash".
The entity proving ownership of the UTXO needs to show a public key (that is so far unknown ... if they haven't reused this address before), AND this public key needs to hash into the address, AND the signature signed by the private key verified.
So if somebody announced they had solved secp256k1 and could break it in 1 week, your funds are safe. (1) They probably don't know your public key. Relax. And (2) You just wait for the BTC soft fork to support new crypto, then do a transfer to yourself. You transmit your transaction to the mempool (exposing your public key for the first time), and it will be mined in 10-30 minutes. Not enough time for the hackers to monitor the mempool and come up with a valid signature. Then your new UTXO is a different spend script for how to spend it next time using some new unbreakable crypto.
As long as there was some pre warning that such a quantum computer+algorithm was going to become available, Bitcoin would be able to fork, and users would be able to move their funds to quantum proofed (or at least hardened) wallets.
It surely depends on which aspect of SHA they would have broken, but the whole point of Bitcoin is the hash being completely unpredictable and requiring brute force. That's the Work in Proof of Work.