Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [multiprocessing]

The tag has no usage guidance.

0
votes
1answer
34 views

Should worker processes accept() or should they get data from the master process?

I'm trying to write an application server in python. I have a master process and multiple worker processes created from the master using fork(). I have two approaches in mind about how the workers ...
1
vote
0answers
104 views

Daemon vs worker and when to use what?

(Note that, below, I am frequently using term "daemon or worker" just to indicate that I dont know which word to use as I dont know the exact difference between them in the context explained below.) ...
1
vote
0answers
94 views

Android Multiple Threads for I/O Operations in Room

I have a small example that i run on a real device with 4+4 cores. ExecutorService service = Executors.newFixedThreadPool(4); for(int i =0 ; i<1000; i++){ Runnable task = new Runnable() { ...
0
votes
2answers
184 views

Design of a Python “service” using multiprocessing and threading

Due to the Global Interpreter Lock, multithreading in Python does not affect parallelism. This limitation is avoided in the multiprocessing library by spawning new processes instead. But threading ...
1
vote
1answer
141 views

Embedded Systems: Designing an API that monitors an address

This question was tossed as a starting point in a technical interview at a semi-conductor company. I guess there are no right ans - the purpose of this open ended question is to gauge the engineer's ...
1
vote
2answers
1k views

How do I get a program designed to run continuously (converting data on a Serial COM port) to exit?

Problem Statement I'm writing a C# console program that takes binary data coming in through Serial COM1, converting each byte into ASCII hex, and then outputting those HEX characters out through ...
0
votes
1answer
109 views

When to run some code in a separate process

I am trying to list the times in which it is useful to run some code in a separate process. Does the following short list cover it? Speed: the obvious one. Multiprocess/distributed parallism Worker ...
0
votes
1answer
119 views

Celluloid actors parallel work slow?

I'm new to actors and just playing around in ruby using Celluloid. I have this code below module Enumerable # Simple parallel map using Celluloid::Futures def pmap(&block) futures = map { ...
3
votes
2answers
914 views

Difference between multithreaded programs on single and multiple cores

When programming using (pre-emptive) multithreading model on a single processor, we need to deal with synchronization, deadlocks, etc. Do any additional concerns appear (and correspondingly, new ...
6
votes
1answer
676 views

Python: Control subprocess from calling thread

I am working on a database interface to a MongoDB using Python Eve as an API. The database stores several documents containing parameters and values needed for some calculations. I wrote a Python ...
5
votes
2answers
749 views

are multithreading, multiprocessing, multitasking implemented at instruction set or OS?

On a computer with a single cpu core, must a multithreading program be implemented based on an OS? Can it be implemented in the instruction set and run without an OS? Can multiple programs run in ...
3
votes
1answer
270 views

How to efficiently implement this background processing chain?

I am working on an audio software that uses The EchoNest web service to identify and retrieve metadata about audio songs and I would like to have some advice on implementing a background processing ...
1
vote
1answer
456 views

How to effectively split jobs into groups for multiprocessing when the job sizes are unknown

With K processor cores, how to optimally split N jobs into groups, with each group to be processed sequentially by one processor core, when the time to process each job is unknown ahead of time and ...
10
votes
3answers
3k views

Python Multiprocessing with Queue vs ZeroMQ IPC

I am busy writing a Python application using ZeroMQ and implementing a variation of the Majordomo pattern as described in the ZGuide. I have a broker as an intermediary between a set of workers and ...
4
votes
1answer
1k views

Multiprocess RPC Architecture Design

I am currently working on a project that has client applications communicating with a server process. The client applications could be local to the same machine as the server process, on the same ...
15
votes
5answers
18k views

Can multiple CPU's / cores access the same RAM simultaneously?

This is what I guess would happen: If two cores tried to access the same address in RAM, one would have to wait for the other to access the RAM. The second time that each core would try to access ...
2
votes
3answers
2k views

Opinions on logging in multiprocess applications

We have written an application that spawns at least 9 parallel processes. All processes generate a lot of logging information. Currently we are using Python’s QueueHandler to consolidate all logs ...
2
votes
1answer
99 views

How to handle multi-processing of libraries which already spawn sub-processes?

I am having some trouble coming up with a good solution to limit sub-processes in a script which uses a multi-processed library and the script itself is also multi-processed. Both, the library and ...