PowerPC Simulator (Setup) -- Using the Version 6.5 SDS toolset for editing, assembling and linking |
If you use the Version 6.5 SDS PowerPC toolset for editing, assembling and linking only very small code segments,you may not experience the instability (crashes) of this program that I have experienced. However, if you do experience the problems, they can be very frustrating. The problems with the Version 6.5 PowerPC toolset are known and "corrected in the latest release, Version 7.X". However, there are other problems that need to be overcome with that version of the demo kit. Watch out for a new release of the "Laboratory Companion" using Version 7.X before Christmas.
My recommendation is that if you have problems on your system with the PowerPC simulator crashing that you avoid the approach of using the Version 6.5 SDS PowerPC toolset for editing, assembling and linking. Instead, follow this procedure
Although using the SDS 68K demo toolkit for editing, assembling, linking, automatically finding errors, as well as for simulation, can be pleasurable, this is not the case for the Version 6.5 SDS PowerPC demo toolkit. Under both WINDOWS 3.1.1 (tested on 1 machine) and WINDOWS 95 (tested on 2 different machines), the program would repeatedly lock-up or crash if I attempted to do editing or assembling after simulation either within or externally to the toolset. The mere fact that the Simulator was active while editing, assembling and linking in a DOS window could cause the system to lock or crash. Although the crashes were somewhat unpredicatable, the program seemed to be particularly susceptable to crashes if you had an error in your code (say after assembly). This instability is known by SDS and said to be corrected in the newly released Version 7.X
Customizing the SDS PowerPC toolset
On this WEB page we shall look at customizing the SDS graphical interface simulation tool to allow
To allow these operations to occur requires modification to one of the three SSTEP.INI files. These SSTEP.INI files are executed in the following order on power up of the SDS program
To avoid possible problems and unexpected "happenings" make sure that you modify the appropriate SSTEP.INI file and avoid having different "working directories".
If you have modified the SSTEP.INI file when setting up the PowerPC toolset no further changes are necessary.
The SDS toolset has an editor that is called using the SDS toolkit's Window | Editor option. You can customize the SDS toolset to activate your own editor youreditor
You can now bring up youreditor by selecting the Tools | External Editor option and selecting the file you wish to edit. Set up your Start up directory to your Laboratory directory for ease of use of this tool.
Return to the top of this page.
To customize the SDS PowerPC toolset for assembling files use the following procedure
You can now use the Tools | Assembler | Execute option to assemble your file. You will see an Editor window and an associated Error Messages window to show the status of your assembly. Dismiss these windows when you have made use of the information in them.
NOTE:- On a portable PC, you may need to adjust the size of the Error Message window to see it. I crashed my Windows-95 lap-top adjusting the screen before completing the assembly.
WARNING:- It appears that the PowerPC DIAB DATA assembler works within hidden DOS shells. You must make sure that you have set up the DOS paths correctly. The Version 7.X path is to a directory called MSDOS\bin !
After you have performed the assembly operation, you get an Editor window and an associated Error Messages window. If you had similiar errors in the 68K Error Messages window, then double-clicking on them brought up the source file. Unfortunately the SDS PowerPC Version 6.5 demo toolkit does not work that way.
Read the caution at the end of this section before reading the rest of the section. This approach does not work for assembly language files (does for "C" files). Use either the DOS window approach or else the TOOL | MAKEFILE option within the PowerPC toolset.
To customize the SDS PowerPC toolset for linking files use the following procedure
You can now use the Tools | Linker | Execute option to link all of your files. You will see an Editor window and an associated Error Messages window to show the status of your linking. Dismiss these windows when you have made use of the information in them. Remember that the SDS demo-kit linker is limited to handling only 3 object (.o) files.
Unfortunately this linker approach does not work.
The SDS PowerPC demo linker operates with a "C" compiler to do the linking. This is standard. You will find that most "C" compilers can be called to
It is item 3 that causes the problem. The SDS simulator is intended to debug "stand-alone" code. To form an executable, the Linker must bring in a startup-file called crt0.o. This file configures the system. This is not what we want. This linker states that this object file requires
Then the linker crashes any way (Memory Protection Error -- tested on Windows 3.1.1).
The WIDFI approach is if the linker wants an crt0.o lets build it one. I built a very simple patch.s file with just a .long statement in it. I then assembled that and used the object file as a replacement for the crt0.o file. This works tremendously well
Then the linker crashes any way (Memory Protection Error -- tested on Windows 3.1.1).
We have come up against another PowerPC demo kit limitation. You are welcome to try some more WIDFI to get the crt0.o approach to work, but since there is an easier WIDFI approach we will use that instead -- the Tool | Make option
Return to the top of this page
The SDS PowerPC Linker GUI interface is not a feasible option at the moment for issuing the necessary commands to link our files. There are four other linking approaches
You can now cause the link to occur with the Tools | Make | Execute option
NOTE:- This third approach will not work on Windows 3.1.1. The link occurs and then the simulator crashes. Use one of the other linker approaches.
Last modified: July 17, 1996 03:13 PM by M. Smith.
Copyright -- M. R. Smith