def send_signal_to_gdb(self, signal_input):
try:<EOL><INDENT>signal = int(signal_input)<EOL><DEDENT>except Exception:<EOL><INDENT>signal = SIGNAL_NAME_TO_NUM.get(signal_input.upper())<EOL><DEDENT>if not signal:<EOL><INDENT>raise ValueError(<EOL>'<STR_LIT>' % str(signal)<EOL>)<EOL><DEDENT>if self.gdb_process:<EOL><INDENT>os.kill(self.gdb_process.pid, signal)<EOL><DEDENT>else:<EOL><INDENT>raise NoGdbProcessError(<EOL>"<STR_LIT>"<EOL>)<EOL><DEDENT>
Send signal name (case insensitive) or number to gdb subprocess
        gdbmi.send_signal_to_gdb(2)  # valid
        gdbmi.send_signal_to_gdb('sigint')  # also valid
        gdbmi.send_signal_to_gdb('SIGINT')  # also valid

        raises ValueError if signal_input is invalie
        raises NoGdbProcessError if there is no gdb process to send a signal to