Ignore:
Timestamp:
6 Nov 2015, 16:18:36 (8 years ago)
Author:
tech
Message:

Macro fixes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-15.2-dev/source/App/TAppDecoder/decmain.cpp

    r1313 r1373  
    5151{
    5252  Int returnCode = EXIT_SUCCESS;
     53#if !NH_MV
    5354  TAppDecTop  cTAppDecTop;
    54 
     55#endif
    5556  // print information
    5657  fprintf( stdout, "\n" );
     
    6566  fprintf( stdout, "\n" );
    6667
    67   // create application decoder class
    68   cTAppDecTop.create();
     68#if NH_MV
     69  Int numDecodings = 1;
     70  Int curDecoding  = 0;
     71  Double dResult = 0;
     72  do {
     73    TAppDecTop  cTAppDecTop;
     74#endif
     75    // create application decoder class
     76    cTAppDecTop.create();
    6977
    70   // parse configuration
    71   if(!cTAppDecTop.parseCfg( argc, argv ))
    72   {
    73     cTAppDecTop.destroy();
    74     returnCode = EXIT_FAILURE;
    75     return returnCode;
    76   }
     78    // parse configuration
     79    if(!cTAppDecTop.parseCfg( argc, argv ))
     80    {
     81      cTAppDecTop.destroy();
     82      returnCode = EXIT_FAILURE;
     83      return returnCode;
     84    }
     85#if NH_MV
     86    numDecodings = cTAppDecTop.getNumDecodings();
     87#endif
    7788
    78   // starting time
     89    // starting time   
     90#if !NH_MV
    7991  Double dResult;
    80   clock_t lBefore = clock();
     92#endif
     93    clock_t lBefore = clock();
    8194
    82   // call decoding function
    83   cTAppDecTop.decode();
     95    // call decoding function
     96#if NH_MV
     97    cTAppDecTop.decode( curDecoding );
     98#else
     99    cTAppDecTop.decode();
     100#endif
    84101
    85   if (cTAppDecTop.getNumberOfChecksumErrorsDetected() != 0)
    86   {
    87     printf("\n\n***ERROR*** A decoding mismatch occured: signalled md5sum does not match\n");
    88     returnCode = EXIT_FAILURE;
    89   }
     102    if (cTAppDecTop.getNumberOfChecksumErrorsDetected() != 0)
     103    {
     104      printf("\n\n***ERROR*** A decoding mismatch occured: signalled md5sum does not match\n");
     105      returnCode = EXIT_FAILURE;
     106    }
    90107
    91   // ending time
     108    // ending time
     109#if NH_MV
     110    dResult += (double)(clock()-lBefore) / CLOCKS_PER_SEC;
     111#else
    92112  dResult = (Double)(clock()-lBefore) / CLOCKS_PER_SEC;
    93113  printf("\n Total Time: %12.3f sec.\n", dResult);
     114#endif
    94115
    95   // destroy application decoder class
    96   cTAppDecTop.destroy();
     116    // destroy application decoder class
     117    cTAppDecTop.destroy();
     118#if NH_MV
     119    curDecoding++;
     120  }
     121  while ( curDecoding < numDecodings );
    97122
     123  printf("\n Total Time: %12.3f sec.\n", dResult);
     124#endif
    98125  return returnCode;
    99126}
Note: See TracChangeset for help on using the changeset viewer.