comp.lang.ada
 help / color / mirror / Atom feed
From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: pragma Thread_Local_Storage on record?
Date: Tue, 1 Mar 2016 16:55:46 +0100
Date: 2016-03-01T16:55:46+01:00	[thread overview]
Message-ID: <nb4e2o$bq8$1@gioia.aioe.org> (raw)
In-Reply-To: 0e3fb431-ee4b-46ca-b1a5-a78e3245d7f3@googlegroups.com

On 01/03/2016 16:22, hanslad@gmail.com wrote:
>
>> I suspect that one of the components of type Core is itself a record
>> and has a component which is not statically initialized.

[..]

I don't see how his could be useful for a messages queue which is 
normally shared between several tasks rather than owned by any. The 
latter looks like a low-level implementation-motivated design.

> Any idea on how I could implement such buffer in a Thread local data structure(record)?

A typical solution is Ada.Task_Attributes instantiated with an access 
type to the object. The object is allocated on demand (access 
dereference by the owner task).

-- 
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de


  reply	other threads:[~2016-03-01 15:55 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-01 13:45 pragma Thread_Local_Storage on record? hanslad
2016-03-01 14:44 ` Florian Weimer
2016-03-01 15:22   ` hanslad
2016-03-01 15:55     ` Dmitry A. Kazakov [this message]
2016-03-01 16:31       ` hanslad
2016-03-01 17:03         ` Dmitry A. Kazakov
2016-03-01 15:52 ` J-P. Rosen
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox