compbench-devel Mailing List for CompBenchmarks (Page 8)
Brought to you by:
xfred
You can subscribe to this list here.
2006 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(48) |
Oct
(51) |
Nov
(66) |
Dec
(83) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2007 |
Jan
(242) |
Feb
(56) |
Mar
(95) |
Apr
(120) |
May
(127) |
Jun
(32) |
Jul
(10) |
Aug
(55) |
Sep
(114) |
Oct
(3) |
Nov
|
Dec
|
From: Frederic T. <xf...@us...> - 2007-07-31 17:28:41
|
Update of /cvsroot/compbench/CompBenchmarks++/Qt-4/Plan In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv30039 Modified Files: PlanDefineBatch.cpp PlanDefineBatch.h Log Message: Changes implied by modification in underlaying API. Index: PlanDefineBatch.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/Qt-4/Plan/PlanDefineBatch.cpp,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** PlanDefineBatch.cpp 21 May 2007 19:59:14 -0000 1.7 --- PlanDefineBatch.cpp 31 Jul 2007 17:28:22 -0000 1.8 *************** *** 49,53 **** addAction(QIcon(":/icons/remove.png"), tr("Remove compiler"), ! this, SLOT(doOptionsRemove())); } } --- 49,53 ---- addAction(QIcon(":/icons/remove.png"), tr("Remove compiler"), ! this, SLOT(doCompilerRemove())); } } *************** *** 223,226 **** --- 223,228 ---- : QTreeWidget(parent) { + plan=new CBM::Plan; + connect(this, SIGNAL(sigPlanBatchRegister(CBM::PlanBatch*)), this, SLOT(doPlanBatchRegister(CBM::PlanBatch*)), *************** *** 343,357 **** void PlanDefineBatchList::doPlanBatchRegister(CBM::PlanBatch *_batch) { - CBM::Plan *P = CBM::cbmSystem->Plan(); - PlanDefineBatchListItem *R = new PlanDefineBatchListItem(_batch); addTopLevelItem(R); ! P->addBatch(_batch); } void PlanDefineBatchList::doPlanBatchUnregister(CBM::PlanBatch *_batch) { - CBM::Plan *P = CBM::cbmSystem->Plan(); PlanDefineBatchListItem *I = Item(_batch); PlanDefineBatchListItem *R; --- 345,356 ---- void PlanDefineBatchList::doPlanBatchRegister(CBM::PlanBatch *_batch) { PlanDefineBatchListItem *R = new PlanDefineBatchListItem(_batch); addTopLevelItem(R); ! plan->addBatch(_batch); } void PlanDefineBatchList::doPlanBatchUnregister(CBM::PlanBatch *_batch) { PlanDefineBatchListItem *I = Item(_batch); PlanDefineBatchListItem *R; *************** *** 366,370 **** delete(invisibleRootItem()->takeChild(invisibleRootItem()->indexOfChild(I))); ! P->removeBatch(_batch); delete(_batch); } --- 365,369 ---- delete(invisibleRootItem()->takeChild(invisibleRootItem()->indexOfChild(I))); ! plan->removeBatch(_batch); delete(_batch); } *************** *** 615,617 **** --- 614,617 ---- PlanDefineBatchList::~PlanDefineBatchList() { + delete(plan); } Index: PlanDefineBatch.h =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/Qt-4/Plan/PlanDefineBatch.h,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** PlanDefineBatch.h 21 May 2007 19:59:14 -0000 1.7 --- PlanDefineBatch.h 31 Jul 2007 17:28:22 -0000 1.8 *************** *** 13,16 **** --- 13,18 ---- #include <Basic/PlanBatchHolder.h> + #include <Plan/Plan.h> + namespace CQT { *************** *** 76,79 **** --- 78,82 ---- Q_OBJECT private: + CBM::Plan *plan; protected: virtual PlanDefineBatchListItem *Item(CBM::PlanBatch *_batch); |
From: Frederic T. <xf...@us...> - 2007-07-31 17:28:29
|
Update of /cvsroot/compbench/CompBenchmarks++/Qt-4/Plan In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv29759 Modified Files: PlanAvailableOption.cpp Log Message: Available options correctly shown. Index: PlanAvailableOption.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/Qt-4/Plan/PlanAvailableOption.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** PlanAvailableOption.cpp 22 May 2007 17:28:52 -0000 1.2 --- PlanAvailableOption.cpp 31 Jul 2007 17:28:04 -0000 1.3 *************** *** 44,53 **** OptionHolder(_option) { ! /* if (Compiler()->getStatus()<CBM::Compiler::Preconfigured) ! setIcon(QIcon(":/icons/error.png")); ! else ! */ ! setIcon(QIcon(":/icons/success.png")); ! // setToolTip(_option->shortDescription().c_str()); } --- 44,56 ---- OptionHolder(_option) { ! CBM::CompilerOptionDescriptions *OD = App->PlanCompilerSelected()->OptionDescriptions(); ! ! CBM::CompilerOptionDescription *D = OD->DescriptionLitteral(_option->Option()); ! ! if ((D) && (D->CompilationTwoPassNeeded()) && (D->CompilationPass()==1)) { ! setIcon(QIcon(":/icons/error.png")); ! } else { ! setIcon(QIcon(":/icons/success.png")); ! } } |
From: Frederic T. <xf...@us...> - 2007-07-31 17:25:49
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv28914 Modified Files: UI-Console.cpp UI.cpp UI.h UI-Msg.cpp UI-Msg.h Log Message: Many improvements and/or fixes. Index: UI.h =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI/UI.h,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** UI.h 13 Jun 2007 18:10:35 -0000 1.9 --- UI.h 31 Jul 2007 17:25:44 -0000 1.10 *************** *** 67,70 **** --- 67,72 ---- virtual UIMsg *msgPlanOptionsRegister(std::string _name); virtual UIMsg *msgPlanOptionsUnregister(std::string _name); + virtual UIMsg *msgPlanOptionRegister(std::string _name); + virtual UIMsg *msgPlanOptionUnregister(std::string _name); virtual UIMsg *msgPlanBenchmarkRegister(std::string _name); virtual UIMsg *msgPlanBenchmarkUnregister(std::string _name); Index: UI.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI/UI.cpp,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** UI.cpp 13 Jun 2007 18:10:35 -0000 1.10 --- UI.cpp 31 Jul 2007 17:25:44 -0000 1.11 *************** *** 290,293 **** --- 290,309 ---- } + UIMsg *UI::msgPlanOptionRegister(std::string _name) + { + UIMsg *msg = new UIMsgPlanOptionRegister(_name); + postMsg(msg); + + return(msg); + } + + UIMsg *UI::msgPlanOptionUnregister(std::string _name) + { + UIMsg *msg = new UIMsgPlanOptionUnregister(_name); + postMsg(msg); + + return(msg); + } + UIMsg *UI::msgPlanBenchmarkRegister(std::string _name) { Index: UI-Msg.h =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI/UI-Msg.h,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** UI-Msg.h 13 Jun 2007 18:10:35 -0000 1.4 --- UI-Msg.h 31 Jul 2007 17:25:44 -0000 1.5 *************** *** 60,63 **** --- 60,64 ---- PlanOptionsetRegister, PlanOptionsetUnregister, PlanOptionsRegister, PlanOptionsUnregister, + PlanOptionRegister, PlanOptionUnregister, PlanBenchmarkRegister, PlanBenchmarkUnregister }; *************** *** 280,283 **** --- 281,296 ---- }; + class UIMsgPlanOptionRegister : public UIMsg { + public: + UIMsgPlanOptionRegister(std::string _name); + virtual ~UIMsgPlanOptionRegister(); + }; + + class UIMsgPlanOptionUnregister : public UIMsg { + public: + UIMsgPlanOptionUnregister(std::string _name); + virtual ~UIMsgPlanOptionUnregister(); + }; + class UIMsgPlanBenchmarkRegister : public UIMsg { public: Index: UI-Msg.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI/UI-Msg.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** UI-Msg.cpp 13 Jun 2007 18:10:35 -0000 1.4 --- UI-Msg.cpp 31 Jul 2007 17:25:44 -0000 1.5 *************** *** 434,437 **** --- 434,459 ---- } + UIMsgPlanOptionRegister::UIMsgPlanOptionRegister(std::string _name) + : UIMsg() + { + addObject(UndefObject, _name); + addAction(PlanOptionRegister); + } + + UIMsgPlanOptionRegister::~UIMsgPlanOptionRegister() + { + } + + UIMsgPlanOptionUnregister::UIMsgPlanOptionUnregister(std::string _name) + : UIMsg() + { + addObject(UndefObject, _name); + addAction(PlanOptionUnregister); + } + + UIMsgPlanOptionUnregister::~UIMsgPlanOptionUnregister() + { + } + UIMsgPlanBenchmarkRegister::UIMsgPlanBenchmarkRegister(std::string _name) : UIMsg() Index: UI-Console.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI/UI-Console.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** UI-Console.cpp 13 Jun 2007 18:10:35 -0000 1.4 --- UI-Console.cpp 31 Jul 2007 17:25:44 -0000 1.5 *************** *** 246,250 **** case UIMsg::PlanOptionsetUnregister: ! curmsg+="Unregistering option set "; curmsg+=objectField(_msg, "name"); break; --- 246,250 ---- case UIMsg::PlanOptionsetUnregister: ! curmsg+="Unregistering option set "; curmsg+=objectField(_msg, "name"); break; |
From: Frederic T. <xf...@us...> - 2007-07-31 17:25:15
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv28523 Modified Files: Plan.cpp Log Message: Broadcast stop (parameter introduced). Changes in PlanBatch's constructor. Index: Plan.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan/Plan.cpp,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** Plan.cpp 13 Jun 2007 18:11:37 -0000 1.13 --- Plan.cpp 31 Jul 2007 17:25:01 -0000 1.14 *************** *** 246,250 **** for(i=0;i<n;i++) { ! getBatch(i)->stop(); } --- 246,250 ---- for(i=0;i<n;i++) { ! getBatch(i)->stop(0); } *************** *** 325,329 **** tmp=PBs->getNode(i); if (tmp->Name()=="plan-batch") { ! pb=new PlanBatch(""); pb->restore(tmp); planBatch.push_back(pb); --- 325,329 ---- tmp=PBs->getNode(i); if (tmp->Name()=="plan-batch") { ! pb=new PlanBatch(this, ""); pb->restore(tmp); planBatch.push_back(pb); |
From: Frederic T. <xf...@us...> - 2007-07-31 17:24:10
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv28223 Modified Files: Plan-Batch.cpp Plan-Batch.h Log Message: Changes implied by modification on underlaying APIs. Index: Plan-Batch.h =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan/Plan-Batch.h,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** Plan-Batch.h 13 Jun 2007 18:40:43 -0000 1.3 --- Plan-Batch.h 31 Jul 2007 17:24:03 -0000 1.4 *************** *** 19,32 **** --- 19,36 ---- #include <Benchmark/Benchmark.h> #include <Compiler/Compiler-OptionSet.h> + #include <Plan/Plan.h> %} #include <Benchmark/Benchmark.h> #include <Compiler/Compiler-OptionSet.h> + #include <Plan/Plan.h> #define CBM_BM CBM::Benchmark #define CBM_OS CBM::CompilerOptionSet #define CBM_OP CBM::CompilerOptions + #define CBM_PLAN CBM::Plan #else # define CBM_BM class Benchmark # define CBM_OS class CompilerOptionSet # define CBM_OP class CompilerOptions + # define CBM_PLAN class Plan #endif *************** *** 40,47 **** private: std::string id; protected: ! std::vector<class Compiler *> compilers; /*!< Compilers */ ! std::vector<CBM_OS*> compilerOptions; /*!< Compiler optimisations' sets */ ! std::vector<class Benchmark *> benchmarks; /*!< Benchmarks */ /** Current iteration. --- 44,53 ---- private: std::string id; + CBM_PLAN *plan; + protected: ! std::vector<class Compiler *> compilers; /*!< Compilers */ ! std::vector<CBM_OS*> compilerOptionSets; /*!< Compiler optimisations' sets */ ! std::vector<class Benchmark *> benchmarks; /*!< Benchmarks */ /** Current iteration. *************** *** 65,69 **** public: ! PlanBatch(std::string _id); virtual std::string Id(void); --- 71,76 ---- public: ! PlanBatch(CBM::Plan *_plan, ! std::string _id); virtual std::string Id(void); *************** *** 85,94 **** virtual int compilerNumber(void); ! virtual int compilerOptionNumber(void); virtual int benchmarkNumber(void); virtual class Compiler* getCompiler(int _index); ! virtual CBM_OS *getCompilerOptions(int _index); ! virtual CBM_OS *getCompilerOptions(std::string id); virtual CBM_BM *getBenchmark(int _index); --- 92,104 ---- virtual int compilerNumber(void); ! virtual int compilerOptionSetNumber(void); ! ! virtual int compilerOptionsTotalNumber(void); ! virtual int benchmarkNumber(void); virtual class Compiler* getCompiler(int _index); ! virtual CBM_OS *getCompilerOptionSet(int _index); ! virtual CBM_OS *getCompilerOptionSet(std::string id); virtual CBM_BM *getBenchmark(int _index); *************** *** 104,113 **** virtual int nextIteration(int simule = 0); ! virtual void stop(void); class XMLNode *XML(void); virtual void reset(void); - virtual int store(void); virtual int restore(XMLNode *_planRootNode); --- 114,122 ---- virtual int nextIteration(int simule = 0); ! virtual void stop(int _broadcast); class XMLNode *XML(void); virtual void reset(void); virtual int restore(XMLNode *_planRootNode); Index: Plan-Batch.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan/Plan-Batch.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** Plan-Batch.cpp 13 Jun 2007 18:40:43 -0000 1.5 --- Plan-Batch.cpp 31 Jul 2007 17:24:02 -0000 1.6 *************** *** 7,10 **** --- 7,11 ---- ------------------------------------------------------------------------- */ #include <Plan/Plan-Batch.h> + #include <Plan/Plan.h> #include <Compiler/Compiler.h> #include <Compiler/Compiler-Options.h> *************** *** 21,28 **** using namespace CBM; ! PlanBatch::PlanBatch(std::string _id) { iteration=0; id=_id; } --- 22,31 ---- using namespace CBM; ! PlanBatch::PlanBatch(CBM::Plan *_plan, ! std::string _id) { iteration=0; id=_id; + plan=_plan; } *************** *** 99,107 **** { int i; ! int n = compilerOptionNumber(); CBM::CompilerOptionSet *O; for(i=0; i<n; i++) { ! O=getCompilerOptions(i); if (O->Id() == _set->Id()) return(0); --- 102,110 ---- { int i; ! int n = compilerOptionSetNumber(); CBM::CompilerOptionSet *O; for(i=0; i<n; i++) { ! O=getCompilerOptionSet(i); if (O->Id() == _set->Id()) return(0); *************** *** 213,217 **** compilers.push_back(_compiler); ! stop(); cbmUI->outputOK(); --- 216,220 ---- compilers.push_back(_compiler); ! stop(1); cbmUI->outputOK(); *************** *** 235,240 **** } ! compilerOptions.push_back(_set); ! stop(); cbmUI->outputOK(); --- 238,243 ---- } ! compilerOptionSets.push_back(_set); ! stop(1); cbmUI->outputOK(); *************** *** 277,281 **** benchmarks.push_back(_benchmark); ! stop(); cbmUI->outputOK(); return(1); --- 280,284 ---- benchmarks.push_back(_benchmark); ! stop(1); cbmUI->outputOK(); return(1); *************** *** 305,309 **** if (found) { compilers=ncompilers; ! stop(); cbmUI->outputOK(); } else { --- 308,312 ---- if (found) { compilers=ncompilers; ! stop(1); cbmUI->outputOK(); } else { *************** *** 317,321 **** { int i; ! int n = compilerOptionNumber(); CBM::CompilerOptionSet *OS = 0; std::vector<CBM::CompilerOptionSet*> noptions; --- 320,324 ---- { int i; ! int n = compilerOptionSetNumber(); CBM::CompilerOptionSet *OS = 0; std::vector<CBM::CompilerOptionSet*> noptions; *************** *** 324,328 **** cbmUI->msgPlanOptionsetUnregister(_set->Id()); for(i=0; i<n; i++) { ! OS=getCompilerOptions(i); if (OS->Id()!=_set->Id()) noptions.push_back(OS); --- 327,331 ---- cbmUI->msgPlanOptionsetUnregister(_set->Id()); for(i=0; i<n; i++) { ! OS=getCompilerOptionSet(i); if (OS->Id()!=_set->Id()) noptions.push_back(OS); *************** *** 335,340 **** if (found) { ! compilerOptions=noptions; ! stop(); cbmUI->outputOK(); } else { --- 338,343 ---- if (found) { ! compilerOptionSets=noptions; ! stop(1); cbmUI->outputOK(); } else { *************** *** 348,352 **** CBM::CompilerOptions *_opt) { ! stop(); return(_set->remove(_opt)); } --- 351,355 ---- CBM::CompilerOptions *_opt) { ! stop(1); return(_set->remove(_opt)); } *************** *** 371,375 **** if (found) { ! stop(); benchmarks=nbenchmarks; cbmUI->outputOK(); --- 374,378 ---- if (found) { ! stop(1); benchmarks=nbenchmarks; cbmUI->outputOK(); *************** *** 388,394 **** } ! int PlanBatch::compilerOptionNumber(void) { ! return(compilerOptions.size()); } --- 391,411 ---- } ! int PlanBatch::compilerOptionSetNumber(void) { ! return(compilerOptionSets.size()); ! } ! ! int PlanBatch::compilerOptionsTotalNumber(void) ! { ! int i, n = compilerOptionSetNumber(); ! CBM::CompilerOptionSet *OS; ! int r = 0; ! ! for(i=0; i<n; i++) { ! OS=getCompilerOptionSet(i); ! r+=OS->optionNumber(); ! } ! ! return(r); } *************** *** 406,424 **** } ! CBM::CompilerOptionSet *PlanBatch::getCompilerOptions(int _index) { ! if (_index<compilerOptionNumber()) ! return(compilerOptions[_index]); else return(0); } ! CBM::CompilerOptionSet *PlanBatch::getCompilerOptions(std::string id) { CBM::CompilerOptionSet *c = 0; ! int i, n = compilerOptionNumber(); for(i=0;i<n;i++) { ! c=getCompilerOptions(i); if (c->Id()==id) return(c); --- 423,441 ---- } ! CBM::CompilerOptionSet *PlanBatch::getCompilerOptionSet(int _index) { ! if (_index<compilerOptionSetNumber()) ! return(compilerOptionSets[_index]); else return(0); } ! CBM::CompilerOptionSet *PlanBatch::getCompilerOptionSet(std::string id) { CBM::CompilerOptionSet *c = 0; ! int i, n = compilerOptionSetNumber(); for(i=0;i<n;i++) { ! c=getCompilerOptionSet(i); if (c->Id()==id) return(c); *************** *** 437,441 **** int PlanBatch::totalIterations(void) { ! return(compilerNumber()*compilerOptionNumber()*benchmarkNumber()); } --- 454,458 ---- int PlanBatch::totalIterations(void) { ! return(compilerNumber()*compilerOptionsTotalNumber()*benchmarkNumber()); } *************** *** 447,451 **** CBM::Compiler *PlanBatch::currentCompiler(void) { ! int compilerIndex = (iteration/(compilerOptionNumber()*benchmarkNumber()))%compilerNumber(); CBM::Compiler *C = getCompiler(compilerIndex); --- 464,468 ---- CBM::Compiler *PlanBatch::currentCompiler(void) { ! int compilerIndex = (iteration/(compilerOptionSetNumber()*benchmarkNumber()))%compilerNumber(); CBM::Compiler *C = getCompiler(compilerIndex); *************** *** 455,463 **** CBM::CompilerOptions *PlanBatch::currentCompilerOptions(void) { ! int optionIndex = (iteration/benchmarkNumber())%compilerOptionNumber(); ! ! // std::string O = getCompilerOptions(optionIndex); ! // return(O); } --- 472,489 ---- CBM::CompilerOptions *PlanBatch::currentCompilerOptions(void) { ! int rawIndex = (iteration/(benchmarkNumber()*compilerNumber()))%compilerOptionsTotalNumber(); ! int i, n = compilerOptionSetNumber(); ! CBM::CompilerOptionSet *OS; ! int on; ! for(i=0; i<n; i++) { ! OS=getCompilerOptionSet(i); ! on=OS->optionNumber(); ! if (rawIndex<=on) { ! return(OS->Options(rawIndex)); ! } else ! rawIndex-=on; ! } ! return(0); } *************** *** 562,568 **** } ! n=compilerOptionNumber(); for(i=0; i<n; i++) { ! tmp=getCompilerOptions(i)->XML(); OS->add(tmp); } --- 588,594 ---- } ! n=compilerOptionSetNumber(); for(i=0; i<n; i++) { ! tmp=getCompilerOptionSet(i)->XML(); OS->add(tmp); } *************** *** 571,579 **** } ! void PlanBatch::stop(void) { if (iteration) cbmUI->outputInfo("Context changed : current plan benchmarking will be restarted."); iteration=0; } --- 597,607 ---- } ! void PlanBatch::stop(int _broadcast) { if (iteration) cbmUI->outputInfo("Context changed : current plan benchmarking will be restarted."); iteration=0; + if (_broadcast) + plan->stop(); } *************** *** 592,610 **** } ! while ( (O=getCompilerOptions(0)) != 0) { remove(O); } } - int PlanBatch::store(void) - { - /* - XMLNode *root = XML(); - - cbmSystem->Config()->setPlan(root); - return(cbmSystem->storeConfiguration()); - */ - } - int PlanBatch::restore(XMLNode *_planRootNode) { --- 620,628 ---- } ! while ( (O=getCompilerOptionSet(0)) != 0) { remove(O); } } int PlanBatch::restore(XMLNode *_planRootNode) { *************** *** 614,618 **** XMLNode *OP; XMLNode *CO; - XMLNode *CI; XMLAttribute *A; --- 632,635 ---- |
From: Frederic T. <xf...@us...> - 2007-07-31 17:23:20
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Compiler In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv28117 Modified Files: Compiler-Options.cpp Compiler-Options.h Log Message: Options' handling (add/remove) improved. Index: Compiler-Options.h =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Compiler/Compiler-Options.h,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** Compiler-Options.h 30 May 2007 17:01:12 -0000 1.4 --- Compiler-Options.h 31 Jul 2007 17:23:13 -0000 1.5 *************** *** 33,36 **** --- 33,39 ---- virtual void remove(CBM::CompilerOption *_option); + virtual int addSingle(std::string _option); + virtual int removeSingle(std::string _option); + public: /** Constructor *************** *** 47,52 **** virtual int optionNumber(void); ! virtual void add(std::string _option); ! virtual void remove(std::string _option); /** Retrives options --- 50,55 ---- virtual int optionNumber(void); ! virtual int add(std::string _options); ! virtual int remove(std::string _options); /** Retrives options Index: Compiler-Options.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Compiler/Compiler-Options.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** Compiler-Options.cpp 30 May 2007 17:01:12 -0000 1.5 --- Compiler-Options.cpp 31 Jul 2007 17:23:13 -0000 1.6 *************** *** 15,34 **** std::string _options) { - std::string o = "!"; - int i = 0; - id=_id; ! if (_options=="") ! return; ! ! while (o!="") { ! o=cbmSystem->Split(_options, " ", i++); ! if ((o=="") && (i==1)) { ! add(_options); ! } ! if (o!="") { ! add(o); ! } ! } } --- 15,20 ---- std::string _options) { id=_id; ! add(_options); } *************** *** 61,64 **** --- 47,72 ---- } + int CompilerOptions::addSingle(std::string _option) + { + if (!Option(_option)) { + add(new CompilerOption(_option)); + return(1); + } else { + return(0); + } + } + + int CompilerOptions::removeSingle(std::string _option) + { + CBM::CompilerOption *O = Option(_option); + + if (O) { + remove(O); + return(1); + } else { + return(0); + } + } + CompilerOption *CompilerOptions::Option(std::string _id) { *************** *** 88,103 **** } ! void CompilerOptions::add(std::string _option) { ! if (!Option(_option)) ! add(new CompilerOption(_option)); } ! void CompilerOptions::remove(std::string _option) { ! CBM::CompilerOption *O = Option(_option); ! if (O) ! remove(O); } --- 96,139 ---- } ! int CompilerOptions::add(std::string _options) { ! std::string o = "!"; ! int i = 0; ! int r = 0; ! ! if (_options=="") ! return(0); ! ! while (o!="") { ! o=cbmSystem->Split(_options, " ", i++); ! if ((o=="") && (i==1)) { ! r+=addSingle(_options); ! } ! if (o!="") { ! r+=addSingle(o); ! } ! } ! return(r); } ! int CompilerOptions::remove(std::string _options) { ! std::string o = "!"; ! int i = 0; ! int r = 0; ! if (_options=="") ! return(0); ! ! while (o!="") { ! o=cbmSystem->Split(_options, " ", i++); ! if ((o=="") && (i==1)) { ! r+=removeSingle(_options); ! } ! if (o!="") { ! r+=removeSingle(o); ! } ! } ! return(r); } |
From: Frederic T. <xf...@us...> - 2007-07-31 17:22:35
|
Update of /cvsroot/compbench/CompBenchmarks++/compbenchmarks-plan In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv27741 Modified Files: cloptions.cpp Log Message: Fixes in CBM::Options* handling. Index: cloptions.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/compbenchmarks-plan/cloptions.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** cloptions.cpp 30 May 2007 19:27:46 -0000 1.4 --- cloptions.cpp 31 Jul 2007 17:22:27 -0000 1.5 *************** *** 29,32 **** --- 29,33 ---- typedef enum { ActionUndef, + ActionHelp, ActionRegisterPlan, ActionUnregisterPlan, ActionRegisterBatch, ActionUnregisterBatch, ActionListBatch, *************** *** 34,37 **** --- 35,39 ---- ActionRegisterOptionset, ActionUnregisterOptionset, ActionListOptionset, ActionRegisterOptions, ActionUnregisterOptions, ActionListOptions, + ActionRegisterOption, ActionUnregisterOption, ActionListOption, ActionRegisterBenchmark, ActionUnregisterBenchmark, ActionListBenchmark } OptAction; *************** *** 102,105 **** --- 104,108 ---- { CBM::PlanBatch *B; + std::string t; (*P)=restorePlan(planFileName); *************** *** 107,111 **** B=(*P)->getBatch(batchId); if (!B) { ! std::cerr << "Batch " << batchId << " not found in " << planFileName << std::endl; } --- 110,121 ---- B=(*P)->getBatch(batchId); if (!B) { ! if (batchId=="") { ! t="not specified. Look at --batch-use <batch-id>."; ! } else { ! t=batchId; ! t+=" not found in "; ! t+=planFileName; ! } ! std::cerr << "Batch " << t << std::endl; } *************** *** 130,134 **** { CBM::CompilerOptionSet *OS; ! OS = B->getCompilerOptions(optionsetName); if (!OS) std::cerr << "No option set defined. Look at --optionset-use." << std::endl; --- 140,144 ---- { CBM::CompilerOptionSet *OS; ! OS = B->getCompilerOptionSet(optionsetName); if (!OS) std::cerr << "No option set defined. Look at --optionset-use." << std::endl; *************** *** 161,164 **** --- 171,175 ---- std::string optionsName; std::string options; + std::string option; std::string benchmarkName; *************** *** 199,206 **** {"options-unregister", required_argument, 0, 5002}, {"options-list", no_argument, 0, 5003}, ! {"benchmark-register", required_argument, 0, 6001}, ! {"benchmark-unregister", required_argument, 0, 6002}, ! {"benchmark-list", no_argument, 0, 6003}, { 0, 0, 0, 0 } --- 210,221 ---- {"options-unregister", required_argument, 0, 5002}, {"options-list", no_argument, 0, 5003}, + {"options-use", required_argument, 0, 5004}, ! {"option-register", required_argument, 0, 6001}, ! {"option-unregister", required_argument, 0, 6002}, ! ! {"benchmark-register", required_argument, 0, 7001}, ! {"benchmark-unregister", required_argument, 0, 7002}, ! {"benchmark-list", no_argument, 0, 7003}, { 0, 0, 0, 0 } *************** *** 223,226 **** --- 238,242 ---- break; case 'h': + action=ActionHelp; break; case 1001: *************** *** 287,294 **** action=ActionRegisterOptions; optionsName=optarg; - optind++; - if (optind<=argc) { - options=argv[optind-1]; - } break; case 5002: --- 303,306 ---- *************** *** 296,311 **** optionsName=optarg; break; case 5003: action=ActionListOptions; break; ! case 6001: action=ActionRegisterBenchmark; benchmarkName=optarg; break; ! case 6002: action=ActionUnregisterBenchmark; benchmarkName=optarg; break; ! case 6003: action=ActionListBenchmark; break; --- 308,334 ---- optionsName=optarg; break; + case 6001: + action=ActionRegisterOption; + option=optarg; + break; + case 6002: + action=ActionUnregisterOption; + option=optarg; + break; case 5003: action=ActionListOptions; break; ! case 5004: ! optionsName=optarg; ! break; ! case 7001: action=ActionRegisterBenchmark; benchmarkName=optarg; break; ! case 7002: action=ActionUnregisterBenchmark; benchmarkName=optarg; break; ! case 7003: action=ActionListBenchmark; break; *************** *** 317,320 **** --- 340,346 ---- switch(action) { + case ActionHelp: + cbmOptionsHelp(); + break; case ActionRegisterPlan: if (cbmSystem->fileExists(planFileName)) { *************** *** 372,382 **** P=restorePlan(planFileName); if (P) { ! CBM::PlanBatch *B = new CBM::PlanBatch(batchName); P->addBatch(B); parseExitValue=!(P->store(planFileName)); storePlan(P, planFileName); - if (!parseExitValue) { - std::cout << "Batch " << batchName << " added in " << planFileName << std::endl; - } delete(P); } --- 398,405 ---- P=restorePlan(planFileName); if (P) { ! CBM::PlanBatch *B = new CBM::PlanBatch(P, batchName); P->addBatch(B); parseExitValue=!(P->store(planFileName)); storePlan(P, planFileName); delete(P); } *************** *** 391,398 **** parseExitValue=!(P->removeBatch(batchName)); if (!parseExitValue) { - std::cout << "Batch " << batchName << " removed from " << planFileName << std::endl; storePlan(P, planFileName); - } else { - std::cerr << "Cant't find such batch in plan " << planFileName << std::endl; } } --- 414,418 ---- *************** *** 443,455 **** if (B->add(C)) { storePlan(P, planFileName); - if (!parseExitValue) { - std::cout << C->Name() << " added in batch " << batchName << std::endl; - } - } else { - std::cerr << compilerName << " has not been added (probably because it was already present in that plan)." << std::endl; } delete(C); - } else { - std::cerr << compilerName << " is not a supported compiler." << std::endl; } delete(CS); --- 463,468 ---- *************** *** 479,491 **** if (B->remove(C)) { storePlan(P, planFileName); - if (!parseExitValue) { - std::cout << C->Name() << " removed from batch " << batchName << std::endl; - } - } else { - std::cerr << compilerName << " not found in that plan" << std::endl; } delete(C); - } else { - std::cerr << compilerName << " is not a supported compiler." << std::endl; } delete(CS); --- 492,497 ---- *************** *** 527,531 **** if (!getPlanFileName(planFileName)) break; ! B=restoreBatch(&P, planFileName, --- 533,537 ---- if (!getPlanFileName(planFileName)) break; ! B=restoreBatch(&P, planFileName, *************** *** 543,551 **** if (B->add(OS)) { storePlan(P, planFileName); - if (!parseExitValue) { - std::cout << OS->Id() << " added in batch " << batchName << std::endl; - } - } else { - std::cerr << optionsetName << " has not been added." << std::endl; } delete(P); --- 549,552 ---- *************** *** 568,581 **** } ! OS = B->getCompilerOptions(optionsetName); ! if (B->remove(OS)) { ! storePlan(P, planFileName); ! if (!parseExitValue) { ! std::cout << OS->Id() << " removed from batch " << batchName << std::endl; } } else { ! std::cerr << optionsetName << " not found in batch." << std::endl; } - delete(P); --- 569,580 ---- } ! OS = B->getCompilerOptionSet(optionsetName); ! if (OS) { ! if (B->remove(OS)) { ! storePlan(P, planFileName); } } else { ! std::cerr << "No such option set." << std::endl; } delete(P); *************** *** 597,601 **** } ! n=B->compilerOptionNumber(); if (!n) { std::cout << "No option set registered." << std::endl; --- 596,600 ---- } ! n=B->compilerOptionSetNumber(); if (!n) { std::cout << "No option set registered." << std::endl; *************** *** 604,608 **** for(i=0; i<n; i++) { ! OS=B->getCompilerOptions(i); std::cout << " * " << OS->Id() << std::endl; } --- 603,607 ---- for(i=0; i<n; i++) { ! OS=B->getCompilerOptionSet(i); std::cout << " * " << OS->Id() << std::endl; } *************** *** 629,641 **** if (!OS) break; ! ! O=new CBM::CompilerOptions(optionsName, options); if (OS->add(O)) { storePlan(P, planFileName); - if (!parseExitValue) { - std::cout << O->Id() << " added in set " << optionsetName << std::endl; - } - } else { - std::cerr << O->Id() << " has not been added." << std::endl; } delete(P); --- 628,634 ---- if (!OS) break; ! O=new CBM::CompilerOptions(optionsName, ""); if (OS->add(O)) { storePlan(P, planFileName); } delete(P); *************** *** 666,678 **** if (OS->remove(O)) { storePlan(P, planFileName); ! if (!parseExitValue) { ! std::cout << O->Id() << " removed from set " << optionsetName << std::endl; ! } ! } else { ! std::cerr << O->Id() << " can't be removed." << std::endl; ! } delete(O); - } else { - std::cerr << optionsName << " has not been found." << std::endl; } delete(P); --- 659,664 ---- if (OS->remove(O)) { storePlan(P, planFileName); ! } delete(O); } delete(P); *************** *** 714,719 **** delete(P); break; ! case ActionRegisterBenchmark: if (!getPlanFileName(planFileName)) break; --- 700,734 ---- delete(P); break; + case ActionRegisterOption: + if (!getPlanFileName(planFileName)) + break; + + B=restoreBatch(&P, + planFileName, + batchName); + + if (!P) + break; + + if (!B) { + delete(P); + break; + } + + OS = getOptionSet(B, optionsetName); + if (!OS) + break; + + O=OS->get(optionsName); + if (O) { + if (O->add(option)) { + storePlan(P, planFileName); + } + delete(O); + } + delete(P); + break; ! case ActionUnregisterOption: if (!getPlanFileName(planFileName)) break; *************** *** 731,750 **** } ! BM=getBenchmark(benchmarkName); ! if (!BM) break; ! if (B->add(BM)) { ! storePlan(P, planFileName); ! if (!parseExitValue) { ! std::cout << BM->Name() << " added in " << B->Id() << std::endl; } else { ! std::cerr << BM->Name() << " can't be added." << std::endl; } - } else { - std::cerr << benchmarkName << " can't be added; see ./compbenchmarks-core -qib" << std::endl; - std::cerr << "Possible causes are either that " << BM->Name() << " is already present" - << "in that plan or not fully installed." << std::endl; } delete(BM); delete(P); --- 746,821 ---- } ! OS = getOptionSet(B, optionsetName); ! if (!OS) break; ! O=OS->get(optionsName); ! if (O) { ! if (O->remove(option)) { ! storePlan(P, planFileName); ! } ! delete(O); ! } ! delete(P); ! break; ! case ActionListOption: ! if (!getPlanFileName(planFileName)) ! break; ! ! B=restoreBatch(&P, ! planFileName, ! batchName); ! ! if (!P) ! break; ! ! if (!B) { ! delete(P); ! break; ! } ! ! OS = getOptionSet(B, optionsetName); ! if (!OS) ! break; ! ! O=OS->get(optionsName); ! if (O) { ! n=O->optionNumber(); ! if (!n) { ! std::cout << "No option set registered." << std::endl; } else { ! printf("%d option found :\n", n); ! ! for(i=0; i<n; i++) { ! OS=B->getCompilerOptionSet(i); ! std::cout << " * " << O->Option(i) << std::endl; ! } } } + delete(P); + break; + case ActionRegisterBenchmark: + if (!getPlanFileName(planFileName)) + break; + + B=restoreBatch(&P, + planFileName, + batchName); + + if (!P) + break; + + if (!B) { + delete(P); + break; + } + + BM=getBenchmark(benchmarkName); + if (!BM) + break; + + if (B->add(BM)) + storePlan(P, planFileName); + delete(BM); delete(P); *************** *** 773,781 **** if (B->remove(BM)) { storePlan(P, planFileName); - if (!parseExitValue) { - std::cout << BM->Name() << " removed from " << B->Id() << std::endl; - } else { - std::cerr << BM->Name() << " can't be removed." << std::endl; - } } else { std::cerr << benchmarkName << " can't be removed; see ./compbenchmarks-core -qib" << std::endl; --- 844,847 ---- |
From: Frederic T. <xf...@us...> - 2007-06-13 19:45:47
|
Update of /cvsroot/compbench/CompBenchmarks++/CBM-PI/t/reference In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv23176 Added Files: plan-1batch.xml plan-compilersbatch.xml plan-empty.xml Log Message: First import. --- NEW FILE: plan-compilersbatch.xml --- <libcompbenchmarks-plan> <plan-batchs> <plan-batch id="b0"> <selection> <benchmarks/> <compilers> <compiler id="/usr/bin/gcc"/> </compilers> <option-set/> </selection> </plan-batch> </plan-batchs> <run> <iteration index="0"/> </run> </libcompbenchmarks-plan> --- NEW FILE: plan-empty.xml --- <libcompbenchmarks-plan> <plan-batchs/> <run> <iteration index="0"/> </run> </libcompbenchmarks-plan> --- NEW FILE: plan-1batch.xml --- <libcompbenchmarks-plan> <plan-batchs> <plan-batch id="b0"> <selection> <benchmarks/> <compilers/> <option-set/> </selection> </plan-batch> </plan-batchs> <run> <iteration index="0"/> </run> </libcompbenchmarks-plan> |
From: Frederic T. <xf...@us...> - 2007-06-13 18:40:46
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv1230 Modified Files: Plan-Batch.cpp Plan-Batch.h Log Message: Language compatibility checking before adding benchmarks or compilers. Index: Plan-Batch.h =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan/Plan-Batch.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** Plan-Batch.h 30 May 2007 17:02:27 -0000 1.2 --- Plan-Batch.h 13 Jun 2007 18:40:43 -0000 1.3 *************** *** 52,55 **** --- 52,60 ---- virtual int isUnique(class Compiler *_compiler); + + /** languages */ + virtual int isLanguageCompatibleWithCompilers(std::string _lang); + virtual int isLanguageCompatibleWithBenchmarks(std::string _lang); + virtual int isUnique(CBM_OS *_set); virtual int isUnique(class Benchmark *_benchmark); Index: Plan-Batch.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan/Plan-Batch.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** Plan-Batch.cpp 13 Jun 2007 18:11:37 -0000 1.4 --- Plan-Batch.cpp 13 Jun 2007 18:40:43 -0000 1.5 *************** *** 52,55 **** --- 52,99 ---- } + int PlanBatch::isLanguageCompatibleWithCompilers(std::string _lang) + { + int i; + int n = compilerNumber(); + CBM::Compiler *C; + std::string l; + + for(i=0; i<n; i++) { + C=getCompiler(i); + if (C->Language() != _lang) { + l=_lang; + l+=" language is incompatible with "; + l+=C->Language(); + l+=" defined by "; + l+=C->Name(); + cbmUI->outputInfo(l); + return(0); + } + } + return(1); + } + + int PlanBatch::isLanguageCompatibleWithBenchmarks(std::string _lang) + { + int i; + int n = benchmarkNumber(); + CBM::Benchmark *B; + std::string l; + + for(i=0; i<n; i++) { + B=getBenchmark(i); + if (B->Package()->language() != _lang) { + l=_lang; + l+=" language is incompatible with "; + l+=B->Package()->language(); + l+=" defined by "; + l+=B->Name(); + cbmUI->outputInfo(l); + return(0); + } + } + return(1); + } + int PlanBatch::isUnique(CBM::CompilerOptionSet *_set) { *************** *** 151,155 **** if (!_compiler) { ! cbmUI->outputKO("Not a supported compiler"); return(0); } --- 195,206 ---- if (!_compiler) { ! cbmUI->outputInfo("Not a supported compiler"); ! cbmUI->outputKO(); ! return(0); ! } ! ! if ((!isLanguageCompatibleWithCompilers(_compiler->Language())) || ! (!isLanguageCompatibleWithBenchmarks(_compiler->Language()))) { ! cbmUI->outputKO(); return(0); } *************** *** 212,215 **** --- 263,273 ---- return(0); } + + if ((!isLanguageCompatibleWithCompilers(_benchmark->Package()->language())) || + (!isLanguageCompatibleWithBenchmarks(_benchmark->Package()->language()))) { + cbmUI->outputKO(); + return(0); + } + if (_benchmark->Package()->getStatus()<CBM::Package::Preconfigured) { cbmUI->outputInfo("Benchmark not configured. Please finish its installation"); |
From: Frederic T. <xf...@us...> - 2007-06-13 18:40:04
|
Update of /cvsroot/compbench/CompBenchmarks++/compbenchmarks-core In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv818 Modified Files: cloptions.cpp Log Message: std::out message removed. Index: cloptions.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/compbenchmarks-core/cloptions.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** cloptions.cpp 7 Jun 2007 16:18:13 -0000 1.5 --- cloptions.cpp 13 Jun 2007 18:39:58 -0000 1.6 *************** *** 86,89 **** --- 86,90 ---- << " --force : force operation" << std::endl << " --verbose <0,1,2> : manage messages (quiet,basic reporting,complete)" << std::endl + << " --quiet : alias for --verbose 0" << std::endl << std::endl; } *************** *** 283,286 **** --- 284,288 ---- {"force", 0, 0, 'f' }, {"verbose", required_argument, 0, 'V' }, + {"quiet", no_argument, 0, 'Q' }, { 0, 0, 0, 0} }; *************** *** 292,296 **** break; ! c = getopt_long (argc, argv, "hvxiI:F:U:qHc:p::V:B:b::A:aMmD:E:P:C:T:R:S:f", // uLHPCFIB", /* :011000112", */ long_options, &option_index); if (c==-1) { --- 294,298 ---- break; ! c = getopt_long (argc, argv, "hvxiI:F:U:qHc:p::V:B:b::A:aMmD:E:P:C:T:R:S:fQ", // uLHPCFIB", /* :011000112", */ long_options, &option_index); if (c==-1) { *************** *** 323,326 **** --- 325,331 ---- } break; + case 'Q': + UO_verbose=CBM::None; + break; case 'q': cbmSingleDomain(&domain, DomainQuery, "q"); |
From: Frederic T. <xf...@us...> - 2007-06-13 18:12:05
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Compiler In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv22997 Modified Files: Compiler-OptionSet.cpp Log Message: Plan related messages added. Index: Compiler-OptionSet.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Compiler/Compiler-OptionSet.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** Compiler-OptionSet.cpp 30 May 2007 17:01:35 -0000 1.2 --- Compiler-OptionSet.cpp 13 Jun 2007 18:11:55 -0000 1.3 *************** *** 9,12 **** --- 9,13 ---- #include <Compiler/Compiler-OptionSet.h> #include <Compiler/Compiler-Options.h> + #include <UI/UI.h> using namespace CBM; *************** *** 43,50 **** CBM::CompilerOptions *CompilerOptionSet::add(std::string _id) { ! CBM::CompilerOptions *result; ! result=new CBM::CompilerOptions(_id); ! options.push_back(result); return(result); --- 44,57 ---- CBM::CompilerOptions *CompilerOptionSet::add(std::string _id) { ! CBM::CompilerOptions *result = 0; ! cbmUI->msgPlanOptionsetRegister(_id); ! if (!get(_id)) { ! result=new CBM::CompilerOptions(_id); ! options.push_back(result); ! cbmUI->outputOK(); ! } else { ! cbmUI->outputKO("Options already exists (change name)"); ! } return(result); *************** *** 53,57 **** CBM::CompilerOptions *CompilerOptionSet::add(CBM::CompilerOptions *_options) { ! options.push_back(_options); return(_options); --- 60,72 ---- CBM::CompilerOptions *CompilerOptionSet::add(CBM::CompilerOptions *_options) { ! cbmUI->msgPlanOptionsetRegister(_options->Id()); ! ! if (!get(_options->Id())) { ! options.push_back(_options); ! cbmUI->outputOK(); ! } else { ! cbmUI->outputKO("Options already exists (change name)"); ! return(0); ! } return(_options); *************** *** 65,69 **** std::vector<CBM::CompilerOptions*> noptions; int found = 0; ! for(i=0; i<n; i++) { O=options[i]; --- 80,86 ---- std::vector<CBM::CompilerOptions*> noptions; int found = 0; ! ! cbmUI->msgPlanOptionsUnregister(_options->Id()); ! for(i=0; i<n; i++) { O=options[i]; *************** *** 75,80 **** } } ! if (found) options=noptions; return(found); } --- 92,101 ---- } } ! if (found) { ! cbmUI->outputOK(); options=noptions; + } else { + cbmUI->outputKO("Specified options not found"); + } return(found); } *************** *** 83,86 **** --- 104,108 ---- { CBM::CompilerOptions *O = get(_id); + if (O) return(remove(O)); |
From: Frederic T. <xf...@us...> - 2007-06-13 18:11:52
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv22980 Modified Files: Plan-Batch.cpp Plan.cpp Log Message: Plan related messages added. Index: Plan.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan/Plan.cpp,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** Plan.cpp 6 Jun 2007 21:42:57 -0000 1.12 --- Plan.cpp 13 Jun 2007 18:11:37 -0000 1.13 *************** *** 19,22 **** --- 19,24 ---- #include <Base/Result.h> + #include <UI/UI.h> + using namespace CBM; *************** *** 71,76 **** --- 73,80 ---- CBM::PlanBatch *Plan::addBatch(CBM::PlanBatch *_batch) { + cbmUI->msgPlanBatchRegister(_batch->Id()); planBatch.push_back(_batch); stop(); + cbmUI->outputOK(); return(_batch); } *************** *** 84,87 **** --- 88,92 ---- int r = 0; + cbmUI->msgPlanBatchUnregister(_ps->Id()); for(i=0; i<n; i++) { B=getBatch(i); *************** *** 91,98 **** r=1; } ! delete(_ps); ! planBatch=nplanBatch; ! if (r) stop(); return(r); } --- 96,108 ---- r=1; } ! ! if (r) { stop(); + delete(_ps); + planBatch=nplanBatch; + cbmUI->outputOK(); + } else { + cbmUI->outputKO("Given batch not found"); + } return(r); } *************** *** 253,256 **** --- 263,267 ---- int Plan::store(std::string _filename) { + int r; XMLNode *root = XML(); std::string data = root->str(); *************** *** 260,264 **** filename=_filename; ! return(cbmSystem->fileWrite(filename, data)); } --- 271,284 ---- filename=_filename; ! // !!! default... ! cbmUI->msgPlanRegister(filename, ! 0); ! r=cbmSystem->fileWrite(filename, data); ! ! if (r) ! cbmUI->outputOK(); ! else ! cbmUI->outputKO(); ! return(r); } *************** *** 278,281 **** --- 298,303 ---- + cbmUI->msgPlanRestore(_filename); + filename=_filename; *************** *** 283,296 **** reset(); ! if (!planRootNode) return(0); if (planRootNode->Name()!="libcompbenchmarks-plan") { return(0); } PBs=planRootNode->getNode("plan-batchs"); ! if (!PBs) return(0); n=PBs->nodeNumber(); --- 305,323 ---- reset(); ! if (!planRootNode) { ! cbmUI->outputKO("Not a Plan XML file"); return(0); + } if (planRootNode->Name()!="libcompbenchmarks-plan") { + cbmUI->outputKO("Invalid plan file : root object is not libcompbenchmarks-plan"); return(0); } PBs=planRootNode->getNode("plan-batchs"); ! if (!PBs) { ! cbmUI->outputKO("Invalid plan file : <plan-batchs/> not found"); return(0); + } n=PBs->nodeNumber(); *************** *** 306,322 **** R=planRootNode->getNode("run"); ! if (!R) return(0); CI=R->getNode("iteration"); ! if (!CI) return(0); A=CI->getAttribute("index"); ! if (!A) return(0); iteration=atoi(A->Value().c_str()); return(1); } --- 333,357 ---- R=planRootNode->getNode("run"); ! if (!R) { ! cbmUI->outputKO("Invalid plan file : <run/> not fount"); return(0); + } CI=R->getNode("iteration"); ! if (!CI) { ! cbmUI->outputKO("Invalid plan file : <iteration/> not found"); return(0); + } A=CI->getAttribute("index"); ! if (!A) { ! cbmUI->outputKO("Invalid plan file : index attribute not found for <iteration/>"); return(0); + } iteration=atoi(A->Value().c_str()); + + cbmUI->outputOK(); return(1); } Index: Plan-Batch.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan/Plan-Batch.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** Plan-Batch.cpp 6 Jun 2007 21:42:57 -0000 1.3 --- Plan-Batch.cpp 13 Jun 2007 18:11:37 -0000 1.4 *************** *** 17,20 **** --- 17,22 ---- #include <Base/Result.h> + #include <UI/UI.h> + using namespace CBM; *************** *** 146,150 **** int PlanBatch::add(CBM::Compiler *_compiler) { ! if ((!_compiler) || (!isUnique(_compiler))) { return(0); } --- 148,161 ---- int PlanBatch::add(CBM::Compiler *_compiler) { ! cbmUI->msgPlanCompilerRegister(_compiler->Name()); ! ! if (!_compiler) { ! cbmUI->outputKO("Not a supported compiler"); ! return(0); ! } ! ! if (!isUnique(_compiler)) { ! cbmUI->outputInfo("Compiler already exists in batch"); ! cbmUI->outputKO(); return(0); } *************** *** 152,155 **** --- 163,168 ---- compilers.push_back(_compiler); stop(); + + cbmUI->outputOK(); return(1); } *************** *** 157,161 **** int PlanBatch::add(CBM::CompilerOptionSet *_set) { ! if ((!_set) || (!isUnique(_set))) { return(0); } --- 170,184 ---- int PlanBatch::add(CBM::CompilerOptionSet *_set) { ! cbmUI->msgPlanOptionsetRegister(_set->Id()); ! ! if (!_set) { ! cbmUI->outputInfo("No valid option set given"); ! cbmUI->outputKO(); ! return(0); ! } ! ! if (!isUnique(_set)) { ! cbmUI->outputInfo("Option set already exists in batch"); ! cbmUI->outputKO(); return(0); } *************** *** 163,166 **** --- 186,191 ---- compilerOptions.push_back(_set); stop(); + + cbmUI->outputOK(); return(1); } *************** *** 174,181 **** int PlanBatch::add(CBM::Benchmark *_benchmark) { ! if ((!_benchmark) || (!isUnique(_benchmark))) { return(0); } if (_benchmark->Package()->getStatus()<CBM::Package::Preconfigured) { return(0); } --- 199,218 ---- int PlanBatch::add(CBM::Benchmark *_benchmark) { ! cbmUI->msgPlanBenchmarkRegister(_benchmark->Name()); ! ! if (!_benchmark) { ! cbmUI->outputInfo("No valid/supported benchmark given"); ! cbmUI->outputKO(); ! return(0); ! } ! ! if (!isUnique(_benchmark)) { ! cbmUI->outputInfo("Benchmark already exists in batch"); ! cbmUI->outputKO(); return(0); } if (_benchmark->Package()->getStatus()<CBM::Package::Preconfigured) { + cbmUI->outputInfo("Benchmark not configured. Please finish its installation"); + cbmUI->outputKO(); return(0); } *************** *** 183,186 **** --- 220,224 ---- benchmarks.push_back(_benchmark); stop(); + cbmUI->outputOK(); return(1); } *************** *** 194,197 **** --- 232,236 ---- int found = 0; + cbmUI->msgPlanCompilerUnregister(_compiler->Name()); for(i=0; i<n; i++) { C=getCompiler(i); *************** *** 205,212 **** } } - compilers=ncompilers; ! if (found) stop(); return(found); } --- 244,256 ---- } } ! if (found) { ! compilers=ncompilers; stop(); + cbmUI->outputOK(); + } else { + cbmUI->outputInfo("No such compiler in batch"); + cbmUI->outputKO(); + } return(found); } *************** *** 220,223 **** --- 264,268 ---- int found = 0; + cbmUI->msgPlanOptionsetUnregister(_set->Id()); for(i=0; i<n; i++) { OS=getCompilerOptions(i); *************** *** 230,236 **** } } ! compilerOptions=noptions; ! if (found) stop(); return(found); } --- 275,287 ---- } } ! ! if (found) { ! compilerOptions=noptions; stop(); + cbmUI->outputOK(); + } else { + cbmUI->outputInfo("No such option set in batch"); + cbmUI->outputKO(); + } return(found); } *************** *** 249,261 **** CBM::Benchmark *B = 0; std::vector<CBM::Benchmark*> nbenchmarks; for(i=0; i<n; i++) { B=getBenchmark(i); if (B!=_benchmark) nbenchmarks.push_back(B); } ! stop(); ! benchmarks=nbenchmarks; ! return(1); } --- 300,325 ---- CBM::Benchmark *B = 0; std::vector<CBM::Benchmark*> nbenchmarks; + int found = 0; + cbmUI->msgPlanBenchmarkUnregister(_benchmark->Name()); + for(i=0; i<n; i++) { B=getBenchmark(i); if (B!=_benchmark) nbenchmarks.push_back(B); + else + found=1; } ! ! if (found) { ! stop(); ! benchmarks=nbenchmarks; ! cbmUI->outputOK(); ! } else { ! cbmUI->outputInfo("No such benchmark in batch"); ! cbmUI->outputKO(); ! } ! ! return(found); } *************** *** 451,454 **** --- 515,520 ---- void PlanBatch::stop(void) { + if (iteration) + cbmUI->outputInfo("Context changed : current plan benchmarking will be restarted."); iteration=0; } |
From: Frederic T. <xf...@us...> - 2007-06-13 18:11:46
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv22569 Modified Files: UI-Console.cpp UI.cpp UI.h UI-Msg.cpp UI-Msg.h Log Message: Plan related added messages. Index: UI.h =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI/UI.h,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** UI.h 6 Jun 2007 17:39:19 -0000 1.8 --- UI.h 13 Jun 2007 18:10:35 -0000 1.9 *************** *** 11,14 **** --- 11,15 ---- #include <UI/UI-Msg.h> + #include <Base/Thread.h> namespace CBM { *************** *** 23,26 **** --- 24,28 ---- UIMsg *root; UIMsg *current; + Mutex mui; virtual UIMsg *currentMsg(void); *************** *** 53,56 **** --- 55,73 ---- virtual UIMsg *msgGroup(std::string _name); + virtual UIMsg *msgPlanRegister(std::string _file, + int _default); + virtual UIMsg *msgPlanRestore(std::string _name); + virtual UIMsg *msgPlanUnregister(std::string _name); + virtual UIMsg *msgPlanBatchRegister(std::string _name); + virtual UIMsg *msgPlanBatchUnregister(std::string _name); + virtual UIMsg *msgPlanCompilerRegister(std::string _name); + virtual UIMsg *msgPlanCompilerUnregister(std::string _name); + virtual UIMsg *msgPlanOptionsetRegister(std::string _name); + virtual UIMsg *msgPlanOptionsetUnregister(std::string _name); + virtual UIMsg *msgPlanOptionsRegister(std::string _name); + virtual UIMsg *msgPlanOptionsUnregister(std::string _name); + virtual UIMsg *msgPlanBenchmarkRegister(std::string _name); + virtual UIMsg *msgPlanBenchmarkUnregister(std::string _name); + virtual UIMsg *outputInfo(std::string _text); virtual UIMsg *Progress(float _pc); Index: UI.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI/UI.cpp,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** UI.cpp 6 Jun 2007 17:39:19 -0000 1.9 --- UI.cpp 13 Jun 2007 18:10:35 -0000 1.10 *************** *** 9,13 **** #include <UI/UI.h> #include <System/System.h> - #include <Base/Thread.h> #include <libcompbenchmarks.h> --- 9,12 ---- *************** *** 19,23 **** CBM::UI *CBM::cbmUI = 0; CBM::UI *CBM::cbmUI_old = 0; - pthread_t ui_main_thread = currentThread(); UI::UI() --- 18,21 ---- *************** *** 39,49 **** void UI::postMsg(UIMsg *_msg) { ! if (ui_main_thread!=currentThread()) { ! std::cerr << "BUG : UI::postMsg() used in another thread.\n" << std::endl; ! std::cerr << "BUG : here's message : " << std::endl; ! std::cerr << _msg->str() << std::endl; ! return; ! } ! if (!current) current=root; --- 37,41 ---- void UI::postMsg(UIMsg *_msg) { ! mui.Lock(); if (!current) current=root; *************** *** 53,60 **** --- 45,54 ---- current=_msg; Display(current); + mui.Unlock(); } void UI::childDone(void) { + mui.Lock(); if (current) { DisplayDone(current); *************** *** 64,67 **** --- 58,62 ---- current=0; } + mui.Unlock(); } *************** *** 206,209 **** --- 201,310 ---- } + UIMsg *UI::msgPlanRegister(std::string _name, + int _default) + { + UIMsg *msg = new UIMsgPlanRegister(_name, _default); + postMsg(msg); + + return(msg); + } + + UIMsg *UI::msgPlanRestore(std::string _name) + { + UIMsg *msg = new UIMsgPlanRestore(_name); + postMsg(msg); + + return(msg); + } + + UIMsg *UI::msgPlanUnregister(std::string _name) + { + UIMsg *msg = new UIMsgPlanUnregister(_name); + postMsg(msg); + + return(msg); + } + + UIMsg *UI::msgPlanBatchRegister(std::string _name) + { + UIMsg *msg = new UIMsgPlanBatchRegister(_name); + postMsg(msg); + + return(msg); + } + + UIMsg *UI::msgPlanBatchUnregister(std::string _name) + { + UIMsg *msg = new UIMsgPlanBatchUnregister(_name); + postMsg(msg); + + return(msg); + } + + UIMsg *UI::msgPlanCompilerRegister(std::string _name) + { + UIMsg *msg = new UIMsgPlanCompilerRegister(_name); + postMsg(msg); + + return(msg); + } + + UIMsg *UI::msgPlanCompilerUnregister(std::string _name) + { + UIMsg *msg = new UIMsgPlanCompilerUnregister(_name); + postMsg(msg); + + return(msg); + } + + UIMsg *UI::msgPlanOptionsetRegister(std::string _name) + { + UIMsg *msg = new UIMsgPlanOptionsetRegister(_name); + postMsg(msg); + + return(msg); + } + + UIMsg *UI::msgPlanOptionsetUnregister(std::string _name) + { + UIMsg *msg = new UIMsgPlanOptionsetUnregister(_name); + postMsg(msg); + + return(msg); + } + + UIMsg *UI::msgPlanOptionsRegister(std::string _name) + { + UIMsg *msg = new UIMsgPlanOptionsRegister(_name); + postMsg(msg); + + return(msg); + } + + UIMsg *UI::msgPlanOptionsUnregister(std::string _name) + { + UIMsg *msg = new UIMsgPlanOptionsUnregister(_name); + postMsg(msg); + + return(msg); + } + + UIMsg *UI::msgPlanBenchmarkRegister(std::string _name) + { + UIMsg *msg = new UIMsgPlanBenchmarkRegister(_name); + postMsg(msg); + + return(msg); + } + + UIMsg *UI::msgPlanBenchmarkUnregister(std::string _name) + { + UIMsg *msg = new UIMsgPlanBenchmarkUnregister(_name); + postMsg(msg); + + return(msg); + } + + UIMsg *UI::outputInfo(std::string _test) { Index: UI-Msg.h =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI/UI-Msg.h,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** UI-Msg.h 6 Jun 2007 21:37:59 -0000 1.3 --- UI-Msg.h 13 Jun 2007 18:10:35 -0000 1.4 *************** *** 54,58 **** PackageMake, PackageTest, PackageClean, BenchmarkBench, BenchmarkResult, ! CompilerAutodetect }; private: --- 54,64 ---- PackageMake, PackageTest, PackageClean, BenchmarkBench, BenchmarkResult, ! CompilerAutodetect, ! PlanRegister, PlanRestore, PlanUnregister, ! PlanBatchRegister, PlanBatchUnregister, ! PlanCompilerRegister, PlanCompilerUnregister, ! PlanOptionsetRegister, PlanOptionsetUnregister, ! PlanOptionsRegister, PlanOptionsUnregister, ! PlanBenchmarkRegister, PlanBenchmarkUnregister }; private: *************** *** 60,63 **** --- 66,70 ---- XMLNode *progressNode; XMLNode *childsNode; + Flags flags; virtual std::string toString(int _i); *************** *** 67,70 **** --- 74,80 ---- virtual void addObject(ObjectType _type, std::string _name); + virtual void addField(std::string _name, + std::string _value); + virtual void addAction(ActionType _type, std::string _action = ""); *************** *** 76,79 **** --- 86,90 ---- UIMsg(Flags _flags = NoProgress); + virtual Flags getFlags(void); virtual void addChild(UIMsg *_child); *************** *** 198,202 **** --- 209,299 ---- virtual ~UIMsgBench(); }; + + + + + class UIMsgPlanRegister : public UIMsg { + public: + UIMsgPlanRegister(std::string _file, + int _default); + virtual ~UIMsgPlanRegister(); + }; + + class UIMsgPlanRestore : public UIMsg { + public: + UIMsgPlanRestore(std::string _file); + virtual ~UIMsgPlanRestore(); + }; + + class UIMsgPlanUnregister : public UIMsg { + public: + UIMsgPlanUnregister(std::string _name); + virtual ~UIMsgPlanUnregister(); + }; + + class UIMsgPlanBatchRegister : public UIMsg { + public: + UIMsgPlanBatchRegister(std::string _name); + virtual ~UIMsgPlanBatchRegister(); + }; + + class UIMsgPlanBatchUnregister : public UIMsg { + public: + UIMsgPlanBatchUnregister(std::string _name); + virtual ~UIMsgPlanBatchUnregister(); + }; + + class UIMsgPlanCompilerRegister : public UIMsg { + public: + UIMsgPlanCompilerRegister(std::string _name); + virtual ~UIMsgPlanCompilerRegister(); + }; + + class UIMsgPlanCompilerUnregister : public UIMsg { + public: + UIMsgPlanCompilerUnregister(std::string _name); + virtual ~UIMsgPlanCompilerUnregister(); + }; + + class UIMsgPlanOptionsetRegister : public UIMsg { + public: + UIMsgPlanOptionsetRegister(std::string _name); + virtual ~UIMsgPlanOptionsetRegister(); + }; + + class UIMsgPlanOptionsetUnregister : public UIMsg { + public: + UIMsgPlanOptionsetUnregister(std::string _name); + virtual ~UIMsgPlanOptionsetUnregister(); + }; + class UIMsgPlanOptionsRegister : public UIMsg { + public: + UIMsgPlanOptionsRegister(std::string _name); + virtual ~UIMsgPlanOptionsRegister(); + }; + + class UIMsgPlanOptionsUnregister : public UIMsg { + public: + UIMsgPlanOptionsUnregister(std::string _name); + virtual ~UIMsgPlanOptionsUnregister(); + }; + + class UIMsgPlanBenchmarkRegister : public UIMsg { + public: + UIMsgPlanBenchmarkRegister(std::string _name); + virtual ~UIMsgPlanBenchmarkRegister(); + }; + + class UIMsgPlanBenchmarkUnregister : public UIMsg { + public: + UIMsgPlanBenchmarkUnregister(std::string _name); + virtual ~UIMsgPlanBenchmarkUnregister(); + }; + + + + + class UIMsgGroup : public UIMsg { public: Index: UI-Msg.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI/UI-Msg.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** UI-Msg.cpp 6 Jun 2007 21:37:59 -0000 1.3 --- UI-Msg.cpp 13 Jun 2007 18:10:35 -0000 1.4 *************** *** 15,21 **** : XMLNode("msg") { ! if (_flags == NoProgress) addAttribute("flags", "NoProgress"); ! if (_flags == Progress) addAttribute("flags", "Progress"); --- 15,22 ---- : XMLNode("msg") { ! flags=_flags; ! if (flags == NoProgress) addAttribute("flags", "NoProgress"); ! if (flags == Progress) addAttribute("flags", "Progress"); *************** *** 25,28 **** --- 26,34 ---- } + CBM::UIMsg::Flags UIMsg::getFlags(void) + { + return(flags); + } + std::string UIMsg::toString(int _i) { *************** *** 53,56 **** --- 59,71 ---- } + void UIMsg::addField(std::string _name, + std::string _value) + { + XMLNode *O = getNode("object"); + + O->addAttribute(_name, _value); + add(O); + } + void UIMsg::addAction(ActionType _type, std::string _action) *************** *** 292,295 **** --- 307,464 ---- } + + + + UIMsgPlanRegister::UIMsgPlanRegister(std::string _file, + int _default) + : UIMsg() + { + addObject(UndefObject, _file); + addField("default", _default ? "yes" : "no"); + + addAction(PlanRegister); + } + + UIMsgPlanRegister::~UIMsgPlanRegister() + { + } + + UIMsgPlanRestore::UIMsgPlanRestore(std::string _file) + : UIMsg() + { + addObject(UndefObject, _file); + addAction(PlanRestore); + } + + UIMsgPlanRestore::~UIMsgPlanRestore() + { + } + + UIMsgPlanUnregister::UIMsgPlanUnregister(std::string _file) + : UIMsg() + { + addObject(UndefObject, _file); + addAction(PlanUnregister); + } + + UIMsgPlanUnregister::~UIMsgPlanUnregister() + { + } + + UIMsgPlanBatchRegister::UIMsgPlanBatchRegister(std::string _name) + : UIMsg() + { + addObject(UndefObject, _name); + addAction(PlanBatchRegister); + } + + UIMsgPlanBatchRegister::~UIMsgPlanBatchRegister() + { + } + + UIMsgPlanBatchUnregister::UIMsgPlanBatchUnregister(std::string _name) + : UIMsg() + { + addObject(UndefObject, _name); + addAction(PlanBatchUnregister); + } + + UIMsgPlanBatchUnregister::~UIMsgPlanBatchUnregister() + { + } + + UIMsgPlanCompilerRegister::UIMsgPlanCompilerRegister(std::string _name) + : UIMsg() + { + addObject(UndefObject, _name); + addAction(PlanCompilerRegister); + } + + UIMsgPlanCompilerRegister::~UIMsgPlanCompilerRegister() + { + } + + UIMsgPlanCompilerUnregister::UIMsgPlanCompilerUnregister(std::string _name) + : UIMsg() + { + addObject(UndefObject, _name); + addAction(PlanCompilerUnregister); + } + + UIMsgPlanCompilerUnregister::~UIMsgPlanCompilerUnregister() + { + } + + UIMsgPlanOptionsetRegister::UIMsgPlanOptionsetRegister(std::string _name) + : UIMsg() + { + addObject(UndefObject, _name); + addAction(PlanOptionsetRegister); + } + + UIMsgPlanOptionsetRegister::~UIMsgPlanOptionsetRegister() + { + } + + UIMsgPlanOptionsetUnregister::UIMsgPlanOptionsetUnregister(std::string _name) + : UIMsg() + { + addObject(UndefObject, _name); + addAction(PlanOptionsetUnregister); + } + + UIMsgPlanOptionsetUnregister::~UIMsgPlanOptionsetUnregister() + { + } + + UIMsgPlanOptionsRegister::UIMsgPlanOptionsRegister(std::string _name) + : UIMsg() + { + addObject(UndefObject, _name); + addAction(PlanOptionsRegister); + } + + UIMsgPlanOptionsRegister::~UIMsgPlanOptionsRegister() + { + } + + UIMsgPlanOptionsUnregister::UIMsgPlanOptionsUnregister(std::string _name) + : UIMsg() + { + addObject(UndefObject, _name); + addAction(PlanOptionsUnregister); + } + + UIMsgPlanOptionsUnregister::~UIMsgPlanOptionsUnregister() + { + } + + UIMsgPlanBenchmarkRegister::UIMsgPlanBenchmarkRegister(std::string _name) + : UIMsg() + { + addObject(UndefObject, _name); + addAction(PlanBenchmarkRegister); + } + + UIMsgPlanBenchmarkRegister::~UIMsgPlanBenchmarkRegister() + { + } + + UIMsgPlanBenchmarkUnregister::UIMsgPlanBenchmarkUnregister(std::string _name) + : UIMsg() + { + addObject(UndefObject, _name); + addAction(PlanBenchmarkUnregister); + } + + UIMsgPlanBenchmarkUnregister::~UIMsgPlanBenchmarkUnregister() + { + } + + + + + + UIMsgGroup::UIMsgGroup(std::string _name) : UIMsg() Index: UI-Console.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI/UI-Console.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** UI-Console.cpp 6 Jun 2007 21:38:53 -0000 1.3 --- UI-Console.cpp 13 Jun 2007 18:10:35 -0000 1.4 *************** *** 7,10 **** --- 7,11 ---- ------------------------------------------------------------------------- */ #include <UI/UI-Console.h> + #include <libcompbenchmarks.h> #include <iostream> #include <stdlib.h> *************** *** 12,17 **** using namespace CBM; - int uiconsole_verbose_shell = 0; - UIConsole::UIConsole() : UI() --- 13,16 ---- *************** *** 34,38 **** while ((_msg) && (_msg->getParent())) { _msg=(UIMsg*)_msg->getParent()->getParent(); ! if ((uiconsole_verbose_shell) || (action(_msg)!=UIMsg::ShellCommand)) d++; --- 33,37 ---- while ((_msg) && (_msg->getParent())) { _msg=(UIMsg*)_msg->getParent()->getParent(); ! if ((UO_verbose==CBM::All) || (action(_msg)!=UIMsg::ShellCommand)) d++; *************** *** 113,117 **** for(i=0;i<n;i++) { N=R->getNode(i); ! if ((uiconsole_verbose_shell) || (action((UIMsg*)N)!=UIMsg::ShellCommand)) r++; --- 112,116 ---- for(i=0;i<n;i++) { N=R->getNode(i); ! if ((UO_verbose==CBM::All) || (action((UIMsg*)N)!=UIMsg::ShellCommand)) r++; *************** *** 123,130 **** void UIConsole::Display(UIMsg *_msg) { ! int d = depth(_msg); ! if ((!uiconsole_verbose_shell) && (action(_msg)==UIMsg::ShellCommand)) return; --- 122,134 ---- void UIConsole::Display(UIMsg *_msg) { ! int d; + if (UO_verbose==CBM::None) + return; ! d=depth(_msg); ! ! ! if ((UO_verbose!=CBM::All) && (action(_msg)==UIMsg::ShellCommand)) return; *************** *** 201,207 **** curmsg+=objectField(_msg, "name"); break; ! case UIMsg::Group: curmsg+=objectField(_msg, "name"); break; default: curmsg+="Display::DEFAULT/"; --- 205,274 ---- curmsg+=objectField(_msg, "name"); break; ! case UIMsg::Group: ! curmsg+=objectField(_msg, "name"); ! break; ! case UIMsg::PlanRegister: ! curmsg+="Registering plan "; ! curmsg+=objectField(_msg, "file"); ! break; ! case UIMsg::PlanRestore: ! curmsg+="Restoring plan "; ! curmsg+=objectField(_msg, "file"); ! break; ! case UIMsg::PlanUnregister: ! curmsg+="Unregistering plan "; ! curmsg+=objectField(_msg, "name"); ! break; ! ! case UIMsg::PlanBatchRegister: ! curmsg+="Registering batch "; ! curmsg+=objectField(_msg, "name"); ! break; ! case UIMsg::PlanBatchUnregister: ! curmsg+="Unregistering batch "; ! curmsg+=objectField(_msg, "name"); ! break; ! ! case UIMsg::PlanCompilerRegister: ! curmsg+="Registering compiler "; ! curmsg+=objectField(_msg, "name"); ! break; ! ! case UIMsg::PlanCompilerUnregister: ! curmsg+="Unregistering compiler "; ! curmsg+=objectField(_msg, "name"); ! break; ! ! case UIMsg::PlanOptionsetRegister: ! curmsg+="Registering option set "; ! curmsg+=objectField(_msg, "name"); ! break; ! ! case UIMsg::PlanOptionsetUnregister: ! curmsg+="Unregistering option set "; ! curmsg+=objectField(_msg, "name"); ! break; ! ! case UIMsg::PlanOptionsRegister: ! curmsg+="Registering options "; ! curmsg+=objectField(_msg, "name"); ! break; ! ! case UIMsg::PlanOptionsUnregister: ! curmsg+="Unregistering options "; ! curmsg+=objectField(_msg, "name"); ! break; ! ! case UIMsg::PlanBenchmarkRegister: ! curmsg+="Registering benchmark "; curmsg+=objectField(_msg, "name"); break; + + case UIMsg::PlanBenchmarkUnregister: + curmsg+="Unregistering benchmark "; + curmsg+=objectField(_msg, "name"); + break; + + default: curmsg+="Display::DEFAULT/"; *************** *** 220,224 **** void UIConsole::DisplayProgressUpdate(UIMsg *_msg) { ! if ((!uiconsole_verbose_shell) && (action(_msg)==UIMsg::ShellCommand)) return; --- 287,294 ---- void UIConsole::DisplayProgressUpdate(UIMsg *_msg) { ! if (UO_verbose==CBM::None) ! return; ! ! if ((UO_verbose!=CBM::All) && (action(_msg)==UIMsg::ShellCommand)) return; *************** *** 230,250 **** void UIConsole::DisplayDone(UIMsg *_msg) { ! XMLNode *R = _msg->getNode("output"); XMLNode *N; XMLAttribute *A; UIMsg::Status status; ! int i, n = R->nodeNumber(); ! int d = depth(_msg); ! int s; ! int p_sp = 0; ! int frc = 0; ! // std::cout << _msg->str() << std::endl; ! if ((!uiconsole_verbose_shell) && (action(_msg)==UIMsg::ShellCommand)) return; for(i=0;i<n;i++) { N=R->getNode(i); --- 300,332 ---- void UIConsole::DisplayDone(UIMsg *_msg) { ! XMLNode *R; XMLNode *N; XMLAttribute *A; UIMsg::Status status; ! int i, n; ! int d; ! int s; ! int p_sp; ! int frc; ! if (UO_verbose==CBM::None) ! return; ! ! if ((UO_verbose!=CBM::All) && (action(_msg)==UIMsg::ShellCommand)) return; + + R=_msg->getNode("output"); + + n=R->nodeNumber(); + d=depth(_msg); + p_sp = 0; + frc = 0; + + // std::cout << _msg->str() << std::endl; + for(i=0;i<n;i++) { N=R->getNode(i); *************** *** 287,296 **** if (!lastisLF) { LF(); if (d) { s=d+1; ! while (s--) ! std::cout << " "; ! p_sp=1; } } std::cout << N->Value(); --- 369,382 ---- if (!lastisLF) { LF(); + s=0; if (d) { s=d+1; ! } else { ! if (!childNumber(_msg)) ! s=1; } + while (s--) + std::cout << " "; + p_sp=1; } std::cout << N->Value(); |
From: Frederic T. <xf...@us...> - 2007-06-07 16:22:34
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv1598 Modified Files: libcompbenchmarks.cpp libcompbenchmarks.h Log Message: Verbosity (of displayed XML messages) can be changed by command line option. Simplified interface. Index: libcompbenchmarks.h =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/libcompbenchmarks.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** libcompbenchmarks.h 26 Jan 2007 01:48:07 -0000 1.2 --- libcompbenchmarks.h 7 Jun 2007 16:22:31 -0000 1.3 *************** *** 25,31 **** namespace CBM { ! /** Enable/disable verbosity ! * \sa UO_verbose */ ! extern void setVerbosity(int v); /** Defines version of the libcompbenchmarks library */ --- 25,32 ---- namespace CBM { ! ! typedef enum Verbosity { ! None, Basic, All ! }; /** Defines version of the libcompbenchmarks library */ *************** *** 38,50 **** extern int UO_force; ! /** Verbose mode. ! * If set to 0, disable verbose mode (UI messages disabled). */ ! extern int UO_verbose; extern int UO_verbose_dl; - - /** Enable exits on fatal error. - * Set to 1 in Perl wrapper; defaults to 0. */ - extern int UO_fatal; } --- 39,46 ---- extern int UO_force; ! /** Verbosity flag */ ! extern Verbosity UO_verbose; extern int UO_verbose_dl; } Index: libcompbenchmarks.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/libcompbenchmarks.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** libcompbenchmarks.cpp 17 Apr 2007 18:22:05 -0000 1.3 --- libcompbenchmarks.cpp 7 Jun 2007 16:22:31 -0000 1.4 *************** *** 11,22 **** char *CBM::libcompbenchmarks_version = VERSION; ! int CBM::UO_enableTestSuite = 1; ! int CBM::UO_force = 0; ! int CBM::UO_verbose = 1; ! int CBM::UO_verbose_dl = 0; ! int CBM::UO_fatal = 1; - void CBM::setVerbosity(int v) - { - CBM::UO_verbose=v; - } --- 11,17 ---- char *CBM::libcompbenchmarks_version = VERSION; ! int CBM::UO_enableTestSuite = 1; ! int CBM::UO_force = 0; ! CBM::Verbosity CBM::UO_verbose = CBM::Basic; ! int CBM::UO_verbose_dl = 0; |
From: Frederic T. <xf...@us...> - 2007-06-07 16:18:52
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/System In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv374 Modified Files: System-Unix.cpp Log Message: Verbosity (of displayed XML messages) can be changed by command line option. Index: System-Unix.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/System/System-Unix.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** System-Unix.cpp 6 Jun 2007 15:59:31 -0000 1.5 --- System-Unix.cpp 7 Jun 2007 16:18:49 -0000 1.6 *************** *** 46,52 **** cmd+=to; ! if (! UO_verbose) { ! cmd+=" 2> /dev/null"; ! } return(exec(cmd, sstdout)); --- 46,50 ---- cmd+=to; ! cmd+=" 2> /dev/null"; return(exec(cmd, sstdout)); |
From: Frederic T. <xf...@us...> - 2007-06-07 16:18:35
|
Update of /cvsroot/compbench/CompBenchmarks++/CBM-PI In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv362 Modified Files: Glue.cpp Log Message: Verbosity (of displayed XML messages) can be changed by command line option. Index: Glue.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/CBM-PI/Glue.cpp,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** Glue.cpp 25 Jan 2007 15:42:56 -0000 1.7 --- Glue.cpp 7 Jun 2007 16:18:32 -0000 1.8 *************** *** 17,22 **** { sys = new CBM_SYSTEM(_filename); - CBM::UO_verbose=0; - CBM::UO_fatal=0; sys->init(); return(sys); --- 17,20 ---- |
From: Frederic T. <xf...@us...> - 2007-06-07 16:18:19
|
Update of /cvsroot/compbench/CompBenchmarks++/compbenchmarks-core In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv334 Modified Files: cloptions.cpp Log Message: Verbosity (of displayed XML messages) can be changed by command line option. Index: cloptions.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/compbenchmarks-core/cloptions.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** cloptions.cpp 6 Jun 2007 21:40:23 -0000 1.4 --- cloptions.cpp 7 Jun 2007 16:18:13 -0000 1.5 *************** *** 79,88 **** << " --package-test | -T : run package's testsuite" << std::endl << " --package-release | -R : clean compiled object" << std::endl << std::endl ! << "Benchmarking options (with -b or --bench domain) : " << std::endl ! << " [-b|--bench] <BID> <C> [O] : use compiler C with optional arguments" << std::endl << " O to build benchmark BID" << std::endl << " --disable-testsuite | -S : disable package's test suite" << std::endl << std::endl << "Other options that may affect behaviour :" << std::endl << " --force : force operation" << std::endl << std::endl; } --- 79,89 ---- << " --package-test | -T : run package's testsuite" << std::endl << " --package-release | -R : clean compiled object" << std::endl << std::endl ! << "Benchmarking options (with -B or --bench domain) : " << std::endl ! << " [-B|--bench] <BID> <C> [O] : use compiler C with optional arguments" << std::endl << " O to build benchmark BID" << std::endl << " --disable-testsuite | -S : disable package's test suite" << std::endl << std::endl << "Other options that may affect behaviour :" << std::endl << " --force : force operation" << std::endl + << " --verbose <0,1,2> : manage messages (quiet,basic reporting,complete)" << std::endl << std::endl; } *************** *** 281,284 **** --- 282,286 ---- {"disable-testsuite", 0, 0, 'S' }, {"force", 0, 0, 'f' }, + {"verbose", required_argument, 0, 'V' }, { 0, 0, 0, 0} }; *************** *** 290,294 **** break; ! c = getopt_long (argc, argv, "hvxiI:F:U:qHc:p::B:b::A:aMmD:E:P:C:T:R:S:f", // uLHPCFIB", /* :011000112", */ long_options, &option_index); if (c==-1) { --- 292,296 ---- break; ! c = getopt_long (argc, argv, "hvxiI:F:U:qHc:p::V:B:b::A:aMmD:E:P:C:T:R:S:f", // uLHPCFIB", /* :011000112", */ long_options, &option_index); if (c==-1) { *************** *** 300,303 **** --- 302,326 ---- cbmSingleDomain(&domain, DomainVersion, "v"); break; + case 'V': + if (optarg) { + tmp=optarg; + if (tmp=="0") + UO_verbose=CBM::None; + else { + if (tmp=="1") { + UO_verbose=CBM::Basic; + } else { + if (tmp=="2") { + UO_verbose=CBM::All; + } else { + cbmUI->msgFatal("0, 1 or 2 expected for --verbose"); + cbmSystem->done(); + exit(parseExitValue); + break; + } + } + } + } + break; case 'q': cbmSingleDomain(&domain, DomainQuery, "q"); |
From: Frederic T. <xf...@us...> - 2007-06-06 21:43:02
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv9777 Modified Files: Plan-Batch.cpp Plan.cpp Log Message: Updates due to changes in CBM::Benchmark::Bench() interface : disabled calls. Index: Plan.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan/Plan.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** Plan.cpp 30 May 2007 17:04:03 -0000 1.11 --- Plan.cpp 6 Jun 2007 21:42:57 -0000 1.12 *************** *** 191,195 **** } ! bmValue=B->Bench(); } result=new CBM::Result(bmValue, --- 191,195 ---- } ! // bmValue=B->Bench(); arf. !!! } result=new CBM::Result(bmValue, Index: Plan-Batch.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan/Plan-Batch.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** Plan-Batch.cpp 30 May 2007 17:02:27 -0000 1.2 --- Plan-Batch.cpp 6 Jun 2007 21:42:57 -0000 1.3 *************** *** 177,181 **** return(0); } ! benchmarks.push_back(_benchmark); stop(); --- 177,184 ---- return(0); } ! if (_benchmark->Package()->getStatus()<CBM::Package::Preconfigured) { ! return(0); ! } ! benchmarks.push_back(_benchmark); stop(); *************** *** 385,389 **** } ! bmValue=B->Bench(); } result=new CBM::Result(bmValue, --- 388,392 ---- } ! // bmValue=B->Bench(C, O); arf. !!! } result=new CBM::Result(bmValue, |
From: Frederic T. <xf...@us...> - 2007-06-06 21:42:18
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv9746 Modified Files: Makefile.am Log Message: Link to libxml2 libraries. Index: Makefile.am =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Plan/Makefile.am,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** Makefile.am 17 May 2007 14:32:38 -0000 1.2 --- Makefile.am 6 Jun 2007 21:42:13 -0000 1.3 *************** *** 17,19 **** libPlanincludedir = $(includedir)/compbenchmarks/Plan ! INCLUDES = -I $(top_srcdir)/libcompbenchmarks \ No newline at end of file --- 17,21 ---- libPlanincludedir = $(includedir)/compbenchmarks/Plan ! INCLUDES = -I $(top_srcdir)/libcompbenchmarks @XML_CPPFLAGS@ ! ! libPlan_la_LIBADD = @XML_LIBS@ \ No newline at end of file |
From: Frederic T. <xf...@us...> - 2007-06-06 21:40:26
|
Update of /cvsroot/compbench/CompBenchmarks++/compbenchmarks-core In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv9303 Modified Files: cloptions.cpp Log Message: Updates due to changes in CBM::Benchmark::Bench() interface. Fatal error on unrecognized option has been modified. Index: cloptions.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/compbenchmarks-core/cloptions.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** cloptions.cpp 6 Jun 2007 16:02:11 -0000 1.3 --- cloptions.cpp 6 Jun 2007 21:40:23 -0000 1.4 *************** *** 92,98 **** std::string str; if (*domain!=DomainUndef) { ! str="Unexpected option : "; str+=opt; CBM::cbmUI->msgFatal(str); } else { *domain=value; --- 92,102 ---- std::string str; if (*domain!=DomainUndef) { ! str="Unexpected option '"; str+=opt; + str+="'"; + parseExitValue=255; CBM::cbmUI->msgFatal(str); + cbmSystem->done(); + exit(parseExitValue); } else { *domain=value; *************** *** 225,230 **** { int c; - int context; - CBM::Package::Status status; CBM::Package *P = 0; --- 229,232 ---- *************** *** 778,782 **** break; } ! O=new CBM::CompilerOptions(options); P=B->Package(); if (P->getStatus()<CBM::Package::Preconfigured) { --- 780,785 ---- break; } ! ! O=new CBM::CompilerOptions("command-line", options); P=B->Package(); if (P->getStatus()<CBM::Package::Preconfigured) { *************** *** 785,801 **** break; } ! context=P->ContextMatches(C, O); ! ! status=P->getStatus(); ! if ((status>=CBM::Package::Configured) && (!context)) { ! P->Release(); ! } ! ! if (!context) { ! P->Configure(C, O); ! P->Make(UO_force); ! P->Test(UO_force); ! } ! B->Bench(); parseExitValue=0; --- 788,793 ---- break; } ! ! B->Bench(C, O); parseExitValue=0; |
From: Frederic T. <xf...@us...> - 2007-06-06 21:38:58
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv8531 Modified Files: UI-Console.cpp Log Message: Fatal errors handled. Index: UI-Console.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI/UI-Console.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** UI-Console.cpp 6 Jun 2007 17:39:59 -0000 1.2 --- UI-Console.cpp 6 Jun 2007 21:38:53 -0000 1.3 *************** *** 146,149 **** --- 146,153 ---- curmsg+="'"; break; + case UIMsg::FatalError: + curmsg+="FATAL : "; + curmsg+=objectField(_msg, "name"); + break; case UIMsg::BenchmarkBench: curmsg+="Benchmarking "; |
From: Frederic T. <xf...@us...> - 2007-06-06 21:38:05
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv8148 Modified Files: UI-Msg.cpp UI-Msg.h Log Message: Fatal errors handled. Index: UI-Msg.h =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI/UI-Msg.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** UI-Msg.h 6 Jun 2007 17:39:19 -0000 1.2 --- UI-Msg.h 6 Jun 2007 21:37:59 -0000 1.3 *************** *** 39,43 **** typedef enum ObjectType { UndefObject, - FatalError, Shell, File, Directory, Package, Benchmark, Compiler }; --- 39,42 ---- *************** *** 46,49 **** --- 45,49 ---- UndefAction, ShellCommand, + FatalError, Group, Create, Read, Write, Remove, Checksum, Index: UI-Msg.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/UI/UI-Msg.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** UI-Msg.cpp 6 Jun 2007 17:39:19 -0000 1.2 --- UI-Msg.cpp 6 Jun 2007 21:37:59 -0000 1.3 *************** *** 116,120 **** : UIMsg() { ! addObject(FatalError, _text); } --- 116,121 ---- : UIMsg() { ! addAction(FatalError); ! addObject(UndefObject, _text); } |
From: Frederic T. <xf...@us...> - 2007-06-06 21:36:41
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Benchmark In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv7749 Modified Files: Benchmark.cpp Benchmark.h Log Message: Bench() changed : it now calls Clean(), Configure() and Make(); methods if needed. Index: Benchmark.h =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Benchmark/Benchmark.h,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** Benchmark.h 17 May 2007 14:29:12 -0000 1.6 --- Benchmark.h 6 Jun 2007 21:36:28 -0000 1.7 *************** *** 71,75 **** * \sa executionTime() * \sa status */ ! virtual std::string Bench(void); /** Give execution time. --- 71,76 ---- * \sa executionTime() * \sa status */ ! virtual std::string Bench(Compiler *C, ! CompilerOptions *O); /** Give execution time. Index: Benchmark.cpp =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Benchmark/Benchmark.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** Benchmark.cpp 6 Jun 2007 15:59:47 -0000 1.11 --- Benchmark.cpp 6 Jun 2007 21:36:28 -0000 1.12 *************** *** 52,61 **** } ! std::string Benchmark::Bench(void) { ! std::string r; ! std::string info; ! double end; ! char tmp[128]; cbmUI->msgBench(Name()); --- 52,80 ---- } ! std::string Benchmark::Bench(Compiler *C, ! CompilerOptions *O) { ! std::string r; ! std::string info; ! double end; ! char tmp[128]; ! ! int p_cm; ! CBM::Package::Status p_status; ! ! cbmUI->msgGroup("Benchmark"); ! ! p_cm=Package()->ContextMatches(C, O); ! ! p_status=Package()->getStatus(); ! if ((p_status>=CBM::Package::Configured) && (!p_cm)) { ! Package()->Release(); ! } ! ! if (!p_cm) { ! Package()->Configure(C, O); ! Package()->Make(UO_force); ! Package()->Test(UO_force); ! } cbmUI->msgBench(Name()); *************** *** 65,68 **** --- 84,88 ---- info+=" not tested !"; cbmUI->outputKO(info); + cbmUI->outputKO(info); return("0"); } *************** *** 85,88 **** --- 105,109 ---- cbmUI->outputInfo(i_r); cbmUI->outputOK(); + cbmUI->outputOK(); } else { cbmUI->outputKO(); *************** *** 90,93 **** --- 111,115 ---- info+=Package()->Name(); cbmUI->msgFatal(info); + cbmUI->outputKO(); } |
From: Frederic T. <xf...@us...> - 2007-06-06 19:23:27
|
Update of /cvsroot/compbench/CompBenchmarks++/CBM-PI/t In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv22394 Modified Files: 00-CBMSystem-public.pl Log Message: Version changed to 0.5.0-BETA2 Index: 00-CBMSystem-public.pl =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/CBM-PI/t/00-CBMSystem-public.pl,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** 00-CBMSystem-public.pl 27 May 2007 15:56:13 -0000 1.10 --- 00-CBMSystem-public.pl 6 Jun 2007 19:23:24 -0000 1.11 *************** *** 165,169 **** test_getLastCommand(); test_getLastCommandOutput(); ! ok($sys->Version() eq "0.5.0-BETA1"); $sys->done(); --- 165,169 ---- test_getLastCommand(); test_getLastCommandOutput(); ! ok($sys->Version() eq "0.5.0-BETA2"); $sys->done(); |
From: Frederic T. <xf...@us...> - 2007-06-06 18:05:14
|
Update of /cvsroot/compbench/CompBenchmarks++/CBM-PI/t In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv25238 Modified Files: 04-Config.pl Log Message: Match changes on CBM::Config (<defaults/> node, removed plan). Index: 04-Config.pl =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/CBM-PI/t/04-Config.pl,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** 04-Config.pl 25 Jan 2007 17:06:20 -0000 1.4 --- 04-Config.pl 6 Jun 2007 18:05:09 -0000 1.5 *************** *** 32,37 **** <benchmark id="gzip-1c" status="0"/> </benchmarks> ! <paths/> ! <plan/> </libcompbenchmarks> EOF --- 32,38 ---- <benchmark id="gzip-1c" status="0"/> </benchmarks> ! <defaults> ! <paths/> ! </defaults> </libcompbenchmarks> EOF *************** *** 48,53 **** <benchmark id="gzip-1c" status="1"/> </benchmarks> ! <paths/> ! <plan/> </libcompbenchmarks> EOF --- 49,55 ---- <benchmark id="gzip-1c" status="1"/> </benchmarks> ! <defaults> ! <paths/> ! </defaults> </libcompbenchmarks> EOF *************** *** 79,84 **** </benchmark> </benchmarks> ! <paths/> ! <plan/> </libcompbenchmarks> EOF --- 81,87 ---- </benchmark> </benchmarks> ! <defaults> ! <paths/> ! </defaults> </libcompbenchmarks> EOF |