Skip to content

Commit

Permalink
docs: Document deprecated gather/scatter
Browse files Browse the repository at this point in the history
This uses the text from Vc 0.7 for those functions.

Signed-off-by: Matthias Kretz <kretz@kde.org>
  • Loading branch information
mattkretz committed Feb 25, 2016
1 parent f3be3ea commit 85f4e21
Show file tree
Hide file tree
Showing 2 changed files with 255 additions and 19 deletions.
181 changes: 169 additions & 12 deletions common/gatherinterface.h
Original file line number Diff line number Diff line change
Expand Up @@ -214,8 +214,23 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Vc_ASSERT_GATHER_PARAMETER_TYPES_;
gatherImplementation(mem, adjustIndexParameter(std::forward<IT>(indexes)), mask);
}
///@}

/// \name Deprecated Members
///@{

/// \deprecated Use Vc::array or Vc::vector subscripting instead.
/**
* \deprecated Use Vc::array or Vc::vector subscripting instead.
*
* \param array A pointer into memory (without alignment restrictions).
* \param member1 If \p array points to a struct, \p member1 determines the member in the struct to
* be read. Thus the offsets in \p indexes are relative to the \p array and not to
* the size of the gathered type (i.e. array[i].*member1 is accessed instead of
* (&(array->*member1))[i])
* \param indexes Determines the offsets into \p array where the values are gathered from/scattered
* to. The type of indexes can either be an integer vector or a type that supports
* operator[] access.
*/
template <typename S1, typename IT>
inline Vc_DEPRECATED("use the subscript operator to Vc::array or Vc::vector instead.")
Vc_CURRENT_CLASS_NAME(const S1 *array, const EntryType S1::*member1,
Expand All @@ -225,7 +240,20 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
array, indexes)[member1]
.gatherArguments());
}
/// \deprecated Use Vc::array or Vc::vector subscripting instead.

/**
* \deprecated Use Vc::array or Vc::vector subscripting instead.
*
* \param array A pointer into memory (without alignment restrictions).
* \param member1 If \p array points to a struct, \p member1 determines the member in the struct to
* be read. Thus the offsets in \p indexes are relative to the \p array and not to
* the size of the gathered type (i.e. array[i].*member1 is accessed instead of
* (&(array->*member1))[i])
* \param indexes Determines the offsets into \p array where the values are gathered from/scattered
* to. The type of indexes can either be an integer vector or a type that supports
* operator[] access.
* \param mask If a mask is given only the active entries will be gathered/scattered.
*/
template <typename S1, typename IT>
inline Vc_DEPRECATED("use the subscript operator to Vc::array or Vc::vector instead.")
Vc_CURRENT_CLASS_NAME(const S1 *array, const EntryType S1::*member1,
Expand All @@ -236,7 +264,21 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
.gatherArguments(),
mask);
}
/// \deprecated Use Vc::array or Vc::vector subscripting instead.

/**
* \deprecated Use Vc::array or Vc::vector subscripting instead.
*
* \param array A pointer into memory (without alignment restrictions).
* \param member1 If \p array points to a struct, \p member1 determines the member in the struct to
* be read. Thus the offsets in \p indexes are relative to the \p array and not to
* the size of the gathered type (i.e. array[i].*member1 is accessed instead of
* (&(array->*member1))[i])
* \param member2 If \p member1 is a struct then \p member2 selects the member to be read from that
* struct (i.e. array[i].*member1.*member2 is read).
* \param indexes Determines the offsets into \p array where the values are gathered from/scattered
* to. The type of indexes can either be an integer vector or a type that supports
* operator[] access.
*/
template <typename S1, typename S2, typename IT>
inline Vc_DEPRECATED("use the subscript operator to Vc::array or Vc::vector instead.")
Vc_CURRENT_CLASS_NAME(const S1 *array, const S2 S1::*member1,
Expand All @@ -247,7 +289,22 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
array, indexes)[member1][member2]
.gatherArguments());
}
/// \deprecated Use Vc::array or Vc::vector subscripting instead.

