Browse Source

Tell gdb we can handle large packets.

This speeds up downloads to 93KB/s, which is starting to get usable.
pull/39/head
Tim Newsome 10 years ago
parent
commit
91a4f8114d
  1. 1
      riscv/gdbserver.cc
  2. 2
      riscv/processor.cc
  3. 2
      tests/gdbserver.py

1
riscv/gdbserver.cc

@ -1459,6 +1459,7 @@ void gdbserver_t::handle_query(const std::vector<uint8_t> &packet)
send("swbreak+;");
}
}
send("PacketSize=131072;");
return end_packet();
}

2
riscv/processor.cc

@ -204,7 +204,7 @@ void processor_t::enter_debug_mode(uint8_t cause)
set_privilege(PRV_M);
state.dpc = state.pc;
state.pc = DEBUG_ROM_START;
debug = true; // TODO
//debug = true; // TODO
}
void processor_t::take_trap(trap_t& t, reg_t epc)

2
tests/gdbserver.py

@ -160,7 +160,7 @@ class RegsTest(unittest.TestCase):
class DownloadTest(unittest.TestCase):
def setUp(self):
length = 2**16
length = 2**20
fd = file("data.c", "w")
fd.write("#include <stdint.h>\n")
fd.write("uint32_t length = %d;\n" % length)

Loading…
Cancel
Save