Skip to content

Commit

Permalink
u32 gen
Browse files Browse the repository at this point in the history
  • Loading branch information
primenumber committed Nov 12, 2023
1 parent 279dd56 commit a59560d
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions src/engine/search.rs
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ pub struct SolveObj {
pub evaluator: Arc<Evaluator>,
pub last_cache: Arc<LastCache>,
pub params: SearchParams,
pub cache_gen: u8,
pub cache_gen: u32,
}

impl SolveObj {
Expand All @@ -64,7 +64,7 @@ impl SolveObj {
eval_cache: Arc<EvalCacheTable>,
evaluator: Arc<Evaluator>,
params: SearchParams,
cache_gen: u8,
cache_gen: u32,
) -> SolveObj {
SolveObj {
res_cache,
Expand Down
8 changes: 4 additions & 4 deletions src/engine/table.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ pub struct EvalCache {
pub board: Board,
pub lower: i16,
pub upper: i16,
pub gen: u8,
pub gen: u32,
pub best: Option<Hand>,
pub depth: i32,
}
Expand Down Expand Up @@ -77,7 +77,7 @@ pub struct ResCache {
pub board: Board,
pub lower: i8,
pub upper: i8,
pub gen: u8,
pub gen: u32,
pub best: Option<Hand>,
}

Expand Down Expand Up @@ -198,7 +198,7 @@ pub type EvalCacheTable = CacheTable<EvalCache>;
pub type ResCacheTable = CacheTable<ResCache>;

fn make_record(
gen: u8,
gen: u32,
board: Board,
mut res: i8,
best: Option<Hand>,
Expand All @@ -224,7 +224,7 @@ fn make_record(

pub fn update_table(
res_cache: Arc<ResCacheTable>,
cache_gen: u8,
cache_gen: u32,
board: Board,
res: i8,
best: Option<Hand>,
Expand Down
2 changes: 1 addition & 1 deletion src/engine/think.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ pub struct Searcher {
pub cache: Arc<EvalCacheTable>,
pub timer: Option<Timer>,
pub node_count: usize,
pub cache_gen: u8,
pub cache_gen: u32,
}

pub const DEPTH_SCALE: i32 = 256;
Expand Down

0 comments on commit a59560d

Please sign in to comment.