/[escript]/trunk/escript/src/DataLazy.h
ViewVC logotype

Diff of /trunk/escript/src/DataLazy.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2497 by jfenwick, Mon Jun 29 00:04:45 2009 UTC revision 2500 by jfenwick, Tue Jun 30 00:42:38 2009 UTC
# Line 23  Line 23 
23    
24  #include "LocalOps.h"       // for tensor_binary_op  #include "LocalOps.h"       // for tensor_binary_op
25  #include "BufferGroup.h"  #include "BufferGroup.h"
26    #include "DataVector.h"     // for ElementType
27    
28    
29    //#define LAZY_NODE_STORAGE
30    
31  namespace escript {  namespace escript {
32    
# Line 301  private: Line 305  private:
305    size_t m_children;    size_t m_children;
306    size_t m_height;    size_t m_height;
307    
308    #ifdef LAZY_NODE_STORAGE
309    
310      int* m_sampleids;     // may be NULL
311      DataVector m_samples;  
312    
313    #endif // LAZY_NODE_STORAGE
314    
315    
316    #ifdef LAZY_NODE_STORAGE
317      /**
318      Allocates sample storage at each node
319      */
320      void LazyNodeSetup();
321    
322    
323      const DataTypes::ValueType*
324      resolveNodeUnary(int tid, int sampleNo, size_t& roffset);
325    
326      const DataTypes::ValueType*
327      resolveNodeSample(int tid, int sampleNo, size_t& roffset);
328    
329      const DataTypes::ValueType*
330      resolveNodeBinary(int tid, int sampleNo, size_t& roffset);
331    
332      const DataTypes::ValueType*
333      resolveNodeNP1OUT(int tid, int sampleNo, size_t& roffset);
334    
335      const DataTypes::ValueType*
336      resolveNodeNP1OUT_P(int tid, int sampleNo, size_t& roffset);
337    
338      const DataTypes::ValueType*
339      resolveNodeTProd(int tid, int sampleNo, size_t& roffset);
340    
341      const DataTypes::ValueType*
342      resolveNodeNP1OUT_2P(int tid, int sampleNo, size_t& roffset);
343      
344    #endif
345    
346    /**    /**
347    Does the work for toString.    Does the work for toString.
# Line 345  private: Line 386  private:
386    DataReady_ptr    DataReady_ptr
387    resolveVectorWorker();    resolveVectorWorker();
388    
389    #ifdef LAZY_NODE_STORAGE
390      /**
391      \brief resolve to a ReadyData object using storage at nodes
392      */
393      DataReady_ptr
394      resolveNodeWorker();
395    #endif
396    
397    /**    /**
398    \brief Compute the value of the expression (unary operation) for the given sample.    \brief Compute the value of the expression (unary operation) for the given sample.
399    \return Vector which stores the value of the subexpression for the given sample.    \return Vector which stores the value of the subexpression for the given sample.

Legend:
Removed from v.2497  
changed lines
  Added in v.2500

  ViewVC Help
Powered by ViewVC 1.1.26