[PATCH] c-user: Clarify object services
Gedare Bloom
gedare at rtems.org
Tue Feb 2 19:53:59 UTC 2021
On Tue, Feb 2, 2021 at 12:19 PM Sebastian Huber <
sebastian.huber at embedded-brains.de> wrote:
> On 02/02/2021 16:56, Gedare Bloom wrote:
>
> >
> >
> > On Tue, Feb 2, 2021 at 8:42 AM Sebastian Huber
> > <sebastian.huber at embedded-brains.de
> > <mailto:sebastian.huber at embedded-brains.de>> wrote:
> >
> > On 02/02/2021 16:37, Gedare Bloom wrote:
> >
> > > -.. rubric:: NOTES:
> > > +.. rubric:: CONSTRAINTS:
> > >
> > > -This directive is strictly local and does not impact task
> > scheduling.
> > >
> > >
> > > I may have missed the discussion, but this note is being removed
> > > without being added elsewhere.
> > >
> > > Is it implied that all functions are local and do not impact task
> > > scheduling, unless otherwise constrained?
> > No, I replaced the above with below:
> > >
> > > +The following constraints apply to this directive:
> > > +
> > > +* The directive is implemented by a macro and may be called
> > from
> > > within C/C++
> > > + constant expressions. In addition, a function
> implementation
> > > of the
> > > + directive exists for bindings to other programming
> languages.
> > >
> > I could also add this:
> >
> > * The directive will not cause the calling task to be preempted.
> >
> > I think that will help for clarity, perhaps. It is good to know which
> > rtems_ services can/cannot preempt
> Ok, I will try to add at least one context and at least one preemption
> constraint to each directive.
> >
> > From my point of view it was clear that something which "may be
> > called
> > from within C/C++ constant expressions" cannot impact task
> scheduling.
> >
> >
> > may is not must. If you call it from a non-constant expression it
> > still will not preempt.
> >
> > Also, I think it is a bit odd to say "called from within" a constant.
> > maybe "used from within" is better? You don't actually make a call
> > when it is constant.
> I would keep the "called from within". It is called by the compiler and
> not the processor. In C++ you nowadays have a lot of constexpr functions
> (or templates).
>
> ok
> --
> embedded brains GmbH
> Herr Sebastian HUBER
> Dornierstr. 4
> 82178 Puchheim
> Germany
> email: sebastian.huber at embedded-brains.de
> phone: +49-89-18 94 741 - 16
> fax: +49-89-18 94 741 - 08
>
> Registergericht: Amtsgericht München
> Registernummer: HRB 157899
> Vertretungsberechtigte Geschäftsführer: Peter Rasmussen, Thomas Dörfler
> Unsere Datenschutzerklärung finden Sie hier:
> https://embedded-brains.de/datenschutzerklaerung/
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/devel/attachments/20210202/f37419e2/attachment.html>
More information about the devel
mailing list