code: def get_reg_name(arch, reg_offset):
          
          # todo does this make sense
          if reg_offset is None:
              return None
  
          original_offset = reg_offset
          while reg_offset >= 0 and reg_offset >= original_offset - (arch.bytes):
              if reg_offset in arch.register_names:
                  return arch.register_names[reg_offset]
              else:
                  reg_offset -= 1
          return None
docs: :param arch: the architecture
          :param reg_offset: Tries to find the name of a register given the offset in the registers.
          :return: The register name