[PolyORB-users] Memory management optimization in sequences

Thomas Quinot quinot at adacore.com
Mon May 19 12:12:54 CEST 2008


* Maciej Sobczak, 2008-05-19 :

> This means that the single-element append operations have linear complexity.
> Is it possible to change the implementation to something like:
> 
>     type Sequence is new Ada.Finalization.Controlled with record
>        Length  : Natural;
>        Used    : Natural;
>        Content : Element_Array_Access;
>     end record;
> 
> which would allow amortized O(1) complexity for appends, for the price 
> of more memory consumption on average.

Sure, feel free to submit a patch.

-- 
Thomas Quinot, Ph.D. ** quinot at adacore.com ** Senior Software Engineer
               AdaCore -- Paris, France -- New York, USA


More information about the PolyORB-users mailing list