Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion docs/source/developer/threading_implementation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -197,10 +197,11 @@ The general pattern for using ``get_num_threads`` in code generation is

import llvmlite.llvmpy.core as lc

get_num_threads = builder.module.get_or_insert_function(
get_num_threads = cgutils.get_or_insert_function(builder.module
lc.Type.function(lc.Type.int(types.intp.bitwidth), []),
name="get_num_threads")


Comment thread
esc marked this conversation as resolved.
Resolved
num_threads = builder.call(get_num_threads, [])

with cgutils.if_unlikely(builder, builder.icmp_signed('<=', num_threads,
Expand Down