pr 00.1 decouple more code from vm and hardware

This commit is contained in:
2026-03-24 13:40:23 +00:00
parent 0cacf4fed8
commit ba2344e324
34 changed files with 345 additions and 1088 deletions
+1 -5
View File
@@ -6,8 +6,4 @@ pub mod telemetry;
pub mod debugger_protocol;
pub mod syscalls;
// Tipos da VM que fazem parte do contrato (ex.: inspeção de pilha pelo debugger)
pub mod virtual_machine {
mod value;
pub use value::Value;
}
pub mod virtual_machine;
@@ -0,0 +1,12 @@
mod value;
mod vm_init_error;
pub use value::Value;
pub use vm_init_error::VmInitError;
#[derive(Debug, PartialEq, Clone)]
pub enum VmFault {
Trap(u32, String),
Panic(String),
Unavailable,
}
@@ -0,0 +1,8 @@
#[derive(Debug, Clone, PartialEq, Eq)]
pub enum VmInitError<E> {
InvalidFormat,
UnsupportedFormat,
PbsV0LoadFailed(prometeu_bytecode::LoadError),
EntrypointNotFound,
VerificationFailed(E),
}