cbalint13 opened a new pull request, #19830:
URL: https://github.com/apache/tvm/pull/19830
Implements the tracker service into the existing ```tvm_cpp``` tool.
This is a standalone & portable alternative to the current python only
```tvm.exec.rpc_tracker``` counterpart.
---
#### Implementation details
Implementation follows the TVM tracker full specifications, including the
mandatory priority scheduling.
It can be considered *experimental* due to limited tests done having a setup
of only two remote edge nodes.
```
$ ./tvm_rpc
{...} Command line usage
server - Start the server
{...}
tracker - Start the tracker
--host - Listen adddress of the RPC tracker, Default=0.0.0.0 (any)
--port - The port of the RPC tracker, Default=9190
--port-end - The end search port of the RPC, Default=9199
--silent - Whether to run in silent mode. Default=False
Examples
./tvm_rpc server --host=0.0.0.0 --port=9000 --port-end=9090
--tracker=127.0.0.1:9190 --key=rasp
./tvm_rpc tracker --host=0.0.0.0 --port=9190 --port-end=9199
```
```
[cbalint@yoda build]$ ./tvm_rpc tracker
[11:37:03] {...}/main.cc:136: host = 0.0.0.0
[11:37:03] {...}/main.cc:137: port = 9190
[11:37:03] {...}/main.cc:138: port_end = 9199
[11:37:03] {...}/main.cc:139: silent = False
[11:37:03] {...}/main.cc:378: Starting CPP Tracker, Press Ctrl+C to stop.
[11:37:03] {...}/rpc_tracker.cc:231: Bind to 0.0.0.0:9190
<-- a remote edge [192.168.1.10] tvm_rpc server having 'opi5' key connects
to tracker
[11:37:06] {...}/rpc_tracker.cc:265: New session from 192.168.1.10:46392
[11:37:06] {...}/rpc_tracker.cc:315: Handshake with 192.168.1.10:46392
successful
[11:37:06] {...}/rpc_tracker.cc:345: Received key 'server:opi5' from
192.168.1.10:46392
<-- a tuner process [127.0.0.1] asks for peering session with 'opi5' key
---> tracker gives the tuner available session from the prio scheduler
[11:38:18] {...}/rpc_tracker.cc:265: New session from 127.0.0.1:38706
[11:38:18] {...}/rpc_tracker.cc:315: Handshake with 127.0.0.1:38706
successful
[11:38:18] {...}/rpc_tracker.cc:341: Request using key 'opi5' from
127.0.0.1:38706
[11:38:18] {...}/rpc_tracker.cc:419: Offering matchkey
'opi5:[email protected]:9000' to 127.0.0.1:38706
[11:38:18] {...}/rpc_tracker.cc:357: End session with 127.0.0.1:38706
[11:38:20] {...}/rpc_tracker.cc:265: New session from 127.0.0.1:38716
[11:38:20] {...}/rpc_tracker.cc:315: Handshake with 127.0.0.1:38716
successful
[11:38:20] {...}/rpc_tracker.cc:341: Request using key 'opi5' from
127.0.0.1:38716
[11:38:20] {...}/rpc_tracker.cc:419: Offering matchkey
'opi5:[email protected]:9000' to 127.0.0.1:38716
[11:38:20] {...}/rpc_tracker.cc:357: End session with 127.0.0.1:38716
<-- another remote edge [192.168.1.5] tvm_rpc server having 'riscv' key
connects to tracker
[11:44:58] {...}/rpc_tracker.cc:265: New session from 192.168.1.5:43390
[11:44:58] {...}/rpc_tracker.cc:315: Handshake with 192.168.1.5:43390
successful
[11:44:58] {...}/rpc_tracker.cc:345: Received key 'server:riscv' from
192.168.1.5:43390
<-- a ```python3 -m tvm.exec.query_rpc_tracker --host 127.0.0.1 --port
9190``` info query .
---> tracker gives a summary of available peeering resources.
[11:45:11] {...}/rpc_tracker.cc:265: New session from 127.0.0.1:41410
[11:45:11] {...}/rpc_tracker.cc:315: Handshake with 127.0.0.1:41410
successful
[11:45:11] {...}/rpc_tracker.cc:351: Summary requested from 127.0.0.1:41410
[11:45:11] {...}/rpc_tracker.cc:357: End session with 127.0.0.1:41410
---> query peer reveives the summary as
$ python3 -m tvm.exec.query_rpc_tracker --host 127.0.0.1 --port 9190
Tracker address 127.0.0.1:9190
Server List
------------------------------
server-address key
------------------------------
192.168.1.10:9000 server:opi5
192.168.1.5:9000 server:riscv
------------------------------
Queue Status
-----------------------------
key total free pending
-----------------------------
opi5 1 1 0
riscv 1 1 0
-----------------------------
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]