From: bdemsky Date: Fri, 15 Apr 2011 23:53:34 +0000 (+0000) Subject: bug fixes for tasks... X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=bd7dc519c6ff3cfc43a6456eca90683901823e34;p=IRC.git bug fixes for tasks... --- diff --git a/Robust/src/IR/Flat/BuildCode.java b/Robust/src/IR/Flat/BuildCode.java index fb4c65fd..48126a48 100644 --- a/Robust/src/IR/Flat/BuildCode.java +++ b/Robust/src/IR/Flat/BuildCode.java @@ -193,6 +193,7 @@ public class BuildCode { /* Output code for tasks */ outputTaskCode(outtaskdefs, outmethod); outtaskdefs.close(); + outtask.close(); /* Record maximum number of task parameters */ outstructs.println("#define MAXTASKPARAMS "+maxtaskparams); } else if (state.main!=null) { @@ -204,6 +205,7 @@ public class BuildCode { if (state.TASK&&state.OPTIONAL) { generateOptionalArrays(outoptionalarrays, optionalheaders, state.getAnalysisResult(), state.getOptionalTaskDescriptors()); outoptionalarrays.close(); + optionalheaders.close(); } /* Output structure definitions for repair tool */ @@ -631,6 +633,7 @@ public class BuildCode { } if (state.TASK) { outclassdefs.println(" int flag;"); + outclassdefs.println(" int ___cachedCode___;"); if(!state.MULTICORE) { outclassdefs.println(" void * flagptr;"); } else { @@ -1563,6 +1566,7 @@ public class BuildCode { } if (state.TASK) { classdefout.println(" int flag;"); + classdefout.println(" int ___cachedCode___;"); if((!state.MULTICORE) || (cn.getSymbol().equals("TagDescriptor"))) { classdefout.println(" void * flagptr;"); } else if (state.MULTICORE) {