• Specifying standard headers that don't require run time support

    From Ian Collins@21:1/5 to All on Tue Jan 5 13:16:40 2016
    Hello,

    Has there ever been a move to formally identify standard library
    headers that don't require run time (especially dynamic allocation)
    support? An obvious example would be <array>.

    The reason I ask is to make at least a subset of the standard library
    available to smaller embedded projects.



    --
    Ian Collins


    [ comp.std.c++ is moderated. To submit articles, try posting with your ]
    [ newsreader. If that fails, use mailto:std-cpp-submit@vandevoorde.com ]
    [ --- Please see the FAQ before posting. --- ]
    [ FAQ: http://www.comeaucomputing.com/csc/faq.html ]

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Martin Bonner@21:1/5 to Ian Collins on Fri Jan 15 13:07:17 2016
    On Tuesday, 5 January 2016 20:20:10 UTC+1, Ian Collins wrote:
    Hello,

    Has there ever been a move to formally identify standard library
    headers that don't require run time (especially dynamic allocation)
    support? An obvious example would be <array>.

    The reason I ask is to make at least a subset of the standard library available to smaller embedded projects.


    I don't think so. It seems like a useful exercise if you want to start.

    Expect arguments about whether "exceptions" require run-time support.

    Expect arguments about whether it means "headers that are forbidden from requiring run-time support" or "headers that could be implemented
    without using run-time support".

    Perhaps "header" is too coarse a granularity?

    ... but, I repeat, it still sounds like a broadly worthwhile exercise.



    --
    [ comp.std.c++ is moderated. To submit articles, try posting with your ]
    [ newsreader. If that fails, use mailto:std-cpp-submit@vandevoorde.com ]
    [ --- Please see the FAQ before posting. --- ]
    [ FAQ: http://www.comeaucomputing.com/csc/faq.html ]

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Bo Persson@21:1/5 to Ian Collins on Fri Jan 15 13:07:39 2016
    On 2016-01-05 20:16, Ian Collins wrote:


    Hello,

    Has there ever been a move to formally identify standard library
    headers that don't require run time (especially dynamic allocation)
    support? An obvious example would be <array>.

    The reason I ask is to make at least a subset of the standard library available to smaller embedded projects.
    



    No, I don't think so.

    The standards committee is, in general, not very fond of defining
    language subsets. They strongly prefer compilers to implement the
    whole language.


    Bo Persson



    --
    [ comp.std.c++ is moderated. To submit articles, try posting with your ]
    [ newsreader. If that fails, use mailto:std-cpp-submit@vandevoorde.com ]
    [ --- Please see the FAQ before posting. --- ]
    [ FAQ: http://www.comeaucomputing.com/csc/faq.html ]

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Francis Glassborow@21:1/5 to Bo Persson on Mon Feb 8 11:27:42 2016
    On 15/01/2016 19:07, Bo Persson wrote:


    On 2016-01-05 20:16, Ian Collins wrote:



    Hello,

    Has there ever been a move to formally identify standard library
    headers that don't require run time (especially dynamic allocation)
    support? An obvious example would be <array>.

    The reason I ask is to make at least a subset of the standard library
    available to smaller embedded projects.
    



    No, I don't think so.

    The standards committee is, in general, not very fond of defining
    language subsets. They strongly prefer compilers to implement the
    whole language.


    Bo Persson



    Yes, but I do not think this is about defining language subsets but is
    more akin to the complexity guarantees. And on that line I would
    prefer to see no run time support marked as a requirement where it can
    be achieved.

    Francis



    --
    [ comp.std.c++ is moderated. To submit articles, try posting with your ]
    [ newsreader. If that fails, use mailto:std-cpp-submit@vandevoorde.com ]
    [ --- Please see the FAQ before posting. --- ]
    [ FAQ: http://www.comeaucomputing.com/csc/faq.html ]

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Ian Collins@21:1/5 to Wouter van Ooijen on Sat Feb 20 15:18:30 2016
    Wouter van Ooijen wrote:


    Op 15-Jan-16 om 8:07 PM schreef Bo Persson:



    On 2016-01-05 20:16, Ian Collins wrote:




    Hello,

    Has there ever been a move to formally identify standard library
    headers that don't require run time (especially dynamic allocation)
    support? An obvious example would be <array>.

    The reason I ask is to make at least a subset of the standard library
    available to smaller embedded projects.
    



    No, I don't think so.

    The standards committee is, in general, not very fond of defining
    language subsets. They strongly prefer compilers to implement the
    whole language.


    The question wass not about a compiler implementing a subset, but
    about library functions (or headers, as groups of functions) that do
    not need a particular feature that is incompatible with a specialized
    use, like heap and execptions (and maybe RTTO) not being compatible
    with (very) small micro-controllers.


    Not necessarily small, my application was for 32 bit ARM.

    A ban on dynamic memory is usage is common in embedded systems. This
    is a big niche!


    --
    Ian Collins


    [ comp.std.c++ is moderated. To submit articles, try posting with your ]
    [ newsreader. If that fails, use mailto:std-cpp-submit@vandevoorde.com ]
    [ --- Please see the FAQ before posting. --- ]
    [ FAQ: http://www.comeaucomputing.com/csc/faq.html ]

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Wouter van Ooijen@21:1/5 to All on Mon Feb 8 11:27:16 2016
    Op 15-Jan-16 om 8:07 PM schreef Bo Persson:


    On 2016-01-05 20:16, Ian Collins wrote:



    Hello,

    Has there ever been a move to formally identify standard library
    headers that don't require run time (especially dynamic allocation)
    support? An obvious example would be <array>.

    The reason I ask is to make at least a subset of the standard library
    available to smaller embedded projects.
    



    No, I don't think so.

    The standards committee is, in general, not very fond of defining
    language subsets. They strongly prefer compilers to implement the
    whole language.


    The question wass not about a compiler implementing a subset, but
    about library functions (or headers, as groups of functions) that do
    not need a particular feature that is incompatible with a specialized
    use, like heap and execptions (and maybe RTTO) not being compatible
    with (very) small micro-controllers.

    Wouter



    --
    [ comp.std.c++ is moderated. To submit articles, try posting with your ]
    [ newsreader. If that fails, use mailto:std-cpp-submit@vandevoorde.com ]
    [ --- Please see the FAQ before posting. --- ]
    [ FAQ: http://www.comeaucomputing.com/csc/faq.html ]

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Keith Thompson@21:1/5 to Ian Collins on Fri Apr 1 19:07:25 2016
    Ian Collins <ian-news@this.is.invalid> writes:
    Has there ever been a move to formally identify standard library
    headers that don't require run time (especially dynamic allocation)
    support? An obvious example would be <array>.

    The reason I ask is to make at least a subset of the standard library available to smaller embedded projects.

    That sounds similar to the existing distinction between hosted and
    freestanding implementations. C++11 17.6.1.3 [compliance] has a list of
    the subset of the standard headers that must be supported for
    freestanding implementations. Perhaps <array> (and others?) should be
    added to that list.


    --
    Keith Thompson (The_Other_Keith) kst-u@mib.org <http://www.ghoti.net/~kst> Working, but not speaking, for JetHead Development, Inc.
    "We must do something. This is something. Therefore, we must do this."
    -- Antony Jay and Jonathan Lynn, "Yes Minister"


    [ comp.std.c++ is moderated. To submit articles, try posting with your ]
    [ newsreader. If that fails, use mailto:std-cpp-submit@vandevoorde.com ]
    [ --- Please see the FAQ before posting. --- ]
    [ FAQ: http://www.comeaucomputing.com/csc/faq.html ]

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)