projects
/
deliverable
/
binutils-gdb.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Change regcache list to be an hash map
[deliverable/binutils-gdb.git]
/
gdb
/
gdbsupport
/
ptid.h
diff --git
a/gdb/gdbsupport/ptid.h
b/gdb/gdbsupport/ptid.h
index ef52d55512600c3b108dcdee8e029523c430501d..232593af5d2daf304b2d24306da0b6588b79de8f 100644
(file)
--- a/
gdb/gdbsupport/ptid.h
+++ b/
gdb/gdbsupport/ptid.h
@@
-32,6
+32,8
@@
thread_stratum target that might want to sit on top.
*/
thread_stratum target that might want to sit on top.
*/
+#include <functional>
+
class ptid_t
{
public:
class ptid_t
{
public:
@@
-143,6
+145,17
@@
private:
long m_tid;
};
long m_tid;
};
+struct hash_ptid
+{
+ size_t operator() (const ptid_t &ptid) const
+ {
+ std::hash<long> long_hash;
+ return (long_hash (ptid.pid ())
+ + long_hash (ptid.lwp ())
+ + long_hash (ptid.tid ()));
+ }
+};
+
/* The null or zero ptid, often used to indicate no process. */
extern const ptid_t null_ptid;
/* The null or zero ptid, often used to indicate no process. */
extern const ptid_t null_ptid;
This page took
0.033057 seconds
and
4
git commands to generate.