For modern ARM and RISCV cores, dumping memory and debugging code already in flash should work without problems, however programming if different for every chip, very manufacturer specific.
For other architectures... well... it will be tougher, when there is no standardised debugging interface available. I am aware of 8051 chips like the nRF24lu1p, which has JTAG, but without any documentation, it's pretty useless. I'm not familiar with SHARC, so I don't know if there is any documentation about the debugger architecture.