C++ Logo

std-proposals

Advanced search

Re: [std-proposals] std::thread::detach() can segfault

From: Thiago Macieira <thiago_at_[hidden]>
Date: Wed, 11 Dec 2024 19:45:56 -0300
On Wednesday 11 December 2024 19:11:24 Brasilia Standard Time Phil Bouchard
via Std-Proposals wrote:
> Sorry for the confusion but I'm not using pthread_create directly but
> std::thread() does. All the C++ thread calls use the underlying pthread
> library.

This is looking like a bug report. Please submit to your Standard Library
vendor a small, self-contained testcase of the problem. If they determine the
bug is in pthread, you and they together can file that with the C library
implementation.

If they determine the problem is not a bug, but a limitation of pthread and
that ends up exposed in std::thread, there may be something to be added to the
C++ library.

-- 
Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
  Principal Engineer - Intel DCAI Platform & System Engineering

Received on 2024-12-11 22:46:06