basix_doc 0.1
long_int_mul_op< C > Class Template Reference

#include <int.hpp>

List of all members.

Static Public Member Functions


Detailed Description

template<typename C>
class mmx::long_int_mul_op< C >

Definition at line 292 of file int.hpp.


Member Function Documentation

static void op ( uC &  dest1,
uC &  dest0,
const uC &  a,
const uC &  b 
) [inline, static]

dest1 R + dest0 = a * b.

Definition at line 309 of file int.hpp.

                                                      {
    uC t0, t1;
    uC lo_a = lo (a);
    uC hi_a = hi (a);
    uC lo_b = lo (b);
    uC hi_b = hi (b);
    dest0 = lo_a * lo_b;
    dest1 = hi_a * hi_b;
    t0 = hi_a * lo_b;
    t1 = t0 + lo_a * hi_b;
    if (t1 < t0) dest1 += carry;
    t0 = lo (t1) << n2;
    dest0 += t0;
    dest1 += hi (t1);
    if (dest0 < t0) dest1++;
  }

The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines