mirror of
https://github.com/Chaoscaot/schemsearch.git
synced 2025-11-05 05:54:02 +01:00
Refactor code structure and improve performance by optimizing OpenCL kernel and adding timing macros; update Cargo.toml for release profile settings; enhance main.rs and sinks.rs for better readability and organization.
This commit is contained in:
@ -34,3 +34,14 @@ pub struct Match {
|
||||
pub z: u16,
|
||||
pub percent: f32,
|
||||
}
|
||||
|
||||
#[macro_export]
|
||||
macro_rules! time {
|
||||
($name:ident, $body:block) => {{
|
||||
let start = std::time::Instant::now();
|
||||
let result = $body;
|
||||
let duration = start.elapsed();
|
||||
println!("{} took {:?}", stringify!($name), duration);
|
||||
result
|
||||
}};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user