Python Bindings for Scarf
To increase usability, Scarf provides Python bindings to a limited subset of its functionality through the scarf_python package. This allows Python users to interact with SystemVerilog sources while leveraging the existing (fast) tools written in Rust.
When crossing the FFI boundary, Rust’s borrow checker can no longer
provide lifetime guarantees; as such, many data structures must be
cloned, and have associated From / Into implementations for
their reference-based Rust counterparts. This quickly becomes the
dominant factor in runtime; if speed/space usage becomes a concern,
native Rust applications should be considered instead.
Warning
scarf_python is currently considered unstable. Expect API breaks
between minor versions.