I was having trouble getting CCSv4 to to match the performance of CCSv3.3. In the end, I found this was a problem with the default options used for the "Release" configuration in CCSv4.2.1.00004 (cgt 7.0.3). Unfortunately, the current "Release" options are:
-g –o2
which provides the unoptimized result of 285 cycles.
When I switch the options, I get better results: (measured by CCSv4 profiler on C64x+ cycle accurate simulator)
|
Options |
Cycles |
|
-g –o2 (CCSv4 default) |
285 |
|
-o2 |
277 |
|
-g –o3 |
86 |
|
-o3 (CCSv3.3. default) |
80 |
I’m confused as to why the default options were changed from those found in CCSv3.3 - which resulted in much faster code. Further, I can’t explain why we would have “debugging” turned on for “Release” . (Oh, and don’t get me started on –pm … very hard to find and won’t build.)
The steps used to build/test my project were:
- Create a new CCS Project
- Use the empty BIOS 5 project template
- Add a new (default) TCF file to the project for the C64x+ simulator
- Add my c/h files (previously used with CCSv3.3. project) to the new eclipse project
- Build and profile using both "Debug" and "Release" build configurations
- Change and record results for various "Release" build options
Thanks,
Scott