Menu

Using Ada.Containers

2015-01-27
2016-06-14
  • Simon Wright

    Simon Wright - 2015-01-27

    srini said, in [tickets:#9],

    a. can we use the Ada.Containers packages with the ARM cross compiler. If so apart from RAM limitations, what other restrictions are there?

     

    Related

    Tickets: #9

  • Simon Wright

    Simon Wright - 2015-01-27

    There are two problems: first, I've only included a limited subset of the full RTS, and there’s no Ada.Containers code in there; and second, the restrictions I’ve imposed (see package System) mean that they couldn’t be used (yet). Specifically, No_Allocators means you can only use the Containers that don’t involve memory allocation (i.e. Ada.Containers.Bounded_Vectors); and even then No_Dispatch means you couldn’t compile the subprograms that take ‘Class even if I’d included Ada.Streams and Ada.Iterator_Interfaces.

    It shouldn’t be too hard to solve these problems; I chose the simplest FreeRTOS memory allocator possible, which has a mere 15k of memory to be used for all the task stacks and doesn’t support deallocation, but there are three others and we could always roll our own.

     
  • Simon Wright

    Simon Wright - 2015-05-03

    The 20150406 release includes Bounded_Vectors and Bounded_Hashed_Maps, The new iterators (for some F in Foo loop ...) are NOT supported (they require finalization). See the README for this distribution.

     

    Last edit: Simon Wright 2015-08-18
  • Simon Wright

    Simon Wright - 2016-06-14

    The 20160314 release supports generalized iteration over containers ("for all E of C
    loop"). Note, this is achieved by removing tampering checks. While
    tampering errors are rare, it would be as well to check algorithms
    using a fully-featured desktop compiler.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.