Changeset: fbdcc006e510 for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=fbdcc006e510
Modified Files:
        monetdb5/extras/bwd/optimizer.c
Branch: bwd
Log Message:

* creating a BWDed plan for Q6 in the optimizer (many of the operators aren't 
implemented yet)


Unterschiede (38 Zeilen):

diff --git a/monetdb5/extras/bwd/optimizer.c b/monetdb5/extras/bwd/optimizer.c
--- a/monetdb5/extras/bwd/optimizer.c
+++ b/monetdb5/extras/bwd/optimizer.c
@@ -51,6 +51,7 @@ static inline int OPTBWDImplementation(C
                                rename_function(approximationReverse, "bwd", 
markTRef, &actions, client);
                        
                }
+                                        
                if((oldProgram[i]->modname == sqlRef && oldProgram[i]->fcnname 
== rsColumnRef)){
                        InstrPtr approximationReverse = 
copyInstruction(oldProgram[i]);
                        /* setDestVar(approximationReverse, 
approximations[getDestVar(oldProgram[i])]); */
@@ -59,11 +60,24 @@ static inline int OPTBWDImplementation(C
                        pushInstruction(malBlock, approximationReverse);
                        
                }
+               if(match_function(oldProgram[i], sqlRef, "exportValue")){
+                       InstrPtr approximationReverse = 
copyInstruction(oldProgram[i]);
+                       /* setDestVar(approximationReverse, 
approximations[getDestVar(oldProgram[i])]); */
+                       setArg(approximationReverse, 8, 
approximations[getArg(oldProgram[i],8)]);
+                       rename_function(approximationReverse, "bwd", 
"exportValue", &actions, client);
+                       pushInstruction(malBlock, approximationReverse);
+                       
+               }
 
 
                ////////////////////////////// rewrite operators 
//////////////////////////////
-               if(match_function(oldProgram[i], "algebra", "thetauselect")
-                        || match_function(oldProgram[i], "algebra", 
"leftjoin")) {
+               if(match_function(oldProgram[i], algebraRef, thetauselectRef)
+                        || oldProgram[i]->modname == batcalcRef
+                        || match_function(oldProgram[i], algebraRef, 
uselectRef)
+                        || match_function(oldProgram[i], algebraRef, 
semijoinRef)
+                        || match_function(oldProgram[i], algebraRef, 
selectNotNilRef)
+                        || match_function(oldProgram[i], "aggr", "sum")
+                        || match_function(oldProgram[i], algebraRef, 
leftjoinRef)) {
                        approximations[getDestVar(oldProgram[i])] = 
newTmpVariable(malBlock, getDestType(malBlock, oldProgram[i]));
                        {
                                InstrPtr approximateLeftjoin = 
newInstruction(malBlock, ASSIGNsymbol);
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to