Skip to content

Commit

Permalink
Stale comments fixes [skip ci]
Browse files Browse the repository at this point in the history
  • Loading branch information
mratsim committed Jan 1, 2020
1 parent bf2ec2f commit 5d90172
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
1 change: 0 additions & 1 deletion changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@

`parallelFor`, `parallelForStrided`, `parallelForStaged`, `parallelForStagedStrided`
now support an "awaitable" statement to allow fine-grain sync.

Fine-grained data-dependencies are under research (for example launch a task when the first 50 iterations are done out of a 100 iteration loops), "awaitable" may change
to have an unified syntax for delayed tasks depending on a task, a whole loop or a subset of it.
If possible, it is recommended to use "awaitable" instead of `syncRoot()` to allow composable parallelism, `syncRoot()` can only be called in a serial section of the code.
Expand Down
6 changes: 2 additions & 4 deletions weave/memory/memory_pools.nim
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ const
MostlyUsedRatio = 8
## Beyond 7/8 of its capacity an arena is considered mostly used.
MaxSlowFrees = 8'i8
## In the slow path, up to 5 arenas can be considered for release at once.
## In the slow path, up to 8 arenas can be considered for release at once.

# Sanitizer
template guardedAccess(memBlock: MemBlock, body: untyped): untyped =
Expand Down Expand Up @@ -266,7 +266,6 @@ func getArena(p: pointer): ptr Arena {.inline.} =
result = cast[ptr Arena](arenaAddr)

# Sanity check to ensure we're in an Arena
# TODO: LLVM ASAN, poisoning/unpoisoning?
postCondition: not result.isNil
postCondition: not result.allocator.isNil
postCondition: result.meta.used in 0 .. result.blocks.len
Expand Down Expand Up @@ -456,7 +455,7 @@ proc allocEx(pool: var TLPoolAllocator): ptr MemBlock =
proc initialize*(pool: var TLPoolAllocator) =
## Initialize a thread-local memory pool
## This automatically reserves one arena
## of WV_MemArenaSize (default 32kB) that can
## of WV_MemArenaSize (default 16kB) that can
## serve fixed size memory block for types
## of size up to WV_MemBlockSize (default 256B)
##
Expand Down Expand Up @@ -512,7 +511,6 @@ proc recycle*[T](p: ptr T) {.gcsafe.} =
## Returns a memory block to its memory pool.
##
## This is thread-safe, any thread can call it.
## It must indicates its ID.
## A fast path is used if it's the ID of the borrowing thread,
## otherwise a slow path will be used.
##
Expand Down

0 comments on commit 5d90172

Please sign in to comment.