guile-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] Fix thread-unsafe lazy initializations


From: Mark H Weaver
Subject: Re: [PATCH] Fix thread-unsafe lazy initializations
Date: Thu, 23 Jan 2014 23:04:22 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)

Panicz Maciej Godek <address@hidden> writes:

>>> According to Ludovic, Chris' example corresponds to
>>> test-pthread-create-secondary.c -- yet they differ in that guile's
>>> test doesn't use scm_c_eval_string, which helped to reveal the
>>> problem.
>>> Shouldn't it be added to the test suite along with the patch, for 
>>> regression?

Here's what I should have written in response to the above: this will be
a good thing to do when I have a patch to fix Chris' problem.  However,
that's not what this patch is.

>> It would be a lot of work to add tests for all of these fixes, and I'm
>> not sure it would be easy to write tests that would detect these
>> problems with reasonably high probability.
>
> But if you come up with some ideas, I'd be glad to hear them, and then
> I could perhaps implement them. Maybe it would be a nice feature if
> the "make check" instruction would generate a report that would gather
> all the relevant information about the environment that could be sent
> to some public address.

I don't think such a thing belongs in "make check".  I'm not even sure
such a thing belongs in Guile.  I think it belongs in a separate bug
reporting tool.  Such projects already exist, such as ABRT.  The job is
pretty much the same for any piece of software, so it shouldn't be
reinvented in every piece of software.

>>> Could we come up with any tests that would prove with certainty that
>>> there are still some failures caused by lazy intializations of
>>> modules?
>>
>> I don't need such a test.  It's obvious from the code that module
>> autoloading is not thread safe.
>
> But they might prove good for the time when you progress with your
> work to suspect that the issue is already solved :)

Please, this is a discussion for another time.  I asked for comments
about the patch I just wrote.  I didn't ask for suggestions for new jobs
that I should do that are only vaguely related to the patch I just
wrote.  As I said, I'm overloaded enough as it is.

     Mark



reply via email to

[Prev in Thread] Current Thread [Next in Thread]