awooter: add Arc struct
This commit is contained in:
parent
319d1c4620
commit
a16247d512
@ -5,6 +5,7 @@ use colored::Colorize;
|
||||
#[macro_use]
|
||||
mod npnr;
|
||||
mod partition;
|
||||
mod route;
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn npnr_router_awooter(ctx: Option<NonNull<npnr::Context>>) -> bool {
|
||||
|
18
common/route/awooter/rust/src/route.rs
Normal file
18
common/route/awooter/rust/src/route.rs
Normal file
@ -0,0 +1,18 @@
|
||||
use crate::npnr;
|
||||
|
||||
pub struct Arc {
|
||||
source_wire: npnr::WireId,
|
||||
source_loc: npnr::Loc,
|
||||
sink_wire: npnr::WireId,
|
||||
sink_loc: npnr::Loc,
|
||||
net: *mut npnr::NetInfo,
|
||||
}
|
||||
|
||||
impl Arc {
|
||||
pub fn new(source_wire: npnr::WireId, source_loc: npnr::Loc, sink_wire: npnr::WireId, sink_loc: npnr::Loc, net: *mut npnr::NetInfo) -> Self {
|
||||
Self {
|
||||
source_wire, source_loc, sink_wire, sink_loc, net
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user