L.Dutch made a worthwhile observation in an answer to a different question:
Moreover for close range shots there is almost no time to react and move the limb: for a shot fired at 20 m, with a speed of 200 m/s, you have only 0.1 s to have the limb in place to protect you (if you see the gun pointed at you) or even less if you have to react to the sound of the shot being fired (which reaches you at about 300 m/s).
Suppose our intrepid cyborg is not visually aware of the shot being fired. (Basically, it's "looking in another direction", whatever "looking" means for it.) Its first indication of the possible danger is when the leading edge of the shock wave from the bullet being fired reaches it at the speed of sound, approximately 300 m/s. If the shot is aimed at the cyborg and the bullet is either subsonic or supersonic, the shock wave is closely followed by the bullet itself, which is of course a problem; however, if the bullet is going in some other direction, then the cyborg will be able to detect the fact that a shot has been fired and remain operational.
For an alternative scenario, since lots of people have argued that the speed of the bullet is too low, you may freely choose to consider the following scenario instead: A person stands next to our intrepid cyborg, with both facing the same direction. The person fires the weapon along their mutual line of sight, such that the trajectory of the bullet takes it away from both of them. The cyborg does not visually observe the shot being fired.
Here, we aren't interested in actually dodging the bullet or really doing much of anything with the information, but rather only the processing that goes into determining the fact that a shot has been fired at all with a reasonable false positive rate (no claiming "shots fired!" when someone slams a door shut). To put this in software acceptance criteria terms, the cyborg only needs to set a single bit in a fixed memory location somewhere once a shot fired condition is detected; the time to do this particular write to memory can safely be approximated as instantaneous.
How long would the cyborg at a minimum need to, based on auditory cues alone and with a reasonable false positive rate, determine that a shot has been fired in its vicinity?
You may assume that the cyborg is able to fully process all audio input in real time, with no lag.
I have a feeling that Nyquist and Shannon are working against us here, but I don't know to what extent.