Skip to content

Commit

Permalink
Define the equality operator for qvi_hwloc_bitmap_s. (#252)
Browse files Browse the repository at this point in the history
Signed-off-by: Samuel K. Gutierrez <[email protected]>
  • Loading branch information
samuelkgutierrez authored Jul 26, 2024
1 parent 3d6ea2a commit 6146b9f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 11 deletions.
7 changes: 7 additions & 0 deletions src/qvi-hwloc.h
Original file line number Diff line number Diff line change
Expand Up @@ -451,6 +451,13 @@ struct qvi_hwloc_bitmap_s {
{
qvi_hwloc_bitmap_delete(&m_data);
}
/** Equality operator. */
bool
operator==(
const qvi_hwloc_bitmap_s &x
) const {
return hwloc_bitmap_compare(cdata(), x.cdata()) == 0;
}
/** Assignment operator. */
void
operator=(const qvi_hwloc_bitmap_s &src)
Expand Down
11 changes: 0 additions & 11 deletions src/qvi-hwpool.cc
Original file line number Diff line number Diff line change
Expand Up @@ -47,17 +47,6 @@
#include "qvi-utils.h"

#if 0
/**
* Returns whether two cpusets are equal.
*/
static bool
cpusets_equal(
hwloc_const_cpuset_t a,
hwloc_const_cpuset_t b
) {
return hwloc_bitmap_compare(a, b) == 0;
}

/**
*
*/
Expand Down

0 comments on commit 6146b9f

Please sign in to comment.