Project

General

Profile

Actions

Bug #14486

closed

bhyve needs instruction emul tests

Added by Patrick Mooney 5 months ago. Updated 3 months ago.

Status:
Closed
Priority:
Normal
Category:
bhyve
Start date:
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:

Description

As more unit tests are written as part of the system/bhyve/tests package, it would be nice to have some for the in-kernel instruction emulation. It should be relatively straightforward to create a simple guest environment with a small flat memory space into which isolated instruction tests can be injected and run. The userspace portion of the test could service the as-expected VM exits and check that the desired vCPU states are achieved.


Related issues

Related to illumos gate - Bug #14569: bhyve should consolidate on hrtimeClosedPatrick Mooney

Actions
Actions #1

Updated by Patrick Mooney 4 months ago

  • Status changed from New to In Progress
  • Assignee set to Patrick Mooney
Actions #2

Updated by Electric Monk 3 months ago

  • Gerrit CR set to 2073
Actions #3

Updated by Patrick Mooney 3 months ago

While this was originally desired for testing instruction emulation, the first use case ended up being testing kernel-emulated devices from the perspective of a guest (running an in-guest test payload).

Those tests (timekeeping related) were executed successfully on both AMD and Intel hardware.

Actions #4

Updated by Patrick Mooney 3 months ago

  • Related to Bug #14569: bhyve should consolidate on hrtime added
Actions #5

Updated by Electric Monk 3 months ago

  • Status changed from In Progress to Closed
  • % Done changed from 0 to 100

git commit 5103e761e384621c5728a6d1f4b0bfdc1be233a4

commit  5103e761e384621c5728a6d1f4b0bfdc1be233a4
Author: Patrick Mooney <pmooney@pfmooney.com>
Date:   2022-03-30T15:50:42.000Z

    14569 bhyve should consolidate on hrtime
    14486 bhyve needs instruction emul tests
    Reviewed by: Andy Fiddaman <andy@omnios.org>
    Reviewed by: Luqman Aden <luqman@oxide.computer>
    Approved by: Dan McDonald <danmcd@joyent.com>

Actions

Also available in: Atom PDF