Commit Graph

2 Commits

Author SHA1 Message Date
Carlos Alberto Enciso bab129f2d3 [ADT] Add IntervalTree - light tree data structure to hold intervals.
Fix build failure in:

  https://lab.llvm.org/buildbot/#/builders/36/builds/25424
  error: comparison of integers of different signs:
  'const unsigned long' and 'const int' [-Werror,-Wsign-compare]

  Reviewed By: Orlando

  Differential Revision: https://reviews.llvm.org/D125776
2022-09-27 12:48:44 +01:00
Carlos Alberto Enciso 6584d1f930 [ADT] Add IntervalTree - light tree data structure to hold intervals.
It allows finding all intervals that overlap with any given point.
At this time, it does not support any deletion or rebalancing
operations.

The IntervalTree is designed to be set up once, and then queried
without any further additions.

Reviewed By: psamolysov, probinson

Differential Revision: https://reviews.llvm.org/D125776
2022-09-27 08:22:28 +01:00