/**
* \deprecated Use Vc::array or Vc::vector subscripting instead.
*
* \param array A pointer into memory (without alignment restrictions).
* \param member1 If \p array points to a struct, \p member1 determines the member in the struct to
* be read. Thus the offsets in \p indexes are relative to the \p array and not to
* the size of the gathered type (i.e. array[i].*member1 is accessed instead of
* (&(array->*member1))[i])
* \param member2 If \p member1 is a struct then \p member2 selects the member to be read from that
* struct (i.e. array[i].*member1.*member2 is read).
* \param indexes Determines the offsets into \p array where the values are gathered from/scattered
* to. The type of indexes can either be an integer vector or a type that supports
* operator[] access.
* \param mask If a mask is given only the active entries will be gathered/scattered.
*/
template <typename S1, typename S2, typename IT>
inline Vc_DEPRECATED("use the subscript operator to Vc::array or Vc::vector instead.")
Vc_CURRENT_CLASS_NAME(const S1 *array, const S2 S1::*member1,
Expand All @@ -259,7 +316,18 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
.gatherArguments(),
mask);
}
/// \deprecated Use Vc::array or Vc::vector subscripting instead.

/**
* \deprecated Use Vc::array or Vc::vector subscripting instead.
*
* \param array A pointer into memory (without alignment restrictions).
* \param ptrMember1 If \p array points to a struct, \p member1 determines the member in the struct to
* be read. Thus the offsets in \p indexes are relative to the \p array and not to
* the size of the gathered type (i.e. array[i].*member1 is accessed instead of
* (&(array->*member1))[i])
* \param outerIndexes
* \param innerIndexes
*/
template <typename S1, typename IT1, typename IT2>
inline Vc_DEPRECATED("use the subscript operator to Vc::array or Vc::vector instead.")
Vc_CURRENT_CLASS_NAME(const S1 *array, const EntryType *const S1::*ptrMember1,
Expand All @@ -270,7 +338,19 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
array, outerIndexes)[ptrMember1][innerIndexes]
.gatherArguments());
}
/// \deprecated Use Vc::array or Vc::vector subscripting instead.

/**
* \deprecated Use Vc::array or Vc::vector subscripting instead.
*
* \param array A pointer into memory (without alignment restrictions).
* \param ptrMember1 If \p array points to a struct, \p member1 determines the member in the struct to
* be read. Thus the offsets in \p indexes are relative to the \p array and not to
* the size of the gathered type (i.e. array[i].*member1 is accessed instead of
* (&(array->*member1))[i])
* \param outerIndexes
* \param innerIndexes
* \param mask If a mask is given only the active entries will be gathered/scattered.
*/
template <typename S1, typename IT1, typename IT2>
inline Vc_DEPRECATED("use the subscript operator to Vc::array or Vc::vector instead.")
Vc_CURRENT_CLASS_NAME(const S1 *array, const EntryType *const S1::*ptrMember1,
Expand All @@ -282,7 +362,19 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
.gatherArguments(),
mask);
}
/// \deprecated Use Vc::array or Vc::vector subscripting instead.

/**
* \deprecated Use Vc::array or Vc::vector subscripting instead.
*
* \param array A pointer into memory (without alignment restrictions).
* \param member1 If \p array points to a struct, \p member1 determines the member in the struct to
* be read. Thus the offsets in \p indexes are relative to the \p array and not to
* the size of the gathered type (i.e. array[i].*member1 is accessed instead of
* (&(array->*member1))[i])
* \param indexes Determines the offsets into \p array where the values are gathered from/scattered
* to. The type of indexes can either be an integer vector or a type that supports
* operator[] access.
*/
template <typename S1, typename IT>
inline Vc_DEPRECATED("use the subscript operator to Vc::array or Vc::vector "
"instead.") void gather(const S1 *array,
Expand All @@ -293,7 +385,20 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
array, indexes)[member1]
.gatherArguments());
}
/// \deprecated Use Vc::array or Vc::vector subscripting instead.

/**
* \deprecated Use Vc::array or Vc::vector subscripting instead.
*
* \param array A pointer into memory (without alignment restrictions).
* \param member1 If \p array points to a struct, \p member1 determines the member in the struct to
* be read. Thus the offsets in \p indexes are relative to the \p array and not to
* the size of the gathered type (i.e. array[i].*member1 is accessed instead of
* (&(array->*member1))[i])
* \param indexes Determines the offsets into \p array where the values are gathered from/scattered
* to. The type of indexes can either be an integer vector or a type that supports
* operator[] access.
* \param mask If a mask is given only the active entries will be gathered/scattered.
*/
template <typename S1, typename IT>
inline Vc_DEPRECATED("use the subscript operator to Vc::array or Vc::vector "
"instead.") void gather(const S1 *array,
Expand All @@ -306,7 +411,21 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
.gatherArguments(),
mask);
}
/// \deprecated Use Vc::array or Vc::vector subscripting instead.

