Update of /cvsroot/monetdb/pathfinder/compiler/include
In directory sfp-cvsdas-1.v30.ch3.sourceforge.com:/tmp/cvs-serv6600/include

Modified Files:
        properties.h 
Log Message:
-- Introduced a new column-name-origin property that enhances the column names
   in the DOT generated algebra plans. If a column stems from a ref_tbl or a
   path step we now keep the original name throughout the plan.
   (Use pf-option -fN to print the mapping of original names.)

-- Make property usage a little bit more defensive. Instead of !PFprop_icol
   a new function PFprop_not_icol is introduced that copes correctly with
   missing property information.


Index: properties.h
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/compiler/include/properties.h,v
retrieving revision 1.54
retrieving revision 1.55
diff -u -d -r1.54 -r1.55
--- properties.h        7 Jan 2010 15:24:27 -0000       1.54
+++ properties.h        17 Mar 2010 21:56:32 -0000      1.55
@@ -89,6 +89,7 @@
                                               nodes for the operator */
     PFarray_t       *ckeys;      /**< List of composite lists of columns that
                                       build a key for a relation. */
+    PFarray_t       *name_origin; /**< List of original names of columns */
 
     /* to allow peep-hole optimizations we also store property
        information of the children (left child 'l_', right child 'r_' */
@@ -183,6 +184,13 @@
 };
 typedef struct level_t level_t;
 
+/* name origin item */
+struct name_origin_t {
+    PFalg_col_t  col;
+    char *       name;
+};
+typedef struct name_origin_t name_origin_t;
+
 /**
  * Create new property container.
  */
@@ -197,6 +205,7 @@
                    bool key, bool fd, bool ocols, bool req_node,
                    bool reqval, bool level, bool refctr,
                    bool guides, bool ori_names, bool unq_names,
+                   bool name_origin,
                    PFla_op_t *root, PFguide_list_t *guide_list);
 
 /**
@@ -234,6 +243,7 @@
 void PFprop_infer_reqval (PFla_op_t *root);
 void PFprop_infer_unq_names (PFla_op_t *root);
 void PFprop_infer_ori_names (PFla_op_t *root);
+void PFprop_infer_name_origin (PFla_op_t *root);
 void PFprop_infer_level (PFla_op_t *root);
 void PFprop_infer_refctr (PFla_op_t *root);
 void PFprop_infer_guide (PFla_op_t *root, PFguide_list_t *guides);
@@ -403,6 +413,11 @@
 bool PFprop_icol (const PFprop_t *prop, PFalg_col_t col);
 
 /**
+ * Test if @a col is *not* in the list of icol columns in container @a prop
+ */
+bool PFprop_not_icol (const PFprop_t *prop, PFalg_col_t col);
+
+/**
  * Test if @a col is in the list of icol columns of the left child
  * (information is stored in property container @a prop)
  */
@@ -654,6 +669,13 @@
 #define UNKNOWN_LEVEL -2
 #define LEVEL_KNOWN(l) (l > UNKNOWN_LEVEL)
 
+/* --------------------- name origin property accessors -------------------- */
+
+/**
+ * Return the original name of column @a col (in container @a prop).
+ */
+char * PFprop_name_origin (const PFprop_t *prop, PFalg_col_t col);
+
 /* ------------------ reference counter property accessors ----------------- */
 
 /**


------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Monetdb-pf-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-pf-checkins

Reply via email to