However it occurred to me that CHDK could likely do that in-camera - and do it faster and more accurately with some kind of script that brackets based on scene exposure (selecting exposures just below clipping and just above blackout).
CHDK can do bracketing, without a script
http://chdk.wikia.com/wiki/CHDK_User_Manual#Bracketing_in_continuous_modeThis is done as fast as the camera can make the exposures.
You might be able to make a script that intelligently figured out the required bracket range, but doing a stop or two in each direction should be sufficient in most cases.
I'm sure different kinds of tone-mapping and curves could be incorporated as selections within the script and we'd have good in-camera HDR.
This cannot be done in script, and would be quite difficult to do on camera at all. The camera is not a convenient place to do image processing, because the CPU is slow, memory is very limited, and standard software libraries are not available.
If the image processing side of Digic were better understood, that might change things.
By having a script automate it, the shots would be taken much faster than by the operator and the results could be seen while in the field as opposed to having to wait to see them after processing.
CHDK cannot make the camera shoot faster than continuous mode.