Ramine
3/12/2015 8:55:00 AM
Hello,
My Iterator is not actually using a Binary search, it is using something
that look like Binary search that gives the same result as a binary
search and that works on concurrent AVL trees and concurrent Red Blck
trees and my Iterator is better than the Fail Safe Iterator.
Thank you,
Amine Moulay Ramdane.
On 3/12/2015 1:45 AM, Ramine wrote:
>
> Hello,
>
> I was thinking about the Iterators and concurrency and thinking about
> the following Iterators:
>
> Fail Safe Iterators
> Fail Fast Iterators
>
> I think that Fail Safe takes too much memory, and Fail Fast is not good,
> so what i was thinking about is since we are using concurrency the
> iterator can use the "Binary Search" and return the position of the
> element and if it doesn't find the element it returns the positions
> lesser than the element and if the element is not the first element of
> the datastructure, or is not the last element of the datastructure , it
> will return the next element of the element that is lesser than the
> element that we didn't find in the datastructure, and if the element
> that is lesser is the first element it will test if the element is
> lesser so it will return the next element, or if the element is greater
> it will return the element , and if the element that is returned is the
> last element of the datastructurte it will return "no element found"..
> this way the iterator in the presenc of concurrency will use a Binary
> search that return a view of the datastructure that look like Fail Safe
> Iterators, but my way will allow to use less memory than Fail Safe
> Iterators.
>
>
> This is how i will implement my Iterators for my concurrent AVL tree and
> my concurrent Red Black Tree..
>
>
>
> Thank you,
> Amine Moulay Ramdane.
>
>
>
>