+bool install_plugin(char * name) {
+ ModelVector<TraceAnalysis *> * registeredanalysis=getRegisteredTraceAnalysis();
+ ModelVector<TraceAnalysis *> * installedanalysis=getInstalledTraceAnalysis();
+
+ for(unsigned int i=0;i<registeredanalysis->size();i++) {
+ TraceAnalysis * analysis=(*registeredanalysis)[i];
+ if (strcmp(name, analysis->name())==0) {
+ installedanalysis->push_back(analysis);
+ return false;
+ }
+ }
+ model_print("Analysis %s Not Found\n", name);
+ return true;
+}
+
+static void parse_options(struct model_params *params, int argc, char **argv)
+{
+ const char *shortopts = "hyYt:o:m:M:s:S:f:e:b:u:v::";
+ const struct option longopts[] = {
+ {"help", no_argument, NULL, 'h'},
+ {"liveness", required_argument, NULL, 'm'},
+ {"maxfv", required_argument, NULL, 'M'},
+ {"maxfvdelay", required_argument, NULL, 's'},
+ {"fvslop", required_argument, NULL, 'S'},
+ {"fairness", required_argument, NULL, 'f'},
+ {"yield", no_argument, NULL, 'y'},
+ {"yieldblock", no_argument, NULL, 'Y'},
+ {"enabled", required_argument, NULL, 'e'},
+ {"bound", required_argument, NULL, 'b'},
+ {"verbose", optional_argument, NULL, 'v'},
+ {"uninitialized", optional_argument, NULL, 'u'},
+ {"analysis", optional_argument, NULL, 't'},
+ {"options", optional_argument, NULL, 'o'},
+ {0, 0, 0, 0} /* Terminator */
+ };
+ int opt, longindex;