Skip to main content
Filter by
Sorted by
Tagged with
6 votes
1 answer
91 views

UB in SeqLock implementation in Rust

Below is the code that tries to share some memory between 2 threads (one writer and another reader) and uses sequential lock like mechanism to synchronize access. use std::alloc::Layout; use std::sync:...
Babur Makhmudov's user avatar
0 votes
2 answers
91 views

How to properly ensure an aggregate exists in another bounded context DDD

I realize that there are a bunch of posts somewhat covering this topic already, but there I am yet to find an exact answer to the question that I have. Lets say that I'm developing an application for ...
JackG's user avatar
  • 73
0 votes
2 answers
970 views

Region based isolation problem related to Swift 6 migration

During migration to Swift 6 I ran into this issue, which I haven't found a way around as of yet. The warning reads: Passing closure as a 'sending' parameter risks causing data races between code in ...
Jonny's user avatar
  • 16.4k
0 votes
0 answers
79 views

OpenMP Potential Data Race Not Happening

I am doing matrix multiplication using 1d array with Openmp. For the following code, I think data race may happen as I try to access the same location in different threads. However, it works fine and ...
robthatman's user avatar
0 votes
0 answers
40 views

Read one table write to another data race SQL solution

I'm currently learning about database transactions, isolation levels, and SQL in general. I've thought up a problem which involves a potential data race and can't seem to figure out the solution ...
JackG's user avatar
  • 73
0 votes
1 answer
57 views

Cache deletion and refreshing data race

I'm starting to learn about caching and have thought of the following problem, and really only see one way to solve it but I'm sure I am missing something Lets image that I have two endpoints, one for ...
JackG's user avatar
  • 73
0 votes
1 answer
79 views

Don't understand SCNSceneRenderer delegate data race warning

My app needs a reference to the SCNSceneRenderer for hit testing. I thus use SCNSceneRenderer delegate to get and store the reference as property in my ViewModel: @MainActor @Observable final class ...
Reinhard Männer's user avatar
2 votes
1 answer
116 views

Any real-life examples for memory_order_seq_cst?

It seems Release-Acquire ordering is enough in most cases, so is there any real-life examples where you can only use memory_order_seq_cst?(and Ordering::SeqCst, because rust shares same memory order ...
user24912723's user avatar
1 vote
1 answer
242 views

Why does version 3.22.0 of Valgrind-based Helgrind thread error detector reports data races and version 3.18.1 does not?

1.Background The following C++ code from cppreference.com illustrates how std::condition_variable is used in combination with a std::mutex to facilitate inter-thread communication. #include <...
NeverStopLearning's user avatar
1 vote
0 answers
50 views

Is a mqd_t of a POSIX-MQ a critical resource?

I need to send messages through same Posix-MQ in multiple threads. These threads all act as a "producer" of messages, while the "consumer" is another process. Should I do mq_open ...
Leon's user avatar
  • 2,107
0 votes
1 answer
335 views

Why do Valgrind-based Helgrind thread error detector and Google ThreadSanitizer (TSan) report different data race detection results?

1.Background ① The C++ code in Listing 1 below aims at handling data race for the s variable that the Produce function (running on the main thread) and Consume function (running on the t thread ...
NeverStopLearning's user avatar
-1 votes
1 answer
616 views

Getting WARNING: DATA RACE in golang

I am using this golang size library https://pkg.go.dev/github.com/streamonkey/size which calculates variable's memory consumption at runtime. Here is the link to source code of the library https://...
Sid Sidhant's user avatar
1 vote
0 answers
152 views

How to allow controllable data races in C++ without getting UB

While implementing the transactional memory algorithm TL2, we noticed that it allows data races: while committing the write transaction, a reading transaction can read the same memory region. However, ...
JungleTryne's user avatar
0 votes
0 answers
177 views

Avoiding data races using multi-threading and accessing a shared vector in Julia

I have a code pattern that looks something like this: function output(G) hashes = [] objects = [] for g ∈ G ng = compute(g) h = hash(ng) if h ∉ hashes ...
Michael Zurel's user avatar
0 votes
0 answers
102 views

Data races detected while deleting QThreads

I am working on a multithread project and I am trying to detect thread inconsistency using helgrind (valgrind tool). After closing the app I get multiples reports like this: ==50932== Possible data ...
Dazckel's user avatar
  • 41

15 30 50 per page
1
2 3 4 5
9