Skip to main content

All Questions

3 votes
1 answer
76 views

I have been making a deep learning framework modelled after Pytorch in pure Python. I have made good progress but my framework is currently not seamless to use because the end user of the framework ...
Featherball's user avatar
4 votes
1 answer
187 views

I have a C# class with a number of properties that are read by and set by multiple threads. I use a simple lock when getting and setting them in order to have a full-fence memory barrier, so member ...
Joe's user avatar
  • 140
0 votes
0 answers
54 views

A while ago I wrote for my own needs a (non-reentrant) read-write lock for kotlin's coroutines. I got no reactions on the relevant github thread. I think it's a nice code, so I thought I'd share it ...
Al.G.'s user avatar
  • 109
4 votes
3 answers
709 views

The task is educational. The basic functionality is working. Here are some questions for my code. Please give me feedback. Main: Architecture & Design: Is the decomposition appropriate? Should ...
bonnyped's user avatar
7 votes
1 answer
308 views

EDIT TL;DR Anyone who might consider using my code below in production and can afford to require C++-20 standard should rather use std::barrier as suggested by G. ...
user2233709's user avatar
7 votes
2 answers
456 views

I am writing some C# code. I want to find a data structure that can implement the following strategy: FIFO data access mode Multiple independent threads add elements to the data structure At a random ...
Aycon's user avatar
  • 225
9 votes
2 answers
875 views

I'm unsure whether the following is thread safe. I want to say it is because the static state is only assigned to within the lock. However I'm more of a js programmer so this is out of my comfort ...
aaaaaa's user avatar
  • 221
8 votes
3 answers
1k views

I wrote this small service which emulates a payment registration system. My main concern is thread-safety in general, and the caller shouldn't be able to register a payment while one is already in ...
Mohamed's user avatar
  • 183
2 votes
1 answer
70 views

I wrote this code for a make-up assignment to pass one of my college class and graduate from my program in the field of electronic and embedded system. It's pretty much the realization of a solar ...
Null_DreiAcht's user avatar
6 votes
3 answers
754 views

The following code is designed for handling real-time messages. It assumes there will be only two threads using the RingBuffer object: A provider thread calls the <...
Gabriella Chaos's user avatar
3 votes
1 answer
82 views

Previous version of my ThreadPool is here This one is improved and updated using advices: added variables list (vector) to not use std::any. it's very basic and simple. added thread-safe queue !main....
vansergh's user avatar
  • 313
3 votes
1 answer
74 views

ThreadPool, Task I continue to study C++ for the fourth month, every day from morning to night. Today I want to submit my Thread Pool for review. I'm not really sure if I have the right code style, ...
vansergh's user avatar
  • 313
2 votes
1 answer
117 views

I'm new to threading in Python. I want to use it to speed up taking images on my lab computer. I have the following dummy code: ...
AccidentalTaylorExpansion's user avatar
4 votes
1 answer
296 views

What it does The code creates a logger class which instantiates a circular buffer at construction and uses producer-consumer style approach using condition_variable to log and print the messages to ...
wwite's user avatar
  • 83
4 votes
1 answer
559 views

I have implemented an Iterator for my Pojo class. The purpose here is to lazily decode multiple ...
William's user avatar
  • 141

15 30 50 per page
1
2 3 4 5
36