Home

SH-4A, SH4AL-DSP E200F Emulator User`s Manual

image

Contents

1. Figure 4 36 Session has been modified Message Box 124 RENESAS 4 8 Uninstalling the Emulator s Software Follow this procedure to remove the installed emulator s software from the user s host machine As the installed product is registered with the High performance Embedded Workshop uninstall the product on the High performance Embedded Workshop screen It is also possible to uninstall the emulator s software by using Add Remove Programs in the control panel In this case however note that all the tools including the compiler in the High performance Embedded Workshop will be removed 1 Activate the High performance Embedded Workshop 2 Click the Administration button in the Welcome dialog box Welcome Options em C Open a recent project workspace Administration C Browse to another project workspace Figure 4 37 Welcome Dialog Box 125 7 ENESAS 3 The Tools Administration dialog box is opened Tools Administration Utility Phases Debugger Components Extension Components Figure 4 38 Tools Administration Dialog Box 126 RENESAS 4 Click the mark at the left of Debugger Components in the Registered components list box to list the installed components Then highlight the product name to be uninstalled Tools Administration Registered components E AUELHRE kt Cancel A Generic StackTrace View ECX A Generic Status View ECX
2. Shift Ctrl E v monitor2 HOOFFBO80 monitor H OOFFBOOO _heap_area Windows Select Figure 5 21 Monitor Setting List 5 3 7 Managing the Monitor Window Selecting Display gt CPU gt Monitor gt Windows Select displays the Windows Select dialog box In this window the current monitoring condition is checked and the new monitoring condition is added edited and deleted in succession Selecting multiple monitoring conditions enables a temporary stop of update hiding and deletion Windows Select Name Address M monitor H OOFFBO80 MV monitort H OOFFBO _heap_area Add Edit Lock Refresh Hide Remove Close Figure 5 22 Windows Select Dialog Box 164 RENESAS 5 4 Viewing the Current Status Choose View gt CPU gt Status or click the View Status toolbar button to open the Status window and see the current status of the debugging platform wz Status Target Device Configuration X RAM Area 05007000 OSOOSFFF Y RAM Area 05017000 OSO1SFFF U RAM Area OSSEOOOO OS61FFFF Internal I O 04000000 O FFFFFF Internal I O 10000000 1FFFFFFF System Memory Resources Remain Emulation Memory OM Memory Loaded Area Figure 5 23 Status Window The Status window has three sheets e Memory sheet Contains information about the current memory status including the memory mapping resources and the areas used by the currentl
3. Software trace data SHway trace data Figure 5 82 Editing the AUD Performance Analysis Measurement Condition Dialog Box for Setting the AUD Event Notes 1 When the AUD performance analysis function is used set Performance start stop on the Action page of each channel 2 When the measurement condition is modified the contents are reflected on the AUD Event sheet in the Event window 249 7 ENESAS 5 8 3 Opening the BUS Performance Analysis Window To open the BUS Performance Analysis window choose View gt Performance gt Performance Analysis or click the PA toolbar button to open the Select Performance Analysis Type dialog box Select Performance Analysis Type Performance Analysis BUS Performance Cancel Figure 5 83 Select Performance Analysis Type Dialog Box Select BUS Performance and click the OK button to open the Performance Analysis window Condition TOTAL RUN_TIME RtoR all address H O to H 100 count D 6 read 00h OOmin 00s O00ms O00us address H O to H 300 read PtoP all address H O to H O 00h OOmin 00s 000ms 000us PtoP all address H 2000 to H 3000 write 00h OOmin 00s O00ms 000us None 00h OOmin 00s 000ms 000us None 00h OOmin 00s 000ms 000us Figure 5 84 Performance Analysis Window BUS Performance The BUS performance analysis function does not affect the realtime operation because it measures execution performance in the specified range by using
4. Figure 6 32 Breakpoint Dialog Box Note This dialog box differs according to the product For the items of each product refer to the online help e Click the OK button 322 7 ENESAS The PC breakpoint that has been set is displayed in the Event window Condition Breakpoint Enable Address H 00001098 tutorial cpp 48 Physical space 4 4 gt Breakpoint Onchip Event A AUD Event A Other Event A BUS Event Figure 6 33 Event Window PC Breakpoint Setting Note The items that can be displayed in this window differ according to the product For the items that can be displayed refer to the online help To stop the tutorial program at the PC breakpoint the following procedure must be executed e Set the program counter and stack pointer values PC H 00000800 and R15 H 00010000 that were set in section 6 8 Setting Registers in the Register window Click the Go button e If program execution is failed reset the device and execute again the procedures above 323 RENESAS 00001038 00001040 0000104c 00001056 0000105e 00001066 0000106a 0000106c 00001084 0000106e 00001098 000010aa 000010be 000010ce 000010e0 o000010f2 00001104 00001116 00001128 0000113a 00001146 00001166 The program runs and stops at the set PC breakpoint void main void long a 10 long j int i class Sample p_sam while 1 p_sam new Sample for i 0 i lt 10 i
5. Properties cot Figure 4 22 New Project Workspace Dialog Box Workspace Name edit box Enter the new workspace name Here for example enter test Project Name edit box Enter the project name When the project name is the same as the workspace name it needs not be entered CPU family drop down list box Select the target CPU family Tool chain drop down list box Select the target toolchain name when using the toolchain Otherwise select None Project type list box Select the project type to be used Note When Demonstration is selected in the emulator note the following The Demonstration is a program for the simulator When using a program to be generated delete the Printf statement 109 7 ENESAS 3 Make the required setting for the toolchain When the setting has been completed the following dialog box is displayed New Project MSHxxxx E200F SYSTEM CPU SH4AL Figure 4 23 New Project Step 7 Dialog Box Check the target emulator and click the Next button Mark other products as required 110 7RENESAS 4 Set the configuration file name The configuration file saves the state of High performance Embedded Workshop except for the emulator New Projec Target name SHxxxx E200F SYSTEM CPU SH44L DSP Configuration name Debug_SHxxxx_E200F_SYSTEM Detail options Setting Modify lt Back __New gt Finish Cancel Figure 4 24 New Project
6. RENESAS an l L memory access write of an operand Table 1 4 Measurement Items cont Classification Type System bus System bus performance only available for Ch3 and Ch4 Measurement Item Option Number of requests RQ Note The number of valid bus cycles cells is counted by the system bus clock Number of RS responses The number of valid bus cycles cells is counted by the system bus clock Waited cycles for WRQ request The cycles for an issued request req that no acceptance signal gnt is issued to are counted by the system bus clock Even if the waits are issued simultaneously for multiple requests they are counted as 1 Waited cycles for WRS response 7 ENESAS The cycles for an issued response r_req that no acceptance signal r_gnt is issued to are counted by the system bus clock Even if the waits are issued simultaneously for multiple requests they are counted as 1 47 Table 1 5 shows the measurement items and methods that are mainly used Table 1 5 Main Measurement Items Main Measurement Item Elapsed time Measurement Method Number of elapsed cycles x CPU clock cycles Number of execution instructions Number of valid instructions issued number of cases of simultaneous execution of two instructions Number of interrupts accepted Number of exceptions accepted Number of instruction fetches for both cache and non cache Nu
7. RESET signal Please check RESET and Vec w Retry Ignore Figure 4 11 Can not find RESET signal Dialog Box b Ifthe following dialog box is displayed the user system may be turned off or the H UDI port connector may not be correctly connected Check that the user system is turned on and the H UDI port connector is connected hexxxx IN Check the connection between the H UDI pins and the H UDI port connector Figure 4 12 Check the connection Dialog Box 101 RENESAS c If the following dialog box is displayed the device may not correctly operate Check if there are reasons for illegal device operation hexxxx AN COMMUNICATION TIMEOUT ERROR Figure 4 13 COMMUNICATION TIMEOUT ERROR Dialog Box hexxxx N INVALID ASERAM FIRMWARE Figure 4 14 INVALID ASERAM FIRMWARE Dialog Box hexxxx N Error JTAG boot Figure 4 15 Error JTAG boot Dialog Box 2 Ifthe emulator is not activated due to other reasons a message box corresponding to the status is displayed Use the message as a reference to check the wiring on the board 102 7 ENESAS 4 2 Method for Activating High performance Embedded Workshop To activate the High performance Embedded Workshop follow the procedure listed below 1 Connect the emulator to the host machine and the user system then turn on the user system 2 Select High performance Embedded Workshop from Renesas High performance Embedded Workshop of Program
8. Set PC To Cursor Sets the PC to the address at the row of the text cursor Run Launches the Run Program dialog box allowing the user to enter the PC or PC breakpoint during executing the user program Step In F11 RENESAS Executes a block of user program before breaking 377 Table A 1 GUI Menus cont Menu Option Debug cont Step Over Toolbar Shortcut Button F10 P Remarks Executes a block of user program before breaking If a subroutine call is reached then the subroutine will not be entered Step Out Shift A F11 G Executes the user program to reach the end of the current function Step Launches the Step Program dialog box allowing the user to modify the settings for stepping Step Auto Mode Steps only one source line when the Source window is active When the Disassembly window is active stepping is executed ina unit of assembly instructions Assembly Executes stepping in a unit of assembly instructions Source Steps only one source line Halt Program Esc Stops the execution of the user program Connect la 6 Connects the debugging platform Initialize Disconnects the debugging platform and connects it again Disconnect Disconnects the debugging platform Download Modules Downloads the object program Unload Modules 378 RENESAS Unloads the object program Appen
9. hexxxx IN Please Reset the user system and press lt Enter gt Key Figure 4 8 Dialog Box of the RESET Signal Input Request Message 12 Input the reset signal from the user system and click the OK button 99 RENESAS 13 If no reset signal is detected the following dialog box is displayed hexxxx Can not find RESET signal Please check RESET and Vec a Retry Ignore Figure 4 9 Can not find RESET signal Dialog Box When the Ignore button is clicked the emulator issues a reset in the CPU for initiation However this method is unavailable for some products For details refer to section 2 2 Specific Functions for the Emulator when Using the SHxxxx in the additional document Supplementary Information on Using the SHxxxx 14 When Connected is displayed in the Output window of the High performance Embedded Workshop the emulator initiation is completed Connected I Build A Debug Find in Files J Macro A Test Hy Version Control i Figure 4 10 Output Window 100 RENESAS Notes 1 Ifthe emulator is not initiated the following dialog boxes shown in figures 4 11 through 4 15 will be displayed a If the following dialog box is displayed and the method 12 above is unavailable the power of the user system may not be input or the RESET signal may not be input to the device Check the input circuits for the power of the user system and the reset pin hexxxx Can not find
10. l EEE 0000106c ali is J Download modules D tutorialabs 00000000 00001084 p_sam gt sort a a Dependencies 0000108e p_sam gt change a 00001098 p_sam gt s0 a 0 000010ea p_sam gt sl al 1 000010be p_sam gt s2 a 2 000010ce p_sam gt s3 a 3 000010e0 p_sam gt s4 a 4 O00010f2 p_sam gt s5 a 5 00001104 p_sam gt s6 a 6 00001116 p_sam gt s a 7 00001128 p_sam gt s8 a 8 00001134 p_sam gt s9 a 9 00001146 ea P_sam Figure 6 6 Source Window Setting a PC Breakpoint The symbol e will appear on the line containing the sort function This shows that a PC breakpoint has been set Note The PC breakpoint cannot be set in the ROM area 302 7 ENESAS 6 8 Setting Registers Set values of the program counter and the stack pointer before executing the program e Select Registers from the CPU submenu of the View menu The Register window is displayed Value 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00010000 00000800 01110000000000000000000011110000 MRB000000000000 00000000 00000000 00000000 annannnnan Figure 6 7 Register Window 303 7 ENESAS e To change the value of the program counter PC double click the value area in the Register window with the mouse The following dialog box is then displayed and the value can be changed Set
11. s request for debugging When the High performance Embedded Workshop is activated and connected to the emulator the required functions can be selected At this time the following dialog box will be displayed Function select xi m Function setting Main board mode setting RealProfile Areal function mode x Bus board mode setting Perfor mance ch x Option board mode setting RealProfile Area2 function mode x Monitor Setting Virtual space C Physical space Figure 2 18 Function select Dialog Box The following sections describe the contents that can be selected in this dialog box Note For details on each function refer to section 1 3 Emulator Functions 77 RENESAS 2 7 1 Changing the Functions when Using the E200F Main Unit Select the item in the Main board mode setting combo box of the Function select dialog box Function select x m Function setting Main board mode setting _ RealProfile Areal IProfile Areal Gunction mode mode Bus board mode setting Performance 6ch Option board mode setting RealProfile Area2 Gunction mode m Monitor Setting Virtual space Physical space Cancel Figure 2 19 Function select Dialog Box e RealProfile Areal function mode Measures accumulation of execution time of each function the subroutine execution time is not included e RealProfile Areal nest mode Measures accumulation of execution time o
12. 0 no verify Abnormal end other than 0 1 verify Verify error BT R5 L Access size 0x4220 byte 0x5720 word 0x4C20 longword R6 L Write data Erase module R4 L Access size None 0x4220 byte 0x5720 word 0x4C20 longword Note The L means the longword size 361 7 ENESAS Note Write module The write data for the access size is set to the R6 register When the access size is word or byte 0 is set to the upper bits of the R6 register e Flash memory download method For downloading to the flash memory set the items on the Loading flash memory page in the Configuration dialog box which is opened from System then Emulator from the Options menu General Loading flash memory Loading flash memory C Disable Erasing flash memory Disable Enable File name Browse Bus width of flash memory 22 bit bus width x Flash memory erasing time minute Entry point All erasing module address Writing module address Ho f v Access size Figure 6 62 Loading flash memory Page 362 7 ENESAS Table 6 4 shows the options for the Loading flash memory page Table 6 4 Loading flash memory Page Options Option Loading flash memory radio button Description Sets Enable for flash memory downloading When Enable is selected and File load is selected from the File menu for downloading the write module is always called Enable Download to the flash me
13. 7 ENESAS Loading flash memory Erasing flash memory File name Bus width of flash memory Flash memory erasing time Entry point 144 Sets Enable for flash memory downloading At Enable when the flash memory is downloaded on the High performance Embedded Workshop the write module is always called Disable Not download to the flash memory Enable Download to the flash memory Sets Enable for erasing before the flash memory is written At Enable the erase module is called before calling the write module Disable Not erase the flash memory Enable Erase the flash memory Sets the write erase module name The file that has been set is loaded to the RAM area before loading to the flash memory Sets the bus width of the flash memory Sets the TIMEOUT value at flash memory erasing Increase the value if erasing requires much time although the default time is three minutes The values that can be set are as follows D O minimum and D 65535 maximum Only positive integers can be input Sets the calling destination address of the write erase module It must be RAM address All erasing module address Enters the calling destination address of the erase module Writing module address Enters the calling destination address of the write module Access size Selects the access size of the RAM area that is used for loading the write erase module RENESAS 5 1 7 Opening the Memory
14. A CAUTION Observe the conditions listed in tables 1 7 and 1 8 when using the emulator Failure to do so will cause illegal operation in the user system the emulator product and the user program Table 1 7 Environmental Conditions Item Specifications Temperature Operating 10 C to 35 C Storage 10 C to 50 C Humidity Operating 35 RH to 80 RH no condensation Storage 35 RH to 80 RH no condensation Vibration Operating 2 45 m s max Storage 4 9 m s max Transportation 14 7 m s max Ambient gases No corrosive gases may be present RENESAS 55 Table 1 8 lists the acceptable operating environments Table 1 8 Operating Environments Item Host machine Description Built in Pentium III or higher performance CPU 1 GHz or higher recommended IBM PC or compatible machine with USB 1 1 2 0 Full Speed Operating system Windows 2000 or Windows XP Minimum memory capacity 128 Mbytes or more 512 Mbytes recommended Hard disk capacity Installation disk capacity 250 Mbytes or more Prepare an area at least double the memory capacity four times or more recommended as the swap area Pointing device such as mouse Connectable to the host machine compatible with Windows 2000 or Windows XP Display Monitor resolution 1024 x 768 or higher AC input power supply 5 0 0 25 V USB bus power type Current consumption Volta
15. DESTINATION SnancH DESTINATION BRANC DESTINATION BRANCH DESTINATION Brancn DESTINATION BPANCH DESTINATION DrazchType Bus GENERAL GENERAL ornenau GENERAL GENERAL ornen GENERAL GRUERAL oenenaL GENERAL GENERAL Oren GENERAL GENERAL Orne SUBROUTINE Figure 6 54 Internal AUD Usermemory trace Window Example 351 7 ENESAS 6 19 2 Displaying the BUS MFI trace Window Select Trace from the Code submenu of the View menu The Trace Window Type dialog box is displayed Trace Window Type race window BUS MFI trace X oneei Figure 6 55 Trace Window Type Dialog Box Select BUS MFI trace and click the OK button The BUS MFI trace window will appear 352 1RENESAS External bus trace function This function is enabled when the external bus pins of the MPU are connected to the emulator The methods to acquire the external bus trace are described below a Setting the bus trace Set the multiplexed state of the bus pins or the connected memory referring to section 2 7 2 External Bus Trace Break Function and External Bus Performance Function b Setting the trace acquisition mode Click the BUS MFI trace window with the right hand mouse button and select Acquisition from the popup menu to display the BUS acquisition dialog box Set the acquisition mode for the external bus trace as shown in figure 6 56 BUS acquisition Trace Mode Trace type BUS buffer ov
16. Generic TLB View ECX Generic Trace View ECX j Generic Watch View ECX Unregister a 2i re A Generic Waveform View ECX 2i 2i a Register Intel Hex Record Object Reader SH E200F SYSTEM Export SRecord object reader Hp A SuperH RISC engine GPU J Search disk Extension Components Communication Tools Tool information I Show all components Current HEW tools database location E Hew3 Modify Figure 4 39 Highlighting the Product to be Uninstalled Uninstaller 5 Click the Unregister button After the following message box is displayed click the Yes button High performance Embedded Workshop Unregistering this tool removes it From the HEW system consequently it will not be available to any HEW WorkSpace re you sure that you want to unregister it Figure 4 40 Unregistering this tool Message Box 127 7 ENESAS This is the end of canceling the High performance Embedded Workshop registration Then remove the file for the emulator from the host machine 6 Click the Uninstaller button in the Tools Administration dialog box to open the Uninstall HEW Tool dialog box Uninstall HEW Tool a EA a Wrirtrstalll Figure 4 41 Uninstall HEW Tool Dialog Box 128 z ENESAS Click the Start button to list the installed components Uninstall HEW Tool Select the directory in which to begin the search for tools ose C Hew3
17. I have a text file open in the editor but syntactic color coding is not being displayed Ensure that you have named the file i e saved it and that the Syntax coloring check box is set on the Editor tab of the Options dialog box which is launched via Setup gt Options The High performance Embedded Workshop looks up the filename extension to determine the group to which the file belongs and decides whether or not coloring should be applied to the file To view the currently defined filename extensions and file groups select Project gt File Extensions to launch the File Extensions dialog box To view the coloring information select Setup gt Format to display the Color tab of the Format dialog box for further details see the Syntax Coloring section in Chapter 4 Using the Editor of the volume on the High performance Embedded Workshop I want to change the settings of a tool but the Tools gt Administration menu option is not selectable Tools gt Administration is not selectable while a workspace is open To open the Tool Administration dialog box close the current workspace I opened a workspace from my PC and one of my colleagues opened the same workspace simultaneously from another PC I changed the settings of the workspace and saved it My colleague saved the workspace after me I opened the workspace again and found that the settings of the workspace dif
18. Searches upwards when this box is checked Enters a PTR value to start a search Enters a PTR value to end a search Note Along with setting the range for searching PTR values to start and end searching can be set in the Start PTR and End PTR options respectively 228 7 ENESAS 2 Address page Set an address condition Trace Find General Address data Type Bus RAW I Don t care Setting 1e HFFEF80 Cancel Apply Figure 5 63 Trace Find Dialog Box Address Page Don t care Detects no address when this box is checked Setting Detects the specified address Value Enter the address value not available when Don t care has been checked 229 7 ENESAS 3 Data page Set a data condition Trace Find General Address data Type Bus RAW I Don t care Setting 1e Fo000 Cancel Apply Figure 5 64 Trace Find Dialog Box data Page Don t care Detects no data when this box is checked Setting Detects the specified data Value Enter the data value not available when Don t care has been checked 230 7 ENESAS 4 R W page Select the type of access cycles Trace Find General Address data Type Bus R W yepeeeeeeyaeeneeenenneny Set String READ 7 Cancel Apply Figure 5 65 Trace Find Dialog Box R W Page Don t care Detects no read write condition when this box i
19. Type of branch only when the branch trace is acquired GENERAL General branch SUBROUTINE Subroutine branch EXCEPTION Exception branch The bus which was being accessed Whether the generated data is associated with read or write access Address The data of the generated data access When Type is S_TRACE value x a variable of function Trace x is displayed Internal performance counter Ch3 output Internal performance counter Ch4 output Instruction mnemonic The C C or assembly language source program Label information 217 RENESAS 2 Acquiring AUD Trace Information AUD trace Selecting the Set menu in the popup menu of the Internal AUD Usermemory acquisition window displays the Internal AUD Usermemory acquisition dialog box When AUD trace is selected in Trace Type within the dialog box the trace information is acquired by using the AUD trace function Note Since the AUD trace function is implemented according to the information in the MPU output from the AUD pin the trace acquisition condition for the Onchip Eventpoint must be set Set trace acquisition conditions for on chip event channels Ch OA Ch6 OA Ch7 SystemBus Ch8 SystemBus and Ch12 Branch or software trace Internal AUD Usermemory trace 000008 D 000008 OoooFFc4 000053DC 000007 D 000007 OOOOFFCS 00002704 000006 D 000006 OOOOFFCC 00005665 000005 D 000005 OOOOFFDO oooo0DAA 000004 D o000004 OOOOFFD4 oo00421F
20. according to the color of the R mark Blue R An updated value of the data at this location has been read by the monitoring function Black R A value has been updated by reading the normal data Notes 1 This function can be set per variable or per element or body for structures of data 2 The information is lost when it is scrolled out of the Watch window and when the window is closed 3 A variable that is allocated to a register cannot be selected for monitoring 4 The realtime watch function is realized by using the AUD monitoring function It is thus possible to monitor four areas in total by the AUD monitoring function and the realtime update function of the Watch window 5 3 6 Hiding the Monitor Window When using the Monitor function to monitor the value of a variable from the Watch window hide the Monitor window for the effective use of the screen The current monitoring information is listed as the submenu when selecting Display gt CPU gt Monitor The list consists of the Monitor window name and the address to start monitoring When the left of the list is checked the Monitor window is being displayed Selecting items of the Monitor window you want to hide from the monitor setting list displays no Monitor window and removes the check mark at the left of the list 163 7 ENESAS To display the Monitor window again select the hidden the Monitor window Monitor 4 Monitor Setting
21. gt Performance gt Performance Analysis or click the PA toolbar button E to open the Select Performance Analysis Type dialog box Select Performance Analysis Type Performance Analysis AUD Performance Figure 5 79 Select Performance Analysis Type Dialog Box Select AUD Performance and click the OK button to open the Performance Analysis window Performance Analysis lel E3 Channel Condition TOTAL RUN_TIME Count Chl Start Branch source address H O End Bran a 00h OOmin 00s 000ms O000u 0 Ch2 None 0 00h OOmin 00s 000ms O00u 0 Ch3 Start By break End None 0 00h OOmin 00s 000ms 000u 0 Ch4 None 00h OOmin 00s 000ms 000u 0 Figure 5 80 Performance Analysis Window AUD Performance The AUD Performance Analysis function does not affect the realtime operation because it measures execution performance in the specified range by using the circuit for performance measurement on the emulator main unit case The start and end conditions of the measurement channel of the AUD Performance Analysis use one AUD event channel respectively Four measurement channels use eight AUD event channels Note Since the AUD performance function is implemented according to the information in the MPU output from the AUD pin the trace acquisition condition for the Onchip Performance analysis must be set Set trace acquisition conditions for on chip event channels Ch5 OA Ch6 OA Ch7 SystemBus Ch8 SystemB
22. oo00104c NOP 0 0 0 0 0 0 0 0 0 0 0 Figure 5 108 Code Coverage Window Specifying a Source File This window is divided into two by the splitter e Left hand window Displays the coverage range and statistical information of the coverage The items are displayed as follows Functions Function to be selected for coverage Statistic CO coverage value in percentage The percentage will be displayed in the Statistic column by selecting Percentage from the popup menu in the left hand window Clicking the column tab allows the function names or CO coverage values to be listed in descending or ascending order 282 7 ENESAS e Right hand window Displays coverage information of the function selected by double clicking on the left hand window at the C C or assembly language level The items are displayed as follows Executed 1 the instruction was executed or 0 the instruction was not executed Address Instruction address Assembler Disassembled program Source C C or assembly source program 5 11 2 Displaying a Source File Selecting Display a Source File from the popup menu opens the Editor window which displays the source file for the address at the cursor location on the Code Coverage window 5 11 3 Changing the Address to be Displayed Selecting Go To Address from the popup menu opens the Go To Address dialog box which allows the user to change the address to be displayed in
23. p_sam gt s3 a 3 p_sam gt s4 a 4 p_sam gt s5 a 5 p_sam gt s6 a 6 p_sam gt s7 a 7 p_sam gt s8 a 8 p_sam gt s9 a 9 delete p_sam Figure 6 38 Source Window at Execution Stop Onchip Eventpoint Channel 1 329 7 ENESAS The Status window displays the following contents SHXXXX EZOOF SYSTEM i CPU SH4AL DSP Renesas E Series USB Driver SHXXXX Ready EVENT CONDITION 1 Run time count 00h OOmin 00s 007ms 7lZus Z 00ns Emulation mode Hardware break disable Big Disconnected Not used Bus Board Connected Option Board Disconnected Platform Events Fj Figure 6 39 Displayed Contents of the Status Window Onchip Event Ch1 IA_OA Note The items that can be displayed in this window differ according to the product For the items that can be displayed refer to the online help 330 RENESAS 6 18 2 Setting the Sequential Onchip Eventpoint The sequential break is enabled by the combination of Onchip Eventpoints Set the satisfaction conditions of Onchip Eventpoint as follows Ch1 IA_OA A break condition is satisfied immediately before when an instruction of address H 00001084 is executed Ch2 7 A_OA_DT_CT A break condition is satisfied immediately before when an instruction of address H 0000106C is executed Follow the setting method described in the previous section To set these eventpoints as sequential e Select Sequential Setting from the popup menu by clicking the Event window
24. performance measurement function or data that has been measured will be deleted c Since the profiling function is implemented with the internal break it takes a long time to start and end the user program execution The stopping time of the user program depends on the performance of the host machine in use or the JTAG clock that time under the following environment is shown below Environment Host machine 850 MHz Pentium IID Memory 256 Mbytes SH7323 10 MHz TCK clock OS Windows 2000 Execution program 10 000 nested calls i When the profiling function is not used 1 second or lower ii When the profiling function is used in the setting without including a child function 63 seconds iii When the profiling function is used in the setting including a child function 72 seconds d When the profiling function is used the trace settings are internally changed and the Internal trace mode is set Note that a part of emulator functions cannot be used if the mode is not changed to AUD trace 267 RENESAS 5 10 Viewing Realtime Profile Information The realtime profiling function is used to measure the execution performance in the specified range of the application program in a function unit This function is effective to investigate the position and the cause of the lowered performance in the application program The realtime profiling function does not affect the realtime operation because it measures the performance by us
25. 5 Clearing the Trace Information cies eseeseeeseceseceeeeseeeaeeeseeeaecesessseeeeeaees 234 5 7 6 Saving the Trace Information in a File ee e eee eee cseeeseeeseeeseeeseeeneeseeenees 234 5 7 7 Viewing the Source Window cceeceeeseeeesceceseeeeneeeeeeceeeceeeceeaeeeneeeenaeeeneeees 234 5 7 8 Trimming th SOULE praises eesin arn a E Eae seavsieosieecs sou tes 234 5 7 9 Temporarily Stopping Trace Acquisition eeseesesesseesesreeresrssrsresresresrrsresrrsrese 235 5 7 10 Extracting Records from the Acquired Information sseeseeseeseessereerrereresereeree 235 vii RENESAS 5 8 5 9 5 11 viii 5 7 11 Analyzing Statistical Information eee eee cece cereeeeeeseseseseeeteetseenaeeeaeees 242 5 7 12 Extracting Function Calls from the Acquired Trace Information 244 Analyzing Performance ceense Peeves isnessdssdesavtyeusdasdyesosuaesscesssduevves caster EEA E EIRENE 245 5 8 1 Opening the Onchip Performance Analysis Window seesseeeeeeeeeererenrereereee 245 5 8 2 Opening the AUD Performance Analysis WindoW sssesseeeeeeseeereererrerreree 247 5 8 3 Opening the BUS Performance Analysis Window ssessesseeeseerreererereerrereree 250 3 8 4 Hiding the Column sis csct ecictes sccsvies irescial pi serdecasetunsditanseandensds elu aeoeeeh dace ns 254 5 8 5 Starting Performance Data Acquisition 0 ei ceeeeeseeeseeeeeteeeeeeeseteneteneeseeeaeens 254 5 8 6 Deleting a Measurement Condition 0 0 e
26. 6 8 Setting Registers in the Register window Click the Go button e If program execution is failed reset the device and execute again the procedures above 332 7tENESAS The program runs and then stops at the condition specified under event channel 1 00001038 ai main void long a 10 long j int 13 class Sample p_sam 00001040 while 1 i 0000104c p_sam new Sample 00001056 for i 0 i lt 10 i 0000105e j rand 00001066 ifj lt of o000106a ps sj 0000106 ali j amp 00001084 amp 0000108e p_sam gt change a 00001098 p_sam gt s0 a 0 000010aa p_sam gt sl a 1 o00010be p_sam gt s2 a 2 o00010ce p_sam gt s3 a 3 000010e0 p_sam gt s4 a 4 ooo0010 2 p_sam gt s5 a 5 00001104 p_sam gt s6 a 6 00001116 p_sam gt s al7 00001128 p_sam gt s8 a 8 0000113a p_sam gt s9 a 9 00001146 ii p_sam Figure 6 42 Source Window at Execution Stop Sequential Break 333 RENESAS The Status window displays the following contents SHXXXX EZOOF SYSTEM CPU SH4AL DSP Renesas E Series USB Driver SHXXXX Ready EVENT CONDITION 1 2 Run time count 00h OOmin 00s 007ms 705us O00ns Emulation mode Hardware break disable Endian Big Option Cable Discomnected Not used Bus Board Comnected Option Board Disconnected Platform Events 7 Figure 6 43 Displayed Contents of the Status Window Sequential Break Note The items that can b
27. Channels for Setting Event Conditions Function Bus Window Address Data State Address Branch Bus Bus ASID Condition Condition LDTLB Count Condition Condition Condition Condition Bus Window System Instruction Condition Branch Software Channel Address Data ASID Status address Bus Break Count Trace Trace Action Ch1 oO X 6 oO X X X X X X O IA_OA B and P Ch2 oO oO O O X X X oO X X oO IA_OA_ B and DT_CT P Cho IA 0 X O X X X X xX X X O B and P Ch4 IA 6 X O X X X X X X X O B and P Ch5 OA X X O O oO X X X X X 0 B T and P Ch6 OA X X oO O oO X X X X X 0 B T and P Ch7 X X X X X X O X X X Break LDTLB fixed Ch8 0 X X X X O X X X X O System B T Bus and P Ch9 oO X X X X oO X X X X O System B T Bus and P Ch10 oO X 6 O X X X X X X O IA_OA_ B and R P Ch11 oO O O O X X X O X X 0 IA_OA_ B and DT_CT_ P R 176 7 ENESAS Table 5 2 Channels for Setting Event Conditions cont Function Bus Window Address Data State Address Branch Bus Bus ASID Condition Condition LDTLB Count Condition Condition Condition Condition Bus Window System Instruction Condition Branch Software Channel Address Data ASID Status address Bus Break Count Trace Trace Action Chi2 X X X X X X X X O X 6 Branch B T and P Software X X X X X X X X X oO Trace Trace fixed Notes 1 O Can be set in the dialog box X Cannot be set in the dial
28. Coverage Information in the Editor Window 290 5 12 Synchronizing Multiple Debugging Platforms 20 0 eeeeseeeeeeeeeseeteeeseeeseeeaeeaes 291 5 12 1 Distinguishing Two Emulators 00 eee eeeeseceseeeseeeseseeeceeeeaeeneeeeeeeneeeseeeneeeaaes 292 Section 6 Witoriall 3545 cceiasictoescaidisceseelepcacaaciebsecasteccdidid a EETAS ETS 295 6 1 Introduction serie ipone aa n E E REER E E EENS 295 6 2 Running the High performance Embedded Workshop ssessssessseseesreseeresrerrsrreresrreresrrsreee 296 6 3 Setting Up the mul ators ciscices cise te ceceedts vee seld iedldeteenacctascedleveceessutueedcegssessuaneged denwsesievbansudes 296 6 4 Setting the Configuration Dialog Box eee ceeeceeeeeeeeeeeseeeseeeseeeeeeeeseseaeeeaeenseeags 297 6 5 Checking the Operation of the Target Memory for Downloading eee eee eects 298 6 6 Downloading the Tutorial Program 0 eee eee cece eeeeeeeeeseeeaeceaecceeseesseeeseeeaessaeesaeseeaes 300 6 6 1 Downloading the Tutorial Program ee eee eeseeseeeseeceeeeseeeaeeeaecneeesseeneeeaees 300 6 6 2 Displaying the Source Program eee eecceeeeseeeseeeseseseceseceeeeseeeaeeeseesaeeeseesseesaes 301 6 7 Setting a PC Breakpoint sorier A S E eke eta E ERa 302 6 8 Setting RegistetS innies eeeada cc ceedh sotvueen eoucege E EE NE EEE E EE ES 303 6 9 Executing the Prosramsicaticciscesceecesacescsece drsnsdaccenhsdensoasetacds ckedeedpastdncdont suivehsess Siscbesssdvertentenes 305 6 10 R
29. DebugComp Platform E200F Tutorial Tutorial Debug_SHxxxx_E200F_SYSTEM tutorial abs 7 Memory Save During User Program Execution Do not execute memory save or verifying during user program execution 8 Load of Motorola S type Files This High performance Embedded Workshop does not support Motorola S type files with only the CR code H OD at the end of each record Load Motorola S type files with the CR and LF codes H ODOA at the end of each record 382 RENESAS 9 Note on Register Window Operation During Program Execution The register value cannot be changed in the Register window during program execution Even if the changed value is displayed the register contents are not changed actually 10 Break Function BREAKPOINT cancellation When the contents of the BREAKPOINT address is modified during user program execution the following message is displayed when the user program stops BREAKPOINT IS DELETED A xxxxxxxx If the above message is displayed cancel all BREAKPOINT settings with the Delete All or Disable button in the Eventpoint window 1 _ Number of BREAKPOINT and Stop At Settings in the Run Menu The maximum number of BREAKPOINTs and Stop At settings allowed in the Run menu is 1000 Therefore when 1000 BREAKPOINTS are set specification by Stop At in the Run menu becomes invalid Use the BREAKPOINTs and Stop At in the Run menu with 1000 or less total settings 12 Not
30. Figure 5 41 Sequential AUD Event Dialog Box Don t care Sets no sequential AUD event condition Channel select Specifies the order that the sequential AUD event is satisfied Channel 3 gt 2 After conditions have been matched in the order of AUD event channel 3 gt 2 a sequential AUD event occurs Channel 4 gt 3 gt 2 After conditions have been matched in the order of AUD event channel 4 gt 3 gt 2 a sequential AUD event occurs 197 7 ENESAS Note 198 Sequential reset Action Channel 5 gt 4 gt 3 gt 2 After conditions have been matched in the order of AUD event channel 5 gt 4 gt 3 gt 2 a sequential AUD event occurs Channel 6 gt 5 gt 4 gt 3 gt 2 After conditions have been matched in the order of AUD event channel 6 gt 5 gt 4 gt 3 gt 2 a sequential AUD event occurs Channel 7 gt 6 gt 5 gt 4 gt 3 gt 2 After conditions have been matched in the order of AUD event channel 7 gt 6 gt 5 gt 4 gt 3 gt 2 a sequential AUD event occurs Channel 8 gt 7 gt 6 gt 5 gt 4 gt 3 gt 2 After conditions have been matched in the order of AUD event channel 8 gt 7 gt 6 gt 5 gt 4 gt 3 gt 2 a sequential AUD event occurs Selects whether or not AUD event channel Ch1 is used as the reset point Disable Not used as the reset point Enable Used as the reset point Specif
31. Functions When the optional peripheral I O analyzer function is used for trace acquisition the trace result can be displayed on the same window 2 Useful functions of the Trace window 34 The Trace window provides the following useful functions a Searches for the specified data b Extracts the specified data c Filters and displays again the specified data d Supplements the information from the branch destination address to the next branch source address For the usage of those functions refer to section 5 7 Viewing the Trace Information e Changes the trace settings during user program execution Trace settings can be changed during user program execution 7 ENESAS 1 3 4 Break Function The emulator has the following seven break functions 1 PC break function BREAKPOINT Breaks the program at the specified address by replacing the dedicated instruction onto the original instruction This function cannot be set at a place other than RAM since a memory write occurs This function can be set in the Breakpoint sheet of the Event window It can also be set in the Source or Disassembly window by double clicking on the line to be set in the S W breakpoint column 2 On chip event break function Breaks when the specified event has been detected by the on chip event detection function This function is available when the operation after detecting an event is set as break in the Onchip E
32. HOo0000074 H 00000000 H 000011E0 H0000002C H 00000000 Figure 5 91 Tree Sheet Double clicking a function in the Function column expands or reduces the tree structure display The expansion or reduction is also provided by the or key Double clicking the Address column displays the source program corresponding to the specific address Right clicking on the mouse within the window displays a pop up menu Supported menu options are described in the following e View Source Displays the source program or disassembled memory contents for the address in the selected line e View Profile Chart Displays the Profile Chart window focused on the function in the specified line e Enable Profiler Toggles acquisition profile data When profile data acquisition is active a check mark is shown to the left of the menu text e Not trace the function call Stops tracing function calls while profile data is acquired This menu is used when acquiring profile data of the program in which functions are called in a special way such as task switching in the operating system 261 RENESAS To display the relation of function calls in the Tree sheet of the Profile window acquire profile data without selecting this menu In addition do not select this menu when optimizing the program by the optimizing linkage editor using the acquired profile information file e Find Displays the Find Text
33. Measurement Item Option Note Instruction bus Instruction Number of ICM The number of cache misses performance cont instruction cache by an instruction cache access cont miss the number of accesses to the outside of the CPU core due to a cache miss Number of internal XL The number of accesses for RAM access for the XY memory in the MPU instruction fetch XY during memory accesses of the RAM or L memory opcode O L memory Number of I L ILIF The number of accesses for memory access for the I L memory in the MPU instruction fetch during memory accesses of the opcode Number of U ULF The number of accesses for memory access for the U memory in the MPU instruction fetch during memory accesses of the opcode Operand bus Access Number of memory MR The number of memory performance count access for operand accesses by an operand read fetch READ equal to loading on the operand bus Accesses by the PREF instruction or canceled accesses are not included Number of memory MW The number of memory access for operand accesses by an operand write fetch WRITE equal to storing memory on the operand bus Canceled accesses are not included Number of operand CR The number of operand cache cache access reads during memory access READ read of an operand Number of operand CW The number of operand cache cache access reads during memory access WRITE write of an operand 44 Table 1 4 Measurement Items cont Classification Oper
34. Note The items that can be set in this window differ according to the product For details on the settings for each product refer to the online help e Set the start and end addresses which are in the memory range that outputs the trace result in the Start and End edit boxes of User memory area respectively e Enter the addresses depending on your environment Do not specify the range that the program has been downloaded to as the memory contents are overwritten by the trace output result 350 7 ENESAS b Setting the trace acquisition condition The setting for the acquisition condition of the memory output trace function is the same as that of the internal trace function Refer to section 6 19 1 1 Internal trace function c Displaying the trace result Run the program as shown in the example of section 6 17 1 PC Break Function The trace results are displayed in the Internal AUD Usermemory trace window after the program execution is completed The following is an example of the trace display PTR 000031 000030 000019 000038 000037 000016 000035 000014 000031 000010 000006 000005 000004 000003 000002 000001 000000 D 000015 p 000014 p 000033 D 000012 p 000011 000003 000008 1000007 000006 o0000 1000004 D 000003 p 000003 000001 ESTINATION en DESTINATION BNANCH DESTINATION BRANCH DESTINATION BRANCH DESTINATION BRANCH DESTINATION
35. Personal injury due to electric shock may occur if this product is disassembled and modified e Make sure nothing falls into the cooling fan on the top panel especially liquids metal objects or anything combustible Warning for Installation 9 e Do not set this product in water or areas of high humidity Make sure that the product does not get wet Spilling water or some other liquid into the product may cause unrepairable damage Warning for Use Environment e This equipment is to be used in an environment with a maximum ambient temperature of 35 C Care should be taken that this temperature is not exceeded VIII RENESAS A CAUTION Cautions for AC Adapter Q Use only the AC adapter included in this product package e The included AC adapter is for this emulator Do not use it for other product e The DC plug on the included AC adapter has the below polarity O82 The included AC adapter has no power supply switch The AC adapter is always active while connecting the AC power cable Check if the power is supplied by the LED of AC adapter Cautions to Be Taken for This Product Q Use caution when handling this product Be careful not to apply a mechanical shock e Do not pull the main unit by the probe of the emulation probe or the flexible cable which are connected to this product Excessive flexing or force of the flexible cable for connecting this product to the emulation probe ma
36. Step 8 Dialog Box This is the end of the emulator setting Exit the Project Generator according to the instructions on the screen The High performance Embedded Workshop is activated 5 After the High performance Embedded Workshop has been activated connect the emulator However it is not needed to connect the emulator immediately after the High performance Embedded Workshop has been activated To connect the emulator use one of the methods a and b below For operation during connection refer to section 4 1 System Check 111 7 ENESAS a Connecting the emulator after the setting at emulator activation Select Debug settings from the Options menu to open the Debug Settings dialog box It is possible to register the download module or the command chain that is automatically executed at activation For details on the Debug Settings dialog box refer to section 4 3 Setting at Emulator Activation After the Debug Settings dialog box has been set when the dialog box is closed the emulator is connected b Connecting the emulator without the setting at emulator activation The emulator can be easily connected by switching the session file that the setting for the emulator use has been registered E pe Yow p Belt phe Soup Tem Tout Hite tee Osean ele im In Kae zy z r E z Le ee ee ed We Figure 4 25 Selecting the Session File In the list box that is circled in figure 4 25 select the session fi
37. Variables The user can display local variables in a function using the Locals window For example we will examine the local variables in the main function which declares four local variables a j i and p_sam e Select Locals from the Symbol submenu of the View menu The Locals window is displayed The Locals window shows the local variables in the function currently pointed to by the program counter along with their values Note however that the Locals window is initially empty because local variables are yet to be declared Locals Name Ox0000ffcO lone 10 H 000020da R4 lone H 0000000a R14 iint Ox000053d8 R13 class Sample Figure 6 22 Locals Window e Click mark at the left side of array a in the Locals window to display the elements e Refer to the elements of array a before and after the execution of the sort function and confirm that random data is sorted in descending order 315 RENESAS 6 15 Stepping Through a Program The High performance Embedded Workshop provides a range of step menu commands that allow efficient program debugging Table 6 1 Step Option Menu Description Command Step In Executes each statement including statements within functions Step Over Executes a function call in a single step Step Out Steps out of a function and stops at the statement following the statement in the program that called the functio
38. an AC power cable which complies with the safety standard of the country e Do not touch the plug of the AC power cable when your hands are wet This may cause electric shock e This product is connected signal ground with frame ground If your developing product is transformless not having isolation transformer of AC power this may cause electric shock Also this may give an unrepairable damage to this product and your developing one While developing connect AC power of the product to commercial power through isolation transformer in order to avoid these dangers e If other equipment is connected to the same branch circuit care should be taken not to overload the circuit Refer to nameplate for electrical ratings e When installing this equipment insure that a reliable ground connection is maintained RENESAS VII A WARNING amp e If you smell a strange odor hear an unusual sound or see smoke coming from this product then disconnect power immediately by unplugging the AC power cable from the outlet Do not use this as it is because of the danger of electric shock and or fire In this case contact your local distributor e When installing or connecting this product with other equipment shut down AC power or disconnect the AC power cord from the equipment to prevent personal injury or damage to the equipment Warnings to Be Taken for This Product Q e Do not disassemble or modify this product
39. depending on the product Replace the address used in this section with upper 16 bits of the actually loaded address Example Although the PC address is H 0000006c in the manual enter H OCOOxxxx when the loaded address of Tutorial abs is H 0C00006c upper bit H 0000 is changed to H 0C00 295 7 ENESAS 6 2 Running the High performance Embedded Workshop To run the High performance Embedded Workshop refer to section 4 1 System Check 6 3 Setting up the Emulator The clocks which are used for data communications must be set up on the emulator before the program is downloaded e AUD clock A clock used in acquiring AUD traces If its frequency is set too low complete data may not be acquired during realtime tracing Set the frequency not to exceed the upper limit for the MPU s AUD clock The AUD clock is only needed for using emulators that have an AUD trace function e JTAG H UDD clock TCK A communication clock used except for acquiring AUD trace If its frequency is set too low the speed of downloading will be lowered Set the frequency not to exceed the upper limit for the MPU s guaranteed TCK range For details of the limitations on both clocks refer to section 2 2 2 Notes on Using the JTAG H UDI Clock TCK and AUD Clock AUDCK in the additional document Supplementary Information on Using the SHxxxx The following is a description of the procedure used to set the clocks 296 RENESAS 6 4 Setting th
40. dialog box to find a character string in the Function column Search is started by inputting a character string to be found in the edit box and clicking Find Next or pressing the Enter key e Find Data Displays the Find Data dialog box Find Data 2 x end dd fess Cancel Find Data Maximum C Minimum Figure 5 92 Find Data Dialog Box By selecting the column to be searched in the Column combo box and the search type in the Find Data group and entering Find Next button or Enter key search is started If the Find Next button or the Enter key is input repeatedly the second larger data the second smaller data when the Minimum is specified is searched for e Clear Data Clears the number of times functions are called and profile data Data in the List sheet of the Profile window and the data in the Profile Chart window are also cleared e Output Profile Information Files Displays the Save Profile Information Files dialog box Profiling results are saved in a profile information file pro extension The optimizing linkage editor optimizes user programs according to the profile information in this file For details of the optimization using the profile information refer to the manual of the optimizing linkage editor Note If profile information has been acquired by choosing the Not trace the function call menu the program cannot be optimized by the optimizing linkage editor 2
41. e LDTLB instruction execution e Branch condition e Software trace condition e Event count condition Note The PC value when executing the Trace function and the contents of the specified general register are acquired by trace this function is hereafter called as the software trace function 24 RENESAS For an operation when an event is detected break internal trace acquisition acquisition start acquisition stop or internal performance measurement start end can be specified This function can be set in the Onchip Event sheet of the Event window b AUD event function AUD Event This is a function that sets eventpoints according to the information output from the AUD interface There are eight event detection channels The eventpoints can be defined as a combination of one or more of the following e Branch trace data condition e Window trace data condition e System bus trace data condition e Software trace data condition e Event count condition e Delay condition after an event has occurred For an operation when an event is detected break AUD trace acquisition acquisition start acquisition stop or AUD performance measurement start end can be specified This function can be set in the AUD Event sheet of the Event window Notes 1 When a break is generated by detecting the AUD event there is a delay of several cycles from the time of detection to the break If the delay from the generation of an event to
42. e Since the SDRAM is used the bus controller must be set e Set the options on the Loading flash memory page in the Configuration dialog box as follows RENESAS 365 Configuration General Main Board Loading flash memory Loading flash memory Disable Erasing flash memory Disable Enable File name Ic Hew3 Tools Renesas De Browse Bus width of flash memory 32 bit bus width v Flash memory erasing time D 3 minute Entry point All erasing module address H ocoo 000 Writing module address H ocoo 100 Cancel Apply Figure 6 64 Loading flash memory Page Notes 1 When the data has already been written in the flash memory be sure to select Enable for Erasing flash memory If Disable is selected a verify error occurs 2 When Erasing flash memory is selected it takes about one minute to erase the flash memory in this example e Select the object for downloading to the flash memory area 366 RENESAS 6 23 What Next This tutorial has described the major features of the emulator and the use of the High performance Embedded Workshop Sophisticated debugging can be carried out by using the emulation functions that the emulator offers This provides for effective investigation of hardware and software problems by accurately isolating and identifying the conditions under which such problems arise 367 7 ENESAS 368 ENESAS 1 2 3 Section 7 Troubleshooting
43. eseeseeeseceseceseseeeteeeaeseaeenaeees 275 5103 Starting Measurements csiv vs sce irene oas ER EEEE TETE ete caret 276 5 10 4 Clearing Measurement Result eee cece cee ceeeeseeeeeeseeeaeeenesenetseenaeenaeenaeees 276 5 10 5 Deleting Measurement Range eee ee ceseceeeeceeeeeeeeeeseeeaesseeseeeseeeeeenaeens 276 5 10 6 Setting the Minimum Unit of the Measurement Time eect etree 276 Acquiring Code Coverages scsscciiecuvckscteisediends siceee E EEEE E EES RRENEN EA 278 5 11 1 Opening the Code Coverage WindoW sessesesssseesssseessresrnsrsrrsrrsrrnrenresresresreee 278 5 11 2 Displaying a Source Filesricnsccnsirnnesn a E 283 5 11 3 Changing the Address to be Displayed sssessesesseessseesesresresrrsrsrensrsresresresresrsee 283 5 11 4 Changing the Coverage Range to be Displayed ee eee eee eeeeeeeeeneeeneees 284 5 11 5 Clearing the Coverage Information 0 eee eee eee eeeeseeeseeeseceseeeseseeesseeeseeeaeees 286 5 11 6 Saving the Coverage Information to a File 2 eee eeeeseeeeseeeteeeeeeeeeeeneees 286 5 11 7 Loading Coverage Information from a File 00 ee eee eeeeseeeseeeeeteeeeeseeseeeaeees 287 5 11 8 Updating Coverage Information 0 0 0 ee eee ese ceeeseeeseeeseeeseseseceseseeesseeeseeeatens 287 5 11 9 Preventing Update of Coverage Information ou eeeeeeseeeseeeeeteseteeeeeeeeaeees 287 RENESAS 5 11 10 Confirmation Request Dialog BOX lees ese eeseceseseeeeseeesseeaeeeaeeeseeeneesaes 288 5 11 11 Displaying Code
44. for k 0 k lt gap kt 00002044 for i kt gap i lt 10 i i gap 00002050 for j i gap j gt k j j gap 00002058 if a lj gt a j gap i 00002070 t alj 0000207a ali a j gap o000208e l alitgap t else break 00002 0ae gap gap 2 000020c4 void Sample ichange long a long tmp 10 Figure 6 60 Source Window PC Breakpoint Setting 359 RENESAS e Set the same program counter and stack pointer values PC H 00000800 and R15 H 00010000 as were set in section 6 8 Setting Registers again use the Register window Click the Go button e If program execution is failed reset the device and execute again the procedures above e After the break in program execution select Stack Trace from the Code submenu of the View menu to open the Stack Trace window StackTrace 0x0000108e Ox00000824 Ox00000824 Ox00000824 Ox00000824 Ox00000824 Ox00000824 Ox00000824 PowerON_Reset_PCf PowerON_Reset_PC PowerON_Reset_PC PowerON_Reset_PC PowerON_Reset_PC PowerON_Reset_PC PowerON_Reset_PCf JE I EA Figure 6 61 Stack Trace Window mrar a e ee ee e F F F F F F F F Figure 6 61 shows that the position of the program counter is currently at the selected line of the sort function and that the sort function is called from the main function To remove the PC breakpoint double click the Source column in the sort
45. for Event Condition 8 9 An event condition must be set for Ch8 and Chg SystemBus Expands the SystemBus Sequential Extend page Extend The sequential setting is enabled with any combination For details refer to Sequential Break Extension Setting in this section 179 7 ENESAS Sequential Break Extension Setting Sequential setting CPU Sequential Event SystemBus Sequential Event CPU Sequential Extend Chi AOA PreHit Channel Ch2A OA DT_CT CPU Match flag Match flag set gt 1 z Ch2 A_OA_DT_CT PreHit Channel No Select x CPU Match flag No Select z Ch3t1A PreHit Channel No Select bal CPU Match flag No Select x ChA PreHit Channel CPU Match flag CPU Match flag Match flagset gt o Chs OA PreHit Channel No Select CPU Match flag No Select ba CHECOA PreHit Channel No Select CPU Match flag No Se ha Chi OQA OA R PreHit Channel Ch4 1A CPU Match flag Ch110A OA DT_CT_R PreHit Channel No Select CPU Match flag Chl 2 Branch PreHit Channel No Select Figure 5 30 CPU Sequential Extend Page a Indicates the channel name for setting conditions b Selects a condition that is satisfied before the channel which sets up conditions When a channel name is selected it is required that the condition of the channel selected here must have already been satisfied When CPU Match flag is selected the CPU match flag must be set When a condition is selected by the channel selected her
46. input Sets other value than that has been set for the single address or address range as the condition 7 ENESAS 201 2 Data page Specifies the data bus condition Ch2 Delay Address Data Interrupt Count Delay Action Data Read Write C Read C Write H 0000 Outside Figure 5 44 Chx Delay Dialog Box Data Page Data Sets the data condition Don t care Sets no data condition Read Write Sets the read or write cycle as the condition Read Sets the read cycle as the condition Write Sets the write cycle as the condition Value Sets the data bus value mask data can be input Outside Sets other value than that has been set for Value as the condition 202 RENESAS 3 Interrupt page Specifies the signal conditions of NMI and external interrupts Ch2 Delay Address Data Interrupt Count Delay Action IRQI IRQ2 IRQ3 Don t care Don t care Don t care Don t care High High High High C Low C Low C Low C Low IRO4 IRQS IRQ IRQ Don t care Don t care Don t care Don t care High High High High C Low C Low C Low C Low Figure 5 45 Chx Delay Dialog Box Interrupt Page Don t care Sets no signal condition High Satisfies a condition when the signal is high Low Satisfies a condition when the signal is low Note The external interrupt signal d
47. j rand AAA a be ali ji p_sam gt sort a p_sam gt change a p sam gt s0 a 0 000 p_sam gt sl al 1 p_sam gt s2 a 2 p_sam gt s3 a 3 p_sam gt s4 a 4 p_sam gt s5 a 5 p_sam gt s6 a 6 p_sam gt s al p_sam gt s8 a 8 p_sam gt s9 a 9 delete p_sam Hi abort void Figure 6 34 Source Window at Execution Stop PC Break ENESAS The Status window displays the following contents SHXXXX EZOOF SYSTEM CPU SH4AL DSP Renesas E Series USB Driver SHXXXX Ready BREAK POINT 00h OOmin 00s O10ms 067us 300ns Run time count Emulation mode Hardware break disable Endian Big Option Cable Disconnected Not used Connected Bus Board Option Board Disconnected Platform A Events Figure 6 35 Displayed Contents of the Status Window PC Break Note The items that can be displayed in this window differ according to the product For the items that can be displayed refer to the online help 325 RENESAS 6 18 Break Function by an Eventpoint With this emulator an Onchip Eventpoint AUD Eventpoint Other Eventpoint and BUS Eventpoint can be set An example of how to set a break using an Onchip Eventpoint is shown below For other eventpoint setting methods refer to section 5 6 Using the Eventpoints 6 18 1 Setting the Break by an Onchip Eventpoint A method is given below in which the address bus condition is set under event channel 1 Ch1 I
48. main unit case b Peripheral I O analyzer Marked ANALYZER I F This is a connector for the peripheral unit connector T O analyzer unit Be sure to connect this connector to the dedicated analyzer cable provided for the optional peripheral I O analyzer unit c Trace unit connector Marked TRACE I F This is a connector for the trace unit Be sure to connect this connector to the dedicated trace cable provided for the optional trace unit RENESAS Emulator Left side View Figure 1 8 Emulator Left side View a Label for product The serial number revision and safety standard etc of the management emulator are written to The contents differ depending on the time when you purchased the product RENESAS 36 pin Probe Head Upper View ROE0200FOEMU00 Gl Z i h Figure 1 9 36 pin Probe Head Upper View ROEO200FOEMU00 a Screws for fastening the These screws fasten the user system and the probe head probe head 7 ENESAS 36 pin Probe Head Front View ROE0200FOEMU00 Figure 1 10 36 pin Probe Head Front View ROEO200FOEMU00 a H UDI port connector This connector is used when the emulator is used as the on chip 36 pins for user system debugger the same as that of the 36 pin ELOA USB 7 ENESAS 38 pin Probe Head Upper View ROE0200F2EMU00 Figure 1 11 38 pin Probe Head Upper View ROE0200F2EMU00 7 ENESAS 38 pin Probe Head Front View ROE0200F2EMU00 Figure
49. manually locate the file 5 2 1 Downloading a Program A load module to be debugged must be downloaded To download a program select the load module from Debug gt Download or select Download from the popup menu opened by clicking the right hand mouse button on the load module in Download modules of the Workspace window Notes 1 Before downloading a program it must be registered to the High performance Embedded Workshop as a load module For registration refer to section 4 3 Setting at Emulator Activation 2 When a program is downloaded to the external RAM the bus controller must be initially set in the area for downloading Especially check that the initialization of SDRAM or the setting of the bus width is appropriate for the user system 148 7 ENESAS 5 2 2 Viewing the Source Code Select your source file and click the Open button to make the High performance Embedded Workshop open the file in the integrated editor It is also possible to display your source files by double clicking on them in the Workspace window tutorial cpp Line Source A O A B S Source extern C endif void abort void ifdef __cplusplus endif ttinclude sort h finclude lt stdlib h gt 00001038 a main void long a 10 long j int i class Sample p_sam 00001040 while 1 0000104c p_sam new Sample 00001056 for i 0 i lt 10 i 0000105e j rand 00001066 if lt OM 0
50. menu option from the pop up menu The Save Profile Information Files dialog box is displayed Pressing the Save button after selecting a file name will write the profile information to the selected file Pressing the Save All button will write the profile information to all of the profile information files Save Profile Information Files Profile Information files Profile Information files C Hew3 Sample Sample pro Save All Browse Figure 5 94 Save Profile Information Files Dialog Box 265 7 ENESAS 5 9 12 Notes 1 Tolerances The profiling function internally breaks user program execution collects the measured data and re executes the user program Since the function also counts when the measured item is generated at break or re execution tolerances will be included in the measured profile value The measured value of this function should be the reference 2 Functions that cannot be used while the profiling function is being used a On chip performance analysis function The on chip performance analysis function cannot be used when the profiling function is enabled b Step function When the profiling function is enabled do not use the step function The profile data cannot be measured correctly c Internal trace function When the profiling function is enabled it is invalid to select the internal trace mode as all items of the internal trace mode are internally selected Do not use the intern
51. modules Such modules differ depending on the MPU Emulator functions can be changed by each debugging phase Various command line functions can be used Realtime emulation Realtime emulation of the user system is enabled at the maximum operating frequency of the CPU Excellent operability Using the High performance Embedded Workshop on the Microsoft Windows 2000 and Microsoft Windows XP operating systems enables user program debugging using a pointing device such as a mouse The High performance Embedded Workshop enables high speed downloading of load module files Debugging of the user system in the final development stage The user system can be debugged under conditions similar to the actual application conditions Compact debugging environment When the emulator is used a laptop computer can be used as a host machine creating a debugging environment in any place RENESAS CAUTION READ the following warnings before using the emulator product Incorrect operation will damage the user system and the emulator product The USER PROGRAM will be LOST 1 Check all components against the component list after unpacking the emulator 2 Never place heavy objects on the casing 3 Protect the emulator from excessive impacts and stresses For details refer to section 1 4 Environmental Conditions 4 When moving the host machine or user system take care not to vibrate or damage it 5 After conn
52. needed when instructions other than those compatible with SH4 are output When a specific instruction is executed the PC value at execution and the contents of one general register are acquired by trace Describe the Trace x function x is a variable name to be compiled and linked beforehand For details refer to the SuperH RISC engine C C Compiler Assembler Optimizing Linkage Editor User s Manual When the load module is downloaded on the emulator and is executed while a software trace function is valid the PC value that has executed the Trace x function the general register value for x and the source lines are displayed To activate the software trace function select the Acquire Software trace radio button in the Software trace dialog box that is opened by double clicking on the software Trace column of the Event window Note To cancel settings select the Don t care radio button in the Software trace dialog box or select Delete from the popup menu that is opened by clicking on the software Trace column with the right mouse button System Bus Access Trace Function This function can be set with Ch8 or Ch9 of the Event window The information on the system bus in the MPU can be acquired Display Contents When the program breaks the following trace results are displayed in the Trace window e PTR The trace buffer pointer 0 from the last instruction to have been executed e IP Indicates the number o
53. of the Watch window 161 RENESAS 162 l L a R R R R R R R R R R ps R t AAA AAAAAAA 00010000 H 2284e840 H 0e98e253 H OchOe41la H d6f7bdb3 0001000 H 40a0688a 00010010 00010000 H a febblz 00010014 00010004 00010008 H 501b4836 00010018 H aeeScb27 oo001001 H 20a00428 00010020 H bOfeadSe 00010024 Ox00000000 R13 00000000 H 00000800 H 00010000 H 0000083e H 00010000 oooo0000 H O000008 5c 00000010 00000000 H o0000868 00000014 00000004 ooo000008 H e476b06f 00000018 H 80300020 oooo000ic H c6ic88fa 00000020 H 8100400d 00000024 Watch2 A Watch3 A Watch Figure 5 20 Watch Window 7 ENESAS The R mark shows that the value of the variable can be updated during user program execution For reading of memory and updating of the content of the variable that has been registered in the Watch window during execution of the user program there are following two methods 1 Use the monitoring function without halting the user program The value of the variable is updated by using the monitoring function of the emulator 2 Temporarily stops the user program and reads the memory contents to update the value Note The realtime operation is disabled because the user program is stopped temporarily It is possible to recognize the method for updating the value during execution of the user program
54. or the Go button on the toolbar Figure 6 29 Go Button e The program goes into an endless loop To force a break in execution select Halt from the Debug menu or the Stop button on the toolbar Figure 6 30 Stop Button 320 RENESAS 6 17 Break Function The emulator has PC break functions and break functions by eventpoints With the High performance Embedded Workshop a PC breakpoint can be set using the Breakpoint sheet of the Event window The eventpoint condition setting can be set by the event type using the Onchip Event AUD Event Other Event and BUS Event sheets An overview and setting of the break function are described below 6 17 1 PC Break Function The emulator can set up to 1000 PC breakpoints Other methods for setting a PC breakpoint than in section 6 7 Setting a PC Breakpoint are described below e Select Eventpoints from the Code submenu of the View menu The Event window is displayed e Select the Breakpoint sheet wt Event tyme state condition ction OE lt gt Breakpoint A Onchip Event A AUD Event A Other Event A BUS Event Figure 6 31 Event Window Before PC Breakpoint Setting 321 7 ENESAS e Click the Event window with the right hand mouse button and select Add from the popup menu e Enter H 00001098 in the Address edit box Address Address Value Hoon 098 Physical space Virtual space ASID po Orce
55. select Initialize from the popup menu in the Performance Analysis window or specify INIT with the PERFORMANCE_ANALYSIS command 49 7 ENESAS 2 AUD Performance Analysis Function AUD Performance Analysis The emulator allows you to measure the time or count of execution between specified events in the AUD event detection system It is possible to set the resolution of the timer to any of the following values 20 ns 40 ns 100 ns or 400 ns At 20 ns the maximum time that can be measured is about six hours and at 400 ns the maximum time is about five days 3 External Bus Performance Analysis Function BUS Performance Analysis The emulator allows you to measure the time or count of execution between specified start and end conditions It is possible to set the resolution of the timer to any of the following values 20 ns 50 ns or 400 ns At 20 ns the maximum time that can be measured is about six hours and at 400 ns the maximum time is about five days 4 Profiling Function Profile The profiling function is used to measure the performance of each function A function having low performance can be easily found if the statistics of the time for each function are maintained Items that can be measured are the same as those for the on chip performance measurement function Notes 1 Use of the profiling and on chip performance analysis functions at the same time is not possible The Can not use this function error
56. the Code Coverage window Go To Address Address Cancel Figure 5 109 Go To Address Dialog Box 283 7 ENESAS 5 11 4 Changing the Coverage Range to be Displayed e When the coverage range for display has been specified by address Selecting Set Range from the popup menu opens the Coverage Display Range dialog box which allows the user to change the condition for acquisition of information on executed instructions Coverage Display Range Start Address H 002000 x End address H0020FF x ae File gt Browse Figure 5 110 Coverage Display Range Dialog Box The following items can be specified Start Address Start address in hexadecimal when the prefix is omitted End Address End address in hexadecimal when the prefix is omitted Clicking the OK button changes the coverage range to be displayed 284 7 ENESAS e When the coverage range for display has been specified by a source file Selecting Set Range from the popup menu opens the Coverage Display Range dialog box which allows the user to change the condition for acquisition of information on executed instructions Coverage Display Range End address T Cancel File Tutorial Source SORT CPP gt Browse Figure 5 111 Coverage Display Range Dialog Box Specifying a Source File The following item can be specified File Specifies a source file that has C or CPP as its file type name fro
57. the program counter to H 00000800 in this tutorial program and click the OK button PG Set Value Value fooooosoo Radix Hex z Set Asi Whole Resister H Figure 6 8 Register Dialog Box PC e Change the value of the stack pointer SP in the same way Set H 00010000 for the value of the stack pointer in this tutorial program R15 Set Value Value Radix Set As nole Reister x E Figure 6 9 Register Dialog Box R15 304 1RENESAS 6 9 Executing the Program Execute the program as described in the following e To execute the program select Go from the Debug menu or click the Go button on the toolbar Figure 6 10 Go Button When the program execution is started RUNNING is displayed on the status bar and then the executed PC address is displayed The program will be executed up to the breakpoint that has been set and an arrow will be displayed in the Source column to show the position that the program has halted with the message BREAKPOINT in the status bar Notes 1 When the source file is displayed after a break a path of the source file may be inquired The location of the source file is as follows lt Drive where the OS has been installed gt Workspace Tutorial E200F xxxx Tutorial source 2 If program execution is failed select Reset CPU from the Debug menu reset the device and restart the procedure from figure 6 8 305 RENESAS 0x0000103
58. this window and then select Edit from the popup menu to display the Breakpoint dialog box Breakpoint Address Address Value H0 C Physical space Virtual space ASID oo oree Figure 5 27 Breakpoint Dialog Box This dialog box specifies address conditions of PC breakpoints A breakpoint address to be set is specified in the Value edit box The PC register can also be specified such as PC Up to 1000 breakpoints can be specified The contents to be set differ depending on the product For details refer to the on line help for each product When Value is selected if an overloaded function or class name including a member function is specified in address the Select Function dialog box opens Clicking the OK button sets the specified breakpoint conditions Clicking the Cancel button closes this dialog box without setting the break conditions 172 RENESAS 5 6 5 Setting Onchip Eventpoints On the Onchip Event sheet the settings for Onchip Eventpoints are displayed and modified w Event Disable None Disable None Disable None Enable Address H 00000000 pc Disable None Disable None Disable None Enable Address H 00000000 x initiator H 22 byte access Disable None Disable None Disable None Enable general enable subroutine enable exception enable Software Trace Disable None 4 gt f Breakpoint A Onchip Event A AUD Event A Other Event A BUS Event f Fig
59. to the product For the items that can be displayed refer to the online help 307 RENESAS 6 10 Reviewing Breakpoints The user can see all the breakpoints set in the program in the Event window e Select Eventpoints from the Code submenu of the View menu The Event window is displayed Select the Breakpoint sheet Event tye state condition ction Breakpoint Enable Address H 00001084 tutorial cpp 45 Physical space BUS Event Figure 6 13 Event Window The popup menu opened by clicking the Event window with the right hand mouse button allows the user to set or change breakpoints define new breakpoints and delete enable or disable breakpoints 308 7 ENESAS 6 11 Referring to Symbols The Label window can be used to display the information on symbols in modules Select Label from the Symbol submenu of the View menu The Label window is displayed so that the user can refer to the addresses of symbols in modules By X AE BP Address 00000000 RESET Vectors 00000010 INT Vectors O000044E zerodiv 00000800 PowerON Reset PC O000082C Manual Reset PC 00000844 INT Illegal code 00000848 Dummy 00001000 sbrk 00001024 main 00001088 abort 000010D0 INITSCT 000010E4 loopl 000010EC loop2 000010F0 next _loop2 000010F4 next_loopl 00001100 loops 00001104 loop4 00001110 next _loop4 00001114 next loops 00001128 bsec_top O00011l2zCc bsec_end __ Figure 6 14 L
60. trace information Software trace data Sets the eventpoint condition according to the software trace information SystemBus trace data Sets the eventpoint condition according to the system bus trace information 184 RENESAS 2 Branch page Specifies the type and address conditions of the branch trace Ch2 Delay General Branch Count Delay Action Branch type Source Destination Source Destination r Address Don t care C Address Range Start Hooo00000 End fHoo000000 Outside omes Figure 5 34 Chx Delay Dialog Box Branch Page Branch type Sets branch types Source Destination Sets no branch type Source Sets the branch source address condition Destination Sets the branch destination address condition Address Sets address conditions Don t care Sets no address condition Address Sets the single address Range Sets the address range 185 RENESAS Start Sets the single address or the start address of the address range End Sets the end address of the address range Outside Sets other value than that has been set for the single address or address range as the condition Notes 1 This page is only displayed when Branch trace data is specified on the General page 2 The address range can only be specified for AUD event channels Ch1 and Ch2 3 The mask address can be input for Start when the single address is s
61. using the flash memory download function The following are notes on downloading to the flash memory When the flash memory download is enabled downloading to areas other than the flash memory area is disabled Downloading is only enabled to the flash memory area Perform memory write or PC break only to the RAM area When the flash memory erase is enabled the Stop button cannot stop erasing 363 7 ENESAS The area for the write and erase modules must be set in an MMU disabled space e Anexample of downloading to the flash memory The following is an example of downloading to the flash memory manufactured by Intel Corporation type number G28F640J5 150 that has been connected as shown in figure 6 63 A sample is provided in the Fmtool folder in the installation destination folder Create a program that suits the user specifications by referring to this sample Table 6 5 Board Specifications Item Contents SDRAM address H 0C000000 to H OFFFFFFF Flash memory address H 00000000 to H 01 FFFFFF Bus width of flash memory 32 bits Operating environment Endian Big endian Flash memory SHxxxx FIA bus buffer 32 Mbytes FIA bus buffer FD bus buffer Figure 6 63 Flash Memory Wiring 364 ENESAS Table 6 6 Sample Program Specifications Item Contents RAM area to be used H 0C001000 to H 0C0015BF Write module start address H 0C001100 Erase module start address H 0C001000
62. with the right hand mouse button The Sequential setting dialog box will open Sequential setting CPU Sequential Event SystemBus Sequential Event I Don t care M Chi gt 5 chil gt 10 C Many Channel Sequential Ch3 gt 2 C Ch4 C Chid gt 6 3 C Chil gt 10 gt 655 gt 4 gt 3 GPU Extend Figure 6 40 Sequential setting Dialog Box Note The items that can be displayed in this dialog box differ according to the product For the items that can be displayed refer to the online help 331 7 ENESAS e Select the 2 Channel Sequential radio button and Channel 2 gt 1 and click the OK button When the setting is completed the Event window will be as shown in figure 6 41 w Event Enable Address H 0000106c tutorial cpp 43 pe Sequential Break Enable Address H 00001084 tutorial cpp 45 pe Sequential Break Disable None Disable None Disable None Disable None Disable None Disable None Disable None Disable None Disable None Enable general enable subroutine enable exception enable software Trace Disable None no Breakpoint A Onchip Event A AUD Event Other Event A BUS Event Figure 6 41 Onchip Event Sheet Note The items that can be displayed in this dialog box differ according to the product For the items that can be displayed refer to the online help e Set the program counter and stack pointer values PC H 00000800 and R15 H 00010000 that were set in section
63. 0 H OOOO11EO H o000002C H o0001180 H oo000060 H 00001130 H 00000028 H o00010C8 H o0000000 H 00001024 H o0000008C H o00001000 H o00000024 _malloc _free _rand operator newfunsigned long __ CALL INIT __INITSCT main Cie ie ie ie ie ie ie ie ie ia ie E ooo c 0c OD OOGO OR O O O qG O O O OGG amp 0 GOGE Figure 5 90 List Sheet Clicking the column header sorts the items in an alphabetical or ascending order Double clicking the Function Variable or Address column displays the source program corresponding to the address in the line Right clicking on the mouse within the window displays a pop up menu For details on this pop up menu refer to section 5 9 8 Tree Sheet 260 1RENESAS 5 9 8 Tree Sheet This sheet displays the relation of function calls along with the profile data that are values when the function is called This sheet is available when Disable Tree Not traces function call is not selected from the pop up menu in the Profile window Profile Function tress Size Stack Size Times Option GC Hew3 Tools Renesas DebugComp Platfo _PowerON_Reset_PC Hoo000800 H ooo0002C H 00000000 _INITSCT H 000010C8 H o0000000 H o0000000 _CALL_INIT H 00001130 H o0000028 H o0000000 H 00001024 Sample Sample H 00002000 H0000002E H00000000 operator newdunsigned long H 00001180 HO00000060 H 00000000 malloc H 000012B0 H o0000000 H oo000000 Sample sort lone Ho0000202E
64. 00 Figure 5 77 Performance Analysis Window Onchip Performance The Onchip Performance Analysis function does not affect the realtime operation because it uses the performance measurement function in the MPU 245 7 ENESAS Note The measurement conditions and the number of channels for the on chip performance analysis function differ depending on the product The time measurement continues even if a break occurs before execution reaches the measurement stop address after passing the measurement start address of the AUD performance function When a measurement channel is double clicked or selected and Set is selected from the popup menu in this window the Performance Analysis dialog box is opened and measurement conditions can be modified Performance Analy Condition Cycle Selection of a count item CPU performance Cycle Count Instruction Branch Exception interruption C Stalled Cycle C TLB performance C Instruction bus performance Operand bus performance C Access count C Access miss count C Waited cycle C System bus performance Extend counter I Enable omes Figure 5 78 Performance Analysis Dialog Box For details on the Performance Analysis dialog box refer to the online help for each product 246 RENESAS 5 8 2 Opening the AUD Performance Analysis Window To open the AUD Performance Analysis window choose View
65. 000003 D 000003 OOOOFFDS OO003EAD 000002 D 000002 OOOOFFDC 00004D1D 000001 D 000001 0000FFE0 00002F54 000000 D 000000 OOOOFFE4 oo002z0DA Figure 5 57 Internal AUD Usermemory trace Window AUD Trace This window displays the following trace information items some of this information will not be displayed in some products PTR The AUD trace buffer pointer 0 for the last executed instruction IP The amount of acquired trace information Type Type of trace information BRANCH Branch source DESTINATION Branch destination MEMORY Memory access S_TRACE Executed Trace x function LOST Lost trace information only in the realtime mode Bus The bus which was being accessed 218 RENESAS R W Whether the generated data is associated with read or write access Address Address Data The data of the generated data access When Type is S_TRACE value x a variable of function Trace x is displayed PPC3 Internal performance counter Ch3 output PPC4 Internal performance counter Ch4 output Instruction Instruction mnemonic Probe State of the input probe Timestamp Time stamp value Source The C C or assembly language source program Label Label information Timestamp Difference Difference value of the time stamp Note Since the displayed contents differ depending on the product refer to each product s online help Some MPUs supported may not have the AUD trace function 3 Acquiri
66. 00010643 j j 00001060 o E 00001084 p_sam gt sort a 0000108e p_sam gt change a 00001098 p_sam gt s0 a 0 000010aa p_sam gt sl a 1 000010bc p_sam gt s2 a 2 000010ce p_sam gt s3 a 3 000010e0 p_sam gt s4 a 4 000010f2 p_sam gt s5 a 5 00001104 p_sam gt s6 a 6 NNANANIIIR n sam gt Se al71 Figure 5 10 Source Window 149 RENESAS In this window the following items are shown on the left as line information The first column Source address column Address information The second column Onchip event column On chip event information The third column AUD event column AUD event information The fourth column BUS event column External bus event information The fifth column CodeCoverage column Coverage information The sixth column S W breakpoint column PC bookmark and breakpoint information Note When the trace unit is not connected to the emulator the BUS event column is not displayed Source address column When a program is downloaded an address for the current source file is displayed on the Source address column These addresses are helpful when setting the PC value or breakpoints Onchip event column The Onchip event column displays the following item An address condition for the on chip event is set The number of address conditions that can be set is the same as that of on chip event channels at which the address condition can be set The bitmap s
67. 01 EDIT Dialog Box When the expansion profiling unit is connected to the emulator it is possible to measure the profile information within the 6 Mbyte ranges in total When the expansion profiling unit is not connected to the emulator it is possible to measure the profile information within the 2 Mbyte ranges in total In the emulator 512 Kbytes are considered as a unit to acquire the profiling information on all the functions in the eight block areas Addresses to be specified for each block need not be adjacent When the expansion profiling unit is connected to the emulator 16 blocks of 512 Kbytes are added and the 24 block areas can be measured in total The measured data in each block is displayed on each page of the Realtime Profile window To switch the page to be displayed select that page and click the OK button in the Select Page dialog box that is opened by selecting Select Page from the popup menu of the Realtime Profile window 275 RENESAS Select Page Page 1 5 Page Information JOU E F OOOBFFFF H H 000C0000 H 000F FF FF Page5 H 00100000 H 0013FFFF omes Figure 5 102 Select Page Dialog Box 5 10 3 Starting Measurement When the user program is executed measurement is started When the user program is halted the measurement result is displayed in the Realtime Profile window 5 10 4 Clearing Measurement Result Selecting Clear Data from the popup menu clears the measurement result of
68. 1 12 38 pin Probe Head Front View ROE0200F2EMU00 a H UDI port connector This connector is used when the emulator is used as the on chip 38 pins for user system debugger the same as that of the 38 pin E10A USB 7 ENESAS Storing the Probe Head 7tENESAS Figure 1 13 Storing the Probe Head ROEO200FOEMU00 a Base unit for placing the A base unit when the emulator is placed vertically The probe head emulator vertically can be stored when the emulator is not in use RENESAS Trace Unit Optional Upper View Figure 1 14 Trace Unit Optional Upper View a Trace cable connectors Connectors for connecting the trace cable in the trace board Be sure to use the provided trace cable 2ENESAS Trace Unit Optional Rear View j lo 4 T Figure 1 15 Trace Unit Optional Rear View a User interface connectors Connectors for the user interface of the external bus trace They for the external bus trace are connected to the dedicated connector on the user system zRENESAS Expansion Profiling Unit Optional Rear View Figure 1 16 Expansion Profiling Unit Optional Rear View a Optional connectors in the Connectors for the interface to connect the expansion profiling expansion profiling unit unit and the main unit case They are connected to the optional connector on the main unit case 7 ENESAS 1 3 Emulator Functions This section describes the emulator functions They differ according to
69. 125 Vcc 74AVCA16245 AUDSYNC 74LVC2G125 Vcc 74AVCA16245 74LVC2G125 AUDRST 74LVC2G125 Vcc AY Figure 3 2 Interface Circuits in the Emulator 36 pin Interface for AUD 85 7 ENESAS User connector Emulator control circuit 38 pins AVCA164245 AVCA164245 74LVC2G125 RESET ASEBRKAK Figure 3 3 Interface Circuits in the Emulator 38 pin Interface for H UDI 86 RENESAS Emulator control circuit FIN1104 User connector 38 pins LP2996 AUDSYNC AUDATA S3 0 Figure 3 4 Interface Circuits in the Emulator 38 pin Interface for AUD RENESAS 87 3 3 Reducing EMI Noise To prevent EMI noise enclose the trace unit in a case at usage as shown in figure 3 5 The recommended material of the case is iron plated with nickel or resin internally plated with nickel The case must be large enough to include the trace unit the probe head and the user system Figure 3 5 Countermeasure for EMI Noise Note EMI stands for Electrical Magnetic Interference 88 RENESAS 3 4 Diagnostic Procedure This section describes how to set up and execute the diagnostic program and output the result 3 4 1 Installing the Diagnostic Program 1 Opening SOT ROEO200FxEMU00 Setup exe Execute Setup exe from the SOT ROEO200FxEMU00 directory of the CD R Open SOT ROEO200FOEMUO00 Setup exe and SOT ROEO200F2EMU00 Setup exe for ROEO200FOEMUO00 and ROEO200F2EMUO00 respectively Follow t
70. 2Z00FOEMU00 or ROEO200F2EMU00 In the event of a malfunction fill in the repair request sheet on the following pages and send it to your distributor 385 7 ENESAS To Distributor Repair Request Sheet Your company name Person in charge Tel Item Symptom 1 Date and time when the malfunction occurred Month Day Year at system initiation in system operation Circle either of items in the braces 2 Frequency of generation of the malfunction times in day s week s or month s Enter the appropriate numbers in the parentheses and circle one of the three items in the braces 3 System configuration when the malfunction occurred System configuration of the emulator E200F emulator ROEQ2ZO0OFOEMUOO or ROEO200F2EMU00 Serial No Revision The side of the emulator unit is labeled with the above items the serial no is the four digit number and the revision is the string of letters following the number Trace unit ROEOQ2Z00FOETUOO Serial No Revision These are impressed on the circuit board Expansion profiling unit ROEO200FOEPUOO Serial No Revision These are impressed on the circuit board Provided CD R ROEO200FOEMUOOS Version V Shown as V x xx release on the CD R x numeral Host computer in use Manufacturer Type number OS Windows 2000 or Windows XP 386 RENESAS Item Symptom 4 Settings whe
71. 33 READ 000032 D 000032 READ 000031 D 000031 READ 000030 D 000030 READ 000029 D 000029 READ 000028 D 000028 READ 000027 D 000027 READ 000026 D 000026 READ 000025 D 000025 READ 000024 D 000024 READ 000023 D 000023 READ 000022 D 000022 READ 000021 D 000021 READ 000020 D 000020 READ 000019 D 000019 READ 000018 D 000018 READ 000017 D 000017 READ 000016 D 000016 READ 00001042 00001044 00001046 00000108E 00001090 00001092 00001094 00001096 00001098 00001094 00000109C 00001109E 00001178 00001174 00001040 00001042 00001044 00001046 00001048 00001044 00001044C 00000104E Figure 6 58 BUS MFI trace Window e If necessary adjust the column width by dragging the header bar immediately below the title bar Note The type and the amount of information that can be acquired by a trace differ according to the product For details on the specifications of each product refer to the online help 355 RENESAS 6 20 MMU Support This function can be used when the supported MPU has an MMU e TLB window In the emulator the contents of the TLB table can be easily displayed and edited by selecting CPU gt TLB from the View menu For details refer to the online help e VP_MAP translation function The MPU which has an MMU translates internal addresses virtual addresses to actual memory addresses physical addresses Address translation is performed according to the ad
72. 44 NOP o000104C MOV tH 00 R4 0000104E HOY L 8 H70110 8 PC R3 00001050 BR3 00001052 P 00001054 R0 R13 for i 0 i lt 10 itt Ji 00001056 H 00 R14 00001058 H 0A RI 00001054 R1 R14 NNNNIARP AH INGA A p_sam new Sample Figure 5 15 Disassembly Window 154 RENESAS 5 2 4 Modifying the Assembly Language Code You can modify the assembly language code by double clicking on the instruction that you want to change The Assembler dialog box will be opened Assembler Address Code 00000802 0009 a Cancel Mnemonic Figure 5 16 Assembler Dialog Box The address machine code and disassembled instruction are displayed Enter the new instruction or edit the current instruction in the Mnemonic field Pressing the Enter key will assemble the instruction into memory and move on to the next instruction Clicking the OK button will assemble the instruction into memory and close the dialog box Clicking the Cancel button or pressing the Esc key will close the dialog box Note The assembly language display is disassembled from the actual machine code in the memory If the memory contents are changed the dialog box and the Disassembly window will show the new assembly language code but the display content of the Source window will not be changed This is the same even if the source file contains an assembly codes 155 RENESAS 5 2 5 Viewing a Specific Address
73. 5 gt 4 gt 3 gt 2 a Sequential BUS Event occurs 207 7 ENESAS Note 208 Channel 6 gt 5 gt 4 gt 3 gt 2 After conditions have been matched in the order of bus event channel 6 gt 5 gt 4 gt 3 gt 2 a Sequential BUS Event occurs Sequential reset Selects whether or not bus event channel Ch1 is used as the reset point Disable Not used as the reset point Enable Used as the reset point Action Specifies the operation after the Sequential BUS Event has been detected Break Breaks after the Sequential BUS Event has been detected Trace stop Stops external bus trace after the Sequential BUS Event has been detected When the Sequential BUS Event condition is set and the eventpoint condition is edited with the bus event channel that has been selected for Channel select the Action page cannot be modified To modify the settings of the Action page cancel the Sequential BUS Event condition When a sequential event is specified no condition will be satisfied on channels other than those selected for this event RENESAS 5 6 8 Setting Other Eventpoints On the Other Event sheet the settings for Other Eventpoints are displayed and modified probe x0xl edge and AUD trace start runtime cycle D 12345678 clock 20ns Break None Start MFICS access data H 1234 End THCS access data H 5673 MFI trace get None Figure 5 50 Event Window Other Event Sheet Items that can be displa
74. 5 1 4 Bus Board Page When a measurement channel is double clicked or selected and Set is selected from the popup menu in this window the Performance Analysis BUS Channel x dialog box is opened and measurement conditions can be modified 251 7 ENESAS Performance Analysis Bus Channel 1 gt 2 Measurement Method E CTAS ESS eee ea X Count Up Mode start condition and end condition are satisfied X Start Range End Range Start Address H 00000000 Start Address H 00000000 End Address 000001 00 End Address H 00000300 Extend Condition Extend Condition NV Enable Count Overflow Break D 6 Common Setting of Bus Performance Ch1 6 Time Measurement Unit Ons cancel Figure 5 85 Performance Analysis BUS Channel x Dialog Box Measurement Method Specifies the measurement mode Specified Range measurement Measurement within the specified range Start Point to End Point measurement Measurement between specified addresses Start Range to End Range measurement Measurement between specified ranges Count Up Mode Specifies the counting up method of execution counts start condition and end condition are satisfied Counted up when the end condition is satisfied after the start condition has been satisfied end condition is satisfied Counted up whenever the end condition is satisfied Start Range Sets the measurement condition or the measurement start condition for Start Range to End Ra
75. 62 RENESAS Output Text File Displays the Save Text of Profile Data dialog box Displayed contents are saved in a text file Setting This menu has the following submenus the menus available only in the List sheet are also included Show Functions Variables Displays both functions and global variables in the Function Variable column Show Functions Displays only functions in the Function Variable column Show Variables Displays only global variables in the Function Variable column Only Executed Functions Only displays the executed functions If a stack information file sni extension output from the optimizing linkage editor does not exist in the directory where the load module is located only the executed functions are displayed even if this check box is not checked Include Data of Child Functions Sets whether or not to display information for a child function called in the function as profile data Properties Sets the items to be measured 263 7 ENESAS 5 9 9 Profile Chart Window The Profile Chart window displays the relation of calls for a specific function This window displays the specified function in the middle with the callers of the function on the left and the callees of the function on the right The numbers of times the function calls the called functions or is called by the calling functions are also displayed in this window Profile Chart _PowerON_Reset_PC sort long S
76. 8 0x00001040 0x0000104c 0x00001056 0x0000105e 0x00001066 0x0000106a O0x0000106c 0x00001084 0x0000108e 0x00001098 0x000010aa 0x000010be 0x000010ce 0x000010e0 Ox000010f2 0x00001104 0x00001116 0x00001128 0x0000113a 0x00001146 0x00001166 306 void main void long a 10 long J ink 13 class Sample p_sam while 1 p_sam new Sample for i 0 i lt 10 i j rand iffi lt Of j j ali j p_sam gt sort a p_sam gt change a p_sam gt s0 a 0 p_sam gt sl a 1 p_sam gt s2 a 2 p_sam gt s9 a 3 p_sam gt s4 a 4 p_sam gt s5 a 5 p_sam gt s6 a 6 p_sam gt s7 a 7 p_sam gt s8 a 8 p_sam gt s9 a 9 delete p_sam rie abort void Figure 6 11 Source Window Break State 7 ENESAS The user can see the cause of the break that occurred last time in the Status window e Select Status from the CPU submenu of the View menu After the Status window is displayed open the Platform sheet and check the Status of Cause of last break Item Connected to CPU Run status Cause of last break Run time count Status SHxxxx EZOOF SYSTEM Renesas E Series USB Driver SHxxxx Ready BREAK POINT 00h OOmin 00s O02ms 578us 660ns Hardware break disable Big Disconnected Not used Connected Connected gt Platform A Events F Figure 6 12 Status Window Note The items that can be displayed in this window differ according
77. AUD trace display range Start pointer End pointer User memory area Start Address H0 End Address JH3FF r Trace Extend Mode Trace data with PPG ome Figure 6 53 Internal AUD Usermemory acquisition Dialog Box 349 7 ENESAS Trace type Selects the type of trace function AUD trace Selects the AUD trace function Internal trace Selects the internal trace function User Memory trace Selects the user memory output trace function Trace Mode 1 Selects the operation mode when the trace information has been P sequentially generated Realtime trace Some trace information will not be output Non realtime trace The CPU stops operations until the trace information is output Trace mode 2 Specifies the operation when the trace buffer becomes full Trace continue The oldest trace information is overwritten to acquire the latest trace information Trace stop When the trace buffer becomes full the trace information is no longer acquired User memory area Sets the trace display range when the user memory output trace function is used Start Address Specifies the start address of the display range End Address Specifies the end address of the display range Trace Extend Mode Sets whether or not internal performance counter Ch3 or Ch4 is included as the item for trace acquisition Trace data with PPC When checked internal performance counter Ch3 or Ch4 is included
78. A_OA of the Onchip Eventpoint e Select Eventpoints from the Code submenu of the View menu The Event window is displayed e The PC breakpoint that has been previously set is deleted Click the Event window with the right hand mouse button and select Delete All from the popup menu to cancel all PC breakpoints that have been set e To set an Onchip Eventpoint click on Onchip Eventpoint Up to 13 conditions can be set independently for the Onchip Eventpoints In this example set event channel 1 Note The number of event channels of the Onchip Eventpoint differs according to the product For the number that can be specified for each product refer to the online help 326 RENESAS e Select a line of Ch1 IA_OA in the Event window When highlighted double click this line None None Disable None Disable None Disable None Disable None Disable None Ch SystemBus Disable None Cho SystemBus Disable None None None general enable subroutine enable exception enable None AUD Event A Other Event A BUS Event Figure 6 36 Event Window Onchip Event Sheet e The Event condition 1 dialog box is displayed e Clear the Don t care check box in the Address page e Select the Prefetch address break before executing radio button and enter H 00001084 as the value in the Address edit box 327 RENESAS Event condition 1 Address ASID Action r Address C Data address Prefetch address brea
79. C Breakpoints When the instruction of the specified address is fetched the user program is stopped Up to 1000 points can be set 5 6 2 Eventpoints Eventpoints can be used for higher level conditions such as the data condition as well as specification of the single address Up to four eventpoints can be set in the emulator 1 Onchip Eventpoint This is a function that sets eventpoints according to the information in the MPU There are 13 event detection channels For an operation when an event is detected break internal trace acquisition acquisition start acquisition stop or internal performance measurement start end can be specified A combination of one or more of the Onchip Eventpoints enables specifying more complex sequential conditions This function can be set in the Onchip Event sheet of the Event window Note The contents to be set will differ depending on the product For details refer to the on line help for each product 2 AUD Eventpoint This is a function that sets eventpoints according to the information output from the AUD interface There are eight event detection channels For an operation when an event is detected break AUD trace acquisition acquisition start acquisition stop or AUD performance measurement start end can be specified A combination of one or more of the AUD evenpoints enables specifying more complex sequential conditions 168 RENESAS This function can be set in the AUD Ev
80. Clock 100ns v Figure 5 39 Chx Delay Dialog Box Delay Page Don t care Sets no delay condition Delay Sets the delay cycle counts D 0 to D 262143 is available Clock Sets a cycle for delay measurement 100ns Specifies 100 ns as one cycle number of trace information Specifies a set of AUD trace information as one cycle Notes 1 This page is only displayed when AUD event channel Ch2 is selected and Trace stop is specified on the Action page 2 When PPC information is output by the AUD trace two sets of AUD trace information are specified as one cycle 194 RENESAS 8 Action page Sets the operation after the condition has been satisfied Chi Reset General Branch Count Action Action Break C Trace Perfor me Trace option Trace start Trace stop Trace get Performance option Sampling time 20ns Enable output trigger Figure 5 40 Chx Reset Dialog Box Action Page Break Breaks after conditions have been matched Trace Enables Trace option and sets the AUD trace operation Trace start Starts AUD trace after conditions have been matched Trace stop Stops AUD trace after conditions have been matched Trace get Acquires AUD trace after conditions have been matched Performance start Starts or ends AUD performance measurement after conditions have been matched When this option is select
81. ENESAS Table 1 4 Measurement Items cont Classification Type Measurement Item Option Note CPU Stalled Cycles stalled in full SFM All items are counted performance cycle trace mode with independently cont multi counts Cycles stalled in full SF This item is not counted if the trace mode without stall cycle is generated multi counts simultaneously with a stall cycle that has occurred due to instruction execution TLB TLB Number of UTLB miss UMI The number of TLB miss performance for instruction fetch exceptions generated by an instruction fetch number of EXPEVT sets Number of UTLB miss UMO The number of TLB miss for operand fetch exceptions generated by an operand access number of EXPEVT sets Number of ITLB miss IM The number of ITLB misses for valid accesses does not include UTLB hits or misses Instruction bus Instruction Number of memory MIF The number of memory performance accesses for accesses by an instruction instruction fetch fetch Accesses canceled by an instruction fetch bus are not counted Instruction fetches which have been fetched in anticipation of a branch but not actually executed are counted Accesses by the PREFI instruction are included Number of instruction IC The number of accesses for cache access 7 ENESAS an instruction cache during memory access of the opcode 43 Table 1 4 Measurement Items cont RENESAS Classification Type
82. Enable Extracts function calls Disable Does not extract function calls When Enable is selected only the cycles that include function calls are extracted for display from the acquired trace information The content of the trace buffer is not changed by extraction of function calls Using this function for the trace information that includes function calls allows the user to know the order of function calls 244 RENESAS 5 8 Analyzing Performance Use the performance analysis function to measure execution performance The emulator has three types of performance analysis functions on chip performance analysis Onchip Performance Analysis AUD performance analysis AUD Performance Analysis and external bus performance analysis BUS Performance Analysis For details on the performance analysis functions refer to section 1 3 7 Performance Measurement Function 5 8 1 Opening the Onchip Performance Analysis Window To open the Onchip Performance Analysis window choose View gt Performance gt Performance Analysis or click the PA toolbar button to open the Select Performance Analysis Type dialog box Select Performance Analysis Type Performance Analysis Onchip Performance Figure 5 76 Select Performance Analysis Type Dialog Box Select Onchip Performance and click the OK button to open the Performance Analysis window Performance Analysis Condition 0002E097 00000032 DISABLE 00000000 DISABLE 000000
83. Enter the end address of coverage information to be displayed in hexadecimal when the prefix is omitted File Specifies a source file that has C or CPP as its file type name from the current project This allows a function included in the specified file to be set as the coverage range C will be automatically specified if the file type name is omitted Files with a type name other than C or CPP cannot be specified here A placeholder or the Browse button can be used Open a recent coverage file Lists a maximum of four files that were saved most recently Select one from the list Browse to another coverage file Allows specification of a file that is not included in the list Clicking the OK button in this dialog box opens the Code Coverage window The display format differs depending on whether the address range or source file is specified Note In one Coverage window up to 2 Mbyte address ranges can be opened To check the whole measurement range use multiple windows to show the addresses separately 280 RENESAS Code Coverage Window Specifying an Address Code Coverage 00000800 00000FFF Statistic Executed Address Assembler Source x 00000800 OOOOOFFF 00000800 MOV L H 0040 8 PC R15 void PowerON Rese 00000802 MOV L H 0044 8 PC R2 set_vbr voi 00000804 mov H 10 R6 00000806 SUB R6 R2 00000808 LDC R2 VBR 0000080A MOV L H 0040 8 PC R3 _CALL _I
84. Eventpoint Ch5 OA Channel e Input H 0 into the Start address and H 10000 into the End address e Inthe Action page select acquire trace and double click the OK button b Setting the trace acquisition mode Display the Internal AUD Usermemory trace window Click this window with the right hand mouse button and select Acquisition from the popup menu to display the Internal AUD Usermemory acquisition dialog box The AUD trace acquisition condition is set 342 RENESAS Internal AUD Usermemory acquisition Trace Mode Trace type C Internal trace User Memory trace Trace Mode 1 Realtime trace Non realtime trace Trace Mode 2 Trace continue Trace stop Break AUD Mode Enable free trace Time stamp clock 20ns x AUD trace display range Start pointer D 255 End pointer D o m User memory area Start Address Fo End Address H3FF Trace Extend Mode I Trace data with PPG orei Figure 6 49 Internal AUD Usermemory acquisition Dialog Box 343 RENESAS Trace type Selects the type of trace function AUD trace Selects the AUD trace function Internal trace Selects the internal trace function User Memory trace Selects the user memory output trace function Trace Mode 1 Selects the operation mode when the trace information has been P sequentially generated Realtime trace Some trace information will
85. H 4000FFF Virtual address Physical address Figure 6 59 Address Translation according to VP_MAP Tables How to translate addresses depends on the settings of the radio buttons of the Memory area group in the Configuration dialog box The following shows how to translate addresses in each setting state e When the Normal radio button is selected The VP_MAP table has a priority over the TLB When the VP_MAP table is enabled and the specified address is within the VP_MAP table settings the emulator translates the address according to the VP_MAP table If the specified address is outside the VP_MAP table settings even when the VP_MAP table is enabled or when the VP_MAP table is disabled the emulator translates the address according to the MMU state e When the Physical radio button is selected The address is not translated 357 7 ENESAS e When the Virtual radio button is selected The address is translated according to the TLB If the specified address is outside the TLB table settings a TLB error will occur Table 6 2 Address Translation Tables VP_MAP MMU Within Radio Enabled Outside Enabled Within Outside Table Used for Button Disabled the Range Disabled the TLB Range Translation Normal Enabled Within the Enabled Within the range Translated according to range the VP_MAP table Outside the range Translated according to the VP_MAP table Disabled Within outside the Translated acco
86. I Input state of NMI IRQ5 0 Input states of six IRQs Instruction Instruction mnemonic Timestamp Time stamp of bus cycle Timestamp Difference Difference value of the time stamp 224 RENESAS 2 Specifying Conditions or Modes for Acquiring Trace Information The capacity of the trace buffer is limited When the buffer becomes full the oldest trace information is overwritten Setting the trace acquisition condition allows acquisition of useful trace information and effective use of the trace buffer The trace information acquisition conditions are implemented by eventpoints and acquisition start acquisition end and acquisition can be controlled For setting eventpoints refer to section 5 6 Using the Eventpoints The trace information acquisition mode is set in the BUS acquisition dialog box that is displayed by selecting Set from the popup menu BUS MFI acquisition Trace Mode Trace type e BUS BUS buffer over flow Trace continue Trace stop C Break BUS trace mode Enable free trace 052 SDRAM trace CS3 SDRAM trace Time stamp clock t v C Trace display range Start pointer D 255 End pointer D0 orce Figure 5 61 BUS MFI acquisition Dialog Box 225 1RENESAS BUS buffer over flow Specifies the operation when the external bus trace buffer of the emulator becomes full Trace continue The oldest trace information is overwritten by the latest information Trace stop W
87. I7 STATUSO Signal PTI6 STATUS2 Signal PTI5 PDSTATUS Signal NMI High Signal PTIO IROO High Signal PTJ1 IRQ1 High Signal PTD4 IRQZ SDHIDZ High Signal PTQO SIOFOMCK IRQ3 SIMD Low Signal PTEO IRQ4 High Signal PTE1 IRQS High Signal PTZ1 KEYINO IRQ6 High Signal PTZ5 KEYIN4 IRQ High User System Voltage Reserved User System Clock OK Figure 5 24 Extended Monitor Window Note The items that can be set in this window vary according to the emulator in use For details refer to the online help 166 7 ENESAS 5 5 2 Selecting Items to be Displayed Selecting Properties from the popup menu displays the Extended Monitor Configuration dialog box Extended Monitor Configuration Update millsecond Running 100 Break 1000 Settings M Signal PTJO IROO High M Signal PTJ1 IRQI High M Signal PTOO SIOF MCK IRQ2 High M Signal PTOI SIOFSCKISCK IRQ3 Low M Signal PTOZ SIOSYNC SS0 IRQ4 High Signal PTJ2 IRQ5 High Signal IRQ6 Reserved Signal IRQ Reserved 4 Figure 5 25 Extended Monitor Configuration Dialog Box This dialog box allows the user to set the items to be displayed in the Extended Monitor window 167 7 ENESAS 5 6 Using the Eventpoints The emulator has the eventpoint function that performs breaking tracing and execution time measurement by specifying more complex conditions along with the PC breakpoints standard for the High performance Embedded Workshop 5 6 1 P
88. ISTER R W TEST J OPTION FPGA12 REGISTER R W TEST V MAIN FPGA2 REGISTER R W TEST MEMORY M AUD MEMORY TEST TRACE UNIT MEMORY TEST START STOP FILE LOG BACK Figure 3 9 Screen Showing Test NG If the test is failed Test NG is shown figure 3 9 In this case the emulator may be malfunctioned Create a log file according to the following procedures and send it to the sales office How to create a log file Click the FILE LOG button The E200FTM LOG file is created under the SOT ROEO200FxEMU00 directory Send the log file to the sales office OA ED 93 7 ENESAS Example of the E200F TM error log E200F Emulator T M ERROR LOG TM Version x xX xx Serial Number 000x Date 200x xx xx No STATUS NG Address NG Data 02 1301 A0000000 7EC0A5F NG 03 0304 A8000108 FFFFFFFF NG 94 7 ENESAS Section 4 Preparations for Debugging 4 1 System Check When the software is executed use the procedure below to check that the emulator is connected correctly Here use the workspace for a tutorial provided on the product Connect the emulator to the host machine Connect the user system interface cable to the connector of the emulator Connect the user system interface cable to the connector in the user system Turn on the user system Turn on the emulator OS Se ee T Select Renesas gt High performance Embedded Workshop gt High performance Embedded Workshop from Programs in the Start men
89. IV Include subfolders Located Tools which can be uninstalled SH 1 0 C Hew3 T ools Renesas DebugCom Search Status 1 file found Figure 4 42 Highlighting the Product to be Uninstalled Highlight the product name to be uninstalled and click the Uninstall button This is the end of uninstallation CAUTION A shared file may be detected while the program is being removed If another product may be using the shared file do not remove the file If another product does not start up after the removal process re install that product 7 ENESAS 129 130 7 ENESAS Section 5 Debugging This section explains the functions specific to this product that have not been described in section 15 Using the Debugger of the High performance Embedded Workshop User s Manual 5 1 Setting the Environment for Emulation 5 1 1 Opening the Configuration Dialog Box Selecting Setup gt Emulator gt System or clicking the Emulator System toolbar button E opens the Configuration dialog box 131 7 ENESAS 5 1 2 General Page Sets the emulator operation conditions Configuration General Main Board Bus Board Option Board Loading flash memory Mode SH XXXX T Emulation mode Hardware break disable ba Step option Disables interrupts during single step execution v UBC mode PPG mode Memory area Normal C Physical Virtual ASID D0 AUD clock 18 GPU clock JTAG clo
90. Mapping Dialog Box Selecting Setup gt Emulator gt Memory Resource or clicking the Emulator Memory Resource toolbar button a opens the Memory Mapping dialog box Memory Mapping From To Mappine OU40UU00 OOFFEFFE EMULATION AREA Read Only 16 bit Target Device configuration System memory resources CSO 00000000 OO3FFFFF Can not use Remain Emulation Memory OM CSO 00400000 OOFFFFFF EML16 CSO 00800000 O3FFFFFF Can not use Figure 5 8 Memory Mapping Dialog Box 7 ENESAS 145 This dialog box displays the current memory map and the state of the emulation memory Edit Displays the Edit Memory Mapping dialog box allowing the user to modify the address range and attributes of a memory map Add Allocates the new emulation memory Reset Resets the map memory to its default settings Close Closes the dialog box The memory configuration of the device being emulated is shown on the Memory sheet of the Status window Notes 1 When the trace unit is not connected to the emulator memory mapping cannot be set on this page 2 The items that can be set in this dialog box depend on the emulator in use For details refer to the online help 3 The items to be displayed in this dialog box depend on the emulator in use For details refer to the online help 146 7 ENESAS 5 1 8 Changing the Memory Map Setting Clicking the Edit button on the Memory Mapping dialog box afte
91. NIT ooooosoc JSR R3 0000080E NOP 00000810 STS DSR R2 set_cer SR_Ini 00000812 MOV L H 003C 8 PC R14 oo fo 0 6 6 6 4a 8 v gt A Figure 5 106 Code Coverage Window Specifying an Address The Code Coverage window is divided into two by the splitter e Left hand window Displays the coverage range and statistical information of the coverage The items are displayed as follows Range Address range Statistic CO coverage value in percentage The percentage will be displayed in the Statistic column by selecting Percentage from the popup menu on the left hand window Range statistic Figure 5 107 Percentage Shown in the Code Coverage Window 281 7 ENESAS e Right hand window Displays coverage information at the C C or assembly language level The items are displayed as follows Executed 1 the instruction was executed or 0 the instruction was not executed Address Instruction address Assembler Disassembled program Source C C or assembly source program Code Coverage Window Specifying a Source File Code Coverage 00001038 00001199 Functions Statistic Executed Address Assembler Source 00001038 Mov L R12 R15 void main void 00001034 MOV L R13 R15 0000103 MOV L R14 R15 0000103E STS L PR R15 00001040 app H CC R1IS 00001042 mov H O1 R1 while 1 00001044 mov R1 R0 00001046 CMP EQ H 00 RO 00001048 BF H 104E 8 00001044 BRA H 118 12
92. Note Items other than General and Address vary according to the emulator in use For details refer to the online help Set filtering conditions and then press the OK button This starts filtering according to the conditions Clicking the Cancel button closes the Trace Filter dialog box which holds the settings at the time when the dialog box was opened In filtering only the trace information that satisfies one or more filtering conditions set in the above pages will be displayed in the Trace window 235 7 ENESAS Filtering conditions can be changed several times to analyze data because the content of the trace buffer is not changed by filtering 1 General page Set the range for filtering Trace Filter General Address data Type Bus R w ai Enable Filter Not designation r Trace display range Start PTR End PTR Cancel Apply Figure 5 68 Trace Filter Dialog Box General Page Don t care other pages Only selects the cycle number when this box is checked Other options become invalid Enable Filter Enables the filter when this box is checked Not designation Filters information that does not match the conditions set in those pages when this box is checked Trace display range Sets the range for filtering Start PTR Enters a PTR value to start filtering End PTR Enters a PTR value to end filtering Note Along with setting the range for filterin
93. OEMU0O 38 pin connector 2 5767004 2 Tyco Electronics 38 pin Mictor type ROEO200F2EMU00 AMP K K 2 The pin assignments of the connector are shown in section 2 in the additional document Supplementary Information on Using the SHxxxx 3 When using the 36 pin user system interface cable connect pins 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 32 33 34 and 36 of the H UDI port connector to GND on the PCB When using the 38 pin user system interface cable connect pin 5 of the H UDI port connector and ground bus leads of the connector to GND These pins are used as electrical GND and to monitor the connection of the H UDI port connector Note the pin assignments of the H UDI port connector 4 For the recommended connectors and pin assignments of the optional products refer to the additional document Supplementary Information on Using the SHxxxx 72 7 ENESAS 2 6 1 Connecting the E200F H UDI AUD Probe to the User System Connect the H UDI AUD probe to the user system as shown in figure 2 14 Figure 2 14 Connecting the H UDI AUD Probe to the User System 73 7 ENESAS Fasten the user system and the H UDI AUD probe with screws as shown in figure 2 15 Figure 2 15 Fastening the User System and the H UDI AUD Probe CAUTION Note that the pin number assignments of the connector differ from those of the connector manufacturer Notes 1 Connection of the signals differs depending on the packa
94. REJ10B0137 0600 Everywhere you imagine m gE NESAS SH 4A SH4AL DSP E200F Emulator User s Manual Renesas Microcomputer Development Environment System SH 4A SH4AL DSP E200F ROEO200FOEMU00E Rev 6 00 Renesas Technology Revision Date Jul 25 2007 www renesas com Notes regarding these materials This document is provided for reference purposes only so that Renesas customers may select the appropriate Renesas products for their use Renesas neither makes warranties or representations with respect to the accuracy or completeness of the information contained in this document nor grants any license to any intellectual property rights or any other rights of Renesas or any third party with respect to the information in this document Renesas shall have no liability for damages or infringement of any intellectual property or other rights arising out of the use of any information in this document including but not limited to product data diagrams charts programs algorithms and application circuit examples You should not use the products or the technology described in this document for the purpose of military applications such as the development of weapons of mass destruction or for the purpose of any other military use When exporting the products or technology described herein you should follow the applicable export control laws and regulations and procedures required by such laws and regulations All information included in this docum
95. Registration Sheet is included with this product fill it in and send the same contents to the following address by an email Your registered information is used for only after sale services and not for any other purposes Without user registration you will not be able to receive maintenance services such as a notification of field changes or trouble information So be sure to carry out the user registration For more information about user registration send an email to the following address regist_tool renesas com iii RENESAS RENESAS Contents Section 1 Product Overview senpri i iii 1 LL COMPONENtS irese e p E E E E a REES 5 1 2 Emulator Hardware Configuration 2 00 eeceeseeseeeseeeeecseeeseeeseeeseeseesseeeseeeseeeaeeeaeesaeeags 6 1 3 Em lat r Fume toms nsss lees sage sseis Gea E E E E wee asda Geo aeee 20 13 1 OVERVIEW nunana a ie a Bei ansaid cena A lahat eerie Node lee eee ee 20 1 3 2 Event Detection PUmCtons 2 5ccs s0es dies sasesassedsc s ed sects strates ha O EREKE E 24 1 3 3 Trace PUN CHUONS ss ses cssessieds scesestcoctuensceaseeal esT EEEE E EEN REE OAOE ERRi 21 1 34 Break PUnCtU OD iisecscecgecsascsseceaceu see par i Ea R E pa A 35 L335 Probe Funto sseasccastisscsacesveeeudcieevatvayssea A E E EE 36 1 3 6 Peripheral I O Analyzer FUunctions c ce eeceeeeeseeeseeeeesecececeeseeeaeeeaeenaeesseesseenaes 36 1 3 7 Performance Measurement Function cece eeeeseeseceeeseeeeseeeaeeeaeensecseeesseenee
96. T W FLASH RAW TEST REGISTER R W I H UDI REGISTER R W TEST j AUD REGISTER RAW TEST TRO FPGA REGISTER R W TEST OPTION FPGA12 REGISTER R W TEST jv MAIN FPGA2 REGISTER R W TEST Select UNIT ONLY MEMORY jv AUD MEMORY TEST M TRACE UNIT MEMORY TEST A Figure 3 7 Screen for Selecting Test Note Do not disconnect the USB cable during the test 91 7 ENESAS 11 When the test is executed Testing is shown at the left of STATUS 12 When the test is successfully completed Test OK is displayed E200F Test amp Maintenance Program Versionx x xx 2O0Ox xx xx FILE COMPONENT MAIN IV ERROR STOP SERIAL No 1 TEST COUNT ve J ENDLESS STATUS OPTION MEMORY TEST V SDRAM R W TEST V MAIN MEMORY TEST Aa ile Indicating that the test is REGISTER R W V H UDI REGISTER R W TEST being executed V AUD REGISTER R W TEST I TRC FPGA REGISTER R W TEST OPTION FPGA12 REGISTER R W TEST V MAIN FPGA2 REGISTER RAW TEST MEMORY M AUD MEMORY TEST TRACE UNIT MEMORY TEST START STOP FILE LOG BACK Figure 3 8 Screen Showing Testing 92 ENESAS 3 4 3 Creating a Log File E200F Test amp Maintenance Program Versionx x xx 200x xx xx FILE COMPONENT MAIN J ERROR STOP SERIAL No TEST COUNT v 1 J ENDLESS Test NG STATUS 1301 Vv M OPTION MEMORY TEST V SDRAM RAW TEST M MAIN MEMORY TEST V FLASH R W TEST REGISTER R W V H UDI REGISTER R W TEST V AUD REGISTER R W TEST J TRC FPGA REG
97. Tel lt 44 gt 1628 585 100 Fax lt 44 gt 1628 585 900 Renesas Technology Shanghai Co Ltd Unit 204 205 AZIACenter No 1233 Lujiazui Ring Rd Pudong District Shanghai China 200120 Tel lt 86 gt 21 5877 1818 Fax lt 86 gt 21 6887 7898 Renesas Technology Hong Kong Ltd 7th Floor North Tower World Finance Centre Harbour City 1 Canton Road Tsimshatsui Kowloon Hong Kong Tel lt 852 gt 2265 6688 Fax lt 852 gt 2730 6071 Renesas Technology Taiwan Co Ltd 10th Floor No 99 Fushing North Road Taipei Taiwan Tel lt 886 gt 2 2715 2888 Fax lt 886 gt 2 2713 2999 Renesas Technology Singapore Pte Ltd 1 Harbour Front Avenue 06 10 Keppel Bay Tower Singapore 098632 Tel lt 65 gt 6213 0200 Fax lt 65 gt 6278 8001 Renesas Technology Korea Co Ltd Kukje Center Bldg 18th FI 191 2 ka Hangang ro Yongsan ku Seoul 140 702 Korea Tel lt 82 gt 2 796 3115 Fax lt 82 gt 2 796 2145 Renesas Technology Malaysia Sdn Bhd Unit 906 Block B Menara Amcorp Amcorp Trade Centre No 18 Jalan Persiaran Barat 46050 Petaling Jaya Selangor Darul Ehsan Malaysia Tel lt 603 gt 7955 9390 Fax lt 603 gt 7955 9510 Colophon 6 0 SH 4A SH4AL DSP E200F Emulator User s Manual tENESAS Renesas Technology Corp 2 6 2 Ote machi Chiyoda ku Tokyo 100 0004 Japan
98. When you are viewing your program in the Disassembly window you may want to look at another area of your program s code Rather than scrolling through a lot of code in the program you can go directly to a specific address Select Set Address from the popup menu and the dialog box shown in figure 5 17 is displayed Set Address _main Cancel Figure 5 17 Set Address Dialog Box Enter the address or label name in the edit box and either click on the OK button or press the Enter key The Disassembly window will be updated to show the code at the new address When an overloaded function or a class name is entered the Select Function dialog box opens for you to select a function 5 2 6 Viewing the Current Program Counter Address Wherever you can enter an address or value into the High performance Embedded Workshop you can also enter an expression If you enter a register name prefixed by the hash character the contents of that register will be used as the value in the expression Therefore if you open the Set Address dialog box and enter the expression pc the Source or Disassembly window will display the current PC address It also allows the offset of the current PC to be displayed by entering an expression with the PC register plus an offset e g PC 0x100 156 RENESAS 5 3 Displaying Memory Contents in Realtime Use the Monitor window to monitor the memory contents during user program execution When t
99. abel Window 309 7 ENESAS 6 12 Viewing Memory When the label name is specified the user can view the memory contents that the label has been registered in the Memory window For example to view the memory contents corresponding to _main in word size e Select Memory from the CPU submenu of the View menu enter main in the Display Address edit box Display Address Display Address main x gl Scroll Start Address foooooood Scroll End Address FFFFFFFF Figure 6 15 Format Dialog Box 310 7 ENESAS e Click the OK button The Memory window showing the specified area of memory is displayed ux 16 1040 8 2 abc dt amp db de a 16 32 Address Label Register 00001024 _main 00001034 p 00001044 L e 00001054 TF 211 RN 00001064 vease Budioie iB 00001074 d b R IR R 00001084 HR GR AR BR 00001094 B3 R R Bad 00001044 40 amp n m 1 k OOOO10B4 0000104 Figure 6 16 Memory Window 311 RENESAS 6 13 Watching Variables As the user steps through a program it is possible to watch that the values of variables used in the user program are changed For example set a watch on the long type array a declared at the beginning of the program by using the following procedure e Click the left of displayed array a in the Source window to position the cursor e Select Instant Watch with the right hand mouse button The following dialog b
100. able the settings in the Include profile box specify the Optimize list box as some setting other than None 257 7 ENESAS 5 9 3 Loading Stack Information Files You can select whether or not to read the stack information file in a message box for confirmation that is displayed when a load module is loaded Clicking the OK button of the message box loads the stack information file The message box for confirmation will be displayed when e There are stack information files extension SNT e The Load Stack Information Files SNI files check box is checked in the Confirmation page of the Options dialog box figure 5 89 that can be opened by choosing Tools gt Options from the main menu Build Editor Workspace Confirmation Display confirmation dialogs for Save memory Set All IFill memory Test memory Delete All Labels Delete Label Loading Labels Clear All Saving Labels Delete All Events Delete Event Reset PA Setting Reset All PA Settings Clear PA Data Clear All PA Data Reset All PA Settings at Loading Load Stack Information Files SNI files Rn i K K E K K K K oree Figure 5 89 Options Dialog Box 258 RENESAS 5 9 4 Enabling the Profile Choose View gt Performance gt Profile to open the Profile window Choose Enable Profiler from the pop up menu of the Profile window The it
101. access address access data trace Software trace S_TRACE No display No display Trace x function Variable x execution address data System bus MEMORY No display Read write Memory access Memory trace address access data write only Data lost LOST No display No display No display No display CPU wait CPU WAIT No display No display No display No display generation Notes 1 Not displayed when the PPC option is in use 2 According to the device being debugged there may be no output for the Lost or CPU WAIT type In such a case it is not possible to clarify whether the trace data was not output in time or the CPU generated a wait state for the output trace data b Function to acquire information outside the MPU by a trace The acquired trace information is displayed in the BUS MFI trace window External Bus Trace Function BUS trace This is a large capacity trace function that is enabled when the external bus pins of the MPU are connected to the emulator If an external memory is read from or written to trace information is output in realtime from the external bus pins 7RENESAS 33 The external bus trace acquisition acquisition start and acquisition end can be controlled depending on the specified external bus eventpoint condition For setting eventpoints refer to section 5 6 Using the Eventpoints With this function information of a maximum of 262 144 cycles can be acquired in each bus cycle Other Trace
102. age information CO coverage from the address range specified by the user and displays the results Notes 1 The information on the executed delay slot cannot be acquired 2 Be sure to set the following when using the code coverage function e Acquisition dialog box that is opened by selecting Set from the popup menu of the Trace window Trace type Select AUD Trace Trace Extend Mode Uncheck the Trace data with PPC check box e Ch12 of the Eventpoint window Branch event sheet check all the branch conditions Action sheet Check Acquire trace These settings above are default when the emulator is activated 3 In this function the data that is output by AUD trace is used Accordingly when the emulator is used in realtime trace mode the trace data may be lost and the code coverage information will not be collected normally In such a case it is recommended to use the emulator in non realtime trace mode By default the emulator is activated in realtime trace mode 5 11 1 Opening the Code Coverage Window Select View gt Code gt Code Coverage or click the Code Coverage toolbar button E The following dialog box opens when the coverage function is used for the first time after initiation of the emulator Coverage Acquisition Range Setting Coverage acquisition start address Mainboard 4M Hooo00000 Coverage acquisition start address Optionboard 8M H o0000000 Cancel Figure 5 104 Coverag
103. ailure or malfunction of which may cause a direct threat to human life or create a risk of human injury or which require especially high quality and reliability such as safety systems or equipment or systems for transportation and traffic healthcare combustion control aerospace and aeronautics nuclear power or undersea communication transmission If you are considering the use of our products for such purposes please contact a Renesas sales office beforehand Renesas shall have no liability for damages arising out of the uses set forth above Notwithstanding the preceding paragraph you should not use Renesas products for the purposes listed below 1 artificial life support devices or systems 2 surgical implantations 3 healthcare intervention e g excision administration of medication etc 4 any other purposes that pose a direct threat to human life Renesas shall have no liability for damages arising out of the uses set forth in the above and purchasers who elect to use Renesas products in any of the foregoing applications shall indemnify and hold harmless Renesas Technology Corp its affiliated companies and their officers directors and employees against any and all damages arising out of such applications You should use the products described herein within the range specified by Renesas especially with respect to the maximum rating operating supply voltage range movement power voltage range heat radiation characteristics ins
104. al from Renesas Please contact a Renesas sales office if you have any questions regarding the information contained in this document Renesas semiconductor products or if you have any other inquiries IMPORTANT INFORMATION READ FIRST e READ this user s manual before using this emulator product KEEP the user s manual handy for future reference Do not attempt to use the emulator product until you fully understand its mechanism Emulator Product Throughout this document the term emulator product shall be defined as the following products produced only by Renesas Technology Corp and Renesas Solutions Corp excluding all subsidiary products e Emulator e Trace unit e Expansion profiling unit e Analyzer unit The user system or a host machine is not included in this definition Purpose of the Emulator Product This emulator product is a software and hardware development tool for systems employing the Renesas microcomputers This emulator product must only be used for the above purpose Limited Applications This emulator product is not authorized for use in transportation vehicular medical where human life is potentially at stake aerospace nuclear or undersea repeater applications Buyers of this emulator product must notify Renesas Technology Corporation Renesas Solutions Corporation or an authorized Renesas Technology product distributor before planning to use the product in such applications Improveme
105. al trace when the profiling function is enabled d Halt function When the profiling function is enabled do not use the halt function of the internal AUD external bus and MFI traces e Memory access during user program execution When the profiling function is enabled memory access is disabled during user program execution f When the profiling function is used a break occurs if a branch instruction is generated Accordingly the realtime emulation will not be performed In addition since the emulator firmware is controlled on generation of a break the executed result of the branch instruction may be displayed on the Internal AUD Usermemory trace window when the execution is returned to the user program from the emulator firmware In this case EML is displayed g When the profiling function is used do not use the function of Break Condition 3 h When the profiling function is used do not set Hardware break enable for Emulation mode in the Configuration dialog box i When the profiling function is used the PC and SR values are displayed as undefined on the status bar 266 RENESAS 3 Others a When the profiling function is used an internal break occurs in the execution of the user program Therefore the measurement results of AUD performance analysis bus performance analysis and realtime profile will contain errors b When the profiling function is used the contents that have been set in the on chip
106. ali j 00001098 p_sam gt s0 a 0 000010aa p_sam gt sl al 1 000010be p_sam gt s2 a 2 000010ce p_sam gt s3 a 3 000010e0 p_sam gt s4 a 4 oooo1f2 p_sam gt s5 a 5 00001104 p_sam gt s6 a 6 00001116 p_sam gt s7 a 7 00001128 p_sam gt s8 a 8 0000113a p_sam gt s9 a 9 00001146 ea p_sam Figure 6 5 Source Window Displaying the Source Program e Select a font and size that are legible from the Format Views option in the Setup menu if necessary Initially the Source window shows the start of the user program but the user can use the scroll bar to scroll through the user program and look at the other statements 301 7 ENESAS 6 7 Setting a PC Breakpoint A PC breakpoint is a simple debugging function The Source window provides a very simple way of setting a PC breakpoint at any point in a program For example to set a PC breakpoint at the sort function call e Select by double clicking the S W Breakpoints column on the line containing the sort function call F tutorial tutorial 3 C header file sbrkh 00001038 rele main void sorth E R long a 10 vect ong j 3 C source file int i E dbscte class Sample p_sam l intprec 00001040 while G l resetpre c 0000104c p_sam new Sample sbrkc 00001056 for i 0 i lt 10 i MH A vectibic 0000105e j randQ Ea G source tile 00001086 if lt Ot sotene 0000106a pica
107. ample Figure 5 93 Profile Chart Window 5 9 10 Types and Purposes of Displayed Data The profiling function is able to acquire the following information Address You can see the locations in memory to which the functions are allocated Sorting the list of functions and global variables in order of their addresses allows the user to view the way the items are allocated in the memory space Size Sorting in order of size makes it easy to find small functions that are frequently called Setting such functions as inline may reduce the overhead of function calls If you execute larger functions more of the cache memory will need to be updated This information allows you to check if those functions that may cause cache misses are frequently called Stack Size When there is deep nesting of function calls pursue the route of the function calls and obtain the total stack size for all of the functions on that route to estimate the amount of stack being used Times Sorting by the number of calls or accesses makes it easy to identify the frequently called functions and frequently accessed global variables 264 7 ENESAS Profile Data Measurement of a variety of CPU specific data is also available as well as items that can be measured with the performance measurement function For details refer to the online help 5 9 11 Creating Profile Information Files To create a profile information file choose the Output Profile Information Files
108. and bus performance cont Type Access count cont Measurement Item Option Note Number of internal XLR The number of accesses to XY RAM access for memory in the MPU during operand fetch memory access read of an READ XY RAM or operand L memory O L Accesses via the XY bus and memory the operand bus are included When MOVX and MOVY are executed simultaneously it increments one count regardless of the read or write Number of internal XLW The number of accesses to XY RAM access for memory in the MPU during operand fetch memory access write of an WRITE XY RAM operand or L memory O L Accesses via the XY bus and memory the operand bus are included When MOVX and MOVY are executed simultaneously it increments one count regardless of the read or write Number of I L ILRW The number of accesses to I L memory access for operand fetch READ WRITE memory in the MPU during memory access read write of an operand Number of U RAM UR access READ The number of U memory accesses during memory access read of an operand Accesses via the cache are not included Number of U RAM UW access WRITE The number of U memory accesses during memory access write of an operand Accesses via the cache are not included Access miss count Number of operand CMR cache miss READ RENESAS The number of cache misses by an operand cache access read number of accesses to the o
109. ansion profiling unit optional Type number ROEO200FOEPUO0 Se adanter E200F main unit Type number p ROE0200F0EMUO00 J USB cable with debugger CD R Host machine Peripheral VO analyzer cable optional Type number ROEO2MFOOEP A00 e g MFI External bus trace unit optional Type number ROEO200FOETUOO User system Figure 1 1 System Configuration with the Emulator ROEO200FOEMU00 Note The H UDI is an interface compatible with the Joint Test Action Group JTAG specifications ENESAS Expansion profiling unit optional Type number ROEO200FOEPU00 AC adapter E200F main unit Type number ROEO200F2EMU00 with debugger CD R H UDI JAUD probe Peripheral lO analyzer cable optional Type number ROEO2MFOOEP 400 External bus trace unit optional Type number ROEO200FOETUOO User system Connect to the 38 pin H UDI connector Figure 1 2 System Configuration with the Emulator ROEO200F2EMU00 7 ENESAS The emulator provides the following features Various debugging functions Various break and trace functions enable efficient debugging Breakpoints and break conditions can be set by the specific window and trace information can be displayed on a window In addition various emulation functions such as performance and profiling functions are provided High speed downloading is implemented by supporting USB 2 0 An analyzer function is provided for the peripheral I O
110. asurement items Options in table 1 4 are parameters for lt mode gt of the PERFORMANCE_SET command They are displayed in CONDITION of the Performance Analysis window 41 7 ENESAS Table 1 4 Measurement Items Classification Type Measurement Item Option Note Disabled None Not measured CPU Cycle Elapsed cycles AC Except for power on period performance counted by the CPU clock Cycles executed in PM The number of privileged privileged mode mode cycles among the number of elapsed cycles Cycles for asserting BL The number of cycles when the SR BL bit the SR BL bit 1 among the number of elapsed cycles Instruction Number of effective l The number of execution instructions issued instructions number of valid instructions issued number of cases of simultaneous execution of two instructions The number of valid instructions means the number of completed instructions Number of 2 2l The number of times that two instruction executed instructions are executed simultaneously simultaneously among the valid instructions issued Branch Number of BT The number of unconditional unconditional branch branches other than branches occurring after an exception However RTE is counted Exception Number of EA Interrupts are included interruption exceptions accepted Number of interrupts INT NMI is included accepted Number of UBC UBC Performs OR to count the channel hit number of channel hits in the CPU 42 R
111. been set in the Event Condition dialog box that is opened by double clicking Ch1 to Ch6 and Ch8 to Ch12 on the Onchip Event sheet of the Event window Notes 1 When no measurement start end conditions are specified measurement is started by executing a program and ended when an event condition is satisfied When only the measurement start or end condition is specified performance cannot be measured Be sure to specify both of the measurement start and end conditions When the measurement start end conditions are specified step operation cannot be performed In addition when execution is restarted from the address where step operation has been stopped by the break conditions of BREAKPOINT or Event Condition step functions are used and operation is disabled Restart execution after the settings of the break conditions of BREAKPOINT or Event Condition have been canceled It is not possible to use the break conditions and the start end conditions for performance measurement at the same time with one channel If the start end conditions for performance measurement are set the settings of the break conditions will be disabled Table 1 3 Conditions Specified in the Action Page Item Description PA1 pai1_start_point Specifies the conditions of Event Condition that has been set as the measurement start condition of performance channel 1 pa1_end_point Specifies the conditions of Event Condition that has been set as the m
112. buffer and external bus trace buffer in the emulator become full This function can be set in the Internal AUD Usermemory acquisition dialog box and the BUS acquisition dialog box 7 Forced break function Forcibly breaks the user program 1 3 5 Probe Function Six external probes can be placed on the emulator 1 Four input probes Monitor input signals break the user program and start or end AUD tracing by satisfying the specified condition This can be set on the Other Event sheet of the Event window 2 One event output probe Outputs the event signal when the AUD event is detected This can be set on the Action page of the dialog box for setting the AUD event 3 One GND A probe for connecting the ground 1 3 6 Peripheral I O Analyzer Functions When the pin signals of peripheral I Os are connected to the analyzer cable the emulator sets a break and starts or ends tracing the pin signals with the specified condition by analyzing the protocols of peripheral IPs Note The analyzer functions to be supported differ depending on the product For details on the specifications of each product refer to the additional document Supplementary Information on Using the SHxxxx or the online help 36 7 ENESAS 1 3 7 Performance Measurement Function The emulator has five types of performance measurement functions 1 On chip Performance Analysis Function Onchip Performance Analysis This function applies a counter
113. cacheable area settings of TLB cacheable bit Cache on counting Accessing the non cacheable area is counted less than the actual number of cycles and counts Accessing the cacheable X Y RAM and U RAM areas is counted more than the actual number of cycles and counts Branch count The counter value is incremented by 2 This means that two cycles are valid for one branch Notes 1 In the non realtime trace mode of the AUD trace and memory output trace normal counting cannot be performed because the generation state of the stall or the execution cycle is changed 2 Since the clock source of the counter is the CPU clock counting also stops when the clock halts in the sleep mode e Extension setting of the performance result storing counter The 32 bit counter stores the result of performance and two counters can be used as a 64 bit counter To set a 64 bit counter check the Enable check box in the Extend counter group box of the Performance Analysis dialog box for Ch and Ch3 b Displaying the result of performance The result of performance is displayed in the Performance Analysis window or the PERFORMANCE_ANALYSIS command in hexadecimal 32 bits However when the extension counter is enabled it is displayed in hexadecimal 64 bits Note Ifa performance counter overflows as a result of measurement will be displayed c Initializing the measured result To initialize the measured result
114. ce function is not extended for all products For details on the specifications of each product refer to the online help e AUD Trace Function This is the large capacity trace function that is enabled when the AUD pin is connected to the emulator When a set of the branch source and branch destination instructions is one branch the maximum amount of information acquired by a trace is 262 144 The following information can be acquired e Types of trace information Branch information memory access information from the CPU and PC or Rn value during the Trace Rn instruction execution e Trace acquisition address values e Data values e External probe pin states e Time stamp values e Mnemonics 335 7 ENESAS e Operands e Source lines Notes 1 The AUD trace function is not supported for all products For details on the specifications of each product refer to the online help 2 The types of trace information that can be acquired by an AUD trace function differ according to the product For details on the specifications of each product or the number of acquired branches refer to the online help 3 When multiple loops are performed to reduce the number of AUD trace displays only the IP counts up according to the product e Memory Output Trace Function This function is used to write the trace result to the specified memory range The data is read from the memory range written in the Trace window and the result is then di
115. cessary adjust the column widths by dragging borders in the header bar immediately below the title bar Note The type and the amount of information that can be acquired by a trace differ according to the product For details on the specifications of each product refer to the online help 340 7 ENESAS 2 AUD trace function This function is available when the AUD pin of the MPU is connected to the emulator An Onchip Eventpoint must be set in order to output MPU information from the AUD pin The following is an example of acquiring memory access information between addresses H FFCO to H FFE4 array a The following is the procedure for setting the AUD trace function a Setting the Onchip Eventpoint Set the Onchip Eventpoint so that the AUD trace acquisition condition can be set to the execution information on the MPU that is output from the AUD pin referring to section 5 6 Using the Eventpoints Set the window trace from H 0 to H 10000 to Onchip Event channel Ch5 OA Select and double click Ch5 OA in the Onchip Event sheet of the Event window The Event condition 5 dialog box will appear In the Window address page specify the range of the memory access information to be output from the AUD pin 341 7 ENESAS Event condition 5 Window address ASID Bus State Action m Window address Start address fHoooo0000 End address H0001 000 Figure 6 48 Setting the Onchip
116. cified on the General 190 page The address range can only be specified for AUD event channels Ch1 and Ch2 The mask address can be input for Start when the single address is specified The mask address cannot be input for Start and End when the address range is specified RENESAS 5 SystemBus page Specifies the address and data conditions of the system bus trace Ch2 Delay General SystemBus Count Delay Action Address Don t care C Address Range Start H00000000 End HO0000000 Outside Data Dont care Load Store Load Store Value HOoooo00000000000 C Byte Outside Figure 5 37 Chx Delay Dialog Box SystemBus Page Address Sets the address condition Don t care Sets no address condition Address Sets the single address Range Sets the address range Start Sets the single address or the start address of the address range End Sets the end address of the address range Outside Sets other value than that has been set for the single address or address range as the condition 191 7 ENESAS Data Notes 192 Sets the data condition Don t care Sets no data condition Load Store Sets the load or store cycle as the condition not supported Load Sets the load cycle as the condition not supported Store Sets the store cycle as the condition Value Sets the data bus value mask
117. cifying four external probe signals via the probe cable as the condition For an operation when an event has been detected a break or AUD trace acquisition acquisition start acquisition stop can be specified Note There is a delay of several cycles from the time of detection to the break e Events by the peripheral I O analyzer Events can be detected with the peripheral I O analyzer function Notes 1 There is a delay of several cycles from the time of detection to the break 2 This function is optional it is available when a peripheral I O unit optional is used 26 RENESAS 1 3 3 Trace Functions 1 Trace Functions The emulator has mainly two trace functions e A function that acquires information within the MPU such as the CPU or system bus by a trace e A function that acquires information outside the MPU such as the external bus by a trace a Function to acquire information within the MPU by a trace The acquired trace information is displayed in the Internal AUD Usermemory trace window The information to be acquired by a trace is an event that trace acquisition is selected as the action condition in the channel on the Onchip Event sheet of the Event window To store such information there are following three methods Function to store the information in a dedicated small trace memory in the MPU Eight types of information are stored This function is enabled when the AUD pin is not connected to the em
118. ck 5MHz TLB Mode TLB miss exception is disabled y Read Status V PGSR Figure 5 1 Configuration Dialog Box General Page Items that can be displayed in this page are listed below 132 ENESAS Mode Emulation mode Step option UBC mode PPC mode Memory area Displays the MPU name Selects the emulation mode at user program execution Hardware break disable Disables hardware breaks generated in the emulator main unit case Functions to be disabled are AUD Event break BUS Event break Other Event break and trace overflow break Hardware break enable Enables hardware breaks generated in the emulator main unit case In this case the Onchip Event function and the monitoring function of the physical address during user program execution will be disabled No break Temporarily disables PC breakpoint or break condition settings during emulation Sets the step interrupt option Disable interrupts during single step execution Disables interrupts during step execution Enable interrupts during single step execution Enables interrupts during step execution Sets the UBC mode EML The UBC is used as an Onchip event function by the emulator User Releases the UBC to the users Sets the PPC mode EML The PPC is used as a performance counter by the emulator User Releases the PPC to the users Sets the method to specify the address in
119. contains the column you want to remove and click the right hand mouse button on the Editor window 2 Click the Columns menu item to display a cascaded menu item The columns are displayed in this popup menu If a column is enabled it has a tick mark next to its name Clicking the entry will toggle whether the column is displayed or not 153 RENESAS 5 2 3 Viewing the Assembly Language Code Click the right hand mouse button on the Source window to open the popup menu and select Go to Disassembly to open the Disassembly window at the address that corresponds to the current source file If you do not have a source file but want to view code in the assembly language level either choose View gt Disassembly or click the Disassembly toolbar button amp The Disassembly window opens at the current PC location and shows Address and Code optional which show the disassembled mnemonics with labels when available tutorial cpp Disassembly BEE Disassem Obj code tifdef __cplusplus extern C endif void abort void oo __cplusplus endif include sort h include lt stdlib h gt void main void 00001038 WO L R13 R16 00001034 K R14 8 R16 0000103C A PR R15 00000103E H CC R15 long a 10 long j int i class Sample p_sam while 1 00001040 WOY H 01 R1 00001042 MOY R1 R0 00001044 CMP EQ H 00 RO 00001046 BF BH 1040 8 00001048 BRA BH 115A 12 000010
120. ct Options gt Debug Sessions This will open the Debug Sessions dialog box figure 4 31 Sessions Synchronized Debue Debug sessions etaultsession SessionE200F SYSTEM Eroperties Current session DefaultSession v l Figure 4 31 Debug Sessions Dialog Box 2 Select the session you want to use from the Current session drop down list 3 Click the OK button to set the session 4 4 2 Adding and Removing Sessions A new session can be added by copying settings from another session or removing a session e To add a new empty session 1 Select Options gt Debug Sessions to display the Debug Sessions dialog box figure 4 31 2 Click the Add button to display the Add new session dialog box figure 4 32 3 Check the Add new session radio button 4 Enter a name for the session 118 RENESAS 5 Click the OK button to close the Debug Sessions dialog box 6 This creates a file with the name entered in step 4 Ifa file with this name already exists an error is displayed Add new session C Add a new session Name Cancel Use an existing session file Name tutorial Session file path Browse IV Open and maintain link to session file Make session file link read only Figure 4 32 Add new session Dialog Box e To import an existing session into a new session file 1 Select Options gt Debug Sessions to display the Debug Sessions dialog bo
121. d select Create a new project workspace radio button and click the OK button Welcome Options Cancel C Open a recent project workspace Administration 9 m C Browse to another project workspace Figure 4 17 Welcome Dialog Box 104 RENESAS 2 The Project Generator is started In this section we omit description of the settings for the toolchain If you have not purchased the toolchain the following dialog box is displayed New Project Workspace Projects Chesser Workspace Name Debugger only SHE HEX test Project Name test Directory D Hew3ttest Browse CPU family SuperH RISC engine Tool chain None nf Properties Figure 4 18 New Project Workspace Dialog Box Workspace Name edit box Enter the new workspace name Here for example enter test Project Name edit box Enter the project name When the project name is the same as the workspace name it needs not be entered Other list boxes are used for setting the toolchain the fixed information is displayed when the toolchain has not been installed 105 7 ENESAS 3 The following dialog box is displayed Setting the Targe m For Debugging MSHxxxx E200F SYSTEM CPU SH4AL Figure 4 19 Setting the Target System for Debugging Dialog Box Check the target emulator and click the Next button 106 2RENESAS 4 Set the configuration file name The configuration file saves
122. data can be input Byte Sets the byte access as the condition Word Sets the word access as the condition 32 bit Sets the 32 bit access as the condition 64 bit Sets the 64 bit access as the condition Outside Sets other value than that has been set for Value as the condition 1 This page is only displayed when SystemBus trace data is specified on the General page 2 The address range can only be specified for AUD event channels Ch1 and Ch2 3 The mask address can be input for Start when the single address is specified 4 The mask address cannot be input for Start and End when the address range is specified For the load cycle Load information on the data of the system bus is not output from the AUD pin The data condition can be set only for the store cycle 7 ENESAS 6 Count page Specifies the satisfaction count conditions Ch2 Delay General SystemBus Count Delay Action numbers Figure 5 38 Chx Delay Dialog Box Count Page Don t care Sets no satisfaction count numbers Sets a value as the satisfaction count condition D 1 to D 65535 is available Note If Trace get is selected on the Action page this page will not be displayed 193 RENESAS 7 Delay page Sets the delay cycle from the event detection to the AUD trace stop Ch2 Delay General SystemBus Count Delay Action Delay T Don t care Delay po
123. dition 6 dialog box double click on the Ch5 OA or Ch6 OA column of the Event window Remove the check mark of the Don t care check box in the Window address page and enter the memory range to be set Event condition 5 Window address ASID Bus State Action Window address y Start address H 00000000 End address H 00000000 com Figure 1 18 Window address Page 30 ENESAS i Open the ASID page remove the check mark of the Don t care check box and enter the ASID value to be set When the ASID value is not set as a condition do not remove the check mark of the Don t care check box ii Open the Bus state page and specify the bus type and bus cycle that are to be set Event condition 5 Window address ASID Bus State Action Bus state M Read Write Read Write C Read C Write Figure 1 19 Bus State Page iii Selecting the Acquire trace check box in the Action page enables acquiring memory access within the range Note To cancel settings select the popup menu that is opened by clicking on the Ch5 OA or Ch6 OA column with the right mouse button 31 7 ENESAS 32 Software Trace Function Note This function can be supported with SHC C compiler manufactured by Renesas Technology Corp including OEM and bundle products V6 0 or later However SHC C compiler including OEM and bundle products V8 0 or later is
124. dix B Command Line Functions The emulator supports the commands that can be used in the command line window For details refer to the online help 379 RENESAS 380 RENESAS 1 Appendix C Notes on High performance Embedded Workshop Note on Moving Source File Position after Creating Load Module When the source file is moved after creating the load module the Open dialog box may be displayed to specify the source file during the debugging of the created load module Select the corresponding source file and click the Open button Source Level Execution Source file Do not display source files that do not correspond to the load module in the program window For a file having the same name as the source file that corresponds to the load module only its addresses are displayed in the program window The file cannot be operated in the program window Step Even standard C libraries are executed To return to a higher level function enter Step Out In a for statement or a while statement executing a single step does not move execution to the next line To move to the next line execute two steps Operation During Accessing Files Do not perform other operations during downloading the load module operating Verify Memory or Save Memory in the Memory window or saving in the Trace or Load Coverage window because this will not allow correct file accessing to be performed Watch Local variables at opt
125. dress translation table translation look aside buffer TLB in the MPU The MMU operates during command input wait state as well as during user program execution When a command for memory access is executed while the MMU address translation function is enabled the address translated by the MMU is accessed If the specified address is not within the TLB a TLB miss occurs and the TLB must be updated by the user program The emulator has address translation functions according to the VP_MAP tables The VP_MAP tables are the address translation tables for the emulator created with the VPMAP_SET command The following shows an example of how to use the VP_MAP tables Example 1 Create VP_MAP tables for translating virtual addresses H 10000 to H 10fff to physical addresses H 4000000 to H 4000fff and virtual addresses H 11000 to H 11fff to physical addresses H O to H fff gt vs 10000 10fff 4000000 RET gt vs 11000 11fff 0 RET gt vd RET lt VADDR_TOP gt lt VADDR_END gt lt PADDR_TOP gt 00010000 OOO1OFEE 04000000 00011000 OOO11 FE 00000000 DISABLE 356 RENESAS 2 Then enable the VP_MAP tables When the tables are disabled addresses are not translated gt ve enable RET gt vd RET lt VADDR_TOP gt lt VADDR_END gt lt PADDR_TOP gt 00010000 OOO010ffE 04000000 00011000 00011fff 00000000 ENABLE Here virtual addresses correspond to physical addresses as shown in figure 6 59 H O H 12000 H 12FFF
126. e Configuration Dialog Box e Select Emulator then Systems from the Options menu to set a communication clock The Configuration dialog box is displayed Configuration General Main Board Bus Board Option Board Loading flash memory Mode SH xxxx X Emulation mode Hardware break disable ad Step option Disables interrupts during single step execution Y UBC mode v PPG mode Memory area iN C Physical Virtual E AUD clock 1 8 CPU clock z JTAG clock 5MHz TLB Mode TLB miss exception is disabled aa Read Status MV PSR Figure 6 1 Configuration Dialog Box e Set appropriate values in the AUD clock and JTAG clock combo boxes The clock also operates with the default value Note The items that can be set in this dialog box differ according to the product For details on the settings for each product refer to the online help e Click the OK button to set a configuration 297 7 ENESAS 6 5 Checking the Operation of the Target Memory for Downloading Check that the destination memory area for downloading is operating correctly When the destination memory is SDRAM or DRAM a register in the bus controller of the MPU must be set before downloading Set the bus controller correctly in the IO window according to the memory type to be used When the required settings such as the settings for the bus controller have been completed display and edit the contents of the destination memory i
127. e no break will occur c After conditions have been matched the CPU match flag is set or cleared When a program breaks the CPU match flag is initialized Set the event condition for each channel in the Event Condition dialog box this also applies to the SystemBus Sequential Extend page 180 RENESAS Usage Example of Sequential Break Extension Setting A tutorial program provided for the product is used as an example For the tutorial program refer to section 6 Tutorial in the SuperH Family E200F Emulator User s Manual The conditions of Event Condition are set as follows 1 Chl Breaks address H 00001084 when the condition Prefetch address break after executing is satisfied 2 Ch2 Breaks address H 0000106c when the condition Prefetch address break after executing is satisfied 3 Ch4 Breaks address H 000010aa when the condition Prefetch address break after executing is satisfied 4 Chl10 Breaks address H 000010e0 when the condition Prefetch address break after executing is satisfied Note Do not set other channels 5 Set the CPU Sequential Extend page as shown in figure 5 30 Then set the program counter and stack pointer PC H 00000800 R15 H 00010000 in the Registers window and click the Go button If this does not execute normally issue a reset and execute the above procedures The program is executed up to the condition of Ch10 and halted Here the condition is satisfi
128. e Acquisition Range Setting Dialog Box 278 RENESAS Enable Checking this box allows acquisition of code coverage information Coverage acquisition start address Mainboard 4M The emulator specifies the measurement start address in the range of 4 Mbytes Coverage acquisition start address Optionboard 8M The emulator specifies the measurement start address in the range of 8 Mbytes This function is only available when the expansion profiling unit is connected to the emulator OK Closes this dialog box by setting the specified condition Cancel Closes this dialog box without setting the specified condition This dialog box will only be displayed once after initiation of the emulator To open this dialog box select Hardware Settings from the popup menu of the Code Coverage window When the Coverage Acquisition Range Setting dialog box is closed the Open Coverage dialog box appears Open Covera Options Start address Ho00000 al End address H 000000 x a Cancel Br ows C 2 Open a recent coverage file C Browse to another coverage file Figure 5 105 Open Coverage Dialog Box 279 7 ENESAS In this dialog box specify a range to be shown in the Code Coverage window New Window Specifies a new coverage range Start address Enter the start address of coverage information to be displayed in hexadecimal when the prefix is omitted End address
129. e acquisition functions with the I O analyzer 21 RENESAS Table 1 1 Emulator Functions cont No Item Function 5 Break functions Breaks at satisfaction of a PC breakpoint condition 1000 points Breaks at on chip event detection Breaks at AUD event detection Breaks at external bus event detection Breaks at other types of event detection Breaks at overflow of a trace buffer Forced break function 6 Performance e measurement function Uses a counter in the device to measure the number of cycles that passes during point to point execution Uses an AUD event channel to measure the time or counts of point to point point to range or range to range execution Uses the performance function of an external bus to measure the time or counts of range point to point or range to range execution Measures the number of cycles that pass in executing individual functions and lists them at the end of execution from a Go command Measures the execution time or execution counts of functions in the address range specified by the user and lists them at the end of execution from a Go command 7 Peripheral I O analyzer e function 22 Monitors generated events of the specific peripheral I O or acquires them by a trace The supported peripheral I Os differ depending on the MPU For this function refer to the additional document Supplementary Information on Using the SHxxxx RENESAS Table 1 1 Emulator Functi
130. e are described below a Setting the trace acquisition mode Click the Internal AUD Usermemory trace window with the right hand mouse button and select Acquisition from the popup menu to display the Internal AUD Usermemory acquisition dialog box 337 7 ENESAS Internal AUD Usermemory acquisition Trace Mode Trace type C AUDtrace Int C User Memory trace Trace Mode 1 Realtime trace C Non realtime trace Trace Mode 2 f Trace continue Trace stop f Break AUD Mode Enable free trace Time stamp clock AUD trace display range Start pointer End pointer po o o User memory area Start Address moo End Address JHSFF Trace Extend Mode Trace data with PPC oee Figure 6 45 Internal AUD Usermemory acquisition Dialog Box Select Internal trace for Trace Type and click the OK button 338 RENESAS b Setting the trace acquisition condition The following is an example of acquiring branch source and branch destination information For acquiring other trace information refer to section 5 6 Using the Eventpoints Select and double click Ch12 Branch on the Onchip Event sheet of the Event window The Event condition 12 dialog box will appear Select the type of branch information After selecting Acquire trace on the Action page click the OK button Event condition 12 Branch event Action Branch Don t care J Ac
131. e displayed in this window differ according to the product For the items that can be displayed refer to the online help e The sequential break conditions that have been previously set are deleted Click the Event window with the right hand mouse button and select Delete All from the popup menu to cancel all eventpoint conditions that have been set e Select Sequential Setting from the popup menu by clicking the Event window with the right hand mouse button The Sequential setting dialog box will open figure 6 40 e Select the Don t care radio button and click the OK button 334 7 ENESAS 6 19 Trace Functions The emulator has the five trace functions listed below e Internal Trace Function Since this function uses the trace buffer built into the MPU a realtime trace can be acquired The following information can be acquired e Types of trace information Branch information memory access information from the CPU and PC or Rn value during the Trace Rn instruction execution e Trace acquisition address values e Data values e Mnemonics e Operands e Source lines Notes 1 The number of branch instructions that can be acquired by a trace differs according to the product For the number that can be specified for each product refer to the online help 2 The internal trace function is not supported for all products For details on the specifications of each product refer to the online help 3 The internal tra
132. e emulator that is connected to the master CPU Initiate the High performance Embedded Workshop using the normal procedures When initiating the slave High performance Embedded Workshop in the Channel drop down list box select the information on the serial number of the emulator that is connected to the slave CPU 293 RENESAS 294 RENESAS Section 6 Tutorial 6 1 Introduction This section describes the main functions of the emulator by using a tutorial program The tutorial program is based on the C program that sorts ten random data items in ascending or descending order The tutorial program performs the following actions e The main function generates random data to be sorted e The sort function sorts the generated random data in ascending order e The change function then sorts the data in descending order The file tutorial cpp contains source code for the tutorial program The file Tutorial abs is a compiled load module in the Dwarf2 format Notes 1 Operation of Tutorial abs is big endian For little endian operation Tutorial abs must be recompiled After recompilation the addresses may differ from those given in this section 2 This section describes general usage examples for the emulator For the specifications of particular products refer to the additional document Supplementary Information on Using the SHxxxx or the online help 3 The operation address of Tutorial abs attached to each product differs
133. e main unit case Figure 2 10 Connecting the Expansion Profiling Unit to the Main Unit Case 67 7 ENESAS e Fasten the expansion profiling unit with screws provided Figure 2 11 Fastening the Expansion Profiling Unit to the Main Unit Case e Close the cover of the main unit case to be fastened with two screws e Fasten the screw of the base unit 68 7 ENESAS 2 4 Connecting the AC Adapter to the Emulator Main Unit Case Connect the provided AC adapter to the main unit case Figure 2 12 Connecting the AC Adapter to the Main Unit Case Connect the provided AC adapter to the connector to input DC 12 V of the AC adapter marked DC IN 69 RENESAS WARNING Be sure to use the AC adapter dedicated for E200F Failure to do so will result in a FIRE HAZARD and will damage the user system or the emulator product 2 5 Connecting the Emulator to the Host Machine This section describes how to connect the emulator to the host machine For the position of each connector of the emulator refer to section 1 2 Emulator Hardware Configuration Notes 1 When Add New Hardware Wizard is displayed select the Search for the best driver for your device Recommended radio button and then the Specify a location check box to select the path to be searched for drivers The location must be specified as lt Drive gt DRIVERS lt Drive gt is the CD drive letter 2 Be sure to install the software for t
134. e on Displaying Timeout error If Timeout error is displayed the emulator cannot communicate with the target microcomputer Turn off the user system and connect the USB connector of the emulator again by using the High performance Embedded Workshop 1 WwW Note on Using the Run Program Dialog Box When Run is selected from the Debug menu to specify the stop address there is the following note When the breakpoint that has been set as Disable is specified as the stop address note that the breakpoint becomes Enable when the user program stops 14 BREAKPOINT Setting for SLEEP Instruction When a break is set for the SLEEP instruction use the Break Condition not the BREAKPOINT 15 Note on Session Save in the Configuration Dialog Box The following settings are not saved as a session JTAG clock in the General page Loading flash memory in the Loading flash memory page 383 RENESAS 16 Scrolling Window During User Program Execution Do not scroll the Memory and Disassembly windows by dragging the scroll box during user program execution This generates many memory reads causing the user program to stop execution until the memory reads have been completed 17 Memory Test Function This product does not support the memory test function which is used by selecting Test from the Memory menu 384 7 ENESAS Appendix D Repair Request Sheet Thank you for purchasing the E200F emulator ROEO
135. easesscdnetsapeseczacesapessesedatesessepespeteaaes 171 5 6 5 Setting Onchip Eyentpointssssissoscrieirsnriiiaieee iiin 173 5 6 6 Setting AUD EventpolntS ecsscrssinerei osre aner e nE aA A E SEa E E 182 5 6 7 Setting BUS EvyentpolntSo irsirissiecniessosae sitni inperioari eetis 199 5 6 8 Setting Other Eventpoints eee eee eeceeseeeseeeseeeseseseceeeaeeeaesesessseeseeeneeeaees 209 5 6 9 Editing Breakpoint or Eventpoint 0 eee cece eeseeeeceeecseeeaeeeseeeaecesessseeeeeaees 214 5 6 10 Enabling Breakpoint or Eventpoint eee eee ese ceseceeeseeeeseeeseeeaeeeseesseeeneesees 214 5 6 11 Disabling Breakpoint or Eventpoint 00 eee cece eese cece ceeeeseeeaeeeseenseesseeneeeaees 214 5 6 12 Deleting Breakpoint or Eventpoint 0 0 ee eee eseeeeceeeceeeeseeeseeeaeceseeseeeeeeaees 214 5 6 13 Deleting All Breakpoints or Eventpoint 00 0 cece eeeeceeeeeeeeeeeeeeneeesseenseesees 214 5 6 14 Viewing the Source Line for Breakpoints or Eventpoints 0 0 0 0 ee eeeeeeeees 214 Viewing the Trace Information ee eeeesceseceseeeceeseeeeeesecececseecaeeeaeenarsnaeeseeeneeeneeeaees 215 5 7 1 Opening the Internal AUD Usermemory trace Window c eects 215 5 7 2 Opening the BUS MFI trace Window ee eeeeseeseeeeceeeeeeeeaeeeaeenaeesseeeneeeaes 223 5 7 3 Hiding the Trace Colmtiis s sc csisecssesviss cogs stcesectsuge e rE a 226 5 7 4 Searching for a Trace Record ee eeeecceeceeseeeseceseceseseeeceeeseeeseeeaeeeaeeeseesseesees 227 5 7
136. easurement end condition of performance channel 1 PA2 pa2_start_point Specifies the conditions of Event Condition that has been set as the measurement start condition of performance channel 2 pa2_end_point Specifies the conditions of Event Condition that has been set as the measurement end condition of performance channel 2 PA3 pa3_start_point Specifies the conditions of Event Condition that has been set as the measurement start condition of performance channel 3 pa3_end_point Specifies the conditions of Event Condition that has been set as the measurement end condition of performance channel 3 PA4 pa4_start_point Specifies the conditions of Event Condition that has been set as the measurement start condition of performance channel 4 pa4_end_point Specifies the conditions of Event Condition that has been set as the measurement end condition of performance channel 4 39 7 ENESAS Event condition 1 Address ASID Bus State Action pal _start_point C pal _end_point fad star paint 6 Figure 1 21 Action Page Note PA1 or PA2 cannot be set for Ch8 and Ch9 e Measurement tolerance The measured value includes tolerance Tolerance will be generated before or after a break For details see table 1 6 40 7 ENESAS Measurement items Items are measured in the Performance Analysis dialog box for each channel from Ch1 to Ch4 A maximum of four conditions can be specified at the same time Table 1 4 shows the me
137. ecting the cable check that it is connected correctly For details refer to section 2 Setting Up the Emulator 6 Supply power to the connected equipment after connecting all cables Cables must not be connected or removed while the power is on 1 1 Components Check that all of the components are present when unpacking the product For details on the emulator components refer to section 1 1 in the additional document Supplementary Information on Using the SHxxxx If all of the components are not present contact your nearest Renesas sales office 7 ENESAS 1 2 Emulator Hardware Configuration As shown in figure 1 3 the emulator ROEO2Z00FOEMU00 consists of a main unit case a trace unit optional an expansion profiling unit a USB cable an AC adapter an external probe and an peripheral I O analyzer unit optional The emulator is connected to the host machine via USB 2 0 Figure 1 4 shows the hardware configuration of the emulator ROEO200F2EMUO00 E200F main unit Expansion profiling unit optional Included in main unit Debugger CD R AC adapter USB cable External probe Peripheral KO analyzer unit optional Trace unit optional Figure 1 3 Emulator Hardware Configuration ROEO200FOEMU00 7 ENESAS E200F main unit Included in main unit Debugger CD R AC adapter USB cable External probe Expansion profiling unit optional Peripheral VO analyzer unit optional Trace unit optiona
138. ed 240 RENESAS 6 Bus page Select the status of a bus The selection is not available when a time stamp is acquired Trace Filter General Address data Type Bus Don t care Setting Cancel Apply Figure 5 73 Trace Filter Dialog Box Bus Page Don t care Detects no bus condition when this box is checked Setting Detects the specified bus condition not available when Don t care has been checked 241 7 ENESAS 5 7 11 Analyzing Statistical Information Choose Statistic from the popup menu to open the Statistic dialog box and analyze statistical information under the specified conditions Statistic r Statistic Analysis ile C Range lt None gt x Result Figure 5 74 Statistic Dialog Box Statistic Analysis Setting required for analysis of statistical information Default Sets a single input value or character string Range Sets the input value or character string as a range Item Sets the item for analysis Start Sets the input value or character string To set a range the start value must be specified here 242 RENESAS End Specify the end value if a range has been set only available when Range has been selected Set Adds a new condition to the current one New Creates a new condition Result button Obtains the result of statistical information analysis Clear Initializ
139. ed Performance option is enabled and the time interval of the performance measurement can be specified Sampling time Specifies the time interval of the AUD 195 7 ENESAS performance measurement as any of the following values 20 ns 40 ns 100 ns or 400 ns Enable output trigger Specifies whether or not the trigger is output after conditions have been matched Notes 1 For AUD performance measurement two AUD event channels are used to start and 196 stop measurement When an event channel is specified for performance measurement the related channels Ch1 to Ch2 Ch3 to Ch4 Ch5 to Ch6 and Ch7 to Ch8 must also be specified 2 The Performance option is only displayed for AUD event channels Ch1 Ch3 Ch5 and Ch7 RENESAS 9 Sequential AUD Event dialog box The sequential AUD event occurs when all the AUD Eventpoint conditions are satisfied in the specified order AUD event channel Ch1 can be specified as the reset point When the reset point is passed the satisfied eventpoint condition is disabled and checking the first eventpoint condition is started Sequential AUD Event I Don t care Channel select C Channel 3 gt 2 Channel 5 gt 4 gt 3 gt 2 C Channel 6 gt 5 gt 4 gt 3 gt 2 C Channel gt 6 gt 5 gt 4 gt 3 gt 2 C Chamel 8 gt 7 gt 6 gt 56 Se Aloe Soe Sequential reset Disable C Enable Action Break Trace stop oeei
140. ed for the RAM area Therefore an operation such as memory write or BREAKPOINT should be set only for the RAM 53 7 ENESAS area When the memory area can be read by the MMU do not perform memory write BREAKPOINT setting or downloading 3 Cache operation during user program break When cache is enabled in the device incorporating a cache the emulator accesses the memory by the following methods e At memory write Writes to the cache then issues an external single write The LRU is not updated e At memory read Reads memory from the cache The LRU is not updated 1 3 9 Stack Trace Function The emulator uses the stack s information to display the name of the calling function for a function at the current program counter This function can be used only when the load module that has the Dwarf2 type debugging information is loaded For the usage of this function refer to section 6 21 Stack Trace Function 1 3 10 User interrupt Open Function during User Program Break Some devices to be debugged enable all interrupts while executing emulation to the user During a user program break it is possible to specify the mode whether or not the interrupt processing is executed 1 3 11 Online Help An online help explains the usage of each function or the command syntax that can be entered from the command line window Select Emulator Help from the Help menu to view the emulator help 54 RENESAS 1 4 Environmental Conditions
141. ed in the order of Ch2 gt 1 gt 4 gt 10 181 RENESAS wewevauwun o000106c ali j 00001084 p_sam gt sort a o0000108e p_sam gt change a 00001098 p_sam gt s0 a 0 000010aa p_sam gt sl a 1 0000 10be p_sam gt s2 a 2 o00010ce p_sam gt s3 a 3 o00010e0 o00010f2 p_sam gt s5 a 5 00001104 p_sam gt s a 6 00001116 p_sam gt s7 a 7 00001128 p_sam gt s8 a 8 0000113a p_sam gt s9 a 9 00001146 ied p_sam Figure 5 31 Source Window at Execution Halted Sequential Break 5 6 6 Setting AUD Eventpoints On the AUD Event sheet the settings for AUD Eventpoints are displayed and modified Event Reset Branch source address H 1234 Break Delay None Normal Window address H 5678 outside data H FFFF word read count D 1234 Trace start Normal None Normal Software address H 2222 PAS start interval 20ns Normal None Normal None Normal None Breakpoint A Onchip Event Figure 5 32 Event Window AUD Event Sheet Using eight event detection channels sets eight eventpoints Note Since the AUD eventpoint condition is set according to the information in the MPU output from the AUD pin the trace acquisition condition for the Onchip Eventpoint must be set 182 RENESAS Set trace acquisition conditions for on chip event channels Ch5 OA Ch6 OA Ch7 SystemBus Ch8 SystemBus and Ch12 Branch or software trace Items that can be displayed
142. ee eeeeeeeeeeeeeeceeeseeeeeteserseeeaeeeaeens 254 5 8 7 Deleting All Measurement Conditions 0000 0 eeceeseeeseeeseeeseceeeseeeeseeeaeees 255 Viewing the Profile Information eee eee cee cseeeneeeseceseesseceeeseeeaeseaessaesseesseeeseeentees 255 59 1 Stack Information Files sc 34 2 ccsisssedesvs nenn oR AEE EEEE ER ERE EREE 255 5 9 2 Profile Information Files eee eee seiis nii aiiis aniis 257 5 9 3 Loading Stack Information Files ss ssseseeseesesseesssrsresresresrrsresresresrnrrsrrsresrenresrene 258 5 9 4 Enabling the Proflesissirsssienenna n r E E 259 5 9 5 Specifying Measuring Mode ee eee eeeeceececeeeseeeeeeseeeaeeeaeseaeseeeseeeeeeeeaeee 259 5 9 6 Executing the Program and Checking the Results 0 0 0 eee eeseeeeeeeetereeeeeeeees 259 DOT List SWC tees sesciccasciee oa eaves aeeateets coed set re eE ER E veaes E abate ie 260 59 8 Iree Sheet rnei nasi E E aE E ETE 261 59 9 Profile Chart WNdOW ccrtcn E de ees 264 5 9 10 Types and Purposes of Displayed Data sessssessseeseeseesesresrerrsrrsrrsrrnrenresrrsrnseses 264 5 9 11 Creating Profile Information Files 0 0 0 0 eee eeeeseeeseeeeeseeeeseeeaeeeaeeneeeeeeeaeees 265 DDD NOES er a E E ety ammevists gttvesst 266 Viewing Realtime Profile Information eee eee eeeeseeeeeeseseeeseeeseeeaeeeaeeneeeseeeseees 268 5 10 1 Opening the Realtime Profile Window 000 0 eee ec eeceeseeeseeeseeeeeceaeeneeeeeeeaeees 274 5 10 2 Specifying the Measurement Range 00 0 eee eee
143. eeeeseeeseeeseeeaeeeaeesees 157 5 3 1 Opening the Monitor Window cc ceceeceeseesecesecesesesecececeeeeaeeeaeseseeneeeneeesensaes 158 5 3 2 Changing the Monitor Settings ec eeeceeceeeeeseeeseeeseseeeceeeeaeeeaeeeaeenaeesseeeaeeeaes 160 5 3 3 Temporarily Stopping Update of the Monitor eee eeeeeeeeeeeeeeseeeeeeseeeeees 161 5 3 4 Deleting the Monitor Settings 0 0 ceceeeeeeeeeeeeeseseeeceaeeceeeeeaeeeaeseaeseaeeeaes 161 5 3 3 Monitoring Variables sssrini opsie e aian ANTE 161 5 3 6 Hiding the Monitor Window sesseesesesseeseesressrsesesseersrsrersressresereseresrensenesrnssense 163 5 3 7 Managing the Monitor Window sssesssssesesssssserssrsresresresresresrssrsrenresresresresreerese 164 Viewing th Current Status iniinis en e e aa Ea NA a Sii 165 Reading and Displaying the Emulator Information Regularly eee eee eeeeeeeees 166 5 5 1 Opening the Extended Monitor Window 0000 eee eeeeseeeeeceeeeeseeeeeeneeeneeeaees 166 5 5 2 Selecting Items to be Displayed 0 eee ceeeseeeseeeseceeecseeeeeeseeeeseaeeeaeesaes 167 Using the Bventpomnts s 2 scisipssscesgises Sissi ipen ressa is Gi sscge des A e ES ioioGuaa westiees 168 5 6 1 PC Break powats isossa ETE E E saaueteersevveyeevacuuabewees 168 5 0 2 Eventpoint sian eai n Ee A AEE A R NE 168 5 6 3 Opening the Event Window ssesssesssseesssresrsresrrsresreerssrertnrnrrsrrsrenrenresrnsrnsrerret 170 5 0 4 Setting PC BreakpointS cisc s cccsciss agecsgevepecogscneec
144. eesneeeeeaes 72 2 6 1 Connecting the E200F H UDI AUD Probe to the User System ee 73 2 6 2 Connecting System Ground o0 eee eeceneceeeeseesseeseeeseecseeeaeeeaseneesneeeneeeeeeaees 76 2 7 Changing the Seti gs cu ccisedcisesateres deed pisinn inise aee p n a EE EE ESAE EE E N 71 2 7 1 Changing the Functions when Using the E200F Main Unit ee 78 2 7 2 Changing the Functions when Using the External Bus Trace Unit 79 2 7 3 Changing the Functions when Using the Expansion Profiling Unit 80 2 7 4 Changing the Monitoring Function lee eseceseceeeseeeeseeeaeeesecseeeseeeneeeaees 81 RENESAS section 3 Hardware SpeCieahOns za c2sescccs2ssscdsveedstsanonagecadacsaseitencetGseenseseduancsss 83 Sel List OFS PECiACAtIONS ssion eoe aE E E a e a ENS 83 3 2 Interface Circuits in the Bru lator css ctscssessasesscesasesety sapevveesdecvveses caus EE ANEKERE ESKER Eai 83 3 3 Reducing BMILNOISG ws catessicresescscceviegiead sipesiasbdesddedecpasseachaulans E r REENA NEE E 88 3 4 Diagnostic Procedure scsi cs steasccsavencetevasacesevestech seeds itueveay eo daa Euni AE AERAR Ei 89 3 4 1 Installing the Diagnostic Program sseseseesreseesesreeresrerrsrrsresresresrenrsrrsrenresresrese 89 3 4 2 Executing the Diagnostic Program seeeeseseesesresrertrresrestesresresrerrnresresrrnresresrnsent 89 34 3 Creating a Log Fil ssrsicsisor arpir nienn ae ne AEAEE 93 Section 4 Preparations for Debugging esessesrreereserrersrrsrrsrrrsersrt
145. em on the menu will be checked 5 9 5 Specifying Measuring Mode You can specify whether to trace functions calls while profile data is acquired When function calls are traced the relations of function calls during user program execution are displayed as a tree diagram When not traced the relations of function calls cannot be displayed but the time for acquiring profile data can be reduced To stop tracing function calls choose Disable Tree Not traces function call from the pop up menu in the Profile window a check mark is shown to the left of the menu item When acquiring profile data of the program in which functions are called in a special way such as task switching in the operating system stop tracing function calls 5 9 6 Executing the Program and Checking the Results After the user program has been executed and execution has been halted the results of measurement are displayed in the Profile window The Profile window has two sheets a List sheet and a Tree sheet 259 7 ENESAS 5 9 7 List Sheet This sheet lists functions and global variables and displays the profile data for each function and variable Profile Function Variable __ F v address size Tines option option2 PowerON Reset PC H oooo0002c Sample sort long H o0000202E H o0000074 Sample Sample H o00002000 H 0000002E _ divlu H 00001446 H o0000000 0x00001360 H 00001360 H o0000000 H 000012B0 H o0000000 H o000120C H o000000
146. emulator driver USB drivers for the E200F emulator Help Online help for the E200F An online help file This is copied to the hard emulator disk as part of the installation process Manual E200F emulator manuals E200F emulator user s manuals They are provided as PDF files sot Diagnostic program for the The usage is described in section 3 4 E200F emulator Diagnostic Procedure Execute HewInstMan exe from the root directory of the CD R to start the installation manager Follow the cues given by the installation manager to install the software Note When a driver is installed in Windows XP a warning message on the Windows logo test may be displayed but it is not a problem Select Continue Anyway to proceed with driver installation 58 7 ENESAS 2 3 Connecting the Optional Units to the Emulator Main Unit Case Optional units are included in the emulator This section describes how to connect them to the E200F main unit case 2 3 1 Connecting the E200F Trace Unit to the User System e Open the cover of TRACE I F on the side of the main unit case e Connect the trace cable provided for the trace unit to the emulator as shown in figure 2 2 Figure 2 2 Connecting the Trace Cable to E200F 59 RENESAS e Connect the trace unit to the trace cable CN1 side Figure 2 3 Connecting the Trace Cable to the Trace Unit 60 RENESAS e After checking the location of pin 1 connect the user system to the trace uni
147. ent sheet of the Event window 3 BUS Eventpoint This is a function that sets eventpoints according to the external bus of the MPU or information on the pin such as an interrupt pin There are six event detection channels For an operation when an event is detected break or external bus trace acquisition acquisition start acquisition stop can be specified A combination of one or more of the BUS evenpoints enables specifying more complex sequential conditions This function can be set in the BUS Event sheet of the Event window Notes 1 When the trace unit is not connected to the emulator this function is not supported 2 When the function of the trace unit is changed the function of event detection channels is changed For details refer to section 5 1 4 Bus Board Page 4 Other Eventpoint This function can be set in the Other Event sheet of the Event window a Execution time eventpoint Eventpoints can be defined specifying the program execution time as the condition There is one event detection channel For an operation when an event is detected break can be specified b External probe eventpoint Eventpoints can be defined specifying four external probe signals via the probe cable as the condition There is one event detection channel For an operation when an event is detected break or AUD trace acquisition acquisition start acquisition stop can be specified c Other eventpoints Event condi
148. ent such as product data diagrams charts programs algorithms and application circuit examples is current as of the date this document is issued Such information however is subject to change without any prior notice Before purchasing or using any Renesas products listed in this document please confirm the latest product information with a Renesas sales office Also please pay regular and careful attention to additional and different information to be disclosed by Renesas such as that disclosed through our website http Awww renesas com Renesas has used reasonable care in compiling the information included in this document but Renesas assumes no liability whatsoever for any damages incurred as a result of errors or omissions in the information included in this document When using or otherwise relying on the information in this document you should evaluate the information in light of the total system before deciding about the applicability of such information to the intended application Renesas makes no representations warranties or guaranties regarding the suitability of its products for any particular application and specifically disclaims any liability arising out of the application and use of the information in this document or Renesas products With the exception of products specified by Renesas as suitable for automobile applications Renesas products are not designed manufactured or tested for applications or otherwise in systems the f
149. epairing products of the model may become impossible 8 4 4 Transportation Fees at Sending Your Product for Repair Send your product to us for repair at your expense 372 7 ENESAS 8 5 How to Make a Request for Repair If your product is found faulty follow the procedure below to send your product for repair Fill in the Repair Request Sheet included with this product then send it along with this product for repair to your local distributor Make sure that information in the Repair Request Sheet is written in as much detail as possible to facilitate repair A CAUTION Note on Transporting the Product When sending your product for repair use the packing box and cushion material supplied with this product when delivered to you and specify handling caution for it to be handled as precision equipment If packing of your product is not complete it may be damaged during transportation When you pack your product in a bag make sure to use conductive polyvinyl supplied with this product usually a blue bag When you use other bags they may cause a trouble on your product because of static electricity 373 RENESAS 374 RENESAS Table A 1 shows GUI menus Table A 1 GUI Menus Menu View Appendix A Menus Toolbar Option Shortcut Button Remarks Disassembly Ctrl D Opens the Disassembly window Command Line Ctrl L Opens the Command Line window Workspace Alt K 1 Opens the Wor
150. er flow Trace continue Trace stop Break BUS trace mode Enable free trace M CS2 SDRAM trace M CS3 SDRAM trace Time stamp clock Trace display range Start pointer D 255 End pointer D0 ores Figure 6 56 BUS acquisition Dialog Box 353 RENESAS c Setting the trace acquisition condition The following is an example of setting the address condition For setting other trace conditions refer to section 5 6 Using the Eventpoints Select and double click Ch3 Normal on the BUS Event sheet of the Event window The Ch3 Normal dialog box will appear Ch3 Normal Address Data Interrupt Count Action m Address I Don tcare Address Start H00007000 End H00002000 Outside Figure 6 57 Ch3 Normal Dialog Box Address Page e Select Range e Input H 1000 and H 2000 into Start and End respectively e Select Trace get in the Action page and click the OK button e The trace information when external memory H 1000 to H 2000 has been accessed is acquired 354 7 ENESAS d Displaying the trace result Run the program as shown in the example of section 6 17 1 PC Break Function The internal trace results are displayed in the BUS MFI trace window after the program execution is completed PTR IP R W Address 000037 D 000037 READ 000036 D 000036 READ 000035 D 000035 READ 000034 D 000034 READ 000033 D 0000
151. es the settings Result list box Clears all conditions and results of statistical information analysis Close Closes this dialog box All the results displayed in the Result list will be cleared This dialog box allows the user to analyze statistical information concerning the trace information Set the target of analysis in Item and the input value or character string by Start and End Click the Result button after setting a condition by pressing the New or Add button to analyze the statistical information and display its result in the Result list Note In this emulator only PTR can be set as a range Each of other items must be specified as a character string In analysis of statistical information character strings are compared with those displayed in the Trace window Only those that completely match are counted Note however that this test is not case sensitive The number of blanks will not be cared either 243 RENESAS 5 7 12 Extracting Function Calls from the Acquired Trace Information To extract function calls from the acquired trace information select Function Call from the popup menu The Function Call Display dialog box will be displayed Function Call Display Setting Enable to display trace information with function call only C Disable OK Cancel Figure 5 75 Function Call Display Dialog Box Setting Selects whether or not to extract function calls
152. esponding source file Reading the stack information file makes it possible for the High performance Embedded Workshop to display this information to do with the calling of functions without executing the user application i e before measuring the profile data However this feature is not available when Setting gt Only Executed Functions is checked in the pop up menu of the Profile window When the High performance Embedded Workshop does not read any stack information files the data about the functions executed during measurement will be displayed by the profile function To make the linker create a stack information file choose Build gt SuperH Risc engine Standard Toolchain and select Other from the Category list box and check the Stack information output box in the Link Library sheet of the Standard Toolchain dialog box 255 7 ENESAS EG All Loaded Projects Sg C source file G source file Assembly source file Compress debug information Linkage symbol file JLow memory use during linkage Absolute Relocatable Library M5tack information output O noprelink rom D R nomessage list CONFIGDIRD PROJECTNAME map nooptimize start DVECTTBL DINTTBL 00 PResetPRG PhlhtPRG 0800 P C C Figure 5 87 Standard Toolchain Dialog Box 1 256 z ENESAS 5 9 2 Profile Information Files To create a profile information file choose the Output Profile Informatio
153. ess bus value or the program counter value matches the specified value Data bus condition Data Breaks when the MPU data bus value matches the specified value Byte word or longword can be specified as the access data size Bus state condition Bus State There are two bus state condition settings Bus state condition Breaks or acquires a trace when the data bus or the X Bus or Y Bus address bus of the MPU is matched Read Write condition Breaks or acquires a trace when the specified read write condition is matched Window address condition Breaks or acquires a trace when the data in the specified memory range is accessed System bus Breaks or acquires a trace when the address or data on the system bus is matched LDTLB instruction event condition Breaks when the MPU executes the LDTLB instruction Count Breaks when the conditions set are satisfied the specified number of times Branch trace condition Branch trace Breaks or acquires a trace when a branch occurs with the condition specified by the MPU By default trace acquisition is enabled Software trace Selects whether or not the software trace is acquired Action Selects the operation when a condition such as setting a break trace or performance start or end is matched Table 5 2 lists the combination of conditions that can be set by Chl to Ch12 and software trace channels 175 RENESAS Table 5 2
154. eting Breakpoint or Eventpoint Select a breakpoint or an eventpoint and choose Delete from the popup menu to delete the selected breakpoint or eventpoint To retain the break condition but not have it cause an event when its conditions are met use the Disable option see section 5 6 11 Disabling Breakpoint or Eventpoint Select a breakpoint or an eventpoint and click Delete from the popup menu Deletes the selected breakpoint s or eventpoint s To retain the details of the breakpoint or eventpoint but not have it satisfy the condition when its conditions are met use the Disable option see section 5 6 11 Disable Breakpoint or Eventpoint 5 6 13 Deleting All Breakpoints or Eventpoints Choose Delete All from the popup menu to delete all breakpoints or eventpoints 5 6 14 Viewing the Source Line for Breakpoints or Eventpoints Select a breakpoint or an eventpoint and choose Go to Source from the popup menu to open the Source or Disassembly window at the address of the breakpoint or eventpoint The Go to Source menu is only available when one breakpoint or eventpoint that has the corresponding source file is selected 214 RENESAS 5 7 Viewing the Trace Information In the emulator there are functions to acquire information within and outside the MPU by a trace The emulator acquires four types of trace information internal trace Internal trace AUD trace AUD trace trace that is output to the user memory Usermem
155. eviewing Breakpoints 0 eee ee eeeeeeceseeeceeeceeseeeseeeseeeseeseesseecseesseeeaeeeaeesaeetaeseaesenereneats 308 6 11 Referrims to Symbols sssesicsscscssesecececeseceichateeazecavenesesaeetveds cede seep useage acvaestapassasea sees iseveccebeseas 309 6 12 Viewing MEMOry acoria e E EE RE slates EEES 310 OAS Watching Variables ccecce ra aane a NENEN ENE 312 6 14 Displaying Local Variables cscssiciiesrsssiinscsisrsnrcrisiesersisioncrsieterrsisrssscsisisneesinisoerstsisist 315 6 15 Stepping Through a Program eee cece eeseeseeeseeeseeeseeeseceaeceaeeeeeseeeseessesesessaessaeesaeeags 316 6 15 1 Executing Step In Command ee eecesecesececeseeeeeeeaeeeaeenaecssessneeseeenees 316 6 15 2 Executing Step Out Command 00 0 eee eee eseeeseceeececececesseeeseeeaeeeaeeeseeseeeaees 318 6 15 3 Executing Step Over Command 000 cee eee eeeeseceeceeeteeeeaeeeaeeeaeseaeesseeseeeaees 319 6 16 Forced Breaking of Program Executions 0 cece eeceeeeeeseeeseceseeeseceseseneeseeeeeeaeeeseeeaeeeas 320 6 17 Break FUMCI ON cnie ar Ee a E e aE 321 6 17 1 PG Break PUM Ct OM sisi cssessse aseiceceasteactes isa E TE AEE EAS 321 6 18 Break Function by an Eventpoint s eeseessesesrsressreressreresresrnresrrstestrsresrnsrnrenrrsrestestreneesreet 326 6 18 1 Setting the Break by an Onchip Eventpoint ssssessesseseeseeeersreerssreresrrsresresreeree 326 6 18 2 Setting the Sequential Onchip Eventpoint sssessessereseeresreersreerssrerrsresresre
156. f cycles that have elapsed since the latest trace information was gathered For branch instructions the branch source and destination are counted together as one e Master Type of bus master that accessed the memory e Type Displays the type of trace acquisition information e Branch Type Branch type only displayed for a branch trace For an AUD trace this item is only displayed if the PPC option has been enabled e Bus Displays which bus was accessed e R W Displays whether the access involved reading or writing e Address Displays the addresses from which the trace data was acquired e Data Displays the data acquired in the trace 7 ENESAS e PPC Output from a performance counter e Instruction Source Label Displays the mnemonic of the instruction at the trace acquisition address along with the corresponding source code and label information Double clicking on the Source column moves the cursor to the corresponding position in the Editor window The Type BUS R W Address and Data columns have different meanings according to the type of trace that has been selected Table 1 2 Trace Window Display Contents Trace Type Type Column BUS Column R W Column Address Column Data Column Branch trace BRANCH No display No display Branch source No display address DESTINATION No display No display Branch destination No display address Memory MEMORY No display Read write Memory access Memory range
157. f each function the subroutine execution time is also included e Coverage 4M Acquires the information on the CO coverage in the 4 Mbyte areas e Others The peripheral I O analyzer function can be selected depending on the product Note Using the realtime profiling and coverage functions increases the ranges that can be set with the expansion profiling unit 78 RENESAS 2 7 2 Changing the Functions when Using the External Bus Trace Unit Select the item in the Bus board mode setting combo box of the Function select dialog box Function select x m Function setting Main board mode setting RealProfile Areal function mode x ee Bus board mode setting Performance ch v Option board mode setting RealProfile Area2 function mode m Monitor Setting Virtual space C Physical space Figure 2 20 Function select Dialog Box e Trace break 6ch Trace 262144 cycles Uses the channel for detecting the external bus event as a break e Performance 6ch Uses the channel for detecting the external bus event as a channel for measuring the execution time e Emulation memory 4M Trace 8192 cycles Uses the external emulation memory function 4 Mbytes x 1 block Note When the trace unit is not connected to the emulator this combo box is displayed in gray 79 RENESAS 2 7 3 Changing the Functions when Using the Expansion Profiling Unit Select the item in the Option board mode se
158. fered from those I had made The last settings to be saved are effective While a workspace is open in the High performance Embedded Workshop updating of the workspace is within the memory The settings are not saved in a file unless the user intentionally saves the workspace In addition to above refer to FAQs on the emulator and High performance Embedded Workshop on the Renesas web site www renesas com 369 RENESAS 370 RENESAS Section 8 Maintenance and Guarantee This section describes maintenance guarantee repair provisions and how to request for repair of the emulator 8 1 User Registration When you purchase our product be sure to register as a user For user registration refer to the section of User Registration p iii of this user s manual 8 2 Maintenance 1 If dust or dirt collects on any equipment of this product wipe the board dry with a soft cloth Do not use thinner or other solvents because these chemicals can cause the equipment s surface coating to separate 2 When you do not use this product for a long period for safety purposes disconnect the power cable from the power supply 8 3 Guarantee If your product becomes faulty within one year after its purchase while being used under good conditions by observing IMPORTANT INFORMATION described in this user s manual we will repair or replace your faulty product free of charge Note however that if your product s fault is raised by any
159. following file and click the Open button Look in Atul e e _ Tutorial Tutorialhws File name IT utorial hws Files of type Workspaces hws Cancel ii Figure 4 3 Open Workspace Dialog Box 8 The CPU Select dialog box is displayed GPU Select GPU Select SHE Figure 4 4 CPU Select Dialog Box Select the CPU from the drop down list and click the OK button 97 RENESAS If the following dialog box is displayed the emulator will not support the CPU in use Check the type number of the main unit referring to section 1 1 Components of the Emulator in the additional document Supplementary Information on Using the SHxxxx he200ush4a Figure 4 5 This CPU is not supported Dialog Box 9 The Function select dialog box is displayed Function select x Function setting Main board mode setting RealProfile Areal function mode x Bus board mode settine Perfor mance Bch Option board mode setting RealProfile Area2 Gunction mode x m Monitor Setting Virtual space Physical space Cancel Figure 4 6 Function select Dialog Box Select the emulator function to be used For the items to be selected refer to section 2 7 Changing the Settings 98 RENESAS 10 The Connecting dialog box is displayed and the emulator connection is started GConnectine Figure 4 7 Connecting Dialog Box 11 The dialog box is displayed as shown in figure 4 8
160. function again Note For details on this function refer to the online help 360 RENESAS 6 22 Download Function to the Flash Memory Area The emulator enables downloading to the external flash memory area This function requires a program for writing the flash memory hereinafter referred to as a write module a program for erasing the flash memory hereinafter referred to as an erase module and the RAM area for downloading and executing these modules Note The write and erase modules must be prepared by the user e Interface with write and erase modules and emulator firmware The write and erase modules must be branched from the emulator firmware To branch from the emulator firmware to the write and erase modules or to return from the write and erase module to the emulator firmware the following conditions must be observed Describe all the write and erase modules with the assembly language Save and return all the general register values and control register values before and after calling the write or erase module Return the write or erase module to the calling source after processing The write and erase module must be a Motorola type file The module interface must be as follows to pass correctly the information that is required for flash memory accessing Table 6 3 Module Interface Module Name Argument Return Value Write module R4 L Write address RO L End code R7 L Verify option Normal end 0
161. g PTR values to start and end filtering can be set in the Start PTR and End PTR options respectively 236 RENESAS 2 Address page Set address conditions Trace Filter T Don t care Setting Point C Range From F To Cancel Apply Figure 5 69 Trace Filter Dialog Box Address Page Don t care Detects no address when this box is checked Setting Detects the specified address Point Specifies a single address not available when Don t care has been checked Range Specifies an address range not available when Don t care has been checked From Enter a single address or the start of the address range not available when Don t care has been checked To Enter a single address or the end of the address range only available when Range has been selected Note Along with setting the address range the start and end of the address range can be set in the From and To options respectively 237 RENESAS 3 Data page Set a data condition Trace Filter Setting Point Range From F To Cancel Apply Figure 5 70 Trace Filter Dialog Box data Page Don t care Detects no data when this box is checked Setting Detects the specified data Point Specifies single data not available when Don t care has been checked Range Specifies a data range not available when Don t care has been checked F
162. ge AC100 V 10 Frequency 50 60 Hz Consumption power 48 W CD ROM drive 56 Required to install the High performance Embedded Workshop for the emulator or refer to the emulator user s manual 7 ENESAS Section 2 Setting Up the Emulator 2 1 Flow Chart before Using the Emulator Unpack the emulator and prepare it for use as follows A WARNING READ the reference sections shaded in figure 2 1 before using the emulator product Incorrect operation will damage the user system and the emulator product The USER PROGRAM will be LOST Reference Unpack the emulator Component list Check the components against the component list Setting up the emulator Set up the emulator Section 2 Connect the optional board Install the HEW Turn on the user system Section 4 Starting the Turn on the emulator emulator Start the HEW Figure 2 1 Emulator Preparation Flow Chart 57 RENESAS 2 2 Installing Debugger 2 2 1 CD R The root directory of the CD R contains a setup program for installing the emulator s software The folders contain the files and programs listed below Table 2 1 Contents of the CD R Directories Directory Name Contents Description Dils Microsoft runtime library A runtime library for the High performance Embedded Workshop The version is checked at installation and this library is copied to the hard disk as part of the installation process Drivers E200F
163. ge For details refer to the MPU s pin assignments 2 The range of communication that the emulator operates at is different depending on the MPU used 3 To connect the signals from the connector refer to section 1 in the additional document Supplementary Information on Using the SHxxxx 74 ENESAS 4 When developing user systems do not connect the TDI and TDO signals of the device to the boundary scan loop or separate them by using a switch figure 2 16 Boundary scan loop User system TDI Test data input TDO Test data output TAP Test access port Figure 2 16 User System Example 75 RENESAS 2 6 2 Connecting System Ground A WARNING Separate the frame ground from the signal ground at the user system Failure to do so will result in a FIRE HAZARD and will damage the user system and the emulator product or will result in PERSONAL INJURY The emulator s signal ground is connected to the user system s signal ground In the emulator the signal ground and frame ground are connected In the user system connect the frame ground only do not connect the signal ground to the frame ground figure 2 17 Signal line Host machine E200F main unit case Trace unit User system Signal ground Frame ground Figure 2 17 Connecting System Ground 76 7 ENESAS 2 7 Changing the Settings In the emulator it is possible to change the emulator function flexibly depending on the user
164. hat column To display the hidden column select the column from the said popup menu again 5 8 5 Starting Performance Data Acquisition Executing the user program clears the result of previous measurement and automatically starts measuring execution performance according to the conditions that have been set Stopping the user program displays the result of measurement in the Performance Analysis window 5 8 6 Deleting a Measurement Condition Select Reset from the popup menu with a measurement condition selected to delete the condition 254 RENESAS 5 8 7 Deleting All Measurement Conditions Select Reset All from the popup menu to delete all the conditions that have been set 5 9 Viewing the Profile Information The profile function enables function by function measurement of the performance of the application program in execution This makes it possible to identify parts of an application program that degrade its performance and the reasons for such degradation The High performance Embedded Workshop displays the results of measurement in three windows according to the method and purpose of viewing the profile data 5 9 1 Stack Information Files The profile function allows the High performance Embedded Workshop to read the stack information files extension SNI which are output by the optimizing linker ver 7 0 or later Each of these files contains information related to the calling of static functions in the corr
165. hat has been accessed without suspending the execution of program and displays it on the window The virtual address that has been accessed by the CPU can be only monitored 7 Emulation memory function The emulator allocates the memory for emulation in the CSO area 8 Other memory operation functions Other functions are as follows e Memory fill e Memory copy e Memory save e Memory verify e Memory search e Internal I O display e Cache table display and edit only for devices incorporating caches e TLB table display or edit only for devices incorporating MMU e Displaying label and variable names and their contents For details refer to the online help Notes 1 Memory access during user program execution When a memory is accessed from the memory window etc during execution of the user program execution stops for the memory access and is then resumed Therefore realtime emulation cannot be performed The stopping time of the user program depends on the performance of the host machine in use or the JTAG clock that time under the following environment is shown below Environment Host machine 800 MHz Pentium II SH7323 96 MHz CPU clock JTAG clock 30 MHz When a one byte memory is read in the command line window the stopping time will be about 96 ms 2 Memory access during user program break The program can also be downloaded for the flash memory area by the emulator Other memory write operations are enabl
166. he cues given by the installation wizard to install the software 3 4 2 Executing the Diagnostic Program The following describes how to execute the diagnostic program Nn 1 Connect the emulator to the host machine not to the user system 2 Turn on the emulator 3 4 The diagnostic program of the emulator is started and the initial screen figure 3 6 is Select E200F TM gt E200F Fx TM x 0 or 2 from Programs in the Start menu displayed Select COMPONENT Do not select TARGET Click the USER TEST MODE button Do not select QA TEST MODE RENESAS 89 E200F Test amp Maintenance Program Version x x xx 200x xx xx TM ver up COMPONENT v Main OPTION j TRC EVA Reserve TARGET Select the component that has been connected QA TEST MODE PASSWORD Figure 3 6 Initial Screen of the E200F System Operation Test 7 When the emulator enters USER TEST MODE the screen shown in figure 3 7 is displayed 8 When clicking UNIT ONLY items that can be tested are selected 9 Click the START button 10 When loading FPGA is completed the test will begin Note When COMPONENT is selected do not select TARGET TARGET is used for jigs for the shipment test 90 7 ENESAS E200F Test amp Maintenance Program Version x x xx 200x xx xx FILE COMPONENT MAIN J ERROR STOP SERIAL No TEST COUNT Vf 7 J ENDLESS STATUS OPTION MEMORY TEST lv SDRAM RITES jv MAIN MEMORY TES
167. he emulator before putting the emulator in place 4 WARNING Always switch OFF the emulator product and the user system before connecting or disconnecting any CABLES except for the USB interface cable Failure to do so will result in a FIRE HAZARD and will damage the user system and the emulator product or will result in PERSONAL INJURY The USER PROGRAM will be LOST 70 7 ENESAS The emulator is connected to the host machine via the USB 1 1 2 0 Figure 2 13 shows the system configuration E200F emulator Host machine USB cable 1 5 m Figure 2 13 System Configuration when Connecting the Emulator to the Host Machine 71 RENESAS 2 6 Connecting the Emulator to the User System Use the procedure below to connect the emulator to the user system with the user system interface cable or to disconnect them when moving the emulator or the user system 1 Check that the emulator is turned off 2 Connect the probe head connector to the user system 3 Fasten the probe head to the user system with the screws for the 36 pin connector only 1 The connector must be installed to the user system Table 2 2 shows the recommended H UDI port connectors for the emulator The connector type of the probe head will differ depending on the emulator in use Table 2 2 Recommended Connectors Connector Type Number Manufacturer Specifications Emulator Type 36 pin connector 2514 6002 3M Limited 36 pin straight type ROEO200F
168. he emulator is activated it is possible to select whether the address to be monitored is the physical address or the virtual address For the physical address monitoring is disabled if Hardware break enable is selected from the Emulation mode combo box in the General sheet of the Configuration dialog box 157 RENESAS 5 3 1 Opening the Monitor Window To open the Monitor window select View gt CPU gt Monitor gt Monitor Setting or click the Monitor toolbar button X to display Monitor Setting Monitor Setting the Monitor Setting dialog box Name Options Address Size byte Access Format V Auto Refresh at rate ms V Reading the Initial monitort m a Fama Byte aso poo5000 ti lt i lt 27 S lt i Value Color Change Indicator Foreground EE V Mayfly Change v Backeround C7 Detail Detail Figure 5 18 158 orei Monitor Setting Dialog Box RENESAS Name Decides the name of the monitor window Options Sets monitor conditions Address Sets the start address for monitoring Size Sets the range for monitoring Access Sets the access size to be displayed in the monitor window Auto Refresh at rate Reading the Initial Value Sets the interval for acquisition by monitoring Selects reading of the values in the monitored area when the monitor windo
169. hen the trace buffer becomes full the trace information is no longer acquired Break A break occurs BUS trace mode Sets the mode when the external bus trace function is used Enable free trace Enables external bus free trace CS2 SDRAM trace Recognizes the CS2 area as SDRAM to be analyzed by a trace CS3 SDRAM trace Recognizes the CS3 area as SDRAM to be analyzed by a trace Time stamp clock Specifies the resolution of the timer for time stamp as any of the following values 20 ns 40 ns 100 ns or 400 ns Trace display range Sets the trace display range Start pointer Enters the numerical start pointer value of the display range End pointer Enters the numerical end pointer value of the display range 5 7 3 Hiding the Trace Column It is possible to hide any column not necessary in the Trace window Selecting a column you want to hide from the popup menu displayed by clicking the right hand mouse button on the header column hides that column To display the hidden column select the column from the said popup menu again Dragging the column with the mouse changes the display order 226 RENESAS 5 7 4 Searching for a Trace Record Use the Trace Find dialog box to search for a trace record To open this dialog box choose Find from the popup menu The Trace Find dialog box has the following options Table 5 4 Trace Find Dialog Box Pages Page Description General Sets the ra
170. idth The bus width can be selected as 4 bits or 8 bits Note In some products the bus width will be fixed For the specifications of each product refer to the online help 136 RENESAS 5 1 4 Bus Board Page Sets the trace unit operation conditions Note When the trace unit is not connected to the emulator this page is not displayed Configuration General Main Board Bus Board Option Board Loading flash memory Bus board mode setting Memory type setting Figure 5 3 Configuration Dialog Box Bus Board Page 137 RENESAS Items that can be displayed in this page are listed below Bus board mode setting Multiplexed pins setting Memory type setting 138 Displays the function of the trace unit Trace break 6ch Trace 262144 cycles The external bus trace or break function has been selected event detection channels six The 262144 bys cycles can be acquired by a trace Performance 6ch The external bus trace function has been selected measurement channels six Emulation memory 4M Trace 8192 cycles The external emulation memory function 4 Mbytes x 1 block has been selected The 8192 bys cycles can be acquired by a trace Selects the state of the multiplexed pins Selects the type of memory for each area or the content of connection Select Normal for other than SRAM with byte control 7 ENESAS Clicking the Multiplexed pins setting b
171. ies dialog box figure 4 33 Session Properties Name Session E200F SYSTEM Location C Program Files Renesas test test SessionE200F_SYST Last modified 12 00 09 Wednesday August 23 2006 ance Read only Figure 4 33 Session Properties Dialog Box e To make a session read only 1 Select Options gt Debug Sessions to display the Debug Sessions dialog box figure 4 31 2 Select the session you would like to make read only 3 Click the Properties button to display the Session Properties dialog box figure 4 33 4 Check the Read only check box to make the link read only This is useful if you are sharing debugger setting files and you do not want data to be modified accidentally 5 Click the OK button e To save a session with a different name 1 Select Options gt Debug Sessions to display the Debug Sessions dialog box figure 4 31 Select the session you would like to save Par Click the Save as button to display the Save Session dialog box figure 4 34 4 Browse to the new file location 120 RENESAS 5 If you want to export the session file to another location leave the Maintain link check box unchecked If you would like the High performance Embedded Workshop to use this location instead of the current session location check the Maintain link check box 6 Click the Save button SimDebug_SH 2 fa DefautSession hsf a SimSessionSH 2 h
172. ies the operation after the sequential AUD event has been detected Break Breaks after the sequential AUD event has been detected Trace stop Stops AUD trace after the sequential AUD event has been detected When the sequential AUD event condition is set and the eventpoint condition is edited with the AUD event channel that has been selected for Channel select the Action page cannot be modified To modify the settings of the Action page cancel the sequential AUD event condition RENESAS 5 6 7 Setting BUS Eventpoints On the BUS Event sheet the settings for BUS Eventpoints are displayed and modified Reset Enable address H 1234 to H 5678 Break Delay Disable None Normal Enable data H FFFF word read nmi high irq O0xxl0xlx Trace start Normal Disable None Normal Enable address H 1llll count D 1234 Trace get Trigger Normal Disable None Breakpoint AUD Event Figure 5 42 Event Window BUS Event Sheet Using six event detection channels sets six eventpoints Notes 1 When the trace unit is not connected to the emulator this function is not supported 2 When the debugging function of the trace unit is set again the number of event detection channels is changed For details refer to section 5 1 4 Bus Board Page Items that can be displayed in the sheet are listed below Type External bus event channel number and type Normal Standard event channel Delay Event channel that delay condition
173. iffers depending on the supported MPU For details refer to the online help 203 RENESAS 4 Count page Specifies the satisfaction count condition Ch2 Delay Address Data Interrupt Count Delay Action numbers Figure 5 46 Chx Delay Dialog Box Count Page Don t care Sets no satisfaction count numbers Sets a value as the satisfaction count condition D 1 to D 65535 is available Note If Trace get is selected on the Action page this page will not be displayed 204 ENESAS 5 Delay page Sets the delay cycle from the event detection to the external bus trace stop Ch2 Delay Address Data Interrupt Count Delay Action Delay oree Figure 5 47 Chx Delay Dialog Box Delay Page Don t care Sets no delay condition Delay Sets the delay cycle counts D 0 to D 262143 is available Note This page is only displayed when external bus event channel Ch2 is selected and Trace stop is specified on the Action page 205 RENESAS 6 Action page Sets the operation after the condition has been satisfied Ch2 Delay Address Data Interrupt Count Action Action C Break On Trace start Trace stop Trace get ls option Figure 5 48 Chx Delay Dialog Box Action Page Break Breaks after conditions have been matched Trace Enables Trace option and sets the exte
174. ils on the specifications of each product refer to the online help The following four types of information in the MPU can be acquired by a trace Branch information Range memory access information in the virtual address Software trace System bus access information RENESAS Branch Trace Functions The branch source and destination addresses their source lines branch types and types of accessed bus masters are displayed Setting Method Select the check box in the Branch group box in the Branch trace page of the Branch trace dialog box that opens by double clicking on the Ch12 Branch column of the Event window The branch condition to be acquired can be set Branch trace Branch trace Action Branch l Dort care M Acquire subroutine branch instruction trace M Acquire exception branch instruction trace Figure 1 17 Branch trace Dialog Box A branch trace can be acquired by selecting the Acquire trace check box of the Action page Note To cancel settings select Delete from the popup menu that is opened by clicking on the Ch12 Branch column with the right mouse button 29 7 ENESAS Range Memory Access Trace Functions The memory access within the specified range is acquired by a trace The read cycle write cycle or read write cycle can be selected as the bus type ASID value or bus cycle for trace acquisition Setting Method To open the Event condition 5 or Event con
175. imestamp 000012 p 000012 READ OOOOFFBF 2000 11111111 O000h000minO00s007ms372us440ns 000011 p 000011 READ 00002129 2FEO 11111111 O000h000min000s007ms372us82Z0ns 000010 p 000010 READ 00002128 2FEO 11411111 O000h000min0O00s007ms373 us300ns 000009 p 000009 READ 0000212D 2FE1 11110111 0000h000min000s007ms373us660ns 000008 pD 000008 READ 0000212F 2FEO 11110111 0000h000min000s007ms3 74us040ns 000007 p 000007 READ 00001099 203B 11111111 O000h000min000s007ms3 74us400ns 000006 p o000006 READ 00001098 E600 14311111 0000h000min000s007ms3 74us740ns 000005 p 000005 READ oo00109D 6523 11110111 O000h000min000s007ms3 74us740ns 000004 p o00004 READ 0000109F 6263 11110111 OO000h000minO00s007ms374us740ns 000003 p 000003 READ 00001041 6208 11111111 0000h000min000s007ms374us740ns 000002 D 000002 READ 00001043 3520 11111111 O000h000min000s007ms374us740ns 000001 p 000001 READ 00001045 6253 Ty Bs Lu ln O0000h000min000s007ms3 74us740ns 000000 p O00000 READ 000010a7 6622 11110111 OO000h000min000s007ms374us740ns lt Figure 5 60 BUS MFI trace Window BUS Trace Items that can be displayed in this window are listed below For details on the specifications of each product refer to the online help PTR The bus trace buffer pointer 0 for the last executed instruction IP The amount of acquired trace information R W Whether the generated data is associated with read or write access Address Address Data The data bus value NM
176. imization Depending on the generated object code local variables in a C source file that is compiled with the optimization option enabled will not be displayed correctly Check the generated object code by displaying the Disassembly window If the allocation area of the specified local variable does not exist displays as follows Example The variable name is asc asc target error 2010 xxxx Variable name specification When a name other than a variable name such as a symbol name or function name is specified no data is displayed 381 7 ENESAS Example The function name is main main 5 Line Assembly Input radix Regardless of the Radix setting the default for line assembly input is decimal Specify H or Ox as the radix for a hexadecimal input 6 Command Line Interface Batch file To display the message Not currently available while executing a batch file enter the sleep command Adjust the sleep time length which differs according to the operating environment Example To display Not currently available during memory_fill execution sleep d 3000 memory_fill 0 ffff 0 File specification by commands The current directory may be altered by file specifications in commands It is recommended to use absolute paths are recommended to be used to specify the files in a command file so that the current directory alteration is not affected Example FILE_LOAD C HEW3 Tools Renesas
177. in the device to measure the number of cycles from one specified condition being satisfied until a next specified condition is satisfied Not only the number of cycles but also various items such as the number of cache misses or of TLB misses can be measured according to the supported devices Note Items to be measured will differ according to the product For details on the specifications of each product refer to the online help a Setting the performance measurement conditions To set the performance measurement conditions use the Performance Analysis dialog box and the PERFORMANCE_SET command When a channel line on the Performance Analysis window is clicked with the right mouse button the popup menu is displayed and the Performance Analysis dialog box is displayed by selecting Setting 37 RENESAS Performance Analysis Condition Cycle T Don t Care Selection of a count item GPU performance Cycle Count C hstruction C Branch C Exception interruption C Stalled Cycle C TLB performance C Instruction bus performance Operand bus performance Access count C Access miss count C Waited cycle Syst Extend counter Enable Figure 1 20 Performance Analysis Dialog Box Note For the command line syntax refer to the online help 38 RENESAS e Specifying the measurement start end conditions Set the performance measurement conditions in the Action page after conditions have
178. in the sheet are listed below Type AUD event channel number and type Normal Standard event channel Delay Event channel that delay conditions can be set Reset Event channel that can be set as the reset point of the AUD sequential event State Whether the eventpoint is enabled or disabled Enable Valid Disable Invalid Condition A condition that satisfies an eventpoint The displayed contents differ depending on the channel Action Operation of the emulator when an eventpoint condition is satisfied The displayed contents differ depending on the channel When an event channel is double clicked or selected and Edit is selected from the popup menu in this window the Chx dialog box is displayed The Chx dialog box consists of the General Branch Window Software SystemBus Count Delay and Action pages The combination of the conditions set in each page is set as the detection condition of eventpoints 183 7 ENESAS 1 General page Specifies AUD trace information used to set the AUD Eventpoint condition Ch2 Delay General Branch Count Delay Action AUD function data C Window trace data Software trace data C SystemBus trace data Figure 5 33 Chx Delay Dialog Box General Page Branch trace data Sets the eventpoint condition according to the branch trace information Window trace data Sets the eventpoint condition according to the window
179. ing the profiler measurement circuit on the main unit case and expansion profiling unit of the emulator The following shows the realtime profiling measurement modes e Function mode This function does not include the subroutine execution time when accumulation of the function execution time is displayed e Nest mode This function includes the subroutine execution time when accumulation of the function execution time is displayed Determine which mode is to be used in the Function select dialog box that is displayed when the emulator is activated Note There are following restrictions in the realtime profiling function 1 Restrictions on all the realtime profiling functions i Areas to be measured In the emulator 512 Kbytes are considered as a unit to acquire the profiling information on all the functions in the areas of a maximum of 24 blocks The hardware of the emulator has a maximum of three types of memory for measuring eight blocks to implement the realtime profiling function Note that the adjacent address areas can be set in each block however it is impossible to set a function of which address ranges are extended on the eight block boundaries If such a function is set a warning message will be displayed and correct measurement will not be performed ii Inline expansion When the functions are inline expanded in accordance with optimization of the compiler they are not displayed in the Realtime Profile windo
180. ing user program execution the display is updated according to the setting value of the auto update interval Note Select Refresh from the popup menu when data is not displayed correctly after changing the address or content of memory 5 3 2 Changing the Monitor Settings Selecting Monitor Settings from the popup menu of the Monitor window displays the Monitor Setting dialog box which allows the settings to be changed Colors the size of accesses and the display format can be easily changed from Color or Access of the popup menu 160 RENESAS 5 3 3 Temporarily Stopping Update of the Monitor During user program execution the display of the Monitor window is automatically updated according to the auto update interval Select Lock Refresh from the popup menu of the Monitor window to stop the update of display The characters in the address section are displayed in black and the update of display is stopped Selecting Lock Refresh again from the popup menu cancels the stopped state 5 3 4 Deleting the Monitor Settings Selecting Close from the popup menu of the Monitor window to be deleted closes the Monitor window and deletes the monitor settings 5 3 5 Monitoring Variables Using the Watch window refers to the value of any variables The value of the variable that has been registered in the Watch window can be updated during execution of the user program Select Auto Update from the popup menu
181. ion is completed Internal AUD Usermemory trace Master Type BranchType Bus R U Address PPC2 Instruc 000008 D 000008 O000FFC4 000053DC 000007 D 000007 OOOOFFCS 00002704 000006 D 000006 O00OFFCC 00005665 000005 D 000005 OOOOFFDO ooo00DAA 000004 D 000004 OOOOFFD4 oo00421F 000003 D 000003 OOOOFFDS 00003EAD 000002 D 000002 OOOOFFDC 00004D1D 000001 D 000001 OOOOFFEO 0000ZF5A 000000 D 000000 OOOOFFE4 000020DA Figure 6 52 Internal AUD Usermemory trace Window Example e The value of array a can be confirmed by opening the Watch window For details refer to section 6 13 WatchingVariables 347 RENESAS 3 Memory Output Trace Function This function is used to write the trace result to the specified memory range The following shows the procedure for acquiring the memory output trace function a Setting the trace acquisition mode Display the Internal AUD Usermemory trace window Click this window with the right hand mouse button and select Acquisition from the popup menu to display the Internal AUD Usermemory acquisition dialog box The memory output trace acquisition mode is set 348 RENESAS Internal AUD Usermemory acquisition Trace Mode Trace type C AUD trace Internal trace Trace Mode 1 Realtime trace Non realtime trace r Trace Mode 2 Trace continue Trace stop Break AUD Mode Enable free trace Time stamp clock
182. ir ee eee eee 372 8 5 How to Make a Request for Repair eee ceeeseeeseceeeeseeeseeeeeeseseaesseesseeseeeeeeseeeaeees 373 Appendix A WAST Sirsa atcteniaencetuataceaiuseanauesacaseeseestacestesseetssaceensceutieteseonetunsOneates 375 Appendix B Command Line Functions seeseeeeeeseeeeeserssesressrserrrrrssersrrrreeseese 379 Appendix C Notes on High performance Embedded Workshop 05 381 Appendix D Repair Request Sheet eeseseeeeeeeeesessessresreesesressrseresresserererreeseese 385 x RENESAS Section 1 Product Overview The High performance Embedded Workshop provides a graphical user interface that eases the development and debugging of applications written in the C C programming languages or assembly language for Renesas microcomputers Its aim is to provide a powerful yet intuitive way of accessing observing and modifying the debugging platform on which the application is running The E200F emulator hereafter referred to as the emulator is a support tool for developing the hardware and software of application systems running on Renesas original microcomputers The main unit of the emulator is connected through the dedicated debugging interface to the user system The user system can be debugged under the conditions similar to the actual application conditions RENESAS Figures 1 1 and 1 2 show the system configuration using two types of emulators ROEO200FOEMUO00 and ROEO200F2EMUO00 respectively Exp
183. k before executing Prefetch address break after executing C Bus address C Y Bus address Address JHO0001 084 Non user mask User mask Mask onei Figure 6 37 Address Page Event condition 1 Dialog Box Note The items that can be set in this dialog box differ according to the product For details on the settings for each product refer to the online help 328 7 ENESAS e Click the OK button e The first point display in the State line changes from Disable to Enable e The first point display in the Condition line changes from None to Address H 00001084 pc e Set the program counter and stack pointer values PC H 00000800 and R15 H 00010000 that were set in section 6 8 Setting Registers in the Register window Click the Go button e If program execution is failed reset the device and execute again the procedures above The program runs and then stops at the condition specified under event channel 1 00001036 00001040 0000104c 00001056 0000105e 00001066 0000106a 0000106c 00001084 0000108e 00001098 000010aa 000010be 000010ce 000010e0 o00010f2 00001104 00001116 00001128 0000113a 00001146 void main void long a 10 long j int iz class Sample p_sam while 1 p_sam new Sample for i 0 i lt 10 j rand U O 0A JF Sis alii ic p_sam gt changela p_sam gt s0 a 0 p_sam gt sl al 1 p_sam gt s2 a 2
184. kspace window Output Alt U A Opens the Output window Difference Opens the Difference window CPU Registers Ctrl R E Opens the Register window Memory Ctrl M I Opens the Memory window IO Ctrl 1 E Opens the IO window Status Ctrl U re Opens the Status window Cache Shift Opens the Cache window Ctrl C al TLB Shift iit Opens the TLB window Ctrl X Monitor Monitor Shift Ey Opens the Monitor Setting Setting Ctrl E dialog box Window Opens the Window Select Select dialog box Extended Monitor 4 RENESAS Opens the Extended Monitor window 375 Table A 1 GUI Menus cont Toolbar Menu Option Shortcut Button Remarks View Sym Labels Shift E Opens the Labels window cont bol Ctrl A Watch Ctrl W Fal Opens the Watch window Locals Shift Fal Opens the Locals window Ctrl W Code Eventpoints Ctrl E Em Opens the Event window Trace Ctrl T Opens the Trace window Stack Trace Ctrl K Opens the Stack Trace window Gra Image Shift E Opens the Image window phic Ctrl G Waveform Shift Opens the Waveform window Ctrl V Per Performance Shift E Opens the Performance Analysis form Analysis Ctrl P window ance Profile Shift a Opens the Profile window Ctrl F Realtime Profile Shift a Opens the Realtime Profile Ctrl R window Setup Radix Hexadeci
185. l Figure 1 4 Emulator Hardware Configuration ROEO200F2EMU00 7 ENESAS The names of each section of the emulator are explained next Emulator Front View Figure 1 5 Emulator Front View a POWER LED Marked PWR When this LED is lit the emulator is supplied with power b RUN LED Marked RUN When this LED is lit the user program is in operation c ACTION LED Marked ACT When this LED is lit the emulator is in operation 8 RENESAS Emulator Rear side View Figure 1 6 Emulator Rear side View a Power switch Marked POWER Turning this switch to I input turns the emulator on and O output turns the emulator off b DC plug Marked DC IN This is a connector to input DC 12 V of the AC adapter Be sure to connect this plug to the provided AC adapter c External probe connector Marked EXT This is a connector for the external probe Be sure to connect this connector to the provided external probe d Host side connector Marked lt A connector USB connector for the host USB connector machine is provided at the side of this mark Be sure to connect this connector to the provided USB cable 7 ENESAS Emulator Right side View Figure 1 7 Emulator Right side View a E200F logo plate A navy blue plate ROEO200FOEMU00 or a silver and red plate ROEO200F2EMU00 dedicated for the emulator is provided to be easily distinguished from other E200F
186. le name including the character string that has been set in the Target name text box in figure 4 24 New Project Step 8 dialog box The setting for using the emulator has been registered in this session file After selected the emulator is automatically connected 112 2RENESAS 4 2 3 Selecting an Existing Workspace 1 In the Welcome dialog box that is displayed when the High performance Embedded Workshop is activated select Browse to another project workspace radio button and click the OK button Welcome Options C Greate a new project workspace Cancel C Open a recent project workspace Administration Figure 4 26 Welcome Dialog Box 113 7 ENESAS 2 The Open Workspace dialog box is displayed Select a directory in which you have created a workspace After that select the workspace file hws and press the Open button oO pen Works pace Look in E sample amp fe E sample hws File name sample hws Files of type Workspaces hws 7 Cancel Figure 4 27 Open Workspace Dialog Box 3 This activates the High performance Embedded Workshop and recovers the state of the selected workspace at the time it was saved When the saved state information of the selected workspace includes connection to the emulator the emulator will automatically be connected To connect the emulator when the saved state information does not include connection to the emulator refer
187. ly to you the original Purchaser It is not transferable to anyone who subsequently purchases the emulator product from you Renesas is not liable for any claim made by a third party or made by you for a third party DISCLAIMER RENESAS MAKES NO WARRANTIES EITHER EXPRESS OR IMPLIED ORAL OR WRITTEN EXCEPT AS PROVIDED HEREIN INCLUDING WITHOUT LIMITATION THEREOF WARRANTIES AS TO MARKETABILITY MERCHANTABILITY FITNESS FOR ANY PARTICULAR PURPOSE OR USE OR AGAINST INFRINGEMENT OF ANY PATENT IN NO EVENT SHALL RENESAS BE LIABLE FOR ANY DIRECT INCIDENTAL OR CONSEQUENTIAL DAMAGES OF ANY NATURE OR LOSSES OR EXPENSES RESULTING FROM ANY DEFECTIVE EMULATOR PRODUCT THE USE OF ANY EMULATOR PRODUCT OR ITS DOCUMENTATION EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES EXCEPT AS EXPRESSLY STATED OTHERWISE IN THIS WARRANTY THIS EMULATOR PRODUCT IS SOLD AS IS AND YOU MUST ASSUME ALL RISK FOR THE USE AND RESULTS OBTAINED FROM THE EMULATOR PRODUCT RENESAS State Law Some states do not allow the exclusion or limitation of implied warranties or liability for incidental or consequential damages so the above limitation or exclusion may not apply to you This warranty gives you specific legal rights and you may have other rights which may vary from state to state The Warranty is Void in the Following Cases Renesas shall have no liability or legal responsibility for any problems caused by misuse abuse misapplication neglect i
188. m the current project This allows a function included in the specified file to be set as the coverage range C will be provided if the file type name is omitted Files with a type name other than C or CPP cannot be specified here A placeholder or the Browse button can be used Clicking the OK button changes the coverage range to be displayed 285 RENESAS 5 11 5 Clearing the Coverage Information e Clearing the coverage information of the specified range Selecting Clear Coverage Range from the popup menu opens the Clear Coverage Range dialog box Start Address End Address Figure 5 112 Clear Coverage Range Dialog Box Enter the start and end addresses of the range to be cleared Clicking the OK button clears the coverage information of the selected range e Clearing all the coverage information Selecting Clear the Entire Coverage from the popup menu clears all the coverage information 5 11 6 Saving the Coverage Information to a File Selecting Save Data from the popup menu opens the Save Coverage Data dialog box File name D Browse Cancel Figure 5 113 Save Coverage Data Dialog Box Specify the location of the coverage information file to be saved and its name A placeholder or the Browse button can be used If the file extension is omitted COV will automatically be added as the file extension An error message will appear if a file extensio
189. mal E Uses a hexadecimal for displaying a radix in which the numerical values will be displayed and entered by default Decimal 10 Uses a decimal for displaying a radix in which the numerical values will be displayed and entered by default Octal 5 Uses an octal for displaying a radix in which the numerical values will be displayed and entered by default 376 RENESAS Table A 1 GUI Menus cont Menu Setup cont Option Shortcut Radix cont Binary Toolbar Button Remarks Uses a binary for displaying a radix in which the numerical values will be displayed and entered by default Emu lator System E Opens the Configuration dialog box allowing the user to modify the debugging platform settings Debug Debug Sessions Opens the Debug Sessions dialog box to list add or remove the debug session Debug Settings Opens the Debug Settings dialog box to set the debugging conditions or download modules Reset CPU fim gt i Resets the target hardware and sets the PC to the reset vector address Go F5 fi t Starts executing the user program at the current PC Reset Go Shift F5 Resets the target microcomputer and executes the user program from the reset vector address Go To Cursor Starts executing the user program at the current PC until the PC reaches the address indicated by the current text cursor position
190. mber of memory accesses in an opcode Instruction cache hit ratio Number of instruction cache accesses instruction cache miss counts instruction cache access counts Number of operand accesses for both cache and non cache Number of memory accesses in an operand read number of memory accesses in an operand write Operand cache hit ratio read Number of operand cache accesses read number of operand cache misses read number of operand cache accesses read Operand cache hit ratio write Number of operand cache accesses write number of operand cache misses write number of operand cache accesses write Operand cache hit ratio Number of operand cache accesses read number of operand cache accesses write number of operand cache misses read number of operand cache misses write number of operand cache accesses read number of operand cache accesses write System bus occupied rate of request bus The equivalent CPU clock value of the number of requests number of elapsed cycles System bus occupied rate of response bus 48 The equivalent CPU clock value of the number of responses number of elapsed cycles RENESAS Each measurement condition is also counted when conditions in table 1 6 are generated Table 1 6 Performance Measurement Conditions to be Counted Measurement Condition Notes No caching due to the Counted for accessing the
191. me is selected the emulator will automatically be connected For details on the session file refer to section 4 4 Debug Sessions 4 6 Reconnecting the Emulator When the emulator is disconnected use the following way for reconnection Select Build gt Debug gt Connect or click the Connect toolbar button 5 The emulator is connected Note The emulator must be selected in the Target drop down list box of the Debug Settings dialog box see figure 4 28 Debug Settings Dialog Box Target Page that is opened by selecting Debug settings from the Options menu 123 7 ENESAS 4 7 Ending the Emulator When using the toolchain the emulator can be exited by using the following two methods e Canceling the connection of the emulator being activated e Exiting the High performance Embedded Workshop 1 Canceling the connection of the emulator being activated Select Disconnect from the Debug menu or click the Disconnect toolbar button e 2 Exiting the High performance Embedded Workshop Select Exit from the File menu A message box is displayed If necessary click the Yes button to save a session After saving a session the High performance Embedded Workshop exits If not necessary click the No button to exit the High performance Embedded Workshop High performance Embedded Workshop rN Session SessionE200F_SYSTEM in project tutorial has been modified Do you want to save it Cancel
192. message dialog box will be displayed if simultaneous use is attempted 2 In this function a break occurs whenever a branch is generated and information is collected to execute the user program again Therefore realtime emulation of the user program will not be performed 50 7 ENESAS 5 Realtime Profiling Function Realtime Profile The performance of each function can be measured within the specified address range A function having low performance can be easily found if the statistics of the time for each function are monitored In this function performance information is collected without break Therefore realtime emulation of the user program will be performed The specifiable address ranges are as follows e When the expansion profiling unit is not connected 512 kbytes to 4 Mbytes 8 blocks at 512 kbytes e When the expansion profiling unit is connected 512 kbytes to 12 Mbytes 24 blocks at 512 kbytes 1 3 8 Coverage Function The emulator displays the information on the executed instructions in the C C and assembly language levels to measure the CO coverage 7 ENESAS 51 1 3 9 Memory Access Functions The emulator has the following memory access functions 1 Memory read write function Memory window The memory contents are displayed in the window Only the amount specified when the Memory window is opened can be read Since there is no cache in the emulator read cycles are always generated If the memo
193. mory Disable Not download to the flash memory Erasing flash memory radio button Sets Enable for erasing before the flash memory is written When Enable is selected the erase module is called before calling the write module Enable Erase the flash memory Disable Not erase the flash memory File name edit box Sets the file name of the S type load module including the write and erase modules The file that has been set is loaded to the RAM area before loading to the flash memory A maximum of 128 characters can be input for the file name Bus width of flash memory list box Sets the bus width of the flash memory Flash memory erasing time edit box Sets the TIMEOUT value for erasing the flash memory Set a larger value if erasing requires much time the default time is three minutes The radix for the input value is decimal It becomes hexadecimal by adding H Entry point group box Sets the calling destination address of the write and erase modules All erasing module address edit box Enters the calling destination address of the erase module Writing module address edit box Enters the calling destination address of the write module Note Although the values that can be set are D 1 to D 65535 the TIMEOUT period may be extended according to the set value Therefore it is recommended to input the minimum value by considering the erasing time of the flash memory in use e Notes on
194. mproper handling installation repair or modifications of the emulator product without Renesas prior written consent or any problems caused by the user system All Rights Reserved 1 Circuitry and other examples described herein are meant merely to indicate the characteristics and performance of Renesas semiconductor products Renesas assumes no responsibility for any intellectual property claims or other problems that may result from applications based on the examples described herein 2 No license is granted by implication or otherwise under any patents or other rights of any third party or Renesas 3 This user s manual and emulator product are copyrighted and all rights are reserved by Renesas No part of this user s manual all or part may be reproduced or duplicated in any form in hard copy or machine readable form by any means available without Renesas prior written consent Figures Some figures in this user s manual may show items different from your actual system RENESAS SAFETY PAGE READ FIRST e READ this user s manual before using this emulator product e KEEP the user s manual handy for future reference Do not attempt to use the emulator product until you fully understand its mechanism DEFINITION OF SIGNAL WORDS Either in the user s manual or on the product several icons are used to insure proper handling of this product and also to prevent injuries to you or other persons or damage to your
195. n Step Steps the specified times repeatedly at a specified rate 6 15 1 Executing Step In Command The Step In command steps into the called function and stops at the first statement of the called function e To step through the sort function select Step In from the Debug menu or click the Step In button on the toolbar Y Figure 6 23 Step In Button 316 7 ENESAS 00002000 00002002 00002014 00002018 oo002z01a o0002z01ic o0002z01e 00002020 00002022 00002024 00002026 00002028 00002032 00002038 o000203a o000203e 00002044 00002050 00002058 00002070 0000207a 0000208e o000z0ae Sample Sample s0 0 s1 0 s2 0 s3 0 s4 0 s5 03 s6 0 sf 0 s8 0 s9 0 long t Int ts ds Ks gap gap 5 while gap gt 0 i for k 0 k lt gap k for i ktgap i lt 10 ititgap for j i gap j gt k j j gapif if ali gt alitgap t alj ali alitgap alitgap t else break gap gap 2 Figure 6 24 Source Window Step In The highlighted line moves to the first statement of the sort function in the Source window 7 ENESAS 317 6 15 2 Executing Step Out Command The Step Out command steps out of the called function and stops at the next statement of the calling statement in the main function e To step out of the sort function select Step Out from the Debug menu or click the Step Out button on the toolbar Note I
196. n Files menu option from the pop up menu of the Profile window and specify the file name after measuring a profile data of the application program This file contains information on the number of times functions are called and global variables are accessed The optimizing linker ver 7 0 or later is capable of reading the profile information file and optimizing the allocation of functions and variables in correspondence with the status of the actual operation of the program To input the profiler information file to the linker choose Optimize from the Category list box and check the Include profile box in the Link Library sheet of the Standard Toolchain dialog box and specify the name of the profile information file ngine Standard Toolchain Configuration Debug_E200F_SYSTEM 7 Tap Optimize H Gj All Loaded Projects Show entries for tutorial rs F z Optimize items 7 C source file E G source file Optimize Speed z Eliminated Size j Tonle H Assembly source file Linkage symbol file Unify strings Eliminate dead code Reallocate registers Modify Eliminate same code Cache size Optimize branches Size ox0008 Line 0x0020 4 Options Link Library noprelink rom D R nomessage list CONFIGDIRI PROJECTNAME map optimize speed Cares Figure 5 88 Standard Toolchain Dialog Box 2 To en
197. n other than COV or TXT is entered 286 RENESAS 5 11 7 Loading Coverage Information from a File Selecting Load Data from the popup menu opens the Load Data dialog box Ee eX File name l p Browse Cancel Offset r Figure 5 114 Load Data Dialog Box Specify the location of the coverage information file to be loaded A placeholder or the Browse button can be used The only file extension available is COV An error message will appear if any other file extension is entered Note If the coverage range has been specified by a source file the saved COV file cannot be loaded 5 11 8 Updating Coverage Information Selecting Refresh from the popup menu updates the content of the Code Coverage window 5 11 9 Preventing Update of Coverage Information Selecting Lock Refresh from the popup menu prevents update of the Code Coverage window while the user program execution is stopped This also prevents access to the emulator for acquisition of coverage information 287 7 ENESAS 5 11 10 Confirmation Request Dialog Box e Clearing code coverage information or closing the Code Coverage window A confirmation dialog box appears before clearing code coverage information or closing the Code Coverage window Confirmation Request Clear Coverage RAM Figure 5 115 Confirmation Request Dialog Box When Save Coverage Data is checked the coverage data can be sa
198. n the Memory window to check that the memory is operating correctly Note The above way of checking the operation of memory may be inadequate It is recommended that a program for checking the memory be created e Select Memory from the CPU submenu of the View menu and enter H 00000000 in the Display Address edit box Display Address Display Address 00000000 gl Scroll Start Address 00000000 Scroll End Address FFFFFFFF Figure 6 2 Display Address Dialog Box 298 RENESAS e Click the OK button The Memory window is displayed and shows the specified memory area Register 0 1 42 3 4 5 46 0 08 0 08 44 0 og t 0 0 lt oo SAS SS900SC 5555 00000090 000000401 000000B0 000000 0 So 252225252255 Sogo ecoooo0og0c0gcoo St StO GO 425325 5505 ecoocooocoeococoocoeo eccooccsecscsococo oOooooocoocoo Figure 6 3 Memory Window e Placing the mouse cursor on a point in the display of data in the Memory window and double clicking allows the values at that point to be changed Data can also be directly edited around the current position of the text cursor For details on the usage of the Memory window such as modifying the displayed data size refer to the High performance Embedded Workshop User s Manual 299 RENESAS 6 6 Downloading the Tutorial Prog
199. n the malfunction 1 Operating mode Mode occurred 2 Voltage of the target system V 3 Clock in use input from Xtal oscillation or external clock circle one item 4 Operating frequency MHz 5 Failure phenomenon 6 Error in debugging 7 Error in the diagnostic program 8 The High performance Embedded Content of the error message Workshop does not link up with the emulator For errors other than the above fill in the box below 387 7RENESAS 388 RENESAS Renesas Microcomputer Development Environment System User s Manual SH 4A SH4AL DSP E200F Emulator Publication Date Rev 1 00 June 2 2004 Rev 6 00 July 25 2007 Published by Sales Strategic Planning Div Renesas Technology Corp Edited by Customer Support Department Global Strategic Communication Div Renesas Solutions Corp 2007 Renesas Technology Corp All rights reserved Printed in Japan Renesas Technology Corp Sales Strategic Planning Div Nippon Bldg 2 6 2 Ohte machi Chiyoda ku Tokyo 100 0004 Japan 2CENESAS RENESAS SALES OFFICES http www renesas com Refer to http Awww renesas com en network for the latest and detailed information Renesas Technology America Inc 450 Holger Way San Jose CA 95134 1368 U S A Tel lt 1 gt 408 382 7500 Fax lt 1 gt 408 382 7501 Renesas Technology Europe Limited Dukes Meadow Millboard Road Bourne End Buckinghamshire SL8 5FH U K
200. n time of function g counts cannot be measured It is recommended that a break occur within the function where execution is started When execution returns to the upper function the execution counts of the function cannot be measured 270 7 ENESAS 3 Restrictions on using the nest mode i Tail call When a tail call is used for a function as shown below the return value of the callee function becomes the return address of the caller function The execution time of the callee function cannot be measured correctly but the execution counts can be masured No branch Figure 5 97 Tail Call Nest Mode 271 RENESAS There is a restriction when the tail call is used to call another function from the function that has been called by the tail call If the tail call occurs continuously three step measurement will be correctly performed Step1 Step2 Step3 Figure 5 98 Restriction on Call ii Nesting functions If 32 step or more calls are generated from the top function within the range to be measured correct measurement will not be performed A warning message will be displayed Gii Calling from a function outside the measurement range Correct measurement will not be performed if a function outside the measurement range calls a function to be measured and the callee function cannot return correctly to the caller function Even if the callee function returns correctly to the caller function correct measurement will
201. naees 37 1 3 8 Coverage FUNCHON o sa ses c ces eissctecvcdeeceetssnebiens ecavassd sy R EAEE R tusdb ys EEEE 51 1 3 9 Memory Access FUNCIONS ssssssserisicorriri sei ssisscoesseisiesusrsiedise esseeri senaosa iakin 52 1 3 9 Stack Trace FUnCHON isceisccssicesesess sees cossvieecessiveysssss aoe engess e eare e TREERE 54 1 3 10 User interrupt Open Function during User Program Break eee 54 LTE Online Help crnce anere arre e E E E r E 54 1 4 Environmental Conditions cessircasrereiiusaiusrapdisinieni iriiria ina e sa EA 55 Section 2 Setting Up the Emulator eeeseeseeeeseseeseesersresreesersrrsressressreererresseeeres 57 2 1 Flow Chart before Using the Emulator ceeeseeeseceeeceeeeecesseeeseeeseeeaeeeaeseneeeeaes 57 2 2 stalling DEDUS SER iosia E Goad NEEE a 58 22l CIDER aein e E aie 1 ales ern is ae es 58 2 3 Connecting the Optional Units to the Emulator Main Unit Case eee eeeeeeeeeeeeees 59 2 3 1 Connecting the E200F Trace Unit to the User System eee eereeeees 59 2 3 2 Connecting the E200F Peripheral I O Analyzer Unit to the User System 62 2 3 3 Connecting the E200F Expansion Profiling Unit to the Main Unit Case 63 2 4 Connecting the AC Adapter to the Emulator Main Unit Case eee eeeeeseeereteeeeees 69 2 5 Connecting the Emulator to the Host Machine eee eee eeeeseceseceseeeseeseeeseeeseeeaeseseeaes 70 2 6 Connecting the Emulator to the User System 0 eee eee ceeeeeceececeeeceeseeeseeeseeea
202. ng Trace Information Usermemory trace Output to the User Memory Selecting the Set menu in the popup menu of the Internal AUD Usermemory acquisition window displays the Internal AUD Usermemory acquisition dialog box When Usermemory trace is selected in Trace Type within the dialog box the trace information output to the user memory is acquired The items to be displayed are the same as those for the internal trace information For details refer to section 5 7 1 1 Acquiring Internal Trace Information 219 RENESAS 4 Specifying Conditions or Modes for Acquiring Trace Information The capacity of the trace buffer is limited When the buffer becomes full the oldest trace information is overwritten Setting the trace acquisition condition allows acquisition of useful trace information and effective use of the trace buffer The trace information acquisition conditions are implemented by eventpoints and acquisition start acquisition end and acquisition can be controlled For setting eventpoints refer to section 5 6 Using the Eventpoints The trace information acquisition mode is set in the Internal AUD Usermemory acquisition dialog box that is displayed by selecting Set from the popup menu 220 RENESAS Internal AUD Usermemory acquisition Trace Mode Trace type Ci Internal trace User Memory trace Trace Mode 1 Realtime trace Non realtime trace Trace Mode 2 Trace continue Trace
203. nge for searching Address Sets an address condition Data Sets a data condition Type Selects the type of trace information Bus Selects the type of a bus R W Selects the type of access cycles Note Items other than General and Address vary according to the emulator in use For details refer to the online help Clicking the OK button after setting conditions in those pages stores the settings and starts searching Clicking the Cancel button closes this dialog box without setting conditions When a trace record that matches the search conditions is found the line for the trace record will be highlighted When no matching trace record is found a message dialog box will appear Only the trace information that satisfies all the conditions set in above pages will be searched If a search operation is successful selecting Find Next from the popup menu will move to the next found item 227 RENESAS 1 General page Set the range for searching Trace Find General Address data Type Bus RAW m Trace search range Not designation Start PTR 32767 End PTR Poo M Upward search Cancel Apply Figure 5 62 Trace Find Dialog Box General Page Trace search range Sets the range for searching Not designation Upward search Start PTR End PTR Searches for information that does not match the conditions set in other pages when this box is checked
204. nge measurement Start Address Enters the start address 252 RENESAS End Address Enters the end address Extend Condition Sets the extension condition End Range Sets the measurement end condition for Start Range to End Range measurement Start Address Enters the start address End Address Enters the end address Extend Condition Sets the extension condition Enable Count Overflow Break A break occurs if the execution count exceeds the specified count Time measurement Unit Specifies the resolution of the measurement timer as any of the Notes 1 following values 20 ns 50 ns or 400 ns The End Range item is only displayed when Start Range to End Range measurement is selected The Enable Count Overflow Break is only displayed when measurement channel 1 is selected 253 RENESAS Clicking the Extend Condition button opens the dialog box to set the extension condition The bus state condition can be set When the range is selected as the measurement condition the read cycle is selected Performance Analysis Bus Channel 1 Bus State Direction Figure 5 86 Dialog Box for Setting the Bus Performance Analysis Extension Condition 5 8 4 Hiding the Column It is possible to hide any column not necessary in the Performance Analysis window Selecting a column you want to hide from the popup menu displayed by clicking the right hand mouse button on the header column hides t
205. ngs Dialog Box Options Page The command chain that is automatically executed at the specified timing is registered The following three timings can be specified e At connecting the emulator e Immediately before downloading e Immediately after downloading Specify the timing for executing the command chain in the Command batch file load timing drop down list box In addition register the command chain file that is executed at the specified timing in the Command Line Batch Processing list box 116 RENESAS 4 4 Debug Sessions The High performance Embedded Workshop stores all of your builder options into a configuration In a similar way the High performance Embedded Workshop stores your debugger options in a session The debugging platforms the programs to be downloaded and each debugging platform s options can be stored in a session Sessions are not directly related to a configuration This means that multiple sessions can share the same download module and avoid unnecessary program rebuilds Each session s data should be stored in a separate file in the High performance Embedded Workshop project Debug sessions are described in detail below 4 4 1 Selecting a Session The current session can be selected in the following two ways e From the toolbar Select a session from the drop down list box figure 4 30 in the toolbar Figure 4 30 Toolbar Selection 117 7 ENESAS e From the dialog box 1 Sele
206. not be output Non realtime trace The CPU stops operations until the trace information is output Trace mode 2 Specifies the operation when the AUD trace buffer of the emulator p p becomes full Trace continue The oldest trace information is overwritten to acquire the latest trace information Trace stop When the trace buffer becomes full the trace information is no longer acquired Break A break occurs AUD Mode Sets the mode when the AUD trace function is used Enable free trace When checked a free trace is enabled Time stamp clock Specifies the resolution of the timer for time stamp as any of the following values 20 ns 40 ns 100 ns or 400 ns AUD trace display range Sets the trace display range when the AUD trace function is used Start pointer Enters the numerical start pointer value of the display range End pointer Enters the numerical end pointer value of the display range Trace Extend Mode Sets whether or not internal performance counter Ch3 or Ch4 is included as the item for trace acquisition Trace data with PPC When checked internal performance counter Ch3 or Ch4 is included Note The items that can be set in this window differ according to the product For details on the settings for each product refer to the online help 344 RENESAS c Setting the trace acquisition condition The following is an example of acquiring memory access information For acquiring other trace info
207. not be performed if other functions are called within three instructions from the return address The user program execution starts from a function outside the measurement range and then moves to a function within the measurement range After that the execution branches to another function outside the measurement range 272 7 ENESAS iv Relationships between the Go start address break address and measurable ranges Figure 5 99 Measurable Ranges Nest Mode Measurable ranges when a break occurs at the position of black circle e Execution time and counts of function h Measurable ranges when a break occurs at the position of red circle e Execution time and counts of functions h and k Measurable ranges when a break occurs at the position of blue circle e Execution time and counts of functions h and k It is recommended that a break occur within the function where execution is started When execution returns to the upper function the execution counts of the function cannot be measured 273 7 ENESAS 5 10 1 Opening the Realtime Profile Window Select View gt Performance gt Realtime Profile to open the Realtime Profile window Clicking the column header changes the ascending or descending order of items in displayed contents Realtime Profile olx Page Function Address Size Count Time _PowerON_Reset_PC H 800 H 30 47789 18253h054min011s721ms117us956ns _Manual_Reset_PC H 830 H 1C 61453 18253h054minO11s721m
208. ns Note When the expansion profiling unit is not connected to the emulator this page is not displayed Configuration General Main Board Bus Board Option Board Loading flash memory Option board mode setting Figure 5 6 Configuration Dialog Box Option Board Page 141 7 ENESAS Item that can be displayed in this page is listed below Option board mode setting 142 Displays the functions of the expansion profiling unit RealProfile Area 2 function mode The realtime profiling function measurement mode function mode has been selected RealProfile Area 2 nest mode The realtime profiling function measurement mode nest mode has been selected Coverage 8M The coverage function has been selected The 8 Mbyte area can be measured RENESAS 5 1 6 Downloading to the Flash Memory Sets the emulator operation conditions for downloading the external flash memory For details refer to section 6 22 Download Function to the Flash Memory Area Configuration General Loading flash memory Loading flash memory C Disable Erasing flash memory Disable Enable File name Browse Bus width of flash memory 32 bit bus width x Flash memory erasing time minute Entry point All erasing module address Writing module address Access size Figure 5 7 Configuration Dialog Box Loading flash memory Page Items that can be displayed in this page are listed below 143
209. ns 40 ns 100 ns or 400 ns AUD trace display range Sets the trace display range when the AUD trace function is used Start pointer Enters the numerical start pointer value of the display range End pointer Enters the numerical end pointer value of the display range User memory area Sets the trace display range when the user memory output trace function is used Start Address Specifies the start address of the display range End Address Specifies the end address of the display range Trace Extend Mode Sets whether or not internal performance counter Ch3 or Ch4 is included as the item for trace acquisition Trace data with PPC When checked internal performance counter Ch3 or Ch4 is included Notes 1 When Internal trace is selected Trace Mode 1 Trace Mode 2 AUD Mode AUD trace display range and User memory area are disabled 2 When only AUD trace is selected Trace Mode 2 AUD Mode and AUD trace display range are enabled 3 When only User Memory trace is selected User memory area is enabled 222 RENESAS Clicking the OK button stores the settings Clicking the Cancel button closes this dialog box without modifying the settings 5 7 2 Opening the BUS MFI trace Window To display the Trace Window Type dialog box choose View gt Code gt Trace or click the Trace toolbar button Trace Window Type race window BUS MFI trace v oeei Figure 5 59 T
210. nt Dialog Box Condition Page The minimum time to be measured Specifies the resolution of the timer for execution time measurement as any of the following values 20 ns 40 ns 100 ns or 400 ns Runtime count Specifies the execution time conditions Don t care Specifies no execution time condition Cycle Enters the measurement cycle counts D 0 to D 1099511627775 is available 212 RENESAS b Action page Sets the operation after the condition has been satisfied Runtime Count Condition Action Figure 5 54 Runtime Count Dialog Box Action Page Break Breaks after conditions have been matched 213 RENESAS 5 6 9 Editing Breakpoint or Eventpoint Select a break condition to be modified and choose Edit from the popup menu to open the dialog box for the point which allows the user to modify the breakpoints or eventpoints The Edit menu is only available when one breakpoint or eventpoint is selected 5 6 10 Enabling Breakpoint or Eventpoint Select a breakpoint or an eventpoint and choose Enable from the popup menu to enable the selected breakpoint or eventpoint 5 6 11 Disabling Breakpoint or Eventpoint Select a breakpoint or an eventpoint and choose Disable from the popup menu to disable the selected breakpoint or eventpoint When a breakpoint or an eventpoint is disabled a condition will not be satisfied when the specified conditions have been satisfied 5 6 12 Del
211. nt Policy Renesas Technology Corp including its subsidiaries hereafter collectively referred to as Renesas pursues a policy of continuing improvement in design performance and safety of the emulator product Renesas reserves the right to change wholly or partially the specifications design user s manual and other documentation at any time without notice RENESAS Target User of the Emulator Product This emulator product should only be used by those who have carefully read and thoroughly understood the information and restrictions contained in the user s manual Do not attempt to use the emulator product until you fully understand its mechanism It is highly recommended that first time users be instructed by users that are well versed in the operation of the emulator product Users are required to be familiar with the basic knowledge for the electric circuits logic circuits and microcomputers Precautions to be Taken when Using This Product 1 This emulator is a development supporting unit for use in your program development and evaluation stages In mass producing your program you have finished developing be sure to make a judgment on your own risk that it can be put to practical use by performing integration test evaluation or some experiment else In no event shall Renesas Solutions Corporation be liable for any consequence arising from the use of this emulator Renesas Solutions Corporation strives to reno
212. og box 2 For the Action item B Setting a break is enabled T Setting a trace is enabled P Setting a performance start or end condition is enabled 177 RENESAS Sequential Setting In the emulator sequential Table 5 3 Sequential Event Conditions Type Event Condition CPU 2 Channel Ch2 gt 1 Sequential Sequential Event Page setting of an Event Condition is enabled Description Halts a program when after conditions have been matched in the order of Event Condition 2 1 An event condition must be set for Ch2 and Ch1 Ch4 gt 3 Halts a program after conditions have been matched in the order of Event Condition 4 3 An event condition must be set for Ch4 and Ch3 Ch6 gt 5 Halts a program after conditions have been matched in the order of Event Condition 6 5 An event condition must be set for Ch6 and Ch5 Ch11 gt 10 Halts a program after conditions have been matched in the order of Event Condition 11 10 An event condition must be set for Ch11 and Ch10 Many Ch3 gt 2 gt 1 Channel Sequential Halts a program after conditions have been matched in the order of Event Condition 3 2 1 An event condition must be set for Ch3 Ch2 and Ch1 Ch4 gt 3 gt 2 gt 1 Halts a program after conditions have been matched in the order of Event Condition 4 3 2 1 An event condition must be set for Ch4 Ch3 Ch2 and Ch1 Ch5 gt 4 gt 3 gt 2 gt 1 Halts a
213. one of the following causes we will repair it or replace it with new one with extra charge e Misuse abuse or use under extraordinary conditions e Unauthorized repair remodeling maintenance and so on e Inadequate user s system or misuse of it e Fires earthquakes and other unexpected disasters In the above cases contact your local distributor If your product is being leased consult the leasing company or the owner 371 7 ENESAS 8 4 Repair Provisions 8 4 1 Repair with Extra Charge The products elapsed more than one year after purchase can be repaired with extra charge 8 4 2 Replacement with Extra Charge If your product s fault falls in any of the following categories the fault will be corrected by replacing the entire product instead of repair or you will be advised to purchase new one depending on the severity of the fault e Faulty or broken mechanical parts e Flaw separation or rust in coated or plated parts e Flaw or cracks in plastic parts e Faults or breakage caused by improper use or unauthorized repair or modification e Heavily damaged electric circuits due to overvoltage overcurrent or shorting of power supply e Cracks in the printed circuit board or burnt down patterns e Wide range of faults that makes replacement less expensive than repair e Unlocatable or unidentified faults 8 4 3 Expiration of the Repair Period When a period of one year elapses after the model was dropped from production r
214. ons cont No Item Function 8 Memory access functions e Downloading to RAM e Downloading to flash memory e Single line assembly e Reverse assembly disassembly e Reading of memory e Writing to memory e Automatic updating of a display of selected variables during user program execution e Fill e Search e Move e Copy e Monitor physical or virtual address e Emulation memory 9 General control register Reads or writes the general control registers access function 10 Internal I O register Reads or writes the internal I O registers access function 11 Source level debugging Various source level debugging functions function 12 Coverage function Displays the information of executed instructions 13 Command line function Supports command input Batch processing is enabled when a file is created by arranging commands in input order 14 Help function Describes the usage of each function or command syntax input from the command line window Note The IO window displays the contents defined in SHxxxx io Editing those contents adds or deletes the registers to be displayed For the contents to be described as SHxxxx io refer to reference 5 I O File Format in the High performance Embedded Workshop V 4 00 User s Manual The following directory contains SHxxxx io xxxx means the core name lt High performance Embedded Workshop folder gt Tools Renesas DebugComp Platform E200F xxxx lOFiles The specific functi
215. ons of the emulator are described in the next section 23 RENESAS 1 3 2 Event Detection Functions The emulator has complex event detection functions in addition to the standard PC breakpoints of the High performance Embedded Workshop 1 Events In most practical debugging applications the program or hardware errors that you are trying to debug occur under a certain restricted set of circumstances For example a hardware error may only occur after a specific area of memory has been accessed Tracking down such problems using simple PC breakpoints can be very time consuming With the emulator the combination of the specified conditions such as address data or access condition can be defined as the eventpoint When an eventpoint condition is satisfied an event will occur The event detection function of the emulator can be used to detect a generated event and control the operations of break trace and performance measurement start end 2 Types of Events The emulator has four types of events a On chip event function Onchip Event This is a function that uses an on chip break controller and sets eventpoints according to the information in the MPU There are 13 event detection channels The eventpoints can be defined as a combination of one or more of the following e Address condition e Data condition e ASID condition e Bus state condition e Address condition for the destination of memory access e System bus condition
216. ory trace and external bus trace BUS trace The peripheral I O trace information can be acquired in some products The information on the Internal trace AUD trace and Usermemory trace is displayed on the Internal AUD Usermemory trace window The information on the BUS trace is displayed on the BUS window For the description on the trace function refer to section 1 3 3 Trace Functions 5 7 1 Opening the Internal AUD Usermemory trace Window To display the Trace Window Type dialog box choose View gt Code gt Trace or click the Trace toolbar button Trace Window Type Trace window TERR eee E E Figure 5 55 Trace Window Type Dialog Box Selecting Internal AUD Usermemory trace and clicking the OK button displays the Internal AUD Usermemory trace window 215 RENESAS 1 Acquiring Internal Trace Information Internal trace Selecting the Set menu in the popup menu of the Internal AUD Usermemory acquisition window displays the Internal AUD Usermemory acquisition dialog box When Internal trace is selected in Trace Type within the dialog box the trace information is acquired by using the internal trace function When the emulator does not set the acquisition condition of the trace information the trace information is acquired by the internal trace function in default The acquired trace information is displayed in the Internal AUD Usermemory trace window Internal AUD Usermemory t
217. out accessing the CPU that value cannot be displayed e Physical space radio button Displays the monitoring function as a physical address 81 7 ENESAS 82 7 ENESAS Section 3 Hardware Specifications 3 1 List of Specifications Table 3 1 lists the external dimensions and mass of the emulator Table 3 1 External Dimensions and Mass No Item Specification 1 External dimensions of E200F main unit case 185 x 130 x 45 mm 2 Mass of E200F main unit case 321 g 3 External dimensions of E200F trace unit 120 x 90 x 1 6 mm 4 Mass of E200F trace unit 104 g 5 External dimensions of E200F profiling unit 115 x 89 x 1 6 mm 6 Mass of E200F profiling unit 95 g 3 2 Interface Circuits in the Emulator Figures 3 1 and 3 2 show 36 pin interface circuits in the emulator Use them as a reference to determine the value of the pull up resistance Figures 3 3 and 3 4 show 38 pin interface circuits in the emulator Note The IC with UVCC power supply operates at 3 3 V or VCC 1 8 to 3 3 V from the H UDI port connector 83 7 ENESAS User connector Emulator control circuit 3 3v 36 pins 74AVCA16245 TCK TRST ASEBRKAK TMS 74LVC2G125 Vcc AY 74LVC2G125 Figure 3 1 Interface Circuits in the Emulator 36 pin Interface for H UDI 84 RENESAS User connector Emulator control circuit 3 3 V 36 pins 74AVCA16245 Vcc con han 74LVC2G125 74AVCA16245 AUDATA 3 0 74LVC2G
218. ox will be displayed Instant Watch a O0x0000ffcO lone flO Figure 6 17 Instant Watch Dialog Box e Click the Add button to add a variable to the Watch window OOOOFFB4 long 10 Fh watch Watch2 Watch Watch4 rd Figure 6 18 Watch Window Displaying the Array 312 1RENESAS The user can also add a variable to the Watch window by specifying its name e Click the Watch window with the right hand mouse button and select Add Watch from the popup menu The following dialog box will be displayed Enter variable i Add Watch Variable or expression fo 5 Cancel Figure 6 19 Add Watch Dialog Box e Click the OK button The Watch window will now also show the int type variable i OOOOFFB4 long 10 H 0000000a R13 int Eh watch A watcha A watcha A watcha Figure 6 20 Watch Window Displaying the Variable 313 7 ENESAS The user can click mark at the left side of array a in the Watch window to watch all the elements H 00005665 oooo H O000053dc Oooo H 00004d1d 0000 H 0000421f oooo H O00003ead Oooo H 00002f5a oooo H 00002704 oooo H 000020da Oooo H O00000daa Oooo H 00000000 oooo H 0000000a R13 SP watch watcha Watcha A Watcha Figure 6 21 Watch Window Displaying Array Elements 314 7 ENESAS 6 14 Displaying Local
219. pecified 4 The mask address cannot be input for Start and End when the address range is specified 186 RENESAS 3 Window page Specifies the address and data conditions of the window trace Ch2 Delay General Window Count Delay Action Address Don t care C Address Range Start H00000000 End Ho0000000 Outside Data Dont care Read Write Read C White Value Hooooo00000000000 C Byte Word 82 bit Outside Cues Figure 5 35 Chx Delay Dialog Box Window Page Address Sets the address condition Don t care Sets no address condition Address Sets the single address Range Sets the address range Start Sets the single address or the start address of the address range End Sets the end address of the address range Outside Sets other value than that has been set for the single address or address range as the condition 187 7 ENESAS Data Sets the data condition Don t care Sets no data condition Read Write Sets the read or write cycle as the condition Read Sets the read cycle as the condition Write Sets the write cycle as the condition Value Sets the data bus value mask data can be input Byte Sets the byte access as the condition Word Sets the word access as the condition 32 bit Sets the 32 bit access as the condition Outside Sets other value than that has been set for Val
220. performance Embedded Workshop When selecting Renesas High performance Embedded Workshop gt High performance Embedded Workshop from Programs in the Start menu to initiate another High performance Embedded Workshop two emulators can be used separately for debugging 291 7 ENESAS 5 12 1 Distinguishing Two Emulators Connect two emulators to the USB connector Then initiate the High performance Embedded Workshop using the tutorial workspace The following message is displayed hexxxx A Please choose driver Figure 5 118 Message for Driver Selection Click the OK button The following dialog box will appear Driver Details Driver KOE GAG X Details hterface F Channel z i Figure 5 119 Driver Details Dialog Box 1 292 RENESAS Select Renesas E Series USB Driver from the Driver drop down list box and open the Channel drop down list box Channel information for two emulators is displayed in the Channel drop down list box as shown in figure 5 120 Driver Details Driver Renesas E Series USB Driver x Details hterface USB interface Channel to000001 000000 0000002 i Close Figure 5 120 Driver Details Dialog Box 2 Information displayed in figure 5 120 is that of the serial number of the emulator When initiating the High performance Embedded Workshop in the Channel drop down list box select the information on the serial number of th
221. program after conditions have been matched in the order of Event Condition 5 4 3 2 1 An event condition must be set for Ch5 Ch4 Ch3 Ch2 and Ch1 Ch6 gt 5 gt 4 gt 3 gt 2 gt 1 Halts a program after conditions have been matched in the order of Event Condition 6 5 4 3 2 1 An event condition must be set for Ch6 Ch5 Ch4 Ch3 Ch2 and Ch1 Ch10 gt 6 gt 5 gt 4 gt 3 gt 2 gt 1 Halts a program after conditions have been matched in the order of Event Condition 10 6 5 4 3 2 1 An event condition must be set for Ch10 Ch6 Ch5 Ch4 Ch3 Ch2 and Ch1 Ch11 gt 10 gt 6 gt 5 gt 4 gt 3 gt 2 gt 1 178 Halts a program after conditions have been matched in the order of Event Condition 11 10 6 5 4 3 2 1 An event condition must be set for Ch11 Ch10 Ch6 Ch5 Ch4 Ch3 Ch2 and Ch1 RENESAS Table 5 3 Sequential Event Conditions cont Type Event Condition Description CPU CPU Extend Expands the CPU Sequential Extend page Sequential The sequential setting is enabled with any Event Page combination cont For details refer to Sequential Break Extension Setting in this section SystemBus SystemBus Ch9 gt 8 Halts a program after conditions have been Sequential Sequential matched for Event Condition 9 8 Event PageEvent An event condition must be set for Ch9 and Ch8 Ch8 gt 9 Halts a program after conditions have been matched
222. properties Their graphic images and meanings are given in this safety page Be sure to read this chapter before using the product gt This is the safety alert symbol It is used to alert you to potential personal injury hazards Obey all safety messages that follow this symbol to avoid possible injury or death A DANGER DANGER indicates an imminently hazardous situation which if not avoided will result in death or serious injury A WARNING WARNING indicates a potentially hazardous situation which if not avoided could result in death or serious injury A CAUTION CAUTION indicates a potentially hazardous situation which if not avoided may result in minor or moderate injury CAUTION CAUTION used without the safety alert symbol indicates a potentially hazardous situation which if not avoided may result in property damage NOTE emphasizes essential information In addition to the four above the following are also used as appropriate RENESAS A means WARNING or CAUTION Example A CAUTION AGAINST AN ELECTRIC SHOCK S means PROHIBITION Example DISASSEMBLY PROHIBITED means A FORCIBLE ACTION Example UNPLUG THE POWER CABLE FROM THE RECEPTACLE VI RENESAS WARNING Warnings for AC Power Supply A If the attached AC power cable does not fit the receptacle do not alter the AC power cable and do not plug it forcibly Failure to comply may cause electric shock and or fire e Use
223. ps trace acquisition and updates the trace display Use this method to check the trace information without stopping execution of the user program 5 7 10 Extracting Records from the Acquired Information Use the filtering function to extract the records you need from the acquired trace information The filtering function allows the trace information acquired by hardware to be filtered by software Unlike the settings made in the Trace Acquisition dialog box for acquiring trace information by conditions changing the settings for filtering several times to filter the acquired trace information allows easy extraction of necessary information which is useful for analysis of data The content of the trace buffer will not be changed even when the filtering function is used Acquiring useful information as much as possible by the Trace Acquisition settings improves the efficiency in analysis of data because the capacity of the trace buffer is limited Use the filtering function in the Trace Filter dialog box To open the Trace Filter dialog box select Filter from the popup menu The Trace Filter dialog box has the following pages Table 5 5 Trace Filter Dialog Box Pages Page Description General Selects the range for filtering Address Sets address conditions Data Sets data conditions Type Selects the type of trace information Bus Selects the type of a bus R W Selects the type of access cycles
224. quire subroutine branch instruction event J Acquire exception branch instruction event Figure 6 46 Event condition 12 Dialog Box Note The items that can be set in this dialog box differ according to the product For details on the settings for each product refer to the online help 339 RENESAS c Displaying the trace result Run the program as shown in the example of section 6 17 1 PC Break Function The internal trace results are displayed in the Internal AUD Usermemory trace window after the program execution is completed Internal AUD Usermemory trace olx PTR IP Master Type BranchType R W Address Data PPCS Instruction Source al 000013 D 000006 CPU BRANCH GENERAL 00002111A BF 000012 DESTINATION 000020FE mov a i tmp 9 i 000011 D o00005 CPU BRANCH GENERAL oo00211Aa BF 000010 DESTINATION 000020FE noy afi tmp 9 i 000009 D 000004 CPU BRANCH GENERAL 00000211A BF 000008 DESTINATION 000020FE noy a i tup 9 i 000007 D 000003 CPU BRANCH GENERAL 00000211A BF 000006 DESTINATION 000020FE mov ali tmp 9 i 000005 D o00002 CPU BRANCH GENERAL oo00211A BF 000004 DESTINATION 000020FE moy afi tmp 9 i 000003 D 000001 CPU BRANCH GENERAL 00002114 BF 000002 DESTINATION 000020FE noy a i tmp 9 i 000001 D 000000 CPU BRANCH SUBROUTINE 00002120 RTS 000000 DESTINATION o000109C nov while l Figure 6 47 Internal AUD Usermemory trace Window e If ne
225. r selecting the information on the memory map setting you want to change opens the Edit Memory Mapping dialog box This dialog box also opens when the Add button is clicked on the Memory Mapping dialog box Edit Memory Mapping Memory Mapping From H 00000000 Setting EMULATION AREA 16 bit ca Figure 5 9 Edit Memory Mapping Dialog Box Use this dialog box to change the address range and attributes of a memory map From Enter the start address of the map range Setting Enter the memory map setting The choices given are listed below Since these items differ depending on the product refer to the online help e EMULATION AREA 16 bit The data bus width is 16 bits e EMULATION AREA 16 bit Read Only This area is write protected and the data bus width is 16 bits e USER AREA This area is specified as the user area Note The unit for mapping the memory is fixed to 4 Mbytes 147 7 ENESAS 5 2 Downloading a Program This section describes how to download a program and view it as source code or assembly language mnemonics Note After a break has occurred the High performance Embedded Workshop displays the location of the program counter PC In most cases for example if an Elf Dwarf2 based project is moved from its original path the source file may not be automatically found In this case the High performance Embedded Workshop will open a source file browser dialog box to allow you to
226. race 2 lu FO Master Type BranchType B R Address D P P Instruction D 000006 CPU BRANCH GENERAL 00002114 H 20F8 2 DESTINATION D 000005 BRANCH GENERAL 00002114 H ZOF8 DESTINATION 000020F8 R15 R1 ali tmp 9 D 000004 BRANCH GENERAL 00002114 H 20F8 DESTINATION 000020F8 R15 R1 ali tmp 9 D 000003 BRANCH GENERAL 00002114 H ZOF8 DESTINATION 000020F8 R15 R1 ali tmp 9 D 000002 BRANCH GENERAL 00002114 H 20F8 DESTINATION 000020F8 R15 R1 ali tmp 9 D 000001 BRANCH GENERAL 00002114 H 20F8 DESTINATION 000020F8 R15 R1 ali tmp 9 000001 D 000000 BRANCH SUBROUTINE 00002114 000000 DESTINATION 00001098 R15 R2 p_sam gt s0 a l Jy lt gt Figure 5 56 Internal AUD Usermemory trace Window Internal Trace Some MPUs to be debugged display the items below For details on the specifications of each product refer to the additional document Supplementary Information on Using the SHxxxx or the online help PTR The trace buffer pointer 0 for the last executed instruction IP The amount of acquired trace information Master Bus Master Type of bus master accessed Type Type of trace information BRANCH Branch source DESTINATION Branch destination MEMORY Memory access S_TRACE Executed Trace x function LOST Lost trace information only in the realtime mode 216 RENESAS Branch Type Bus R W Address Data PPC3 PPC4 Instruction Source Label
227. race Window Type Dialog Box Selecting BUS MFI trace and clicking the OK button displays the BUS MFI trace window Notes 1 When the trace unit is not connected to the emulator the external bus trace function is not supported 2 When the function of the trace unit is changed the number of bus cycles that can be acquired by the external bus trace is changed For details refer to section 5 1 4 Bus Board Page 3 Not only the BUS trace but also other trace functions can be displayed in this window depending on the product For example the display will be BUS MFI Trace in the SH Mobile MPUs In this case the result of the access via MFI that has been acquired by a trace is displayed For details on the specifications of each product refer to the online help 1 Acquiring External Bus Trace Information BUS trace Selecting the Set menu in the popup menu of the BUS MFI trace window displays the BUS acquisition dialog box When BUS MFI trace is selected in Trace Type within the dialog box the trace information is acquired by using the external bus trace function When the emulator does not set the acquisition condition of the trace information the trace information is acquired by the external bus trace function in default The acquired trace information is displayed in the BUS MFI trace window 223 7 ENESAS BUS MFI trace clo e oe e mw ro PTR R W Address Data Instr IRQ7 0 MFICS T T
228. ram 6 6 1 Downloading the Tutorial Program Download the object program to be debugged e Select Download module from Tutorial abs under Download modules E G tutorial S tutorial H E C header file sbrk h sorth stackscth vecth source file dbsctc intpre c resetpre c sbrk c vecttblc Cr source file Download modules 4 tutorialabs 00000000 E Dependencies Download Download Debug Data Only Unload Download A New Module Debug Settings Configure View v Allow Dock ine Hide Properties Figure 6 4 Downloading the Tutorial Program 300 RENESAS 6 6 2 Displaying the Source Program The High performance Embedded Workshop allows the user to debug a user program at the source level e Double click tutorial cpp under C source file G tutorial tutorial a header file sbrk h sorth stackscth vecth source file dbsctc intpre c 00001038 00001040 void main void long a 10 long j int i class Sample p_sam while 1 l resetprec 0000104c sbrk c 00001056 for i 0 i lt 10 vecttble 0000105e j rand C source file 00001066 if lt Ot 0000106 iat l sort cpp 5 z 7 tutor ialcpp 00001060 Download modules 00001084 gt sort la mi E as p_sam sortla L tutoriaLabs 00000000 00001086 p_sam gt change a amp Dependencies pP_sam new Sample
229. ram execution Notes 1 Includes interrupts in a break 2 When User is selected for UBC mode Ch10 IA_OA_R and Ch11 I A_OA_CT_R that can be set on the Onchip sheet of the Event window cannot be used When User is selected for PPC mode Ch1 and Ch2 of the performance analysis function and options 1 and 2 of the profiling function cannot be used Note The items that can be set in this dialog box vary according to the emulator in use For details refer to the online help 134 RENESAS 5 1 3 Main Board Page Sets the main unit case operation conditions Configuration General Main Board Bus Board Option Board Loading flash memory Multi analysis mode setting Aud data bus width Figure 5 2 Configuration Dialog Box Main Board Page 135 RENESAS Items that can be displayed in this page are listed below Multi analysis mode setting AUD data bus width Displays the functions of the E200F main unit Here this item displays which function of realtime profiling coverage or I O analyzer has been selected RealProfile Area 1 function mode The realtime profiling function measurement mode function mode is selected RealProfile Areal nest mode The realtime profiling function measurement mode nest mode is selected Coverage 4M The coverage function is selected lt Depending on the product gt Uses the I O analyzer function Sets the AUD data bus w
230. rding to range the VP_MAP table Outside the Enabled Within the range Translated according to range the TLB table Outside the range TLB error Disabled Within outside the Not translated range Disabled Within Enabled Within the range Translated according to outside the the TLB table range Outside the range TLB error Disabled Within outside the Not translated range Virtual Enabled Within Enabled Within the range Translated according to disabled outside the the TLB table range Outside the range TLB error Disabled Within the range Translated according to the TLB table Outside the range TLB error Physical Enabled Within Enabled Within outside the Not translated disabled outside the disabled range range Note Specified by the Memory area group box in the Configuration dialog box 358 RENESAS 6 21 Stack Trace Function The emulator uses the information on the stack to display the names of functions in the sequence of calls that led to the function to which the program counter is currently pointing Note This function can be used only when the load module that has the Dwarf2 type debugging information is loaded Such load modules are supported in SHC C compiler including OEM and bundle products V6 0 or later e Double click the Source column in the sort function and set a PC breakpoint 00002032 void Sample sort long a long t int is Js Ka gapi 00002038 gap 53 0000203a while gap gt 0 o000203e
231. rmation refer to section 5 6 Using the Eventpoints Select and double click Ch2 Delay on the AUD Event sheet of the Event window The Ch2 Delay dialog box will appear Select the type of trace information to be acquired on the General page Ch Delay General Window Gount Action AUD function data Branch trace data Software trace data C SystemBus trace data Figure 6 50 Ch2 Delay Dialog Box General Page e Select Window trace data and click the Window page e The memory access range condition can be set in the Window page 345 7 ENESAS Ch2 Delay General Window Count Action r Address Don t care C Address Start H0000 FFCO End HOOOOF FES I Outside Data IV Dont care Read Write Read C Write Value f Byte Word 32bit 64 bit F Outside Figure 6 51 Ch2 Delay Dialog Box Windows Page e Select Range to acquire trace in the address range e Input H FFCO and H FFF4 into Start and End respectively e Memory access information between addresses H FFCO to H FFE4 array a is acquired e Select Trace get in the Action page and click the OK button 346 7 ENESAS d Displaying the trace result Run the program as shown in the example of section 6 17 1 PC Break Function The trace results are displayed in the Internal AUD Usermemory trace window after the program execut
232. rnal bus trace operation Trace start Starts external bus trace after conditions have been matched Trace stop Stops external bus trace after conditions have been matched Trace get Acquires external bus trace after conditions have been matched 206 RENESAS 7 Sequential BUS Event dialog box The sequential bus event occurs when all the BUS Eventpoint conditions are satisfied in the specified order Bus event channel Ch1 can be specified as the reset point When the reset point is passed the satisfied eventpoint condition is disabled and checking the first eventpoint condition is started Sequential BUS Event Channel select Channel 3 gt 2 C Channel 4 gt 3 gt 2 C Channel 5 gt 4 gt 3 gt 2 C Channel 6 gt 5 gt 4 gt 3 gt 2 Sequential reset Disable C Enable Action Break Trace stop oee Figure 5 49 Sequential BUS Event Dialog Box Don t care Sets no Sequential BUS Event condition Channel select Specifies the order that the Sequential BUS Event is satisfied Channel 3 gt 2 After conditions have been matched in the order of bus event channel 3 gt 2 a Sequential BUS Event occurs Channel 4 gt 3 gt 2 After conditions have been matched in the order of bus event channel 4 gt 3 gt 2 a Sequential BUS Event occurs Channel 5 gt 4 gt 3 gt 2 After conditions have been matched in the order of bus event channel
233. rom Enter single data or the minimum value of the data range not available when Don t care has been checked To Enter the maximum value of the data range only available when Range has been selected Note Along with setting the data range the minimum and maximum values can be set in the From and To options respectively 238 RENESAS 4 R W page Select the type of access cycles Trace Filter General Address data Type Bus R W Setting READ WRITE Cancel Apply Figure 5 71 Trace Filter Dialog Box R W Page Don t care Detects no read write condition when this box is checked Setting Detects the specified read write condition READ Detects read cycles when this box is checked not available when Don t care has been checked WRITE Detects write cycles when this box is checked not available when Don t care has been checked 239 RENESAS 5 Type page Select the type being accessed The selection is not available when a time stamp is acquired Trace Filter General hake data Type Bus RAW Setting BRANGH DESTINATION MEMORY LOST CPU Wait Cancel Apply Figure 5 72 Trace Filter Dialog Box Type Page Don t care Detects no type condition when this box is checked Setting Detects the specified type condition not available when Don t care has been check
234. rreesressrsrresee 95 AI System CHECK sssrin a E A E E 95 4 2 Method for Activating High performance Embedded Workshop ssessessereeserereserereereree 103 4 2 1 Creating the New Workspace Toolchain Not Used sseeseesseeserseeresreeresrrereer 104 4 2 2 Creating the New Workspace Toolchain Used eeseeeeeeeseeseessesssresrrsresresreere 108 4 2 3 Selecting an Existing Workspace ssssseesseesesseeseseerrssesresresresresresresrnsrerensesresestes 113 4 3 Setting at Emulator Activation s ssserosieicersiiesiresrii ssunod 115 4 4 Deb g SCSSLONS 6 jcc csekseccescdeedcoaeesne dsenoubedhedeacesaeasass E E sendeascia cds AE TE Ei 117 44 1 Selecting a Sessile aoier a easevasssonsvers vented weeded nlasdlie 117 4 4 2 Adding and Removing Sessions cceceecesceeseeeseeeseeeeeseceseeeaeseaeeeaeesaeeeeeseeesees 118 4 4 3 Saving Session Information 0 e eee eeceeseeeseeeeeeseceeeseeecaeecaeeeaeseaeesasesaeeseeenees 121 4 5 Connecting the Pm ulator cc decessceesssatiecdins capes asesscdeeg conessansand enean N N EEEN EEEE 122 4 6 Reconnecting the Emulator ee eeceseceseceecssesseeceesseeeaecesecssecsaeeeeeeeeaeseaessaeseeeeaes 123 4 7 Endine the Emulator ce aeeti cae de iisck E enoe a N EE O OE EEE aE 124 4 8 Uninstalling the Emulator s Software eseesesssessesesrsrrssesresresresresreresresresresresresrerrnsesresrent 125 Sections Debugging norersieniienna era a E Eo 131 5 1 Setting the Environment for Emulation
235. ry is written in the Memory window read cycles in the range displayed in the Memory window will occur for updating the window When the Memory window is not to be updated change the setting in Lock Refresh from the popup menu me command A command line function that reads or writes the specified amount of memory at the specified address 2 User program downloading function A load module registered in the workspace can be downloaded Such module can be selected from Download Module in the Debug menu Downloading is also possible by a popup menu that is opened by right clicking on the mouse at the load module in the workspace The user program is downloaded to the RAM or flash memory When downloading to the flash memory select Emulator from the Options menu open the Configuration window and perform required settings on the Loading flash memory page This function also downloads information required for source level debugging such as debugging information 3 Memory data uploading function The specified amount of memory from the specified address can be saved in a file 4 Memory data downloading function The memory contents saved in a file can be downloaded Select Load from the popup menu in the Memory window 5 Displaying the variable contents The variable contents specified in the user program are displayed 52 RENESAS 6 Monitoring function The emulator monitors a value in the area t
236. s in the Start menu 3 The Welcome dialog box is displayed Welcome Options Cancel C Open a recent project workspace Administration C Browse to another project workspace Figure 4 16 Welcome Dialog Box Create a new project workspace radio button Creates a new workspace Open a recent project workspace radio button Uses an existing workspace and displays the history of the opened workspace Browse to another project workspace radio button Uses an existing workspace this radio button is used when the history of the opened workspace does not remain In this section we describe the following three ways to start up the High performance Embedded Workshop e Create a new project workspace a toolchain is not in use e Create a new project workspace a toolchain is in use e Browse to another project workspace 103 7 ENESAS The following describes how to activate the High performance Embedded Workshop when selecting Create a new project workspace without any toolchain Create a new project workspace with a toolchain and Browse to another project workspace The Open a recent project workspace radio button is used to omit the operation for specifying the workspace file when Browse to another project workspace is selected 4 2 1 Creating the New Workspace Toolchain Not Used 1 In the Welcome dialog box that is displayed when the High performance Embedded Workshop is activate
237. s can be set Reset Event channel that can be set as the reset point of the external bus sequential event State Whether the eventpoint is enabled or disabled Enable Valid Disable Invalid Condition A condition that satisfies an eventpoint The displayed contents differ depending on the channel Action Operation of the emulator when an eventpoint condition is satisfied The displayed contents differ depending on the channel 199 7 ENESAS When an event channel is double clicked or selected and Edit is selected from the popup menu in this window the Chx dialog box is displayed The Chx dialog box consists of the Address Data Interrupt Count Delay and Action pages The combination of the conditions set in each page is set as the detection condition of eventpoints 1 Address page Specifies the address condition Ch2 Delay Address Data Interrupt Count Delay Action Address I Don tcare Address Start H00000000 End Fo0000000 Outside Figure 5 43 Chx Delay Dialog Box Address Page Address Sets the address condition Don t care Sets no address condition Address Sets the single address 200 RENESAS Range Start End Outside Sets the address range Sets the single address or the start address of the address range mask address can be input Sets the end address of the address range mask address can be
238. s checked Setting Detects the specified read write condition String Select a read write condition not available when Don t care has been checked READ Read cycle WRITE Write cycle 231 RENESAS 5 Type page Select the type being accessed The selection is not available when a time stamp is acquired Trace Find General Address data Type Bus RAW Baan r Setting String BRANCH x Cancel Apply Figure 5 66 Trace Find Dialog Box Type Page Don t care Detects no type condition when this box is checked Setting Detects the specified type condition String Select a type condition not available when Don t care has been checked 232 7 ENESAS 6 Bus page Select the status of a bus Trace Find General Address data Type Bus RAW m Setting String Bus Cancel Apply Figure 5 67 Trace Find Dialog Box Bus Page Don t care Detects no bus condition when this box is checked Setting Detects the specified bus condition String Select a bus condition not available when Don t care has been checked 233 RENESAS 5 7 5 Clearing the Trace Information When Clear is selected from the popup menu the trace buffer that stores the trace information becomes empty 5 7 6 Saving the Trace Information in a File Select Save from the popup menu to open the Save As file dialog box which allows the user to sa
239. s117us9S6ns _INT_Illegal_code H 84C H 4 47789 18253h054minO11s721ms117us9S56ns _Dummy H 850 H 4 61453 18253h054min011s721ms117us956ns _sbrk H 1000 H 24 47789 18253h054min011s721ms117us956ns _main H 1024 H 46 61453 18253h054min0118721ms117us9S6ns 1 H 10D8 H C 47789 18253h054minO118s721ms117us9S6ns _h2 H 10EcC H S 61453 18253h054min0O118721ms117us956ns _func3 H 10F4 H 16 47789 18253h054min01138721ms117us956ns _func4 H 1104 H 4 61453 18253h0S54min011s721ms117us956ns 1 1 1 1 1 1 zh a 1 1 Figure 5 100 Realtime Profile Window The following information can be acquired Address You can see the locations in memory to which the functions are allocated Size Sorting in order of size makes it easy to find small functions that are frequently called Setting such functions as inline may reduce the overhead of function calls If you execute larger functions more of the cache memory will need to be updated This information allows you to check if those functions that may cause cache misses are frequently called Count The number of times that functions have been called is displayed Times The total execution time is displayed 274 RENESAS 5 10 2 Specifying the Measurement Range Clicking the right hand mouse button on the window displays the popup menu When Add Range is selected from the popup menu the EDIT dialog box opens to specify the measurement range of realtime profile Start JHOo000000 Cancel Figure 5 1
240. sf Save as type Sessions hsf 7 Cancel I Maintain link Z Figure 4 34 Save Session Dialog Box 4 4 3 Saving Session Information e To save a session Select File gt Save Session 121 7 ENESAS 4 5 Connecting the Emulator Select either of the following two ways to connect the emulator a Connecting the emulator after the setting at emulator activation Select Debug settings from the Options menu to open the Debug Settings dialog box It is possible to register the download module or the command chain that is automatically executed at activation For details on the Debug Settings dialog box refer to section 4 3 Setting at Emulator Activation When the dialog box is closed after setting the Debug Settings dialog box the emulator will automatically be connected b Connecting the emulator without the setting at emulator activation Connect the emulator by simply switching the session file to one in which the setting for the emulator use has been registered Theas ave K ia K Freie Finy tee forse rot We Figure 4 35 Selecting the Session File 122 2eENESAS In the list box that is circled in figure 4 35 select the session file name including the character string that has been set in the Target name text box in figure 4 24 New Project 8 9 Debugger Option dialog box The setting for using the emulator has been registered in this session file After the session file na
241. signal condition OR Determines whether or not the condition is satisfied by OR operation of the probe signal condition Probe 1 to 4 Specifies the probe signal conditions Don t care Specifies no probe signal condition High Satisfies the condition when the probe signal is high Low Satisfies the condition when the probe signal is low 210 RENESAS b Action page Sets the operation after the condition has been satisfied Probe Condition Action r Action Break Trace AUD trace operation Trace start Ci Trace filter Caneel Figure 5 52 Probe Dialog Box Action Page Break Breaks after conditions have been matched Trace Enables AUD trace option and sets the AUD trace operation Trace start Starts AUD trace after conditions have been matched Trace stop Stops AUD trace after conditions have been matched Trace filter Sets the filter condition for acquiring AUD trace after conditions have been matched 211 RENESAS 2 Runtime Count dialog box Double clicking the Runtime Count event channel displays this dialog box Conditions of the eventpoint can be set on the Condition and Action pages a Condition page Specifies the execution time of the user program Runtime Count Condition Action Condition The minimum time to be measured 20ns Run time count Don t care D0 cycle Figure 5 53 Runtime Cou
242. splayed This is large capacity trace function that is useful when the AUD pin of the device is not connected to the emulator Note Some products do not support the memory output trace function For details on the specifications of each product refer to the online help e External Bus Trace Function This is a large capacity trace function that is valid when the external bus pin of the MPU is connected to the emulator The external bus trace function can acquire the information of a maximum of 262 144 cycles per bus cycle The following information can be acquired e External bus address values e External bus data values e Interrupt signal states e Time stamp values e Mnemonics e Operands Note The types of trace information that can be acquired differ according to the product For details on the specifications refer to the online help 336 RENESAS e Trace Function as the I O Analyzer Function The emulator can acquire a trace as part of the I O analyzer function 6 19 1 Displaying the Internal AUD Usermemory trace Window Select Trace from the Code submenu of the View menu The Trace Window Type dialog box is displayed Trace Window Type Trace window RESET ETEN a Figure 6 44 Trace Window Type Dialog Box Select Internal AUD Usermemory trace and click the OK button The Internal AUD Usermemory trace window will appear 1 Internal trace function The methods to acquire the internal trac
243. sreeres 331 6 19 Trace FUNCHONS soi sxp ckeeeds aa eK E E EEEO ETNE 335 6 19 1 Displaying the Internal AUD Usermemory trace Window cece 337 6 19 2 Displaying the BUS MFI trace Window 00 eee cece ceeeseeeseeeeeeeeeseeeseesaes 352 6 20 MMU SUpport err teva aia a E E O E eE ETE E r ANR 356 6 21 Stack Trace Funto sisses ieee ea E RE E A E E ESTRA aE 359 6 22 Download Function to the Flash Memory Area seseseesesseresreresresrrsrrsresresreresresresresrese 361 6 23 What Next osssis si ccsgesige coal iscedteit odstisdas R a 367 RENESAS Section 7 A TOUDIES NO GIID Ssc2 cc 2censcusssecnaecsccasnasensalstuni anaadenaaeauracentiasuucalscunseucen ses 369 Section 8 Maintenance and Guarantee ssiccicesess cosccescessqectuedacosaned faves acaagueaccaneaee 371 Bil UsetRegisttation s ccci crasedeedscpesonssheaieed sarine neoaeae raei N R EE ENEE EEEE ROEN TENERSE 371 8 2 IMaimtem ances sagsecesicssias saseesesedeeeed Rie RE N iE ESEE E AES EERE iE Voa REE EE SA s 371 BS Guarantee iison iae n a ea a EA case a E ra EE a AEE a T gees 371 8 4 Repair PrOViSIONS sporri o ri e EE TEE EEE AEE EE 372 8 4 1 Repair with ExtrasCharge sscan aseen uae yE aN ANE EENE 372 8 4 2 Replacement with Extra Charge esseseeseseesresesresrrsrerrsrrsrenresrestesrerrsrrnreeresrest 372 8 4 3 Expiration of the Repair Period 00 0 0 eee cece eeceeseceseceeeeseeeseceeeseeeeaeeeaeseatenaeees 372 8 4 4 Transportation Fees at Sending Your Product for Repa
244. sssesseseessseeseesesseesesrsresrrsresrenrestrsrerresesrenresresenses 131 5 1 1 Opening the Configuration Dialog BOX sssssssssssreseesresesresresresrerrsrrsrrsresresresrene 131 51 2 General Paena E Ge he E E eee 132 51 9 M n Board Pace srasni nne ae E EE EEEE 135 5 4 Bits Board Pagere E E AE AEA eaa rai iaai 137 5 1 5 Option Board Pages ssrin oa e 141 5 1 6 Downloading to the Flash Memory sesssessesesreesssesrrsrrsrreresresresrerrerrsrenrrnresresrent 143 5 1 7 Opening the Memory Mapping Dialog BoX eee ee eee eeseeeeeteeeeeeeeeeeneees 145 5 1 8 Changing the Memory Map Setting eee cee eseeeseeeseeeeeseeesseeeseeeaeees 147 5 2 Downloading a Progra sneri arneo renine a eNEAN EEE ETa RE FENAN 148 5 2 1 Downloading a Program seiis eee ceeeseeesecesecececsceeseeeseessesesesesesseeseeeaeeeseeeatens 148 5 2 2 Viewing the Source C fe sisii ieor cs corovncotscorneonssvuedsoees EE ESE ERREEN ds 149 5 2 3 Viewing the Assembly Language Code esseseeesseeeesseesesresrestrsreresresrrsresresrrsreee 154 5 2 4 Modifying the Assembly Language Code sseessessrsesssrerrsrrsrrsrenreerenrrerrerrerset 155 vi RENESAS 5 3 5 4 5 5 5 6 5 7 5 2 3 Viewing a Specific Address i555 dese decevesens sovnsore esse suse tuvcsautes weaves sqeusies ER E 156 5 2 6 Viewing the Current Program Counter Address 0 eee eeeeeeeseeeneeeseeeeeseeesees 156 Displaying Memory Contents in Realtime eee cee eeeeeseceeceeee
245. stop Break AUD Mode Enable free trace Time stamp clock 20ns aI AUD trace display range Start pointer D255 End pointer D o User memory area Start Address JHO End Address H3FF Trace Extend Mode I Trace data with PPG oree Figure 5 58 Internal AUD Usermemory acquisition Dialog Box Trace type Selects the type of trace function AUD trace Selects the AUD trace function Internal trace Selects the internal trace function User Memory trace Selects the user memory output trace function Trace Mode 1 Selects the operation mode when the trace information has been sequentially generated Realtime trace Some trace information will not be output 221 7 ENESAS Non realtime trace The CPU stops operations until the trace information is output Trace mode 2 Specifies the operation when the AUD trace buffer of the emulator becomes full Trace continue The oldest trace information is overwritten to acquire the latest trace information Trace stop When the trace buffer becomes full the trace information is no longer acquired Break A break occurs AUD Mode Sets the mode when the AUD trace function is used Enable free trace When checked the settings of the AUD eventpoint are ignored and the whole trace information is acquired Time stamp clock Specifies the resolution of the timer for time stamp as any of the following values 20
246. t Figure 2 4 Connecting the User System to the Trace Unit A CAUTION Check the location of pin 1 before connecting Notes 1 Connection of the signals differs depending on the MPU used 2 To connect the signals to the user system refer to the additional document Supplementary Information on Using the SHxxxx 61 7 ENESAS 2 3 2 Connecting the E200F Peripheral I O Analyzer Unit to the User System Figure 2 5 Connecting the Analyzer Cable to E200F when Using the Peripheral I O Analyzer Unit A CAUTION Check the location of pin 1 before connecting Notes 1 Connection of the signals differs depending on the peripheral I O analyzer unit 2 To connect the signals to the user system refer to the additional document Supplementary Information on Using the SHxxxx 62 RENESAS 2 3 3 Connecting the E200F Expansion Profiling Unit to the Main Unit Case e Remove the screw for fastening the base unit Figure 2 6 Screw for the Base Unit for Placing the Emulator Vertically 63 RENESAS Figure 2 7 Removing the Base Unit for Placing the Emulator Vertically 64 RENESAS e Remove two screws on the rear side of the main unit case Figure 2 8 Screws for the Main Unit Case 65 RENESAS e Remove the main unit case as shown in figure 2 9 Figure 2 9 Removing the Main Unit Case 66 ENESAS e After checking the location of pin 1 connect the expansion profiling unit to th
247. t s0 a 0 0000 10aa p_sam gt sl a 1 tutorialcpp resetpre c Figure 5 117 Code Coverage Column 290 RENESAS 5 12 Synchronizing Multiple Debugging Platforms Multiple debugging platforms can be operated at the same time in the High performance Embedded Workshop Initiating a High performance Embedded Workshop from another High performance Embedded Workshop synchronizes multiple debugging platforms The High performance Embedded Workshop that initiates another High performance Embedded Workshop is called the master and the initiated High performance Embedded Workshop is called the slave Choose Tools gt Launch Slave HEW or click the Launch Slave HEW toolbar button 3 to initiate a slave High performance Embedded Workshop The slave High performance Embedded Workshop has the same functionality as the master High performance Embedded Workshop The slave High performance Embedded Workshop is notified of the following actions done in the master High performance Embedded Workshop to ensure synchronization of the slave High performance Embedded Workshop and the master High performance Embedded Workshop e Reset go e Go e Stop debugging Note The master High performance Embedded Workshop can initiate multiple slave High performance Embedded Workshop applications but slave High performance Embedded Workshop applications cannot be nested no slave High performance Embedded Workshop can initiate another slave High
248. t takes time to execute this function When the calling source is clarified use Go To Cursor iP Figure 6 25 Step Out Button Em p ew pet pai phe Sap Des Tyi ie ie H A Tikwatchs wea K asa Awa 7 TEREE honta rinrin Kias hint ween toed 7 Few ied Figure 6 26 High performance Embedded Workshop Window Step Out The data of variable a displayed in the Watch window is sorted in ascending order 318 RENESAS 6 15 3 Executing Step Over Command The Step Over command executes a function call as a single step and stops at the next statement of the main program e Move to the change function following the procedures described in section 6 15 1 Executing Step In Command e To step through all statements in the change function at a single step select Step Over from the Debug menu or click the Step Over button on the toolbar TP Figure 6 27 Step Over Button gt EM EM ew pemi Belt phe Sap Des Tyi mhie e osueea BHA Tihwatchs waaa K was K waa 7 Til Bat ontag rinri K aos K a ween tved 7 STOP ACORESS E Figure 6 28 High performance Embedded Workshop Window Step Over 319 7 ENESAS 6 16 Forced Breaking of Program Executions The High performance Embedded Workshop can force a break in the execution of a program e Cancel all breaks e To execute the remaining sections of the main function select Go from the Debug menu
249. tallation and other product characteristics Renesas shall have no liability for malfunctions or damages arising out of the use of Renesas products beyond such specified ranges Although Renesas endeavors to improve the quality and reliability of its products IC products have specific characteristics such as the occurrence of failure at a certain rate and malfunctions under certain use conditions Please be sure to implement safety measures to guard against the possibility of physical injury and injury or damage caused by fire in the event of the failure of a Renesas product such as safety design for hardware and software including but not limited to redundancy fire control and malfunction prevention appropriate treatment for aging degradation or any other applicable measures Among others since the evaluation of microcomputer software alone is very difficult please evaluate the safety of the final products or system manufactured by you In case Renesas products listed in this document are detached from the products to which the Renesas products are attached or affixed the risk of accident such as swallowing by infants and small children is very high You should implement safety measures so that Renesas products may not be easily detached from your products Renesas shall have no liability for damages arising out of such detachment This document may not be reproduced or duplicated in any form in whole or in part without prior written approv
250. the Column and Time columns 5 10 5 Deleting Measurement Range Selecting Delete from the popup menu deletes all the specified measurement range and clears the measurement result 5 10 6 Setting the Minimum Unit of the Measurement Time In the emulator it is possible to change the minimum unit of the measurement time as any of 20 ns 40 ns 100 ns or 400 ns At 20 ns the maximum time that can be measured is about three hours At 40 ns the maximum time that can be measured is about six hours At 100 ns the maximum time that can be measured is about 15 hours 276 7 ENESAS At 400 ns the maximum time that can be measured is about 61 hours To change the minimum unit select Set from the popup menu of the Realtime Profile window and open the Properties dialog box Properties Properties Measurement interval Bis aS Figure 5 103 Properties Dialog Box Note Be sure to set the following when using the realtime profiling function e Acquisition dialog box that is opened by selecting Set from the popup menu of the Trace window Trace type Select AUD Trace Trace Extend Mode Uncheck the Trace data with PPC check box e Ch12 of the Eventpoint window Branch event sheet check all the branch conditions Action sheet Check Acquire trace These settings above are default when the emulator is activated 277 RENESAS 5 11 Acquiring Code Coverage The emulator acquires code cover
251. the break in the user system becomes a problem use the on chip event function Onchip event 2 When the acquisition mode of the AUD trace is Realtime trace data that was not output cannot be compared c External bus event function BUS Event This is a function that sets eventpoints according to the external bus of the MPU or pin information such as an interrupt pin There are six event detection channels The eventpoints can be defined as a combination of one or more of the following e External address bus condition e External data bus condition e Interrupt signal condition e Event count condition e Delay condition after an event has occurred 25 RENESAS For an operation when an event has been detected a break or external bus trace acquisition acquisition start acquisition stop can be specified This function can be set in the BUS Event sheet of the Event window Notes 1 When a break is generated by detecting the external bus event there is a delay of several cycles from the time of detection to the break 2 This function is optional it is available when a trace unit optional is used d Other events Other Event This function can be set in the Other Event sheet of the Event window e Execution time event A break occurs after the specified execution time has passed There is one event detection channel e External probe event There is one event detection channel Eventpoints can be defined spe
252. the circuit for performance measurement on the trace unit of the emulator 250 RENESAS Select either of the following three modes according to the purpose of measurement Available Measurement Modes Mode Description Purpose Time Of Specified Range Measures the execution time and Measurement of time taken for Measurement execution count in the specified processing of functions except for range that required for child functions called from the functions Start Point To End Point Measures the execution time and Measurement of time taken for Measurement execution count between the processing of functions specified addresses Start Range To End Measures the execution time Measurement of execution time Range Measurement from a specified range to another spent from calling of any of specified range sequential subroutines to calling of any of another sequential subroutines in a program that includes subroutines in sequence such as an assembly program For the measurement channel up to eight points can be set Note however since the start and end conditions use one measurement channel when Start Range To End Range Measurement is selected two channels are used for one measurement item Notes 1 When the trace unit is not connected to the emulator the external bus function is not supported 2 When the function of the trace unit is changed the number of event detection channels is changed For details refer to section
253. the device supported by the emulator For the usage of each function refer to section 5 Debugging and section 6 Tutorial 1 3 1 Overview Table 1 1 gives a functional overview of the emulator For details on the functions of each product refer to the online help 20 RENESAS Table 1 1 Emulator Functions No 1 Item User program execution function Function Executes a program with the operating frequency within a range guaranteed by devices Reset emulation Step functions Single step one step one instruction Source level step one step one line source Step over a break did not occur in a subroutine Step out when the PC points to a location within a subroutine execution continues until it returns to the calling function 2 Reset function Issues a power on reset from the High performance Embedded Workshop to the device during break 3 Event detection functions 13 on chip event detection channels Eight AUD event detection channels Six external bus event detection channels Other event detection One execution time event detection channel One external probe event detection channel Other event detection functions on the basis of I O analyzed results 4 Trace functions Internal trace function at on chip event detection AUD trace function at AUD event detection Outputs memory of the internal trace data External bus trace function at external bus event detection Other trac
254. the memory range Normal Specifies the address depending on the MMU state Physical Specifies the physical address Virtual Specifies the virtual address 133 7 ENESAS AUD clock JTAG clock TLB Mode Read status A clock used in acquiring AUD traces If its frequency is set too low complete data may not be acquired during realtime tracing Set the frequency not to exceed the upper limit for the MPU s AUD clock The AUD clock is only needed for using emulators that have an AUD trace function For the upper limit for the AUD clock refer to section 2 2 2 Notes on Using the JTAG H UDI Clock TCK and AUD Clock AUDCK in the additional document Supplementary Information on Using the SHxxxx A communication clock used except for acquiring AUD trace If its frequency is set too low the speed of downloading will be lowered Set the frequency not to exceed the upper limit for the MPU s guaranteed TCK range For the upper limit for TCK refer to section 2 2 2 Notes on Using the JTAG H UDI Clock TCK and AUD Clock AUDCK in the additional document Supplementary Information on Using the SHxxxx Enables or disables memory access exception during a break TLB miss exception is disabled Disables memory access exception during a break TLB miss exception is enabled Enables memory access exception during a break Specifies whether or not the value of PC_SR is displayed on the status bar during user prog
255. the state of High performance Embedded Workshop except for the emulator Setting the Debugge Target name SHxxxx E200F SYSTEM CPU SH44L DSP Configuration name Debug_SHxxxx_E200F_SYSTEM Detail options Value Modify Herts Finish Cancel Figure 4 20 Setting the Debugger Options Dialog Box This is the end of the emulator setting Click the Finish button to exit the Project Generator The High performance Embedded Workshop is activated 5 After the High performance Embedded Workshop has been activated the emulator is automatically connected For operation during connection refer to section 4 1 System Check 107 7 ENESAS 4 2 2 Creating the New Workspace Toolchain Used 1 In the Welcome dialog box that is displayed when the High performance Embedded Workshop is activated select Create a new project workspace radio button and click the OK button Welcome ae Cancel C Open a recent project workspace Administration C Browse to another project workspace Figure 4 21 Welcome Dialog Box 108 7 ENESAS 2 The Project Generator is started If you have purchased the toolchain the following dialog box is displayed Projects Workspace Name Demonstration ftest m Empty Application Project Name tE Import Makefile est ooo Library Directory Ic WorkSpace test Browse CPU family SuperH RISC engine x Tool chain Renesas SuperH Standard x
256. tions can be set by some I O analyzer functions 169 7 ENESAS 5 6 3 Opening the Event Window Select View gt Code gt Eventpoints or click the Eventpoints toolbar button E to open the Event window The Event window has the following five sheets Breakpoint sheet Displays the settings made for PC breakpoints It is also possible to set modify and cancel PC breakpoints Onchip Event sheet Displays or sets the settings made for on chip event channels AUD Event sheet Displays or sets the settings made for AUD event channels BUS Event sheet Displays or sets the settings made for external bus event channels Other Event sheet Displays or sets the settings made for other event channels 170 7 ENESAS 5 6 4 Setting PC Breakpoints It is possible to display modify and add PC breakpoints on the Breakpoint sheet w Event Breakpoint Enable Address H 00002234 Physical space Breakpoint Enable Address H 00004566 Physical space Figure 5 26 Event Window Breakpoint Sheet Items that can be displayed in the sheet are listed below Type Breakpoint State Whether the breakpoint is enabled or disabled Condition An address that the breakpoint is set Address Program counter Corresponding file name line and symbol name Action Operation of the emulator when a break condition is satisfied Break Breaks program execution 171 7 ENESAS Select Add or the PC breakpoint displayed in
257. to section 4 5 Connecting the Emulator 114 RENESAS 4 3 Setting at Emulator Activation When the emulator is activated the command chain can be automatically executed It is also possible to register multiple load modules to be downloaded The registered load modules are displayed on the workspace window 1 Select Debug settings from the Options menu to open the Debug Settings dialog box Debug Settings Target l Options Target lt none gt Default Debug Format Elt Dwarf2 Download Modules Remove Modi Up Down Cancel Figure 4 28 Debug Settings Dialog Box Target Page 2 Select the product name to be connected in the Target drop down list box 3 Select the format of the load module to be downloaded in the Default Debug Format drop down list box then register the corresponding download module in the Download Modules list box Note Here no program has been downloaded For downloading refer to section 5 2 Downloading a Program 4 Click the Options tab 115 7 ENESAS Debug Settings DefaultSession X Target Options test Command batch file load timing At target connection Command line batch processing ss V Download modules after build I Reset GPU after download module Remove breakpoints on download I Disable memory access until after target connection command file execution I Limit disassembly memory access Cael Figure 4 29 Debug Setti
258. top is set An external bus trace sequential stop is set The bitmap symbols for break above are shown by double clicking the BUS event column These are also set by using the popup menu Figure 5 13 Popup Menu for the BUS event Column Note The contents of the BUS event column are erased when conditions other than the address condition are added to each channel by using the Edit menu or in the Event window S W breakpoint column Editor column displays the following items E A bookmark is set A PC breakpoint is set gt PC location 152 7 ENESAS gt To switch off a column in all source files Click the right hand mouse button on the Source window Click the Define Column Format menu item The Global Editor Column States dialog box is displayed A check box indicates whether the column is enabled or not If it is checked the column is enabled If the check box is gray the column is enabled in some files and disabled in others Deselect the check box of a column you want to switch off 5 Click the OK button for the new column settings to take effect Pe Oe er Global Editor Column States Aud Event Bus Event Gaal Code Coverage d Oncel S S Disassembly Address Label Line Obj code S S KK A Figure 5 14 Global Editor Column States Dialog Box gt To switch off a column in one source file 1 Open the source file which
259. tting combo box of the Function select dialog box Function select x Function setting Main board mode setting RealProfile Areal function mode Bus board mode settine Perfor mance ch x Option board mode setti RealProfile Area2 function mode v m Monitor Setting Virtual space C Physical space Figure 2 21 Function select Dialog Box e RealProfile Area2 function mode Measures accumulation of execution time of each function the subroutine execution time is not included e RealProfile Area2 nest mode Measures accumulation of execution time of each function the subroutine execution time is also included e Coverage 8M Acquires the information on the CO coverage in the 8 Mbyte areas Note When the expansion profiling unit is not connected to the emulator this combo box is displayed in gray 80 ENESAS 2 7 4 Changing the Monitoring Function There are two radio buttons in the Monitor Setting group box of the Function select dialog box Function select x m Function setting Main board mode setting RealProfile Areal function mode x Bus board mode settine Perfor mance 6ich x Option board mode setting RealProfile Area2 Gunction mode Monitor Setting Virtual space Physical space Figure 2 22 Function select Dialog Box e Virtual space radio button Displays the monitoring function as a virtual address If the value is changed with
260. u UR Accessories Us Startup LE Administrative Tools Common fs High performance Embedc Command Prompt Eg High perfor mance Embe sho e Internet Explorer 8 High performance Embedded Workshop Help 27 Hieh per for mance Embedded Workshop Read Me i Documents Eh Settings Ry Shut Down Figure 4 1 Start Menu Note The High performance Embedded Workshop gt Tools is not displayed depending on the user s environment 95 7 ENESAS 7 The Welcome dialog box is displayed Welcome Options Cancel C Open a recent project workspace Administration C Browse to another project workspace Figure 4 2 Welcome Dialog Box Create a new project workspace radio button Creates a new workspace Open a recent project workspace radio button Uses an existing workspace and displays the history of the opened workspace Browse to another project workspace radio button Uses an existing workspace this radio button is used when the history of the opened workspace does not remain To use a workspace for the tutorial select the Browse to another project workspace radio button and click the OK button When the Open workspace dialog box is opened specify the following directory lt Drive where the OS has been installed gt Workspace Tutorial E200F xxxx Tutorial Here xxxx means the name of the target MPU 96 7 ENESAS After the directory has been specified select the
261. ue as the condition Notes 1 This page is only displayed when Window trace data is specified on the General 188 page The address range can only be specified for AUD event channels Ch1 and Ch2 The mask address can be input for Start when the single address is specified The mask address cannot be input for Start and End when the address range is specified 7tENESAS 4 Software page Specifies the address and data conditions of the software trace Ch2 Delay General Software Count Delay Action Address Don t care C Address Ra Start Ho0000000 End H oo000000 Outside Data Don t care Value HooD00000 Outside omes Figure 5 36 Chx Delay Dialog Box Software Page Address Sets the address condition Don t care Sets no address condition Address Sets the single address Range Sets the address range Start Sets the single address or the start address of the address range End Sets the end address of the address range Outside Sets other value than that has been set for the single address or address range as the condition 189 7 ENESAS Data Sets the data condition Don t care Sets no data condition Value Sets the data bus value mask data can be input Outside Sets other value than that has been set for Value as the condition Notes 1 This page is only displayed when Software trace data is spe
262. ulator or the memory cannot be used for tracing This function is hereafter called as the internal trace function or the Internal trace Function to output the information in realtime from the AUD pins This is the large capacity trace function that is enabled when the AUD pins are connected to the emulator The emulator generates a break on the basis of the information output from the AUD pins This function is hereafter called as the AUD trace function When a set of the branch source and branch destination instructions is one branch the maximum amount of information acquired by a trace is 262 144 Function to store the information in the specified memory The acquired trace information is stored within the specified memory range Do not specify the program area as the trace information is overwritten to the memory in the specified range This function is hereafter called as the memory output trace function or the Usermemory trace The AUD trace function is expanded in the emulator Expanded function 1 The timestamp information can be acquired 27 RENESAS 28 Expanded function 2 The AUD trace acquisition acquisition start and acquisition end can be controlled depending on the specified AUD eventpoint condition and external probe eventpoint condition For setting eventpoints refer to section 5 6 Using the Eventpoints Note The contents that can be acquired by a trace differ according to the product For deta
263. ure 5 28 Event Window Onchip Event Sheet Since the number of event detection channels and the contents to be set differ depending on the product refer to the online help for each product Items that can be displayed in the sheet are listed below Type On chip event channel number and type State Whether the eventpoint is enabled or disabled Condition A condition that satisfies an eventpoint The displayed contents differ depending on the channel Action Operation of the emulator when an eventpoint condition is satisfied The displayed contents differ depending on the channel 173 RENESAS When an event channel is double clicked or selected and Edit is selected from the popup menu in this window the Event condition x dialog box is opened and eventpoint conditions can be modified Event condition 2 Address Data ASID Bus State Count Action Address T Don t care Data address Prefetch address break before executing C Prefetch address break after executing Address fHoo000000 Non user mask User mask Mask oee _ Figure 5 29 Event condition x Dialog Box Address Page Note For details on the Event condition x dialog box refer to the online help for each product 174 7 ENESAS Table 5 1 lists the conditions of Event Condition Table 5 1 Types of Event Conditions Event Condition Type Address bus condition Address Description Breaks when the MPU addr
264. us and Ch12 Branch or software trace The time measurement does not continue when it is executed again if a break occurs before execution reaches the measurement stop address after passing the measurement start address of the AUD performance function 247 7 ENESAS When a measurement channel is double clicked or selected and Set is selected from the popup menu in this window the Performance Analysis AUD Channel x dialog box is opened and measurement conditions can be modified Performance Analysis Aud Channel 1 24x Start Point aud event ch1 Branch source address H 0 Set End Point aud event ch2 Branch destination address H 100 Set Sampling time 20ns gt Cancel Figure 5 81 Performance Analysis AUD Channel x Dialog Box Start Point aud event chx Displays the start pointer condition of the measurement channel End Point aud event chx Displays the end pointer condition of the measurement channel Set Displays the dialog box to set the AUD event channel for the start or end pointer Sampling time Specifies the resolution of the measurement timer as any of the following values 20 ns 40 ns 100 ns or 400 ns Clicking the Set button opens the dialog box to set the corresponding AUD event channel to modify the measurement start or end condition 248 RENESAS Chi Reset General Branch Count Action AUD function data ened Window trace dat
265. utside of the CPU core due to a cache miss Cache misses are not counted by the PREF instruction 45 Table 1 4 Measurement Items cont Classification Type Measurement Item Option Note Operand bus Access Number of operand CMW The number of cache misses by performance miss count cache miss WRITE an operand cache access write cont cont number of accesses to the outside of the CPU core due to a cache miss Write through accesses are not counted Cache misses are not counted by the PREF instruction Number of U RAM UBM This function is disabled for the read buffer miss MPU that the U memory is not incorporated Waited Waited cycles for WOR The number of wait cycles by a cycle operand fetch memory access read of an READ operand Waited cycles for WOW The number of wait cycles by a operand fetch memory access write of an WRITE operand Waited cycles for WCMR The number of wait cycles by an operand cache miss operand cache miss read READ however the number of wait cycles of cache FIII is included due to contention Waited cycles for WCMW The number of wait cycles by an operand cache miss operand cache miss write WRITE Number of waited WILR The number of waited cycles by cycles by an I L an I L memory access read of memory access for an operand operand fetch READ Number of waited WILW The number of waited cycles by cycles by an I L memory access for operand fetch WRITE 46
266. utton opens the Multiplexed pins setting dialog box Select the pin name according to the state of the multiplexed pin Multiplexed pins setting Address pins An PT6 v Chip select pins oso pa ad cs2 052 X Cancel Figure 5 4 Multiplexed pins setting Dialog Box Note This dialog box differs depending on the product 139 7 ENESAS Clicking the Memory type setting button opens the Memory type setting dialog box Set the memory type on the board When SDRAM is to be acquired by trace the number of bits of the row and column addresses and the CAS latency must be set in this dialog box Note that the data bus width will also need to be set If those items are set incorrectly they may be illegally displayed on the BUS MFI trace window Memory type setting Memory type cso SDRAM 4 Nor mal x OS5A Normal OS5B Normal OSGA Normal ooo CS6B Nor mal 7 CS2 SDRAM ROW Address SDCRA2ROWD 0 00 11 bit COLUMN Address SDCRA2COL 0 00 8 bit CAS Latency CS2WCR1 A2CL 1 0 01 2 cycle 0S3 SDRAM ROW Address SDCR ROWE OD 01 12 bit COLUMN Address SDCRCOL 0 00 8 bit Data Bus Width 32 bit v CAS Latency SDWORCLE2 0 fora 3 cycle z Figure 5 5 Memory type setting Dialog Box Note This dialog box differs depending on the product 140 RENESAS 5 1 5 Option Board Page Sets the expansion profiling unit operation conditio
267. vate or provide a workaround for product malfunction at some charge or without charge However this does not necessarily mean that Renesas Solutions Corporation guarantees the renovation or the provision under any circumstances This emulator has been developed by assuming its use for program development and evaluation in laboratories Therefore it does not fall under the application of Electrical Appliance and Material Safety Law and protection against electromagnetic interference when used in Japan This emulator does not conform to safety standards such as UL or IEC Be careful when you take this emulator overseas Renesas cannot anticipate every possible circumstance that might involve a potential hazard The warnings in this user s manual and on the emulator product are therefore not all inclusive Therefore you must use the emulator product safely at your own risk RENESAS LIMITED WARRANTY Renesas warrants its emulator products to be manufactured in accordance with published specifications and free from defects in material and or workmanship Renesas at its option will replace any emulator products returned intact to the factory transportation charges prepaid which Renesas upon inspection shall determine to be defective in material and or workmanship The foregoing shall constitute the sole remedy for any breach of Renesas warranty See the Renesas warranty booklet for details on the warranty period This warranty extends on
268. ve the information displayed in the Trace window as a text file A range can be specified based on the PTR number saving the complete buffer may take several minutes Note that this file cannot be reloaded into the Trace window Note In filtering of trace information the range to be saved cannot be selected All the trace information displayed in the Trace window after filtering will be saved Select a filtering range on the General page in the Trace Filter dialog box if you want to save the selected range For details on the filtering function refer to section 5 7 10 Extracting Records from the Acquired Information 5 7 7 Viewing the Source Window The Source window corresponding to the selected trace record can be displayed in the following two ways e Select a trace record and choose View Source from the popup menu e Double click a trace record The Source or Disassembly window opens and the selected line is marked with a cursor 5 7 8 Trimming the Source Choose Trim Source from the popup menu to remove the white space from the left side of the source When the white space is removed a check mark is shown to the left of the Trim Source menu To restore the white space choose Trim Source while the check mark is shown 234 7 ENESAS 5 7 9 Temporarily Stopping Trace Acquisition To temporarily stop trace acquisition during execution of the user program select Halt from the popup menu This sto
269. ved into a file before clearing Clicking the OK button clears the coverage information 288 ENESAS e When File gt Save Session has been selected When one or more Code Coverage windows are open the number of Save Code Coverage dialog boxes to be opened is the same as that of the Code Coverage window s The data of the windows can be saved separately or together Save Code Coverage Address range H 00001000 H 00001 Oft No NoToAll Yes To All Figure 5 116 Save Code Coverage Dialog Box Clicking No To All closes this dialog box without saving any coverage information Clicking Yes To All saves data of all the Code Coverage windows into one file 289 RENESAS 5 11 11 Displaying Code Coverage Information in the Editor Window Highlighting the Code Coverage column that corresponds to a source line where an instruction has been executed allows the coverage information to also be displayed in the Editor window If the user changes any setting regarding the coverage information in the Code Coverage window the content of the corresponding Code Coverage column will also be updated 00001038 Vil main void long a 10 long j Int i class Sample p_sam 00001040 while 1 0000104c p_sam new Sample 00001056 for i 0 i lt 10 0000105e j rand 00001066 ifj lt of o000106a j j o000106c ali j 00001084 p_sam gt sort a o000108e p_sam gt change a 00001098 p_sam g
270. vent sheet of the Event window It can also be set in the Source or Disassembly window by double clicking on the line to be set in the Onchip event column Note On chip event break settings can be changed during user program execution 3 AUD event break function Breaks when the specified event has been detected by the AUD event detection function This function is available when the operation after detecting an event is set as break in the AUD Event sheet of the Event window It can also be set in the Source or Disassembly window by double clicking on the line to be set in the AUD Event column 4 External bus event break function Breaks when the specified event has been detected by the external bus event detection function This function is available when the operation after detecting an event is set as break in the BUS Event sheet of the Event window It can also be set in the Source or Disassembly window by double clicking on the line to be set in the BUS Event column 5 Other event break functions Execution time event detection function External probe event detection function 35 7 ENESAS Breaks when the specified event has been detected by other event detection functions This function is available when the operation after detecting an event is set as break in the Other Event sheet of the Event window 6 Trace break function Breaks when the AUD trace
271. w 268 RENESAS iil Recursive function The execution time of the recursive function can be correctly measured however the execution count will be once iv AUD trace The realtime profiling function uses the data that is output in AUD trace Therefore when the function is used in the realtime trace mode the trace data may be lost and correct measurement will not be performed In such a case it is recommended that the non realtime trace mode be used v Overlay program No measurement will be performed if a part of the program is rewritten due to an overlay 2 Restrictions on using the function mode i Tail call When a tail call is used for a function as shown below the return value of the callee function becomes the return address of the caller function The execution time or execution counts of the callee function cannot be measured correctly No branch Figure 5 95 Tail Call Function Mode 269 7 ENESAS ii Relationships between the Go start address break address and measurable ranges Figure 5 96 Measurable Ranges Function Mode Measurable ranges when a break occurs at the position of black circle e Execution time and counts of functions h and k Measurable ranges when a break occurs at the position of red circle e Execution time and counts of functions h and k Measurable ranges when a break occurs at the position of blue circle e Execution time and counts of functions h and k e Executio
272. w is opened Color Sets the method to update monitoring and the attribute of colors Change Indicator Foreground Background Mayfly Selects how to display the values that have changed during monitoring available when Reading the Initial Value has been selected No change No color change Change Color is changed according to the Foreground and Background options Gray Those data with values that have not been changed are displayed in gray Appear A value is only displayed after changed Sets the color used for display available when Change has been selected Sets the background color available when Change has been selected A check in this box selects restoration of the color of those data which have not been updated in a specified interval to the color selected in the Background option The specified interval is the interval for monitor acquisition available when Change Gray or Appear has been selected Detail Displays whether the address to be monitored is physical or virtual 159 7 ENESAS History Displays the previous settings Note Selection of the foreground or background color may not be available depending on the operating system in use After setting clicking the OK button displays the Monitor window Address oooo0000 00000010 00000020 00000030 00000040 00000050 00000060 00000070 00000080 Figure 5 19 Monitor Window Dur
273. w to write C C or assembly language programs how to use any particular operating system or how best to tailor code for the individual devices These issues are left to the respective manuals Microsoft and Windows are registered trademarks of Microsoft Corporation Visual SourceSafe is a trademark of Microsoft Corporation IBM is a registered trademark of International Business Machines Corporation All brand or product names used in this manual are trademarks or registered trademarks of their respective companies or organizations Document Conventions This manual uses the following typographic conventions Table 1 Typographic Conventions Convention Meaning Menu gt Menu Option Bold text with gt is used to indicate menu options for example File gt Save As FILENAME C Uppercase names are used to indicate filenames enter this string Used to indicate text that must be entered excluding the quotes Key Key Used to indicate required key presses For example CTRL N means press the CTRL key and then whilst holding the CTRL key down press the N key gt When this symbol is used it is always located in the left hand margin The how to symbol It indicates that the text to its immediate right is describing how to do something RENESAS User Registration When you have purchased the emulator represented in this user s manual be sure to register it As the H W Tool Customer
274. x figure 4 31 Click the Add button to display the Add new session dialog box figure 4 32 Check the Use an existing session file radio button Enter a name for the session ie ee at Enter the name of an existing session file that you would like to import into the existing project or click the Browse button to select the file location If the Open and maintain link to session file check box is not checked the imported new session file is generated in the project directory If the Open and maintain link to session file check box is checked a new session file is not generated in the project directory but is linked to the current session file If the Make session file link read only check box is checked the linked session file is used as read only 6 Click the OK button to close the Debug Sessions dialog box e To remove a session 1 Select Options gt Debug Sessions to display the Debug Sessions dialog box figure 4 31 119 7 ENESAS 2 Select the session you would like to remove 3 Click the Remove button Note that the current session cannot be removed 4 Click the OK button to close the Debug Sessions dialog box e To view the session properties 1 Select Options gt Debug Sessions to display the Debug Sessions dialog box figure 4 31 2 Select the session you would like to view the properties for 3 Click the Properties button to display the Session Propert
275. y break connector Caution for Installation Q When in use do not place the emulator on its side RENESAS RENESAS Introduction The High performance Embedded Workshop is a powerful development environment for embedded applications targeted at Renesas microcontrollers The main features are A configurable build engine that allows you to set up compiler assembler and linker options via an easy to use interface An integrated text editor with user customizable syntax coloring to improve code readability A configurable environment to run your own tools An integrated debugger which allows you to build and debug in the same application Version control support The High performance Embedded Workshop has been designed with two key aims firstly to provide you the user with a set of powerful development tools and secondly to unify and present them in a way that is easy to use RENESAS About This Manual This manual describes preparation before using the emulator emulator functions debugging functions specific to the emulator tutorial and emulator s hardware and software specifications Refer to the High performance Embedded Workshop User s Manual for details on the information on the basic usage of the High performance Embedded Workshop customization of the environment build functions and debugging functions common to each High performance Embedded Workshop product This manual does not intend to explain ho
276. y loaded object file When the emulation memory function is used the System Memory Resources item shows the number of bytes of the emulation memory that can be allocated e Platform sheet Contains information about the current status of the debugging platform typically including CPU type and emulation mode and the state of execution e Events sheet Contains information about the current event breakpoint status including resource information Note The items that can be set in this dialog box vary according to the emulator in use For details refer to the online help 165 7 ENESAS 5 5 Reading and Displaying the Emulator Information Regularly Use the Extended Monitor window to know the changing information on the emulator no matter the user program is running or halted Note The Extended Monitor function does not affect the execution of the user program since it monitors the signal output from the user system or the MPU 5 5 1 Opening the Extended Monitor Window Selecting View gt CPU gt Extended Monitor or clicking the Extended Monitor toolbar button E displays this window Item Signal THCS MFI Connector Signal MFICS MFI Connector Signal MFIINT MFI Connector Signal THMDCH MFI Connector Signal THA3 MFI Connector Signal MFIRS THAZ MFI Connector Signal THAI MFI Connector Signal WEO Signal WE1 Signal RDWR Signal RD Signal RESETP Signal PTRZ WAIT LCDLCLK Signal PT
277. yed in the sheet are listed below The display content will be added depending on the status of the optional units in use Type Other event channel Probe External probe event channel Runtime Count Execution time event channel State Whether the eventpoint is enabled or disabled Enable Valid Disable Invalid Condition A condition that satisfies an eventpoint The displayed contents differ depending on the channel Action Operation of the emulator when an eventpoint condition is satisfied The displayed contents differ depending on the channel When an event channel is double clicked or selected and Edit is selected from the popup menu in this window the dialog box for setting conditions is displayed The displayed contents of this dialog box differ depending on the event channel 209 7 ENESAS 1 Probe dialog box Double clicking the Probe event channel displays this dialog box Conditions of the eventpoint can be set on the Condition and Action pages a Condition page Specifies four external probe signal conditions via the external probe cable Probe Condition Action Condition Operation Probe 1 jLow Probe 2 Don t Care X Probe 3 Hieh Probe 4 Don t Care X Figure 5 51 Probe Dialog Box Condition Page Operation Specifies how to combine the probe signal conditions AND Determines whether or not the condition is satisfied by AND operation of the probe
278. ymbol above is shown by double clicking the Onchip event column This is also set by using the popup menu Remove Figure 5 11 Popup Menu for the Onchip Event Column 150 ENESAS Note The contents of the Onchip event column are erased when conditions other than the address condition are added to each channel by using the Edit menu or in the Event window AUD event column The AUD event column displays the following item An AUD break is set An AUD sequential break is set T An AUD trace acquisition is set gT An AUD trace start is set E An AUD trace stop is set An AUD trace sequential stop is set Ge An AUD performance start is set Ge An AUD performance stop is set The bitmap symbols for break above are shown by double clicking the AUD event column These are also set by using the popup menu ch2 Edit ch3 cht Remove Ch Ch gt gt gt chs gt gt gt chs gt Figure 5 12 Popup Menu for the AUD Event Column Note The contents of the AUD event column are erased when conditions other than the address condition are added to each channel by using the Edit menu or in the Event window 151 7 ENESAS BUS event column The BUS event column displays the following item B An external bus break is set Q An external bus sequential break is set T An external bus trace acquisition is set GT An external bus trace start is set ET An external bus trace s

Download Pdf Manuals

image

Related Search

Related Contents

F-500BAF/-C Service Manual  MODE D`EMPLOI TIRE-BOUCHON DE COMPTOIR Réf. 2121TB  Dell™ XPS™ L412z Manual do Proprietário  Manual de instrucciones R 1200 GS Adventure  Miele Dishwasher M.-NR. 04 390 922 User's Manual  取扱説明書  Geovision GV-CB220  取扱説明書 (6.43 MB/PDF)  User manual Deceased donor registration    

Copyright © All rights reserved.
Failed to retrieve file