7#include "arcane/aleph/AlephArcane.h" 
    8#include "arcane/aleph/cuda/AlephCuda.h" 
   16template <
class T> CNC_Vector<T>::CNC_Vector(
unsigned int size, 
unsigned int alignment) {
 
   20  allocate(size, alignment) ;
 
   23template <
class T> CNC_Vector<T>::~CNC_Vector() { deallocate() ; }
 
   31    base_mem_ = (
char*)malloc(size * 
sizeof(T) + alignment -1) ;
 
   34    while (((
unsigned long long) p) % alignment) { ++p; }
 
   36    for(
unsigned int i=0; i<size; i++) {
 
 
 
   46template <
class T> 
void CNC_Vector<T>::set_all(
const T& value) {
 
   47  for(
unsigned int i=0; i<size_; i++) {
 
   54template <
class T> T& CNC_Vector<T>::operator()(
unsigned int i) {
 
   60template <
class T> 
const T& CNC_Vector<T>::operator()(
unsigned int i)
 const {
 
   66template <
class T> T& CNC_Vector<T>::operator[](
unsigned int index) {
 
   72template <
class T> 
const T& CNC_Vector<T>::operator[](
unsigned int index)
 const {
 
   78template <
class T> T& CNC_Vector<T>::from_linear_index(
unsigned int index) {
 
   84template <
class T> 
const T& CNC_Vector<T>::from_linear_index(
unsigned int index)
 const {
 
   90template <
class T> 
unsigned int CNC_Vector<T>::size()
 const { 
return size_ ; }
 
   94template <
class T> 
unsigned int CNC_Vector<T>::alignment()
 const { 
return alignment_ ; }
 
   98template <
class T> 
void CNC_Vector<T>::clear() { allocate(0) ; }
 
 
  112template <
class T> 
unsigned int CNC_Vector<T>::mem_usage()
 const {
 
  113  return size_ * 
sizeof(T) + 
sizeof(thisclass) ;
 
  118template <
class T> 
void CNC_Vector<T>::print ()
 const {
 
  119  for(
unsigned int index=0; index<size_; index++){
 
  127template <
class T> 
void CNC_Vector<T>::deallocate() {
 
  129    for(
unsigned int i=0; i<size_; i++) {
 
  141template class CNC_Vector<double>;
 
  142template class CNC_Vector<long>;
 
  143template class CNC_Vector<std::set<unsigned int> >;
 
 
void allocate(unsigned int size, unsigned int alignment=1)