view gpf/BIN/setup_function_coverage.bat @ 41:9d4ff52edc36

l1_cmplx.c: l1ddsp_read_iq_dump() calls removed to pass link
author Mychaela Falconia <falcon@ivan.Harhan.ORG>
date Wed, 28 Oct 2015 16:04:40 +0000
parents 509db1a7b7b8
children
line wrap: on
line source

@echo on

@if (%2)==(%3) (@goto labelusage)

@echo Clearing previously set variables ...
@if exist %srcfiles%	(unset srcfiles)
@if exist %exe%		(unset exe)
@if exist %outdir%	(unset outdir)
@if exist %exedir%	(unset exedir)
@if exist %mapfile%	(unset mapfile)
@if exist %methode%	(unset method)
@if exist %arg1%	(unset arg1)
@if exist %arg2%	(unset arg2)
@echo Done

@set method=FV
@set arg1=FV
@set arg2=/SC
@set rsp=%1
@set entry_point=_pei_primitive
@set outpath_ext=%2

call profile_config.bat %3 no_skip %outpath_ext%

rem set outdir=%outdir%%outpath_ext%
rem echo %outdir%

copy %exedir%%exe%.exe %outdir%
copy %mapfile% %outdir%

unset srcfiles

@rem not to be used when using an rsp file.
@rem for /f %a in (%outdir%%1) do ( @set srcfiles=%srcfiles% /INC %a)

@rem working 
@rem PREP /%method% /SF _pei_primitive /OT %outdir%%exe% /OM /EXCALL %srcfiles% %outdir%%exe%

PREP /%method% /SF %entry_point% /OT %outdir%%exe% /OM /EXCALL @%outdir%%rsp% %outdir%%exe%

@rem PREP /%method% /AT /STACK 200 /SF function /OT %outdir%%exe% /OM %outdir%%exe%
@if errorlevel == 1521 goto label1521
@echo ^n
@echo You are now ready to start the actual profiling !
goto done


@rem Error handling.

:label1521
@echo ////////////////////////////////////////////////////////////////////////
@echo ERROR: You have to include some modules (obj) which contains the functions 
@echo to be profiled. When adding obj files to the list do not use the (0-0) 
@echo as for line coverage.
@echo ////////////////////////////////////////////////////////////////////////
@goto done

:labelusage
@echo ^n
@echo usage: setup_function_coverage file_list.rsp path_ext ps_name
@echo where: 
@echo ^n
@echo  -file_list.rsp : text file containing list of files to included or excluded from the profiling.
@echo  -path_ext : the relative directory path to the entity test files (umts base: \g23m\condat\ms\src\, gprs base :\g23m\condat\ms\). 
@echo  -ps_name : the name of the protocol stack (e.g. umts, gprs, gprs_wap, gprs_bt, teststack).
@echo ^n
@echo Examples: setup_function_coverage.bat sndcp.rsp doc\test\ gprs
@echo           setup_function_coverage.bat sndcp.rsp sndcp\test_usm\ umts
@echo           setup_function_coverage.bat xx_tdc.rsp xx_tdc\ teststack
@echo ^n
@echo For more information on how to perform the profiling please refer to the user guide: \gpf\doc\test_coverage\8434_521_test_coverage_user_guide.doc
@echo ^n
@goto done

:done