cml::et::detail::MatrixAssignmentUnroller< OpT, E, AT, BO, L, SrcT > Class Template Reference

Unroll a binary assignment operator on a fixed-size matrix. More...

#include <matrix_unroller.h>

List of all members.

Public Member Functions

void operator() (matrix_type &dest, const SrcT &src, cml::dynamic_size_tag)
 Use a loop for dynamic-sized matrix assignment.
void operator() (cml::matrix< E, AT, BO, L > &dest, const SrcT &src, cml::fixed_size_tag)
 Unroll assignment for a fixed-sized matrix.

Protected Types

typedef ExprTraits< matrix_typedest_traits
typedef cml::matrix< E, AT, BO, L > matrix_type
typedef ExprTraits< SrcT > src_traits

Private Member Functions

matrix_size CheckOrResize (matrix_type &dest, const SrcT &src, cml::not_resizable_tag)
matrix_size CheckOrResize (matrix_type &dest, const SrcT &src, cml::resizable_tag)
matrix_size hack_actual_size (matrix_type &, const SrcT &src, matrix_result_tag)
matrix_size hack_actual_size (matrix_type &dest, const SrcT &, scalar_result_tag)


Detailed Description

template<class OpT, typename E, class AT, typename BO, typename L, class SrcT>
class cml::et::detail::MatrixAssignmentUnroller< OpT, E, AT, BO, L, SrcT >

Unroll a binary assignment operator on a fixed-size matrix.

This uses a forward iteration to make better use of the cache.

See also:
cml::matrix

cml::et::OpAssign

Bug:
Need to verify that OpT is actually an assignment operator.

The 2D unroller needs to be specified for efficient col-major access.

Definition at line 50 of file matrix_unroller.h.


Member Typedef Documentation

template<class OpT , typename E , class AT , typename BO , typename L , class SrcT >
typedef ExprTraits<matrix_type> cml::et::detail::MatrixAssignmentUnroller< OpT, E, AT, BO, L, SrcT >::dest_traits [protected]

Definition at line 58 of file matrix_unroller.h.

template<class OpT , typename E , class AT , typename BO , typename L , class SrcT >
typedef cml::matrix<E,AT,BO,L> cml::et::detail::MatrixAssignmentUnroller< OpT, E, AT, BO, L, SrcT >::matrix_type [protected]

Definition at line 55 of file matrix_unroller.h.

template<class OpT , typename E , class AT , typename BO , typename L , class SrcT >
typedef ExprTraits<SrcT> cml::et::detail::MatrixAssignmentUnroller< OpT, E, AT, BO, L, SrcT >::src_traits [protected]

Definition at line 59 of file matrix_unroller.h.


Member Function Documentation

template<class OpT , typename E , class AT , typename BO , typename L , class SrcT >
matrix_size cml::et::detail::MatrixAssignmentUnroller< OpT, E, AT, BO, L, SrcT >::CheckOrResize ( matrix_type dest,
const SrcT &  src,
cml::not_resizable_tag   
) [inline, private]

Definition at line 229 of file matrix_unroller.h.

References cml::et::CheckedSize().

Here is the call graph for this function:

template<class OpT , typename E , class AT , typename BO , typename L , class SrcT >
matrix_size cml::et::detail::MatrixAssignmentUnroller< OpT, E, AT, BO, L, SrcT >::CheckOrResize ( matrix_type dest,
const SrcT &  src,
cml::resizable_tag   
) [inline, private]

Definition at line 213 of file matrix_unroller.h.

References cml::et::CheckedSize(), and cml::et::detail::MatrixAssignmentUnroller< OpT, E, AT, BO, L, SrcT >::hack_actual_size().

Referenced by cml::et::detail::MatrixAssignmentUnroller< OpT, E, AT, BO, L, SrcT >::operator()().

Here is the call graph for this function:

Here is the caller graph for this function:

template<class OpT , typename E , class AT , typename BO , typename L , class SrcT >
matrix_size cml::et::detail::MatrixAssignmentUnroller< OpT, E, AT, BO, L, SrcT >::hack_actual_size ( matrix_type ,
const SrcT &  src,
matrix_result_tag   
) [inline, private]

Definition at line 205 of file matrix_unroller.h.

template<class OpT , typename E , class AT , typename BO , typename L , class SrcT >
matrix_size cml::et::detail::MatrixAssignmentUnroller< OpT, E, AT, BO, L, SrcT >::hack_actual_size ( matrix_type dest,
const SrcT &  ,
scalar_result_tag   
) [inline, private]

Definition at line 197 of file matrix_unroller.h.

Referenced by cml::et::detail::MatrixAssignmentUnroller< OpT, E, AT, BO, L, SrcT >::CheckOrResize().

Here is the caller graph for this function:

template<class OpT , typename E , class AT , typename BO , typename L , class SrcT >
void cml::et::detail::MatrixAssignmentUnroller< OpT, E, AT, BO, L, SrcT >::operator() ( matrix_type dest,
const SrcT &  src,
cml::dynamic_size_tag   
) [inline]

Use a loop for dynamic-sized matrix assignment.

Note:
The target matrix must already have the correct size.
Todo:
This needs to be specialized for efficient row-major or col-major layout access.

Definition at line 246 of file matrix_unroller.h.

References cml::et::detail::MatrixAssignmentUnroller< OpT, E, AT, BO, L, SrcT >::CheckOrResize().

Here is the call graph for this function:

template<class OpT , typename E , class AT , typename BO , typename L , class SrcT >
void cml::et::detail::MatrixAssignmentUnroller< OpT, E, AT, BO, L, SrcT >::operator() ( cml::matrix< E, AT, BO, L > &  dest,
const SrcT &  src,
cml::fixed_size_tag   
) [inline]

Unroll assignment for a fixed-sized matrix.

Definition at line 156 of file matrix_unroller.h.

References cml::et::CheckedSize().

Here is the call graph for this function:


The documentation for this class was generated from the following file:

Generated on Sat Jul 18 19:35:39 2009 for CML 1.0 by  doxygen 1.5.9