hyperlight-dev / hyperlight-dev/hyperlight

Remove unnecessarily complex guest function dispatch pointer logic

Đang mở
#516 0 bình luận 0 reaction 0 người được giao Xem trên GitHub
lifecycle/blocked-on-author
Ngôn ngữ chính
Rust
Star
4.7k
Fork
208
Merge trung bình
1 ngày 7 giờ
Pull request đã merge (30 ngày)
47

Mô tả

Currently, a hyperlight elf guest binary has an entrypoint. Execution is started at this entrypoint the first time the vm is ran. Additionally, the guest is required to write a pointer to a specific place in memory during execution. This pointer is then read by the host, and the host sets the guest's RIP to this pointer on subsequent guest function calls, so that execution starts from there.

The existing logic is complicated and can be simplified by always starting execution at entrypoint. Whether or not to run "initialization logic" can all be handled from the guest side (e.g. by reading parameters passed to entrypoint, set by the host). Apart from just a code simplification, this restructuring also has the added benefit from the guest's perspective for example, guests that don't require any initialization could avoid doing it entirely (impossible with current hyperlight structure). It would also allow an arbitrary number of separate initialization steps (as opposed to the current max on 1)

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.