[Compbench-devel] CompBenchmarks++/libcompbenchmarks/Benchmark Benchmark-Autotools.h, 1.1, 1.2 Pack
Brought to you by:
xfred
|
From: Frederic T. <xf...@us...> - 2007-09-04 19:16:21
|
Update of /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Benchmark In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv887 Modified Files: Benchmark-Autotools.h Package.h Log Message: For SF's TID #141819 : improving Doxygen documentation. Index: Package.h =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Benchmark/Package.h,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** Package.h 15 Feb 2007 18:56:29 -0000 1.6 --- Package.h 4 Sep 2007 19:16:15 -0000 1.7 *************** *** 78,81 **** --- 78,82 ---- private: /** Package status + * * \sa Package::Status * \sa storeStatus() *************** *** 88,95 **** --- 89,98 ---- /** Expected MD5 on downloaded package + * * \return MD5 expected, as an std::string */ virtual std::string expectedMD5(void) = 0; /** Package's status + * * Initialise the status from file in the directory defined * by CBM::System::Status. *************** *** 111,137 **** class System *system; /** Constructor * Initialise the Package::system variable. */ Package(class System *_system); /** Pure method to extract package ! \return 1 if ok ! \sa Extract() ! \sa localPackageAbsoluteDirectory() */ virtual int extract(int _force = 0) = 0; /** Method to patch package * Must be overloaded to patch package. * \sa Patch() */ virtual int patch(int _force = 0); /** Method to test package. * Must be overloaded to test package using a method provided by package * maintainers. * \sa Test() */ virtual int test(int _force = 0); /** Pure virtual method to pre-configure package ! * Pre-configuration creates any needed elements (files or what ever) to benchmark ! * package. * \return 1 if ok. * \sa PreConfigure() --- 114,150 ---- class System *system; /** Constructor + * * Initialise the Package::system variable. */ Package(class System *_system); /** Pure method to extract package ! * ! * \return 1 if ok ! * \sa Extract() ! * \sa localPackageAbsoluteDirectory() */ virtual int extract(int _force = 0) = 0; /** Method to patch package + * * Must be overloaded to patch package. + * + * \param _force set this to 1 to force patching (regardless of package's state). * \sa Patch() */ virtual int patch(int _force = 0); /** Method to test package. + * * Must be overloaded to test package using a method provided by package * maintainers. + * + * \param _force set this to 1 to force testing (regardless of package's state). * \sa Test() */ virtual int test(int _force = 0); /** Pure virtual method to pre-configure package ! * ! * Pre-configuration creates any needed elements (files or what ever) to benchmark package or to configure/build it. ! * ! * \param _force set this to 1 to force pre-configuration (regardless of package's state). * \return 1 if ok. * \sa PreConfigure() *************** *** 139,144 **** virtual int preConfigure(int _force) = 0; ! /** Pure virtual method to configure package * Broadly speaking, this is ./configure * \sa Configure() * \return 1 if ok */ --- 152,160 ---- virtual int preConfigure(int _force) = 0; ! /** Pure virtual method to configure package. ! * * Broadly speaking, this is ./configure + * \param _curentCompiler Compiler to use + * \param _currentOptions Options to pass to compiler (through configuration mechanism) * \sa Configure() * \return 1 if ok */ *************** *** 147,156 **** /** Pure virtual method to build package * This could be a simple make, for instance. * \return 1 if ok * \sa Make() */ virtual int make(void) = 0; ! /** Pure virtual method to clean-up sources * Useful bettween two Make() to get all sources compiled with same environment. * \sa Release() --- 163,176 ---- /** Pure virtual method to build package + * * This could be a simple make, for instance. + + * \param _force set this to 1 to force the build (regardless of package's state). * \return 1 if ok * \sa Make() */ virtual int make(void) = 0; ! /** Pure virtual method to clean-up sources. ! * * Useful bettween two Make() to get all sources compiled with same environment. * \sa Release() *************** *** 159,163 **** virtual int release(void) = 0; ! /** Uninstall benchmark * Removes information used by CompBenchmarks as well as any downloaded, extracted * or built element. Default behaviour should be ok in most case. --- 179,184 ---- virtual int release(void) = 0; ! /** Uninstall benchmark. ! * * Removes information used by CompBenchmarks as well as any downloaded, extracted * or built element. Default behaviour should be ok in most case. *************** *** 165,171 **** virtual int uninstall(void); ! /** Gets a context ID ! * Give an unique ID according to compiler and options used. This can avoid useless * recompilations. * \return ID (MD5) as std::string * \sa Make() --- 186,195 ---- virtual int uninstall(void); ! /** Gets a context ID. ! * ! * Give an unique (probably new) ID according to compiler and options used. This can avoid useless * recompilations. + * \param _currentCompiler Compiler in new context + * \param _currentOptions Options passed to compiler or given as used within the context * \return ID (MD5) as std::string * \sa Make() *************** *** 176,181 **** CompilerOptions *_currentOptions); ! /** Stores (compilation) context ID * Stores the context ID for the current benchmark. * \sa contextID() * \sa ContextMatches() --- 200,208 ---- CompilerOptions *_currentOptions); ! /** Stores (compilation) context ID. ! * * Stores the context ID for the current benchmark. + * \param _currentCompiler Compiler currently used + * \param _currentOptions Options currently used by compiler * \sa contextID() * \sa ContextMatches() *************** *** 186,192 **** --- 213,227 ---- public: + /** Removes internal references to a benchmark. + * + * References for benchmarks are just removed from internal lists, + * not deleted. + * + * \param _benchmark Benchmark to remove. + */ virtual void removeCached(CBM_BM *_benchmark); /** Indicates if the package needs patching + * * Must be overloaded if so. Returns 0 by default. * \return 0 by default, 1 if patch is needed. *************** *** 197,200 **** --- 232,236 ---- /** Remove context. + * * \sa storeContext() */ *************** *** 202,205 **** --- 238,242 ---- /** Get system abstraction object + * \return CBM::System */ *************** *** 207,228 **** /** Get all supported benchmarks. ! \return Array of std::string. */ virtual BenchmarkVector& Benchmarks(void); ! /** Get supported benchmarks' number ! \return An integer */ virtual int benchmarkNumber(void); ! /** Get a benchmark according to its index ! \sa Benchmarks() ! \return A pointer to the benchmark instance */ virtual CBM_BM *Benchmark(int i); /** Get a benchmark according to its identifier. ! \return References to a Benchmark object */ virtual CBM_BM *Benchmark(std::string bid); /** Stores benchmark status ! * Probably internal usage only. * \return 1 if ok * \sa readStatus() --- 244,275 ---- /** Get all supported benchmarks. ! * ! * \return Array of std::string. */ virtual BenchmarkVector& Benchmarks(void); ! /** Get supported benchmarks' number. ! * ! * \return An integer */ virtual int benchmarkNumber(void); ! /** Get a benchmark according to its index. ! * ! * \param i Benchmark's index ! * \sa Benchmarks() ! * \return A pointer to the benchmark instance */ virtual CBM_BM *Benchmark(int i); /** Get a benchmark according to its identifier. ! * ! * \param bid Benchmark identifier ! * \return References to a Benchmark object */ virtual CBM_BM *Benchmark(std::string bid); /** Stores benchmark status ! * ! * Probably for libcompbenchmarks internal usage only, since calls ! * necessary calls aldready exists in higher level classes. ! * ! * \param _status New (current probably) status for the package * \return 1 if ok * \sa readStatus() *************** *** 230,247 **** virtual int storeStatus(Status _status); ! /** Package name * \return a std::string like 'gzip', without quotes */ virtual std::string Name(void); ! /** Package version * \return a std::string like '1.2.4', without quotes */ virtual std::string Version(void) = 0; ! /** Package size, in bytes * \return an integer coding the size of package's archive (to download) in bytes. */ virtual int Size(void) = 0; ! /** Package comments * Gives comments about package. Short description, or what ever. * \return comments, as std::string --- 277,298 ---- virtual int storeStatus(Status _status); ! /** Package name. ! * * \return a std::string like 'gzip', without quotes */ virtual std::string Name(void); ! /** Package version. ! * * \return a std::string like '1.2.4', without quotes */ virtual std::string Version(void) = 0; ! /** Package size, in bytes. ! * * \return an integer coding the size of package's archive (to download) in bytes. */ virtual int Size(void) = 0; ! /** Package comments. ! * * Gives comments about package. Short description, or what ever. * \return comments, as std::string *************** *** 249,283 **** virtual std::string Comments(void) = 0; ! /** Package local filename * \return a relative filename containing the local name of the uncompressed * package (like 'gzip-1.2.4.tar.Z', without quotes) */ virtual std::string localName(void) = 0; ! /** Benchmark's language * \return std::string (C or C++) */ virtual std::string language(void) = 0; ! /** Returns package or benchmark license ! \return a std::string describing license */ virtual std::string license(void) = 0; ! /** Returns package home page ! \return URL in std::string */ virtual std::string homePage(void) = 0; ! /** Author(s) of package ! \return std::string containing authors. */ virtual std::string author(void) = 0; ! /** Convenience method * \return local uncompressed absolute archive filename for benchmark. * \sa localPackageName() */ virtual std::string localAbsoluteName(void); ! /** Convenience method ! * \return directory used for extracting package * \sa CBM::System::Extract */ virtual std::string localAbsoluteDirectory(void); ! /** Relative directory to extract package * \return relative directory to use (or used, depending) for package extraction * \sa CBM::System::Extract */ --- 300,343 ---- virtual std::string Comments(void) = 0; ! /** Package local filename. ! * * \return a relative filename containing the local name of the uncompressed * package (like 'gzip-1.2.4.tar.Z', without quotes) */ virtual std::string localName(void) = 0; ! /** Benchmark's language. ! * * \return std::string (C or C++) */ virtual std::string language(void) = 0; ! /** Returns package or benchmark license. ! * ! * \return a std::string describing license */ virtual std::string license(void) = 0; ! /** Returns package home page. ! * ! * \return URL in std::string */ virtual std::string homePage(void) = 0; ! /** Author(s) of package. ! * ! * \return std::string containing authors. */ virtual std::string author(void) = 0; ! /** Local absolute archive filename. ! * * \return local uncompressed absolute archive filename for benchmark. * \sa localPackageName() */ virtual std::string localAbsoluteName(void); ! ! /** Extraction directory. ! * ! * \return directory used for extracting packages (e.g. where packages are uncompressed, compiled, and so on). * \sa CBM::System::Extract */ virtual std::string localAbsoluteDirectory(void); ! /** Relative directory to extract package. ! * * \return relative directory to use (or used, depending) for package extraction * \sa CBM::System::Extract */ *************** *** 285,288 **** --- 345,349 ---- /** Indicates if the package provides a test method. + * * Must be overloaded if so. Returns 0 by default. * \return 0 by default, 1 if patch is needed. *************** *** 293,296 **** --- 354,358 ---- /** URL used for downloading package. + * * \return std::string representing the URL of the package * \sa expectedMD5() */ *************** *** 298,301 **** --- 360,364 ---- /** Total size of the package + * * \return Total size, in bytes, of thepackage. This comprises data used * in pre-configuration step. *************** *** 304,309 **** virtual int totalSize(void); ! /** Compairs previous compilation context to current one ! * \return 1 if they match. * \sa contextID() * \sa storeContext() --- 367,375 ---- virtual int totalSize(void); ! /** Compairs previous compilation context to current one. ! * ! * \return 1 if contexts match. ! * \param _currentCompiler Compiler currently used ! * \param _currentOptions Options currently used by compiler * \sa contextID() * \sa storeContext() *************** *** 313,316 **** --- 379,383 ---- CompilerOptions *_currentOptions); /** Download package. + * * Gets downloadURL() object from Internet and verify checksum. * Uses download(). Overloading is unadvised. *************** *** 322,325 **** --- 389,393 ---- /** Extract package. + * * Extracts downloaded package. * Uses extract(). Overloading is unadvised. *************** *** 332,335 **** --- 400,404 ---- /** Patch package. + * * Patches extracted package. * Overloading is unadvised, 1 is returned without any action, by default. *************** *** 343,346 **** --- 412,416 ---- /** Preconfigure package. + * * Preconfigure downloaded package. * Uses preConfigure(). Overloading is unadvised. *************** *** 354,357 **** --- 424,428 ---- /** Configure package. + * * Configure downloaded package. * Uses configure(). Overloading is unadvised. Argument are used to keep *************** *** 359,362 **** --- 430,435 ---- * if ./configure script is not present : they'll be used by Make(). * This step won't be done and'll return 1 if getStatus()>=Package::Configured. May changes status. + * \param _currentCompiler Compiler to be used + * \param _currentOptions Options to be passed to compiler (through package's configuration mechanism) * \return 1 if ok. * \sa Download() *************** *** 370,373 **** --- 443,447 ---- /** Build package. + * * Builds package. * Uses make(). Overloading is unadvised. *************** *** 384,387 **** --- 458,462 ---- /** Give build time. + * * Returns last time (in seconds) of make(). * \return build time in seconds *************** *** 391,394 **** --- 466,470 ---- /** Test a package. + * * Test a built package. * Overloading is unadvised, 1 is returned without any action, by default. *************** *** 403,406 **** --- 479,483 ---- /** Clean objects. + * * Uses release(). Overloading is unadvised. * This step won't be done and'll return 0 if getStatus()<Package::Made. May changes status. *************** *** 419,422 **** --- 496,500 ---- /** Copy a local archive. + * * Copy package to directory defined by CBM::System::Download. It'll be ready * to be extracted using Install(). *************** *** 429,432 **** --- 507,511 ---- /** Uninstall package. + * * Uses uninstall(). Overloading is unadvised. * This step won't be done and'll return 1 if getStatus()==Package::Unknown. *************** *** 436,439 **** --- 515,519 ---- /** Returns benchmark's status + * * \return status (enum). * \sa Package::Status *************** *** 442,445 **** --- 522,526 ---- /** Returns benchmark's status + * * \return status (as string) * \sa Package::Status Index: Benchmark-Autotools.h =================================================================== RCS file: /cvsroot/compbench/CompBenchmarks++/libcompbenchmarks/Benchmark/Benchmark-Autotools.h,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** Benchmark-Autotools.h 22 Jan 2007 18:21:47 -0000 1.1 --- Benchmark-Autotools.h 4 Sep 2007 19:16:15 -0000 1.2 *************** *** 26,39 **** protected: ! /** Extracts package * Extract a gzipped-tarball. * \return 1 if ok. * \sa CBMBenchmark::packageAbsoluteDirectory() */ virtual int extract(int _force = 0); ! /** Configure package ! Use ./configure script and standard options. ! \sa CBMBenchmark::Configure() ! \sa CBMBenchmark::language() ! \return 1 if ok. */ virtual int configure(Compiler *_currentCompiler, --- 26,44 ---- protected: ! /** Extracts package. ! * * Extract a gzipped-tarball. + * \param _force 1 to force extraction (even if detected as already done). * \return 1 if ok. * \sa CBMBenchmark::packageAbsoluteDirectory() */ virtual int extract(int _force = 0); ! /** Configure package. ! * ! * Use ./configure script and standard options. ! * \param _currentCompiler Compiler to pass to ./configure ! * \param _currentOptions Compilation options to use ! * \sa CBMBenchmark::Configure() ! * \sa CBMBenchmark::language() ! * \return 1 if ok. */ virtual int configure(Compiler *_currentCompiler, *************** *** 41,56 **** /** Build package. ! Use make. ! \return 1 if ok. ! \sa CBMBenchmark::make() */ virtual int make(void); /** Removes object files. ! Use make clean. ! \return 1 if ok. ! \sa CBMBenchmark::release() */ virtual int release(void); ! /** Constructor */ PackageAutotools(class System *_system); --- 46,65 ---- /** Build package. ! * ! * Use make. ! * \return 1 if ok. ! * \sa CBMBenchmark::make() */ virtual int make(void); /** Removes object files. ! * ! * Use make clean. ! * \return 1 if ok. ! * \sa CBMBenchmark::release() */ virtual int release(void); ! /** Constructor ! * ! * \param _system A CBM::System instance */ PackageAutotools(class System *_system); |