Lunderberg opened a new pull request #10581:
URL: https://github.com/apache/tvm/pull/10581


   The goal of this commit is to reduce/eliminate common code required through 
unit tests that interact with Hexagon hardware.
   
   - New testing fixtures in `tests/python/contrib/test_hexagon`.  A test   
running on hexagon hardware should only need to use the   `hexagon_session` 
fixture.
   
     - `rpc_server_port`: Iterates through port numbers, selecting an unused 
port for each unit test.  Avoids needing to explicitly specify unique ports for 
each unit test.
   
     - `tvm_tracker`: Starts a tracker on use, exits after test.  Avoids 
needing to manually start a tracker prior to running the unit test.
   
     - `hexagon_launcher`: Starts a `HexagonLauncher` server on use, stops 
server after test.  Avoids needing to call `start_server()` and `stop_server()` 
in each test.
   
     - `hexagon_session`: Starts a hexagon session using 
`hexagon_launcher.start_session()`, exits after test.
   
   - Added `Session.upload` function, which delegates to 
`HexagonLauncher.upload`.  Avoids needing to interact with both the launcher 
and the session.
   
   - Allowed `tvm.IRModule` as argument passed to `Session.load_module`, which 
will automatically save/upload the module, then load it. Avoids needing to 
handle save/upload of temporary files in each unit test.


-- 
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]


Reply via email to