All Questions
Tagged with concurrency asynchronous
623
questions
0
votes
1
answer
44
views
Can CUDA Thrust Kernels operate in parallel on multiple streams?
I am attempting to launch thrust::fill on two different device vectors in parallel on different CUDA streams. However, when I look at the kernel launches in NSight Systems, they appear to be ...
-2
votes
0
answers
91
views
Asyncronous function don't run in the correct order [duplicate]
Why is my code not running in the correct order?
I can’t figure out why my code is not executing in the correct order. My downloadData function includes and should run the following three functions in ...
0
votes
0
answers
24
views
How to efficiently manage an API call inside NSManagedObjectContext.perform in swift?
So I have a function say 'sendData' that basically sends data to server by first fetching it from core data. Function can be called multiple times. So the basic structure is like this:
func sendData() ...
0
votes
1
answer
50
views
Execution of synchronously submitted work items on different threads in iOS
Are synchronously dispatched work items executed always on the main thread in iOS independent of anything (whether they are dispatched to a concurrent, serial, global, or custom queue)?
I checked ...
0
votes
2
answers
95
views
How to keep a local variable from being disposed
I'm trying to understand Swift better through this example. If in the following code the variable snapshotter is declared as a class variable the function startSnapshot does it's intended purpose. But ...
0
votes
1
answer
60
views
What the fundamental difference between an async code polling a cancellation token and registering a callback to be executed when the caller requests?
I'm watching (not for the first time) Working with Asynchrony Generically: A Tour of C++ Executors (part 1 and 2), which is about P2300.
With respect to cancellation support, Eric Niebler says that ...
1
vote
1
answer
56
views
Repeatedly calling an API while concurrently processing that data in C#
Looking to figure out where exactly I'm going wrong.
I have a program that queries an API, the API returns data in chunks and will return a response header with a URL to the next chunk of data, if ...
0
votes
0
answers
94
views
Coroutines and parallelism
A small detail I'm confused about for coroutines. I was told that the following code could run faster if I used coroutines:
fun processFiles() {
val file1 = processFile("file1")
val ...
0
votes
0
answers
27
views
Categorizing the terms "Parallel", "Concurrent", "Synchronous" and "Asynchronous" using Venn diagrams
Concurrency, parallelism, synchronous, and asynchronous are terms that I have come across at various places but have never quite fully understood the true distinction between them. I have seen all ...
1
vote
0
answers
27
views
How to implement concurrent/parallel listen on a WebSocket and a local process? [duplicate]
I'm currently developing a system that can simulate a CLI interaction in a web browser. I do this by receiving user/client input through a websocket, and passing that input into a docker container ...
0
votes
0
answers
36
views
Kotlin coroutines: synchronous vs asynchronous, blocking vs non-blocking, concurrent vs parallel
I'm trying to understand the differences and interplay between the terms synchronous and asynchronous, and how blocking and non-blocking fit into this, particularly in the context of Kotlin coroutines....
0
votes
2
answers
59
views
When does coroutine in asyncio actually cedes the execution?
I am trying to do a deep dive into Python's asyncio module. I understand we need to await the coroutine to get their results and when we await any coroutine, the surrounding coroutine cedes its ...
0
votes
0
answers
95
views
How to run triton ONNX models on CPU concurrently?
Description
I run multiple model instances on the CPU (onnx backend).
I'm confused about how to ensure parallelism in my Triton queries.
On the one hand, the number of model instances directly affects ...
0
votes
1
answer
89
views
Program using Atomic Variable gets stuck unexpectedly
I have a program utilizing a thread pool and atomic variables for synchronization within an event-driven architecture. However, it appears to get stuck unexpectedly under certain conditions, and I'm ...
1
vote
0
answers
39
views
Open next tab using puppeteer
How can I open next tab upon closing existing tab? The main thing here is I have a continuasly reloading pages in executingFunctions and as soon as one of the pages has proper html, puppeteer starts ...