From: Philippe Gerum <rpm@xenomai.org>
To: Jan Kiszka <jan.kiszka@siemens.com>
Cc: "Xenomai@xenomai.org" <Xenomai@xenomai.org>
Subject: Re: [Xenomai] rt_print_auto_init()
Date: Fri, 24 Jul 2015 17:34:30 +0200 [thread overview]
Message-ID: <55B25B06.6090004@xenomai.org> (raw)
In-Reply-To: <55B25A38.4010100@xenomai.org>
On 07/24/2015 05:31 PM, Philippe Gerum wrote:
> On 07/24/2015 05:29 PM, Philippe Gerum wrote:
>> On 07/24/2015 05:23 PM, Jan Kiszka wrote:
>>> On 2015-07-24 17:08, Philippe Gerum wrote:
>>>> On 07/24/2015 04:56 PM, Jan Kiszka wrote:
>>>>> On 2015-07-24 16:29, Philippe Gerum wrote:
>>>>>> On 07/23/2015 03:27 PM, Jan Kiszka wrote:
>>>>>>> On 2015-07-23 11:45, Philippe Gerum wrote:
>>>>>>>> On 07/23/2015 11:37 AM, Jan Kiszka wrote:
>>>>>>>>> On 2015-07-23 11:24, Philippe Gerum wrote:
>>>>>>>>>>
>>>>>>>>>> Hi Jan,
>>>>>>>>>>
>>>>>>>>>> Do you still have a use case for calling rt_print_auto_init(false) or
>>>>>>>>>> not calling rt_print_auto_init(true) from libcobalt's bootstrap code?
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Huh, that was a day-one feature, now 8 years old, barely remember the
>>>>>>>>> details. I'm currently not aware of a concrete scenario. It definitely
>>>>>>>>> makes sense to revisit this think.
>>>>>>>>>
>>>>>>>>> I guess one, if not the major problem back then was that the implicit
>>>>>>>>> malloc of the initialization step was not consistently causing a
>>>>>>>>> SIGDEBUG warning. That is now different.
>>>>>>>>>
>>>>>>>>
>>>>>>>> Since the current thread won't be notified until XNWARN is armed in its
>>>>>>>> TCB, any objection to move that call as a nop placeholder to the compat
>>>>>>>> section in libtrank, leaving the implicit init to libcobalt as currently?
>>>>>>>
>>>>>>> Ack.
>>>>>>>
>>>>>>
>>>>>> Ok, let's see how deep you can dive into your context stack these days:
>>>>>> what about rt_print_cleanup() now? I see no in-tree callers, and I
>>>>>> wonder whether there is any use case for an application to stop the
>>>>>> stdio support during runtime.
>>>>>
>>>>> I used to have one recently that was specifically interested in
>>>>> terminating the associated thread. But that case was modified later on
>>>>> due to other reasons. In principle, the value of this cleanup function
>>>>> is in the printer thread control, even if that means cutting of wrapped
>>>>> I/O (you could still print via unwrapped services then).
>>>>>
>>>>
>>>> Ok. Was it part of a broader feature aimed at moving the per-process rt
>>>> support to a quiescent state?
>>>
>>> No, rather about ensuring that if you terminate only the main thread in
>>> an application that believes this thread was the last one, the
>>> application as a whole terminates.
>>>
>>
>> We could probably tell the existing atexit() handler to wipe the helper
>> thread too.
>>
>
> mm, no. This would not exit, precisely.
>
However, we do have a TSD on the main thread, so signaling the helper
from the TSD destructor would do.
--
Philippe.
next prev parent reply other threads:[~2015-07-24 15:34 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-23 9:24 [Xenomai] rt_print_auto_init() Philippe Gerum
2015-07-23 9:37 ` Jan Kiszka
2015-07-23 9:45 ` Philippe Gerum
2015-07-23 13:27 ` Jan Kiszka
2015-07-24 14:29 ` Philippe Gerum
2015-07-24 14:56 ` Jan Kiszka
2015-07-24 15:08 ` Philippe Gerum
2015-07-24 15:23 ` Jan Kiszka
2015-07-24 15:29 ` Philippe Gerum
2015-07-24 15:31 ` Philippe Gerum
2015-07-24 15:34 ` Philippe Gerum [this message]
2015-07-23 13:57 ` Gilles Chanteperdrix
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=55B25B06.6090004@xenomai.org \
--to=rpm@xenomai.org \
--cc=Xenomai@xenomai.org \
--cc=jan.kiszka@siemens.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.