projects
/
gem5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6ccf28c
)
range_map: Add a method to find which range a single value falls into.
author
Nathan Binkert
<nate@binkert.org>
Fri, 10 Oct 2008 05:19:38 +0000
(22:19 -0700)
committer
Nathan Binkert
<nate@binkert.org>
Fri, 10 Oct 2008 05:19:38 +0000
(22:19 -0700)
src/base/range_map.hh
patch
|
blob
|
history
diff --git
a/src/base/range_map.hh
b/src/base/range_map.hh
index 1c121925df108df39a503cc0ce6d25b60f86b951..0ffc28ed995ef1b3e7526d95b8dc66ab3e86f30c 100644
(file)
--- a/
src/base/range_map.hh
+++ b/
src/base/range_map.hh
@@
-69,6
+69,13
@@
class range_map
return tree.end();
}
+ template <class U>
+ const iterator
+ find(const U &r)
+ {
+ return find(RangeSize(r, 1));
+ }
+
template <class U>
bool
intersect(const Range<U> &r)