Skip to content

Commit

Permalink
Merge pull request #621 from lenguyenthanh/clean-up-binary-fen-bench
Browse files Browse the repository at this point in the history
Clean up BinaryFenBench
  • Loading branch information
lenguyenthanh authored Feb 9, 2025
2 parents c101ed3 + 5a9e4e7 commit e6d1f26
Showing 1 changed file with 4 additions and 37 deletions.
41 changes: 4 additions & 37 deletions bench/src/main/scala/benchmarks/BinaryFenBench.scala
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,10 @@ import java.util.concurrent.TimeUnit

import cats.syntax.all.*
import chess.{ FullMoveNumber, Situation }
import chess.format.BinaryFen
import chess.variant.Standard
import chess.variant.Chess960
import chess.{ Mode as _, * }
import chess.format.{ Fen, FullFen, BinaryFen }
import chess.perft.Perft

@State(Scope.Thread)
@BenchmarkMode(Array(Mode.Throughput))
Expand All @@ -21,41 +23,6 @@ class BinaryFenBench:
// the unit of CPU work per iteration
private val Work: Long = 10

private val binary = BinaryFen(
Array(
0xff.toByte,
0xff.toByte,
0x00.toByte,
0x00.toByte,
0x10.toByte,
0x00.toByte,
0xef.toByte,
0xff.toByte,
0x2d.toByte,
0x84.toByte,
0x4a.toByte,
0xd2.toByte,
0x00.toByte,
0x00.toByte,
0x00.toByte,
0x00.toByte,
0x11.toByte,
0x11.toByte,
0x11.toByte,
0x11.toByte,
0x3e.toByte,
0x95.toByte,
0x5f.toByte,
0xe3.toByte
)
)

import chess.variant.*
import chess.{ Mode as _, * }
import chess.format.FullFen
import chess.perft.Perft
import chess.format.Fen

@Param(Array("10", "100", "1000"))
var games: Int = scala.compiletime.uninitialized
var sits: List[Situation.AndFullMoveNumber] = scala.compiletime.uninitialized
Expand Down

0 comments on commit e6d1f26

Please sign in to comment.