/**
* \deprecated Use Vc::array or Vc::vector subscripting instead.
*
* \param array A pointer into memory (without alignment restrictions).
* \param member1 If \p array points to a struct, \p member1 determines the member in the struct to
* be read. Thus the offsets in \p indexes are relative to the \p array and not to
* the size of the gathered type (i.e. array[i].*member1 is accessed instead of
* (&(array->*member1))[i])
* \param member2 If \p member1 is a struct then \p member2 selects the member to be read from that
* struct (i.e. array[i].*member1.*member2 is read).
* \param indexes Determines the offsets into \p array where the values are gathered from/scattered
* to. The type of indexes can either be an integer vector or a type that supports
* operator[] access.
*/
template <typename S1, typename S2, typename IT>
inline Vc_DEPRECATED("use the subscript operator to Vc::array or Vc::vector "
"instead.") void gather(const S1 *array, const S2 S1::*member1,
Expand All @@ -317,7 +436,22 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
array, indexes)[member1][member2]
.gatherArguments());
}
/// \deprecated Use Vc::array or Vc::vector subscripting instead.

/**
* \deprecated Use Vc::array or Vc::vector subscripting instead.
*
* \param array A pointer into memory (without alignment restrictions).
* \param member1 If \p array points to a struct, \p member1 determines the member in the struct to
* be read. Thus the offsets in \p indexes are relative to the \p array and not to
* the size of the gathered type (i.e. array[i].*member1 is accessed instead of
* (&(array->*member1))[i])
* \param member2 If \p member1 is a struct then \p member2 selects the member to be read from that
* struct (i.e. array[i].*member1.*member2 is read).
* \param indexes Determines the offsets into \p array where the values are gathered from/scattered
* to. The type of indexes can either be an integer vector or a type that supports
* operator[] access.
* \param mask If a mask is given only the active entries will be gathered/scattered.
*/
template <typename S1, typename S2, typename IT>
inline Vc_DEPRECATED("use the subscript operator to Vc::array or Vc::vector "
"instead.") void gather(const S1 *array, const S2 S1::*member1,
Expand All @@ -330,7 +464,18 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
.gatherArguments(),
mask);
}
/// \deprecated Use Vc::array or Vc::vector subscripting instead.

/**
* \deprecated Use Vc::array or Vc::vector subscripting instead.
*
* \param array A pointer into memory (without alignment restrictions).
* \param ptrMember1 If \p array points to a struct, \p member1 determines the member in the struct to
* be read. Thus the offsets in \p indexes are relative to the \p array and not to
* the size of the gathered type (i.e. array[i].*member1 is accessed instead of
* (&(array->*member1))[i])
* \param outerIndexes
* \param innerIndexes
*/
template <typename S1, typename IT1, typename IT2>
inline Vc_DEPRECATED("use the subscript operator to Vc::array or Vc::vector "
"instead.") void gather(const S1 *array,
Expand All @@ -342,7 +487,19 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
array, outerIndexes)[ptrMember1][innerIndexes]
.gatherArguments());
}
/// \deprecated Use Vc::array or Vc::vector subscripting instead.

/**
* \deprecated Use Vc::array or Vc::vector subscripting instead.
*
* \param array A pointer into memory (without alignment restrictions).
* \param ptrMember1 If \p array points to a struct, \p member1 determines the member in the struct to
* be read. Thus the offsets in \p indexes are relative to the \p array and not to
* the size of the gathered type (i.e. array[i].*member1 is accessed instead of
* (&(array->*member1))[i])
* \param outerIndexes
* \param innerIndexes
* \param mask If a mask is given only the active entries will be gathered/scattered.
*/
template <typename S1, typename IT1, typename IT2>
inline Vc_DEPRECATED("use the subscript operator to Vc::array or Vc::vector "
"instead.") void gather(const S1 *array,
Expand Down
Loading

0 comments on commit 85f4e21

Please sign in to comment.