mirror of
https://chromium.googlesource.com/crosvm/crosvm
synced 2025-02-06 02:25:23 +00:00
dc74848b7c
These parameters multiplied the number of type arguments to build_vm unnecessarily and complicated the thread of execution in the programmers head. Closures also complicate the borrow rules, making things much harder to change. This change uses the results of the closures (e.g. PCI devices, IRQ chips) as parameters instead. The rest of this change follows naturally from pulling on that thread until tests pass. As a result of the removal of several type arguments, the code size was reduced by ~100KiB on a 5MiB build. BUG=b:185170486 TEST=./test_all Change-Id: I6bcc5eb1b1f3031d4328bb4a81ddef618d04767b Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/2829136 Tested-by: kokoro <noreply+kokoro@google.com> Commit-Queue: Zach Reizner <zachr@chromium.org> Reviewed-by: Tomasz Jeznach <tjeznach@chromium.org> Reviewed-by: Daniel Verkamp <dverkamp@chromium.org> |
||
---|---|---|
.. | ||
src | ||
Cargo.toml |