Skip to content

Commit

Permalink
Shorten the name of the striped hashtable
Browse files Browse the repository at this point in the history
  • Loading branch information
vasilmkd committed Apr 20, 2021
1 parent f83a4f1 commit 8378a42
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,7 @@ final class IORuntime private[effect] (
val scheduler: Scheduler,
val shutdown: () => Unit,
val config: IORuntimeConfig,
private[effect] val fiberErrorCbs: FiberCallbackStripedHashtable =
new FiberCallbackStripedHashtable()
private[effect] val fiberErrorCbs: StripedHashtable = new StripedHashtable()
) {
override def toString: String = s"IORuntime($compute, $scheduler, $config)"
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ package cats.effect.unsafe
* lock by spreading it to several different locks controlling parts of the
* hash table.
*/
private[effect] final class FiberCallbackStripedHashtable {
private[effect] final class StripedHashtable {
val numTables: Int = {
val cpus = Runtime.getRuntime().availableProcessors()
// Bit twiddling hacks.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import scala.concurrent.duration._

import java.util.concurrent.CountDownLatch

class FiberCallbackStripedHashtableSpec extends BaseSpec with Runners {
class StripedHashtableSpec extends BaseSpec with Runners {

override def executionTimeout: FiniteDuration = 30.seconds

Expand Down Expand Up @@ -55,7 +55,7 @@ class FiberCallbackStripedHashtableSpec extends BaseSpec with Runners {
rt
}

"FiberCallbackStripedHashtable" should {
"StripedHashtable" should {
"work correctly in the presence of many unsafeRuns" in real {
val iterations = 1000000

Expand Down

0 comments on commit 8378a42

Please sign in to comment.