ilmenit Posted April 29, 2021 Author Share Posted April 29, 2021 @vbc thank you for your comment to the blog post! Also for me it was quite strange how the benchmark was done, but I do not think vbcc was sabotaged there, more the author didn't know how to handle this compiler properly. 12 hours ago, vbc said: When I tried to add a timer variable to measure run-time on the C64, the code did not compile anymore on cc65, because it exceeded the 256 byte limitation of cc65. what 256 limit do you mean here? Quote Link to comment Share on other sites More sharing options...
vbc Posted April 29, 2021 Share Posted April 29, 2021 2 hours ago, ilmenit said: @vbc thank you for your comment to the blog post! Also for me it was quite strange how the benchmark was done, but I do not think vbcc was sabotaged there, more the author didn't know how to handle this compiler properly. I agree that he probably did not introduce these bugs intentionally. If such intention is implied by "sabotaged" then my wording was probably wrong (I am not a native English speaker). Also, I appreciate that the author published all his test-code and did openly communicate that he would not recommend vbcc due to his dislike of the license anyway (although this seems a strange reservation for a comparison that is supposed to help a greater audience in choosing a compiler - I know that very few people share this reservation). What I do not appreciate is that when he got a different result with vbcc, he apparently did not really investigate what the problem was. He just claimed that vbcc was buggy, while, in fact, his configuration and his test case was. I would expect more diligence here. Quote what 256 limit do you mean here? Maximum size of stack frame in a function. 1 Quote Link to comment Share on other sites More sharing options...
rchennau Posted April 30, 2021 Share Posted April 30, 2021 Thank you so much for writing this guide! I appreciated and will use this guide often! 1 Quote Link to comment Share on other sites More sharing options...
Harry Potter Posted April 30, 2021 Share Posted April 30, 2021 Did I already post this? I have my own optimization guides for cc65 at https://sourceforge.net/projects/cc65extra/files/, and some of them will work on other C compilers as well. Try them out! 1 Quote Link to comment Share on other sites More sharing options...
ivop Posted April 30, 2021 Share Posted April 30, 2021 Your link points back to AtariAge https://sourceforge.net/projects/cc65extra/files/ Quote Link to comment Share on other sites More sharing options...
zbyti Posted May 14, 2021 Share Posted May 14, 2021 (edited) Evergreen classic: Illustrating C Illustrating C (revised edition).pdf Illustrating C - Erratum Edited May 14, 2021 by zbyti Add Erratum Quote Link to comment Share on other sites More sharing options...
Harry Potter Posted January 20, 2023 Share Posted January 20, 2023 I just noticed that somebody here asked about random numbers. I have my own rand() function at c65 additions - Manage /util at SourceForge.net. The file is at the bottom of the page. It was written for CBM targets, and the _randomize() function reads the CBM clock in ZP, but cc65's _randomize() function should work. One good thing about it is its speed and size, as it doesn't include any multiplying or other involved computation. Another thing: you can supply an extra argument to increase randomness. A bad thing: somebody commented that it didn't produce random enough numbers. I ask you to try it out and tell me how it works. If it doesn't produce good results, try tweaking the constants used in the rand() function. BTW, can the OP link to my optimizations online, please? Quote Link to comment Share on other sites More sharing options...
Wrathchild Posted January 20, 2023 Share Posted January 20, 2023 (edited) 9 hours ago, Harry Potter said: I ask you to try it out and tell me how it works. Shouldn't you be able to find a random-number-generator test suite online somewhere? At least try yourself running a chi-squared test, e.g. here:https://stackoverflow.com/questions/12190091/random-number-generator-test [Edit] Then run yours against the existing CC65 implementations for comparison. When we did the Atari back-port to CC65, Sidney Cadot was on top of ensuring a good implementation went in. e.g. https://cc65.github.io/mailarchive/2000-03/0072.html Edited January 20, 2023 by Wrathchild Quote Link to comment Share on other sites More sharing options...
sanny Posted January 20, 2023 Share Posted January 20, 2023 16 minutes ago, Wrathchild said: When we did the Atari back-port to CC65, Sidney Cadot was on top of ensuring a good implementation went in. e.g. https://cc65.github.io/mailarchive/2000-03/0072.html A flashback from the past....around the time when I started working on the Atari support of cc65.... 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.