Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add caching for GetAllMoves, GetAllAttackableMoves #17

Merged
merged 9 commits into from
Mar 26, 2019
Merged

Conversation

Vadman97
Copy link
Owner

Fix major bug in Hash function - properly cache moves and attackable moves.
Need #16 to use effectively due to high memory usage of storing []Move in cache.
Improves performance though, mostly limited by GC and memory allocation now.

pkg/chessai/board/game_board.go Show resolved Hide resolved
pkg/chessai/board/game_board.go Outdated Show resolved Hide resolved
@Vadman97 Vadman97 requested a review from dadhia March 26, 2019 05:27
@dadhia dadhia merged commit 98c750c into master Mar 26, 2019
@dadhia dadhia deleted the cacheMoves branch March 26, 2019 05:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants