runtests.cmd 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547
  1. ::-------------------------------------------------------------------------------------------------------
  2. :: Copyright (C) Microsoft. All rights reserved.
  3. :: Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
  4. ::-------------------------------------------------------------------------------------------------------
  5. :: ============================================================================
  6. ::
  7. :: runtests.cmd
  8. ::
  9. :: Runs checkin tests using the ch.exe on the path, in 2 variants:
  10. ::
  11. :: -maxInterpretCount:1 -maxSimpleJitRunCount:1 -bgjit-
  12. :: <dynapogo>
  13. ::
  14. :: Logs are placed into:
  15. ::
  16. :: logs\interpreted
  17. :: logs\dynapogo
  18. ::
  19. :: User specified variants:
  20. :: logs\forcedeferparse
  21. :: logs\nodeferparse
  22. :: logs\forceundodefer
  23. :: logs\bytecodeserialized (serialized to byte codes)
  24. :: logs\forceserialized (force bytecode serialization internally)
  25. ::
  26. :: ============================================================================
  27. @echo off
  28. setlocal
  29. goto :main
  30. :: ============================================================================
  31. :: Print usage
  32. :: ============================================================================
  33. :printUsage
  34. echo runtests.cmd -x86^|-x64^|-arm -debug^|-test [options]
  35. echo.
  36. echo Required switches:
  37. echo.
  38. echo Specify architecture of ChakraCore:
  39. echo.
  40. echo -x86 Build arch of binaries is x86
  41. echo -x64 Build arch of binaries is x64
  42. echo -arm Build arch of binaries is ARM
  43. echo -arm64 Build arch of binaries is ARM64
  44. echo.
  45. echo Specify type of ChakraCore:
  46. echo.
  47. echo -debug Build type of binaries is debug
  48. echo -test Build type of binaries is test
  49. echo -codecoverage Build type of binaries is codecoverage
  50. echo.
  51. echo Shorthand combinations can be used, e.g. -x64debug
  52. echo.
  53. echo Note: release build type currently unsupported by ch.exe
  54. echo.
  55. echo Options:
  56. echo.
  57. echo -dirs dirname Run only the specified directory
  58. :: TODO Add more usage help
  59. goto :eof
  60. :: ============================================================================
  61. :: Print how to get help
  62. :: ============================================================================
  63. :printGetHelp
  64. echo For help use runtests.cmd -?
  65. goto :eof
  66. :: ============================================================================
  67. :: Main script
  68. :: ============================================================================
  69. :main
  70. if not exist %cd%\rlexedirs.xml (
  71. echo Error: rlexedirs.xml not found in current directory.
  72. echo runtests.cmd must be run from a test root directory containing rlexedirs.xml.
  73. exit /b 1
  74. )
  75. call :initVars
  76. call :parseArgs %*
  77. if not "%fShowUsage%" == "" (
  78. call :printUsage
  79. goto :eof
  80. )
  81. call :validateArgs
  82. if not "%fShowGetHelp%" == "" (
  83. call :printGetHelp
  84. goto :eof
  85. )
  86. call :configureVars
  87. set _logsRoot=%cd%\logs
  88. call :doSilent del /s /q profile.dpl.*
  89. for %%i in (%_Variants%) do (
  90. set _TESTCONFIG=%%i
  91. call :RunOneVariant
  92. )
  93. call :cleanUp
  94. for %%i in (%_Variants%) do (
  95. echo.
  96. echo ######## Logs for %%i variant ########
  97. if exist %_logsRoot%\%_BuildArch%_%_BuildType%\%%i\rl.log (
  98. type %_logsRoot%\%_BuildArch%_%_BuildType%\%%i\rl.log
  99. ) else (
  100. echo ERROR: Log file '%_logsRoot%\%_BuildArch%_%_BuildType%\%%i\rl.log' does not exist
  101. )
  102. )
  103. exit /b %_HadFailures%
  104. :: ============================================================================
  105. :: Parse the user arguments into environment variables
  106. :: ============================================================================
  107. :parseArgs
  108. :NextArgument
  109. if "%1" == "-?" set fShowUsage=1& goto :ArgOk
  110. if "%1" == "/?" set fShowUsage=1& goto :ArgOk
  111. if /i "%1" == "-x86" set _BuildArch=x86& goto :ArgOk
  112. if /i "%1" == "-x64" set _BuildArch=x64& goto :ArgOk
  113. if /i "%1" == "-arm" set _BuildArch=arm& goto :ArgOk
  114. if /i "%1" == "-arm64" set _BuildArch=arm64& goto :ArgOk
  115. if /i "%1" == "-debug" set _BuildType=debug& goto :ArgOk
  116. if /i "%1" == "-test" set _BuildType=test& goto :ArgOk
  117. if /i "%1" == "-codecoverage" set _BuildType=codecoverage& goto :ArgOk
  118. if /i "%1" == "-x86debug" set _BuildArch=x86&set _BuildType=debug& goto :ArgOk
  119. if /i "%1" == "-x64debug" set _BuildArch=x64&set _BuildType=debug& goto :ArgOk
  120. if /i "%1" == "-armdebug" set _BuildArch=arm&set _BuildType=debug& goto :ArgOk
  121. if /i "%1" == "-arm64debug" set _BuildArch=arm64&set _BuildType=debug& goto :ArgOk
  122. if /i "%1" == "-x86test" set _BuildArch=x86&set _BuildType=test& goto :ArgOk
  123. if /i "%1" == "-x64test" set _BuildArch=x64&set _BuildType=test& goto :ArgOk
  124. if /i "%1" == "-armtest" set _BuildArch=arm&set _BuildType=test& goto :ArgOk
  125. if /i "%1" == "-arm64test" set _BuildArch=arm64&set _BuildType=test& goto :ArgOk
  126. if /i "%1" == "-x86codecoverage" set _BuildArch=x86&set _BuildType=codecoverage& goto :ArgOk
  127. if /i "%1" == "-x64codecoverage" set _BuildArch=x64&set _BuildType=codecoverage& goto :ArgOk
  128. if /i "%1" == "-armcodecoverage" set _BuildArch=arm&set _BuildType=codecoverage& goto :ArgOk
  129. if /i "%1" == "-arm64codecoverage" set _BuildArch=arm64&set _BuildType=codecoverage& goto :ArgOk
  130. if /i "%1" == "-binary" set _Binary=-binary:%2& goto :ArgOkShift2
  131. if /i "%1" == "-bindir" set _BinDir=%~f2& goto :ArgOkShift2
  132. if /i "%1" == "-dirs" set _DIRS=-dirs:%~2& goto :ArgOkShift2
  133. if /i "%1" == "-win7" set TARGET_OS=win7& goto :ArgOk
  134. if /i "%1" == "-win8" set TARGET_OS=win8& goto :ArgOk
  135. if /i "%1" == "-winBlue" set TARGET_OS=winBlue& goto :ArgOk
  136. if /i "%1" == "-win10" set TARGET_OS=win10& goto :ArgOk
  137. if /i "%1" == "-nottags" set _NOTTAGS=%_NOTTAGS% -nottags:%~2& goto :ArgOkShift2
  138. if /i "%1" == "-tags" set _TAGS=%_TAGS% -tags:%~2& goto :ArgOkShift2
  139. if /i "%1" == "-dirtags" set _DIRTAGS=%_DIRTAGS% -dirtags:%~2& goto :ArgOkShift2
  140. if /i "%1" == "-dirnottags" set _DIRNOTTAGS=%_DIRNOTTAGS% -dirnottags:%~2& goto :ArgOkShift2
  141. if /i "%1" == "-includeSlow" set _includeSlow=1& goto :ArgOk
  142. if /i "%1" == "-onlySlow" set _onlySlow=1& goto :ArgOk
  143. if /i "%1" == "-quiet" set _quiet=-quiet& goto :ArgOk
  144. :: TODO Consider removing -drt and exclude_drt in some reasonable manner
  145. if /i "%1" == "-drt" set _drt=1& set _NOTTAGS=%_NOTTAGS% -nottags:exclude_drt& goto :ArgOk
  146. if /i "%1" == "-rebase" set _rebase=-rebase& goto :ArgOk
  147. if /i "%1" == "-rundebug" set _RUNDEBUG=1& goto :ArgOk
  148. :: TODO Figure out best way to specify build arch for tests that are excluded to specific archs
  149. if /i "%1" == "-platform" set _buildArch=%2& goto :ArgOkShift2
  150. :: TODO Figure out best way to specify build type for tests that are excluded to specific type (chk, fre, etc)
  151. if /i "%1" == "-buildType" set _buildType=%2& goto :ArgOkShift2
  152. if /i "%1" == "-binaryRoot" set _binaryRoot=%~f2& goto :ArgOkShift2
  153. if /i "%1" == "-variants" set _Variants=%~2& goto :ArgOkShift2
  154. if /i "%1" == "-cleanupall" set _CleanUpAll=1& goto :ArgOk
  155. if /i "%1" == "-noprogramoutput" set _NoProgramOutput=-noprogramoutput& goto :ArgOk
  156. if /i "%1" == "-onlyassertoutput" set _OnlyAssertOutput=-onlyassertoutput& goto :ArgOk
  157. ::Extra ch.exe command line flags
  158. if /i "%1" == "-ExtraHostFlags" set _ExtraHostFlags=%~2& goto :ArgOkShift2
  159. if /i "%1" == "-DumpOnCrash" set _DumpOnCrash=1& goto :ArgOk
  160. if /i "%1" == "-CrashOnException" set _CrashOnException=1& goto :ArgOk
  161. ::Timeout flag
  162. if /i "%1" == "-timeout" set _TestTimeout=%~2& goto : ArgOkShift2
  163. if /i "%1" == "-extraVariants" (
  164. :: Extra variants are specified by the user but not run by default.
  165. if "%_ExtraVariants%" == "" (
  166. set _ExtraVariants=%~2
  167. ) else (
  168. set _ExtraVariants=%_ExtraVariants%,%~2
  169. )
  170. goto :ArgOkShift2
  171. )
  172. :: Defined here are shorthand versions for specifying
  173. :: extra variants when running.
  174. if /i "%1" == "-parser" (
  175. if "%_ExtraVariants%" == "" (
  176. set _ExtraVariants=forcedeferparse,nodeferparse,forceundodefer
  177. ) else (
  178. set _ExtraVariants=%_ExtraVariants%,forcedeferparse,nodeferparse,forceundodefer
  179. )
  180. goto :ArgOk
  181. )
  182. if /i "%1" == "-serialization" (
  183. if "%_ExtraVariants%" == "" (
  184. set _ExtraVariants=bytecodeserialized,forceserialized
  185. ) else (
  186. set _ExtraVariants=%_ExtraVariants%,bytecodeserialized,forceserialized
  187. )
  188. goto :ArgOk
  189. )
  190. if /i "%1" == "-disablejit" (
  191. set _Variants=disable_jit
  192. goto :ArgOk
  193. )
  194. if /i "%1" == "-lite" (
  195. set _Variants=lite
  196. goto :ArgOk
  197. )
  198. if /i "%1" == "-nightly" (
  199. set _nightly=1
  200. if "%_ExtraVariants%" == "" (
  201. set _ExtraVariants=mediumlayout,largelayout,forceserialized
  202. ) else (
  203. set _ExtraVariants=%_ExtraVariants%,mediumlayout,largelayout,forceserialized
  204. )
  205. goto :ArgOk
  206. )
  207. if not "%1" == "" echo Unknown argument: %1 & set fShowGetHelp=1
  208. goto :eof
  209. :ArgOkShift2
  210. shift
  211. :ArgOk
  212. shift
  213. goto :NextArgument
  214. :: ============================================================================
  215. :: Initialize batch script variables to defaults
  216. :: ============================================================================
  217. :initVars
  218. set _HadFailures=0
  219. set _RootDir=%~dp0..
  220. set _BinDir=%_RootDir%\Build\VcBuild\Bin
  221. set _BuildArch=
  222. set _BuildType=
  223. set _Binary=-binary:ch.exe
  224. set _Variants=
  225. set _TAGS=
  226. set _NOTTAGS=
  227. set _DIRNOTTAGS=
  228. set _DIRTAGS=
  229. set _drt=
  230. set _rebase=
  231. set _ExtraVariants=
  232. set _dynamicprofilecache=-dynamicprofilecache:profile.dpl
  233. set _dynamicprofileinput=-dynamicprofileinput:profile.dpl
  234. set _includeSlow=
  235. set _onlySlow=
  236. set _CleanUpAll=
  237. set _nightly=
  238. set TARGET_OS=win10
  239. set _quiet=
  240. set _ExtraHostFlags=
  241. set _DumpOnCrash=
  242. set _CrashOnException=
  243. set _NoProgramOutput=
  244. set _OnlyAssertOutput=
  245. goto :eof
  246. :: ============================================================================
  247. :: Validate that required arguments were specified
  248. :: ============================================================================
  249. :validateArgs
  250. if "%_BuildArch%" == "" (
  251. echo Error missing required build architecture or build type switch
  252. set fShowGetHelp=1
  253. goto :eof
  254. )
  255. if "%_BuildType%" == "" (
  256. echo Error missing required build architecture or build type switch
  257. set fShowGetHelp=1
  258. )
  259. if not exist %_binDir%\%_BuildArch%_%_BuildType%\%_Binary:~8% (
  260. echo Error missing binary %_binDir%\%_BuildArch%_%_BuildType%\%_Binary:~8%
  261. set fShowGetHelp=1
  262. )
  263. goto :eof
  264. :: ============================================================================
  265. :: Configure the script variables and environment based on parsed arguments
  266. :: ============================================================================
  267. :configureVars
  268. echo Adding to PATH: %_binDir%\%_BuildArch%_%_BuildType%
  269. set path=%_binDir%\%_BuildArch%_%_BuildType%;%path%
  270. :: If the user didn't specify explicit variants then do the defaults
  271. if "%_Variants%"=="" set _Variants=interpreted,dynapogo
  272. :: If the user specified extra variants to run (i.e. in addition to the defaults), include them.
  273. if not "%_ExtraVariants%" == "" set _Variants=%_Variants%,%_ExtraVariants%
  274. if not "%_nightly%" == "1" (
  275. set _NOTTAGS=%_NOTTAGS% -nottags:nightly
  276. ) else (
  277. set _NOTTAGS=%_NOTTAGS% -nottags:exclude_nightly
  278. )
  279. if "%_includeSlow%%_onlySlow%" == "" (
  280. set _NOTTAGS=%_NOTTAGS% -nottags:Slow
  281. )
  282. if "%_onlySlow%" == "1" (
  283. set _TAGS=%_TAGS% -tags:Slow
  284. )
  285. if not "%NUM_RL_THREADS%" == "" (
  286. set _RL_THREAD_FLAGS=-threads:%NUM_RL_THREADS%
  287. )
  288. if "%_DIRS%" == "" (
  289. set _DIRS=-all
  290. )
  291. set _BuildArchMapped=%_BuildArch%
  292. set _BuildTypeMapped=%_BuildType%
  293. :: Map new build arch and type names to old names until rl test tags are
  294. :: updated to the new names
  295. if "%_BuildArchMapped%" == "x64" set _BuildArchMapped=amd64
  296. if "%_BuildTypeMapped%" == "debug" set _BuildTypeMapped=chk
  297. if "%_BuildTypeMapped%" == "test" set _BuildTypeMapped=fre
  298. if "%_BuildTypeMapped%" == "codecoverage" set _BuildTypeMapped=fre
  299. if "%Disable_JIT%" == "1" (
  300. set _dynamicprofilecache=
  301. set _dynamicprofileinput=
  302. )
  303. goto :eof
  304. :: ============================================================================
  305. :: Run one variant
  306. :: ============================================================================
  307. :RunOneVariant
  308. if "%_BuildType%" == "test" (
  309. rem bytecode layout switches not available in test build
  310. if "%_TESTCONFIG%"=="largelayout" (
  311. if not exist %_logsRoot%\%_BuildArch%_%_BuildType%\%_TESTCONFIG% (
  312. mkdir %_logsRoot%\%_BuildArch%_%_BuildType%\%_TESTCONFIG%
  313. )
  314. echo. > %_logsRoot%\%_BuildArch%_%_BuildType%\%_TESTCONFIG%\rl.log
  315. goto :eof
  316. )
  317. if "%_TESTCONFIG%"=="mediumlayout" (
  318. if not exist %_logsRoot%\%_BuildArch%_%_BuildType%\%_TESTCONFIG% (
  319. mkdir %_logsRoot%\%_BuildArch%_%_BuildType%\%_TESTCONFIG%
  320. )
  321. echo. > %_logsRoot%\%_BuildArch%_%_BuildType%\%_TESTCONFIG%\rl.log
  322. goto :eof
  323. )
  324. )
  325. set _OLD_CC_FLAGS=%EXTRA_CC_FLAGS%
  326. set EXTRA_RL_FLAGS=-appendtestnametoextraccflags
  327. set _exclude_serialized=
  328. if "%_BuildType%" == "debug" (
  329. rem Enabling storing dumps on user directory.
  330. set _DumpOnCrash=1
  331. )
  332. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% %_ExtraHostFlags%
  333. if not "%_DumpOnCrash%" == "" (
  334. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% -DumpOnCrash
  335. )
  336. if not "%_CrashOnException%" == "" (
  337. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% -CrashOnException
  338. )
  339. if "%_Binary%" == "-binary:ch.exe" (
  340. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% -WERExceptionSupport -ExtendedErrorStackForTestHost -BaselineMode
  341. )
  342. if "%_TESTCONFIG%"=="interpreted" (
  343. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% -maxInterpretCount:1 -maxSimpleJitRunCount:1 -bgjit- %_dynamicprofilecache%
  344. )
  345. if "%_TESTCONFIG%"=="nonative" (
  346. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% -nonative
  347. set EXTRA_RL_FLAGS=-nottags:exclude_interpreted -nottags:fails_interpreted
  348. )
  349. :: DisableJit is different from NoNative in that NoNative can be used
  350. :: with builds which include backend code, whereas DisableJit doesn't have
  351. :: backend code linked in, and also disables other features that incidentally
  352. :: depends on the backend like dynamic profile, asmjs, simdjs, background parsing etc.
  353. :: TODO: Re-enable interpreter mode asmjs and simdjs
  354. if "%_TESTCONFIG%"=="disable_jit" (
  355. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% -nonative
  356. set EXTRA_RL_FLAGS=-nottags:exclude_interpreted -nottags:fails_interpreted -nottags:require_backend
  357. ) else (
  358. set EXTRA_RL_FLAGS=%EXTRA_RL_FLAGS% -nottags:require_disable_jit
  359. )
  360. if "%_TESTCONFIG%"=="lite" (
  361. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% -nonative
  362. set EXTRA_RL_FLAGS=-nottags:exclude_interpreted -nottags:fails_interpreted -nottags:require_backend -nottags:require_debugger -nottags:Intl
  363. )
  364. if "%_TESTCONFIG%"=="dynapogo" (
  365. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% -forceNative -off:simpleJit -bgJitDelay:0 %_dynamicprofileinput%
  366. )
  367. :: Variants after here are user supplied variants (not run by default).
  368. if "%_TESTCONFIG%"=="forcedeferparse" (
  369. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% -forceDeferParse %_dynamicprofilecache%
  370. set _exclude_forcedeferparse=-nottags:exclude_forcedeferparse
  371. )
  372. if "%_TESTCONFIG%"=="nodeferparse" (
  373. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% -noDeferParse %_dynamicprofilecache%
  374. set _exclude_nodeferparse=-nottags:exclude_nodeferparse
  375. )
  376. if "%_TESTCONFIG%"=="forceundodefer" (
  377. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% -forceUndoDefer %_dynamicprofilecache%
  378. set _exclude_forceundodefer=-nottags:exclude_forceundodefer
  379. )
  380. if "%_TESTCONFIG%"=="bytecodeserialized" (
  381. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% -recreatebytecodefile -serialized:%TEMP%\ByteCode
  382. set _exclude_serialized=-nottags:exclude_serialized
  383. )
  384. if "%_TESTCONFIG%"=="forceserialized" (
  385. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% -forceserialized
  386. set EXTRA_RL_FLAGS=-nottags:exclude_forceserialized
  387. set _exclude_serialized=-nottags:exclude_serialized
  388. )
  389. if "%_TESTCONFIG%"=="mediumlayout" (
  390. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% -MediumByteCodeLayout -forceserialized
  391. set EXTRA_RL_FLAGS=-nottags:exclude_bytecodelayout -nottags:exclude_forceserialized
  392. set _exclude_serialized=-nottags:exclude_serialized
  393. )
  394. if "%_TESTCONFIG%"=="largelayout" (
  395. set EXTRA_CC_FLAGS=%EXTRA_CC_FLAGS% -LargeByteCodeLayout -forceserialized
  396. set EXTRA_RL_FLAGS=-nottags:exclude_bytecodelayout -nottags:exclude_forceserialized
  397. set _exclude_serialized=-nottags:exclude_serialized
  398. )
  399. if not "%_TestTimeout%" == "" (
  400. set EXTRA_RL_FLAGS=%EXTRA_RL_FLAGS% -timeout:%_TestTimeout%
  401. )
  402. echo.
  403. echo ############# Starting %_TESTCONFIG% variant #############
  404. call :doSilent del /q %_logsRoot%\%_BuildArch%_%_BuildType%\%_TESTCONFIG%\rl*
  405. call :doSilent md %_logsRoot%\%_BuildArch%_%_BuildType%\%_TESTCONFIG%
  406. set _rlArgs=%_Binary%
  407. set _rlArgs=%_rlArgs% -target:%_BuildArchMapped%
  408. set _rlArgs=%_rlArgs% -nottags:fail
  409. set _rlArgs=%_rlArgs% %_RL_THREAD_FLAGS%
  410. set _rlArgs=%_rlArgs% %_DIRS%
  411. set _rlArgs=%_rlArgs% -verbose
  412. set _rlArgs=%_rlArgs% %_TAGS%
  413. set _rlArgs=%_rlArgs% %_NOTTAGS%
  414. set _rlArgs=%_rlArgs% %_DIRTAGS%
  415. set _rlArgs=%_rlArgs% %_DIRNOTTAGS%
  416. set _rlArgs=%_rlArgs% -nottags:fails_%_TESTCONFIG%
  417. set _rlArgs=%_rlArgs% -nottags:exclude_%_TESTCONFIG%
  418. set _rlArgs=%_rlArgs% -nottags:exclude_%TARGET_OS%
  419. set _rlArgs=%_rlArgs% -nottags:exclude_%_BuildArchMapped%
  420. set _rlArgs=%_rlArgs% -nottags:exclude_%_BuildTypeMapped%
  421. set _rlArgs=%_rlArgs% %_exclude_serialized%
  422. set _rlArgs=%_rlArgs% %_exclude_forcedeferparse%
  423. set _rlArgs=%_rlArgs% %_exclude_nodeferparse%
  424. set _rlArgs=%_rlArgs% %_exclude_forceundodefer%
  425. set _rlArgs=%_rlArgs% %_ExcludeApolloTests%
  426. set _rlArgs=%_rlArgs% %_NoProgramOutput%
  427. set _rlArgs=%_rlArgs% %_OnlyAssertOutput%
  428. set _rlArgs=%_rlArgs% %_quiet%
  429. set _rlArgs=%_rlArgs% -exe
  430. set _rlArgs=%_rlArgs% %EXTRA_RL_FLAGS%
  431. set _rlArgs=%_rlArgs% %_rebase%
  432. set REGRESS=%CD%
  433. call :do rl %_rlArgs%
  434. if %ERRORLEVEL% NEQ 0 set _HadFailures=1
  435. call :do move /Y %_logsRoot%\*.log %_logsRoot%\%_BuildArch%_%_BuildType%\%_TESTCONFIG%
  436. if %ERRORLEVEL% NEQ 0 set _HadFailures=1
  437. set EXTRA_CC_FLAGS=%_OLD_CC_FLAGS%
  438. goto :eof
  439. :: ============================================================================
  440. :: Clean up left over files
  441. :: ============================================================================
  442. :cleanUp
  443. call :doSilent del /s *.bc
  444. call :doSilent del /s *.out
  445. call :doSilent del /s *.dpl
  446. call :doSilent del /s profile.dpl.*
  447. call :doSilent del /s testout*
  448. if "%_CleanUpAll%" == "1" (
  449. call :doSilent del /s *.rebase
  450. )
  451. goto :eof
  452. :: ============================================================================
  453. :: Echo a command line before executing it
  454. :: ============================================================================
  455. :do
  456. echo ^>^> %*
  457. cmd /s /c "%*"
  458. if %ERRORLEVEL% NEQ 0 exit /b %ERRORLEVEL%
  459. goto :eof
  460. :: ============================================================================
  461. :: Echo a command line before executing it and redirect the command's output
  462. :: to nul
  463. :: ============================================================================
  464. :doSilent
  465. echo ^>^> %* ^> nul 2^>^&1
  466. cmd /s /c "%* > nul 2>&1"
  467. goto :eof