tag:blogger.com,1999:blog-50525915042010777382024-02-20T11:38:06.060+13:00The Big E-UAE JIT blogThe development blog for implementing Just In Time compilation based Motorola 680x0 emulation for PowerPC processors in E-UAE Amiga emulator.Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.comBlogger53125tag:blogger.com,1999:blog-5052591504201077738.post-38633592179834033602015-07-23T19:48:00.000+12:002015-07-23T19:48:08.122+12:00Happy birthday Amiga!<h2 style="text-align: center;">
Happy 30<sup>th</sup> birthday, Amiga!</h2>
<div class="separator" style="clear: both; text-align: center;">
</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgGnmdESiuYAly6HUHQwhzPvYyzHMUnH5FPhJ5U68d3Yx20QHwnEsSlhqabH7xSwcI13FUhHAFVVrzrnEWEipu6Gn6U5LjqRmGPFr7bfvDsgulAXWoDc7qnSm9Xa0A0nPB6-wjzetb7_MU/s1600/bigboing2.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgGnmdESiuYAly6HUHQwhzPvYyzHMUnH5FPhJ5U68d3Yx20QHwnEsSlhqabH7xSwcI13FUhHAFVVrzrnEWEipu6Gn6U5LjqRmGPFr7bfvDsgulAXWoDc7qnSm9Xa0A0nPB6-wjzetb7_MU/s1600/bigboing2.png" /></a></div>
<br />
<div style="text-align: center;">
Your journey has started 30 years ago, on 23<sup>rd</sup> July 1985,</div>
<div style="text-align: center;">
when the first <b>Amiga 1000</b> was introduced to the clueless public at a clumsy, but epic event.</div>
<div style="text-align: center;">
This journey is never ending, still going on after 30 years.</div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: center;">
We love you. </div>
Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com0tag:blogger.com,1999:blog-5052591504201077738.post-52171153617954358812015-01-12T20:17:00.001+13:002015-01-12T20:17:46.082+13:00A sad day<div style="text-align: center;">
Right after the final release was announced I have learned that the main contributor to the bounty:</div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: center;">
<span style="font-family: inherit;"><span style="font-size: small;"><b>William Morris</b></span></span></div>
<div style="text-align: center;">
<span style="font-family: inherit;"><span style="font-size: small;"><b></b><i><span style="font-family: inherit;">(</span><span style="font-family: inherit;"><span style="font-family: inherit;"><span style="font-family: inherit;">F</span>rags</span></span> on AW.net<span style="font-family: inherit;">)</span></i><b><br /></b></span></span></div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: center;">
<span style="font-family: inherit;"><span style="font-size: small;">has passed away <span style="font-family: inherit;">in Ju<span style="font-family: inherit;">ne</span> last year.</span></span></span></div>
<br />
<div style="text-align: center;">
<span style="font-family: inherit;"><span style="font-size: small;"><span style="font-family: inherit;">I<span style="font-family: inherit;">t feels <span style="font-family: inherit;">really sad that he <span style="font-family: inherit;">was not able to see the <span style="font-family: inherit;">result of the project<span style="font-family: inherit;">.</span></span></span></span></span></span></span></span></div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: center;">
<span style="font-family: inherit;"><span style="font-size: small;"><b><span style="font-family: inherit;"><span style="font-family: inherit;">I would like to dedicate the <span style="font-family: inherit;">E-UAE P<span style="font-family: inherit;">owerPC JIT implementation to his memory.</span></span></span></span></b></span></span></div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<span style="font-family: inherit;"><span style="font-size: small;"><span style="font-size: x-small;"><i><span style="font-family: inherit;"><span style="font-family: inherit;"><span style="font-family: inherit;"><span style="font-family: inherit;">Thanks to Carl Moppett <span style="font-family: inherit;">for <span style="font-family: inherit;">letting </span>me know about this tra<span style="font-family: inherit;">gic eve<span style="font-family: inherit;">nt.</span></span></span></span></span></span></span></i></span><b><br /></b></span></span></div>
Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com4tag:blogger.com,1999:blog-5052591504201077738.post-47683395498076816462015-01-08T21:33:00.000+13:002015-01-08T21:33:52.408+13:00Linux stability fix: v1.0.1 (Hoverboard)After releasing the first stable version I have received lots of feedback from folks around the world. Most of you guys were positive about the release, except my good old pal: <b>Mike Blackburn</b>.<br />
<br />
Probably there are not too many E-UAE users are trying to run it on LinuxPPC and one of the reasons is probably: there is no binary distribution. Yet, there are a handful of crazy people... One of them is Mike.<br />
<br />
He was not happy about the final release, because it is not working at all on Linux. The situation was tricky, because it was working before, but not anymore after my (seemingly unrelated) changes regarding the removal of useless debug logging.<br />
<br />
After a week of struggling, roughly 70 emails(!) he figured out what was wrong: <b>cache flushing</b>.<br />
<br />
Thanks to him here is a new "release" for the few LinuxPPC users: v1.0.1.<br />
It is not really a release, since there is no binary build available, but I made a remark in the release folder to get the sources from <a href="https://sourceforge.net/p/euaeppcjit/code-0/HEAD/tree/tags/1.0.1">1.0.1 tag</a> and build it on LinuxPPC.<br />
<br />
<b>Nice work, Mike!</b><br />
<br />Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com0tag:blogger.com,1999:blog-5052591504201077738.post-32488895505126717652015-01-02T12:10:00.000+13:002015-01-02T12:21:50.729+13:00Release 1.0.0 (Waiting for Marty edition)<div style="text-align: center;">
<b>Happy new year Earthlings!</b><span style="font-size: xx-small;"><i> </i></span><br />
<span style="font-size: xx-small;"><i>(...and Ufonauts, in case any of you is reading this post.)</i></span><b><br /></b></div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: left;">
I have an awesome news, the most awesome that have been landed for this project so far:</div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: center;">
<i><span style="font-size: x-large;">It is done! </span></i></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<span style="font-size: small;">Yes, finished, <b>version 1.0.0 is completed</b>. The final round was about some bug fixes and tiny improvements.</span></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<span style="font-size: small;">There are still minor outstanding issues and features I dreamed of while I was busy with bug fixing, these are postponed to v1.1 release for now.</span></div>
<div style="text-align: left;">
<span style="font-size: small;"><br /></span></div>
<div style="text-align: left;">
<span style="font-size: small;">This was a long run, I agree. My original estimation was <b>1 year for completing the projec</b>t. What I haven't considered that I have a life, unlike back in the uni days... Finally, it took <b>almost 4 years</b> to complete the project.</span></div>
<div style="text-align: left;">
<span style="font-size: small;"><br /></span></div>
<div style="text-align: left;">
<span style="font-size: small;">But on the other hand, what I was planning to do for the <a href="http://amigabounty.net/index.php?function=viewproject&projectid=35">bounty</a> was surpassed by a magnitude thanks to all the helping hands and my constant desire to improve things. So, it took some time, but it all worth the wait, I believe.</span></div>
<div style="text-align: left;">
<span style="font-size: small;"><br /></span></div>
<div style="text-align: left;">
<span style="font-size: small;">You, who followed the project closely enough know already that the last half year was spent on polishing the release rather than actual development. All the features were ready a year ago, but it needed some more love (and mostly testing).</span></div>
<div style="text-align: left;">
<span style="font-size: small;"><br /></span></div>
<h3 style="text-align: left;">
<span style="font-size: small;">About the future</span></h3>
<div style="text-align: left;">
<span style="font-size: small;">Speaking of <a href="http://en.wikipedia.org/wiki/Back_to_the_Future_Part_II">Marty</a>, I invite you to have a quick look at the <a href="https://sourceforge.net/p/euaeppcjit/tickets/milestone/Version%201.1/">tickets</a> for the upcoming release. Just like any good open source software project: <b>there is always room for improvements</b>.</span></div>
<div style="text-align: left;">
<span style="font-size: small;"><br /></span></div>
<div style="text-align: left;">
<span style="font-size: small;">When will it be finished - sorry, I couldn't tell. And I don't want to fall into the same mistake again, of course. ;)</span></div>
<div style="text-align: left;">
<span style="font-size: small;"><br /></span></div>
<div style="text-align: left;">
<span style="font-size: small;">If you had found any bugs, please do report. I intend to fix any issues which was discovered in the meanwhile.</span><br />
<br />
<h3>
<span style="font-size: small;">Further dreams</span></h3>
<span style="font-size: small;">This project was set up specifically to implement JIT compiling for PowerPC processors, due to the current state of AmigaOS4 and MorphOS. Since the JIT compiling was already available for x86 it was never a goal for me to come up with a generic solution which supports multiple architectures.</span><br />
<br />
<span style="font-size: small;">But more than 4 years passed since I started to think about it and lots of things have changed. Nowadays smart phones are standing tall, probably even more important than desktop computers. These are mostly running on <b>ARM compatible processors</b>, so PPC or x86 JIT implementations are completely useless for these devices.</span><br />
<span style="font-size: small;">When I had a few email rounds with <b>Toni Wilen</b>, maintainer of <a href="http://www.winuae.net/">WinUAE</a>, he complained about the x86 implementation and mentioned that it is completely outdated in the era of x64 architecture. Unfortunately, the ancient x86 implementation is so complicated and messy that nobody is brave enough to touch it. (This is why I started my own implementation instead of porting the x86 version.)</span><br />
<span style="font-size: small;">AmigaOS4 is running on PowerPCs, but let's be realistic: <b>PowerPC is dead</b>. (<a href="http://www.geek.com/science/nasas-orion-spacecraft-runs-on-a-12-year-old-single-core-processor-from-the-ibook-g3-1611132/">Or is it</a>? Yes, it is at desktop computing.) Sooner or later AmigaOS4 will migrate to a new architecture probably.</span><br />
<span style="font-size: small;"><br /></span>
<span style="font-size: small;">So, what is the bottom line of my ramblings? This JIT implementation was made for PowerPC, but it can be changed to <b>support multiple processor architectures</b>. I don't think that it would be too complicated, the majority of the code can be reused, it just needs some restructuring.</span><br />
<span style="font-size: small;"><br /></span>
<span style="font-size: small;">Am I going to do that? Errr... <i>no</i>? <b>I don't know</b>. Sounds challenging enough, but I have spent enough time on JIT compiling </span><span style="font-size: small;"><span style="font-size: small;">already</span> in my life to look for something new instead.</span></div>
<h3 style="text-align: left;">
<span style="font-size: small;">Big Thanks</span></h3>
Finally, I would like to mention a few folks around the globe who helped me in any way while I have been working on the E-UAE JIT. <i>(Let me know if I mistyped anybody's name...)</i><br />
<br />
<div style="text-align: center;">
<span style="font-size: large;"><span style="font-family: Verdana,sans-serif;">Thank you for your great help!</span></span></div>
<div style="text-align: left;">
<br />
First <b>special thanks</b>:</div>
<div style="text-align: left;">
<br />
<span style="font-size: small;"><span style="font-size: small;"><b>Robert Trevor Dickinson</b> - special thanks for making me do the JIT, you have talked me into it, so this is all your fault now! ;)</span></span><br />
<br />
<span style="font-size: small;"><b>Stephen Fellner</b> - thanks for lending me the µAmigaOne I am still using after my AmigaOne-XE did not survive the moving to New Zealand. Without this machine I wouldn't be able to do any development at all.</span><br />
<br />
<span style="font-size: small;"><b>Michael Trebilcock (MickJT)</b> - you have helped me a lot with the scattered around source code of E-UAE, building, testing, AmigaOne X1000 support and plenty of other things. Without your contribution this project wouldn't be in this good shape at all.</span><br />
<span style="font-size: small;"><br /></span>
<span style="font-size: small;"><span style="font-size: small;"><b>Tobias Netzel</b> - thanks for picking up the G5 support, Tobias. I had no opportunity implementing the required changes, your handiwork made plenty of MacOSX, MorphOS and AmigaOne X1000 user smiling ear-to-ear.</span></span><br />
<br />
<span style="font-size: small;"><span style="font-size: small;"><span style="font-size: small;"><span style="font-size: small;"><b>Mike Blackburn Heltne</b> - great work on improving the build script and Linux support! I always neglected the Linux support, I was too lazy to deal with it, but you picked it up. Also merging fixes from other UAE derivatives helped a lot. (And finally, I have written down your full name. :)</span></span></span></span><br />
<span style="font-size: small;"><span style="font-size: small;"><span style="font-size: small;"><span style="font-size: small;"><br /></span></span></span></span>
<span style="font-size: small;"><b>Chris Handley</b> - thanks for all your help in testing and for maintaining <a href="http://os4depot.net/index.php?function=showfile&file=emulation/utility/runinuae.lha">RunInUAE</a>, which brings the obscure art of E-UAE configuration closer to the average user.</span><br />
<br />
<span style="font-size: small;"><b>kas1e, Luigi Burdo, </b></span><span style="font-size: small;"><b><span style="font-size: small;"><span class="gD" name="Samir Hawamdeh">Samir Hawamdeh, </span></span>Thunder</b> - thanks for all the beta testing results and useful comments you have sent to me. Without testing software is always buggy and I don't have the energy for running hundreds of apps under the emulation.</span><br />
<br />
<span style="font-size: small;"><b>Fabien Coeurjoly (Fab)</b> - thanks for MorphOS-related help and for your time you are investing into proper MorphOS builds. I am an AmigaOS4 fan, so what do I know about MorphOS... :)</span><br />
<br />
<span style="font-size: small;"><span style="font-family: inherit;"><b>And thanks to everybody who helped me directly or indirectly<span style="font-family: inherit;">:</span></b></span></span></div>
<div style="text-align: left;">
</div>
<span style="font-size: small;">Allan Ullmann;</span><br />
<span style="font-size: small;">Andreas Loong;</span><br />
<span style="font-size: small;">Davide Palombo; </span><span style="font-size: small;">Douglas McLaughlin;</span><br />
<span style="font-size: small;">Frank Wille;</span><br />
<span style="font-size: small;">Fredrik Wikstrom;</span><br />
<span style="font-size: small;">hostcove;<br />itix;<br />Massimiliano Tretene (Soft3); </span><br />
<span style="font-size: small;">Michael C. Battilana and <a href="http://www.cloanto.com/">Cloanto</a>;</span><br />
<span style="font-size: small;">Noel Fuller;<br />Philippe Ferrucci;</span><br />
<span style="font-size: small;"><span class="gD" name="Samir Hawamdeh">Sebastian Bauer; </span></span><br />
<span style="font-size: small;">Sven Ottemann;<br />Timothy De Groote;<br />Tommysammy;<br />Troels Ersking and all the staff <span style="font-family: inherit;">at </span><a href="http://amigabounty.net/">AmigaBounty.net</a>;<br />Zerohero.</span><br />
<div style="text-align: left;">
<span style="font-family: inherit;"><span style="font-size: small;"><br /></span></span></div>
<div style="text-align: left;">
<span style="font-family: inherit;"><span style="font-size: small;">I would like to thank the donations to all<b> who <span style="font-family: inherit;">supported </span>the project on <a href="http://amigabounty.net/">AmigaBounty.net</a></b>.</span></span></div>
<div style="text-align: left;">
<span style="font-family: inherit;"><br /></span></div>
<div style="text-align: left;">
<span style="font-family: inherit;"><span style="font-size: small;">Please visit the <a href="http://amigabounty.net/index.php?function=viewdonations&projectid=35">E-UAE JIT bounty page</a> for the complete list.</span></span></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<span style="font-family: inherit;"><span style="font-size: small;">I would like to mention the main donors here, just to commemorate their significant <span style="font-family: inherit;">contribution</span>:</span></span></div>
<div style="text-align: left;">
<span style="font-family: inherit;"><span style="font-size: small;"><br /></span></span></div>
<div style="text-align: center;">
<span style="font-family: inherit;"><span style="font-size: small;"><b>William Morris</b> and <b>Robert Trevor Dickinson</b>.</span></span></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: center;">
<span style="font-family: inherit;"><span style="font-size: small;">Thank you for supporting this project with your hard-earned <span style="font-family: inherit;">mon<span style="font-family: inherit;">ey</span></span>.</span></span></div>
<div style="text-align: left;">
<br />
<br />
<h3>
Am I missing something?</h3>
I have almost forgotten, here is the release... ;)<br />
<br />
<div style="text-align: center;">
<span style="font-size: large;"><b><a href="https://sourceforge.net/projects/euaeppcjit/files/1.0.0-Stable">https://sourceforge.net/projects/euaeppcjit/files/1.0.0-Stable</a></b></span></div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: center;">
See you soon.</div>
<div style="text-align: center;">
<br /></div>
</div>
Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com16tag:blogger.com,1999:blog-5052591504201077738.post-46579399244522479902014-11-13T19:55:00.001+13:002014-11-13T19:55:33.121+13:00Demo reel...I have just discovered that <b>hostcove</b> compiled a nice video of lots of demos running on Amiga X1000.<br />
<br />
I was too lazy for a power demonstration like this one, so I kindly borrow his work... <b>Enjoy</b>!<br />
(No, it is not Rickrolling, I promise! ;)) <br />
<br />
<div style="text-align: center;">
<iframe allowfullscreen="" frameborder="0" height="315" src="http://www.youtube.com/embed/k6kRo2e0Un8" width="420"></iframe></div>
<br />
Big thanks to <i>hostcove </i>for his efforts! Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com1tag:blogger.com,1999:blog-5052591504201077738.post-11296530934622615532014-11-04T21:37:00.003+13:002014-11-04T21:37:56.328+13:00Press R for RetryAs it seems the <i>Devil was in the Machine</i> indeed:<br />
somehow I managed to upload the Beta#4 archive renamed to Beta#5 for the AmigaOS4 package.<br />
<br />
The file is corrected on SourceForge, please download it again from the Beta#5 folder:<br />
<br />
<div style="text-align: center;">
<span style="font-size: large;"><a href="https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA05">https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA05</a></span></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<span style="font-size: large;"><span style="font-size: small;">The other packages were fine, it was a problem only with the AmigaOS4 archive.</span></span></div>
<div style="text-align: left;">
<span style="font-size: large;"><span style="font-size: small;"> </span></span></div>
<div style="text-align: left;">
<span style="font-size: large;"><span style="font-size: small;">Apologies for wasting your precious data...</span></span></div>
<div style="text-align: left;">
<span style="font-size: large;"><span style="font-size: small;">Thanks to <b>Chris Handley</b> and </span></span><span style="font-size: large;"><span style="font-size: small;"><b>Karsten Larsen</b> for bringing it to my attention.</span> </span></div>
Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com6tag:blogger.com,1999:blog-5052591504201077738.post-38655216215895845252014-11-03T21:08:00.000+13:002014-11-03T21:08:07.463+13:00PPCJITBETA05 (Final Countdown)Yes, yes, my dear friends: <b>we are very close now!</b> This is the final countdown indeed: the last beta before the final release of 1.0.<br />
<br />
Are you excited? I bet you are. In the meanwhile download and enjoy the new beta:<br />
<br />
<div style="text-align: center;">
<span style="font-size: large;"><a href="https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA05">https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA05</a></span></div>
<div style="text-align: center;">
<span style="font-size: large;"><br /></span></div>
<div style="text-align: left;">
<span style="font-size: large;"><span style="font-size: small;">To sum up what you will get with the new beta: <b>mainly </b><a href="https://sourceforge.net/p/euaeppcjit/tickets/milestone/PPCJITBETA05/"><b>bugfixes</b></a>. All the features are locked down for the release, the ticket list for release 1.0 is practically empty. I am waiting for any bugs you find before the release.</span></span><br />
<span style="font-size: large;"><span style="font-size: small;"><br /></span></span><b>
</b><span style="font-size: large;"><span style="font-size: small;"><b>So, please do report bugs you find</b>. But again: it is very important to try to verify the issue before you decide about reporting it. Please follow the steps which are documented in the <a href="https://sourceforge.net/p/euaeppcjit/code-0/HEAD/tree/trunk/README#l223">README file</a>.</span></span><br />
<span style="font-size: large;"><span style="font-size: small;"><br /></span></span>
<div style="text-align: center;">
<span style="font-size: large;"><span style="font-size: small;"><b>Your efforts are greatly appreciated.</b></span></span></div>
<span style="font-size: large;"><span style="font-size: small;"></span></span><br />
<h3>
<span style="font-size: large;"><span style="font-size: small;">JIT compatibility diagnostics </span></span></h3>
</div>
<div style="text-align: left;">
I have rejected a few bugs due to the fact that these programs are not compatible with the current JIT compiling implementation. <b>The reason is very simple:</b> if the program is trying to modify itself without flushing the instruction cache properly then the modified code won't be recompiled and the program will misbehave. Like this program: <a href="https://sourceforge.net/p/euaeppcjit/tickets/60/">Where Time Stood Still</a>.<br />
<br />
These programs might work on a real processor and still fail with the JIT compiling because the cache handling is not emulated exactly the same how it would behave on a real processor. (Namely: the number of cache lines are much larger than on a real processor, so more code is "cached".)<br />
<br />
Although this is not ideal, but for now only a handful of programs are depending on the cache size, so it won't cause too much trouble.<br />
<br />
<i>How could you tell that the program is compatible with the JIT compiler?</i><br />
<br />
<b>That is a very valid question</b>. And here is the answer:<b> there is a option for that!</b> (At least there is now.)<br />
I have wasted so much time on chasing errors coming from this issue that finally I have decided I implement a diagnostic configuration option for it. It is called:<br />
<b>comp_test_consistency</b><br />
<br />
Usual disclaimer: <b>read the documentation and if you didn't understand what does it do then don't turn it on.</b><br />
<br />
<span style="font-size: large;"><span style="font-size: small;">Actually, it is pretty simple: in addition to every compiled block of instructions the compiler also compiles a check which compares the original content of the memory which was used for the compiling to the current content. If it doesn't match then the emulation stops.</span></span><br />
<br />
<span style="font-size: large;"><span style="font-size: small;">Basically, it can be used for verifying if the program misbehaves because it does not flush the instruction cache properly, or there is some other reason.</span></span><br />
<br />
<span style="font-size: large;"><span style="font-size: small;">It is safe to keep it turned on, but it slows down the emulation (sometimes considerably), so use it only when it is needed.</span></span><br />
<span style="font-size: large;"><span style="font-size: small;"><br /></span></span>
<h3>
<span style="font-size: large;"><span style="font-size: small;">X1000</span></span></h3>
</div>
<div style="text-align: left;">
<span style="font-size: small;">As I already announced in the <a href="http://euaejit.blogspot.com/2014/07/ppcjitbeta04b-hundreds-and-xthousands.html">previous post</a> (couple months ago): the <b>Amiga X1000 optimized version is available in the package</b>. Please use only that version on Amiga X1000, the generic build won't work properly.</span><br />
<br />
<h3>
<span style="font-size: large;"><span style="font-size: small;">060</span></span></h3>
</div>
<div style="text-align: left;">
<span style="font-size: large;"><span style="font-size: small;">Due to the "popular demand" (more than one request ;) I have fixed the <b>cache handling of the emulated 68060 processor type</b>.</span></span><br />
<span style="font-size: large;"><span style="font-size: small;">Please note: it is stated in the documentation from the original E-UAE that the 060 support is not implemented and all I had done was: fixed the cache bits to let the emulator turn on the caches, so the JIT can be activated. However, it is highly likely that there will be problems with some programs running on 060, since other important aspects of the 060 is not implemented (like proper stackframe).</span></span><br />
<span style="font-size: large;"><span style="font-size: small;"><b>So, watch your steps while using it.</b> (And please don't report bugs for it. <i>kthxbai</i>)</span></span><br />
<span style="font-size: large;"><span style="font-size: small;"><br /></span></span>
<span style="font-size: large;"><span style="font-size: small;"></span></span></div>
<div style="text-align: left;">
<h3>
<span style="font-size: large;"><span style="font-size: small;">RuninUAE</span></span></h3>
<span style="font-size: large;"><span style="font-size: small;">ChrisH kindly implemented the<b> support for the betas in RuninUAE</b>. You can turn on the JIT emulation from the menu now. (<i>You guys are too spoiled!</i>) Thanks Chris!</span></span><br />
<h3>
<span style="font-size: large;"><span style="font-size: small;">WinUAE PPC </span></span></h3>
<span style="font-size: small;">In case you haven't heard: <b>WinUAE is capable of emulating <a href="https://amigafun.wordpress.com/2014/09/15/winuae-powerpc-huge-speed-increases-with-amigaos4-1/">PowerPC hardware through QEmu</a></b> on intel compatible processors and run PPC apps and even AmigaOS4.</span><br />
<br />
<span style="font-size: small;">The obvious question: how much better would it be running PowerPC programs on actual PowerPC processor under hardware emulation? :)</span><br />
<span style="font-size: small;">Probably it would be possible to make use of the native PowerPC processor and it would be fast. <i>Very fast.</i> </span><br />
<span style="font-size: small;">Not to mention it would open the door for AmigaOS4 running on Macintosh iBooks for example.</span><br />
<span style="font-size: small;"><br /></span>
<span style="font-size: small;">Do I have plans implementing it? <b>No, sorry.</b> </span><br />
<span style="font-size: small;">Thanks for asking.</span><br />
<span style="font-size: small;"><br /></span>
<h3>
<span style="font-size: large;"><span style="font-size: small;">Thanks</span></span></h3>
<span style="font-weight: normal;"><span style="font-size: small;">Finally, some thank-you's to the lovely people who helped me in this beta.</span></span><br />
<br />
<span style="font-weight: normal;"><span style="font-size: small;"><b>Big thanks goes to:</b> MickJT, Mike Blackburn,</span></span><span style="font-weight: normal;"><span style="font-size: small;"> </span></span><span style="font-weight: normal;"><span style="font-size: small;"><span style="font-weight: normal;"><span style="font-size: small;">Chris Handley, </span></span>Luigi Burdo, </span></span><span style="font-weight: normal;"><span style="font-size: small;">Samir Hawamdeh, Raziel and Cass.</span></span><br />
<br />
<span style="font-weight: normal;"><span style="font-size: small;">Some guys just can't stay away as it seems. :)</span></span><br />
<span style="font-weight: normal;"><span style="font-size: small;"><br /></span></span>
<b>See you soon.</b></div>
Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com2tag:blogger.com,1999:blog-5052591504201077738.post-33645148278471995712014-07-28T20:13:00.001+12:002014-07-28T20:16:09.380+12:00PPCJITBETA04b (Hundreds and XThousands)There is something new each day, I haven't done this before: a <i>Fast Follow</i> to the previous beta release.<br />
<br />
Let me sprinkle the life of the suffering Amiga X1000 owners, here is a<br />
<br />
<div style="text-align: center;">
<a href="https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA04/"><span style="font-size: large;">PA6T optimized build for Amiga X1000</span></a></div>
<br />
After <a href="https://sourceforge.net/p/euaeppcjit/tickets/21/">I had done</a> some investigation, it turned out that MickJT was right for a long time. We don't need unique changes for Amiga X1000 (for the P.A. Semi PA6T processor), because it is similar to the already supported G5 (PowerPC 970) processor.<br />
<br />
So, I have decided that we must not delay the beta for Amiga X1000 any longer. This new build is exactly the same Beta #4 release feature-wise; which was done for the other platforms already. Except that it is compiled for AmigaOS4 with the same minor changes which increase the performance on G5 significantly.<br />
<br />
Since the code base is the same I kept the same beta version tag with a postfix. For the first and the last time...<i> Úttörő becsület szavamra!</i> :)<br />
<br />
<h3>
Caveat emptor</h3>
This build is not fully optimized for PA6T processor, since there is no support for that processor target in the AmigaOS4 SDK yet. It is still running much better than the previous generic builds.<br />
Hopefully the PA6T support will be resolved sooner or later in the SDK and then <a href="https://sourceforge.net/p/euaeppcjit/tickets/55/">I will add any necessary changes</a> to the E-UAE build too.<br />
<br />
In the meanwhile the binary for this build target will be added to the upcoming releases.<br />
<br />
<h3>
Credz</h3>
Actually, the credit goes to the following good people:<br />
<ul>
<li><b>Tobias Netzel</b> - who implemented the G5 support and helped MickJT with advices;</li>
<li><b>MickJT</b> - who was experimenting with the build for a long time already and pushed me to do this release;</li>
<li><b>Sven Ottemann</b> & <b>Sebastian Bauer</b> - who helped me with the documentation for PA6T; </li>
<li><b>Tommysammy </b>- who was kindly doing the testing.</li>
</ul>
Thanks guys!<br />
<br />
<h3>
Feedback</h3>
This was a blindfolded build again: I have no access to an Amiga X1000, so I couldn't test the build by myself.<br />
<br />
I would like to invite all Amiga X1000 owner to give me some feedback regarding the performance or any issues what turns up with this special build.<br />
<br />
You can find my email address at the end of the README file.<br />
<br />Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com7tag:blogger.com,1999:blog-5052591504201077738.post-36454187877113868772014-07-20T20:36:00.000+12:002014-07-20T20:37:29.654+12:00PPCJITBETA04 (FourFOurfOurfoUR!)<br />
<h2>
</h2>
Four is a nice, round number. Power of 2, not too many, not too less. You know, <b>four is referring to many good things</b>, like: the Fantastic Four, 4th of July, AmigaOS4, The Magnificent Four... <i>Err.. Maybe not that, scratch that </i><i><i>last one</i>.</i><br />
<br />
Therefore, without further ado, here is <b>Beta #4</b>:<br />
<br />
<div style="text-align: center;">
<span style="font-size: large;"><a href="https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA04">https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA04</a></span></div>
<br />
I had an irresistible urge to <a href="http://en.wikipedia.org/wiki/Rickrolling">RickRoll</a> you guys with the link, but that video has been <a href="http://www.billboard.com/articles/business/digital-and-mobile/6165313/youtube-blocks-original-rickroll-video">blocked</a> recently on YouTube in many countries, so maybe next time.<br />
<br />
<h3>
Tickets please</h3>
I had my sweet time with a very <a href="https://sourceforge.net/p/euaeppcjit/tickets/52/">weird bug</a> related to Quake, which is not resolved yet and probably related to the failure to implement the <a href="https://sourceforge.net/p/euaeppcjit/tickets/26/">soft cache flushing</a>. These two tickets are pushed back to <b>Beta #5 </b>for now. Previously I had no intention to do one more beta release before the <b>first Release Candidate</b>, but as it seems I need one more round of testing period.<br />
<br />
I had to shuffle around some tickets while I was rethinking the upcoming Release Candidate. You know, changing priorities, <a href="http://cdn.memegenerator.net/instances/500x/50708330.jpg">agile development</a>, whatnot. What is listed in the milestones now is the plan, although it is not set in (mile)stone... Heheh... <i>(Huh, that was a </i><i><i>really </i> lame pun. You should do better than that!)</i><br />
<br />
The idea is: <b>I am going to fix every issue which is known </b>and give you guys some time to test before the final release (candidate).<br />
<br />
<h3>
SAM440</h3>
After a few rounds of pushing and pulling some SAM440/Flex related codes hopefully we have sorted out all the various problems related to those machines. If you were still experiencing issues then please let me know.<br />
<br />
<h3>
G5 again</h3>
Thanks to <b>Tobias Netzel</b>, the flag extraction on G5 is fixed, this will resolve a number of problems with various programs.<br />
<br />
The <b>compiling for </b><b><b>G5 </b>is still not resolved for MorphOS</b>,
no G5-optimized binary again, sorry guys. If you could tell me how can I
(easily) compile the files for G5 on my iBook then I give it a go, I promise.<br />
<br />
<h3>
What's next</h3>
As you can see: <b>Beta #5 is coming</b>, there are already a <a href="https://sourceforge.net/p/euaeppcjit/tickets/milestone/PPCJITBETA05">handful things</a> lined up for it.<br />
<br />
Please <b>do test Beta #4</b> and please <b>do report bugs</b> you have found. It is important to sort out as many problems as I could. It is equally important to help me reproducing the bug. So, please <a href="https://sourceforge.net/p/euaeppcjit/code-0/HEAD/tree/trunk/README#l236">read the instructions</a>. Thanks a bunch!<br />
<br />
<h3>
Best Boys</h3>
I would like to give a big thanks to <b>Luigi Burdo</b>.
He helped me with a great deal of things, reported lots of bugs and he
is so enthusiastic that he inspired me to keep walking on the road. <b>Thanks a lot, Luigi!</b> Keep up the good spirit!<br />
<br />
And, of course, my dearest sidekicks, who just couldn't stay away from the project:<br />
<b>MickJT</b> and <b>Tobias Netzel</b>. Cheers!<br />
<br />
Also would like to thank the helps, bug reports and overall support to:<br />
<b>Samir Hawamdeh, Kicko, Chris Handley, Allan Ullmann</b>.Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com5tag:blogger.com,1999:blog-5052591504201077738.post-43189926181121686182014-05-30T16:26:00.002+12:002014-05-30T16:27:07.586+12:00Here is your Captain speakingLadies and Gentlemen, I would like to have a word with you about <b>bug reporting</b>...<br />
<br />
Please <b>do not</b> report E-UAE JIT compiling related bugs to:<br />
<ul>
<li><b>a forum at your favorite portal</b> <span style="font-size: xx-small;">(because they are going to give you advices, unless it is a cooking portal, but they won't fix it anyway)</span>;</li>
<li><b>your "friends" on Facebook as a status post</b> <span style="font-size: xx-small;">(because your hot ex-classmate doesn't care, not to mention that she put you to the <i>acquaintances </i>list for a long time and I am prettty sure she won't fix it anyway)</span>;</li>
<li><b>Runinuae author</b> <span style="font-size: xx-small;">(because although Chris is a good guy, almost certainly he won't fix it anyway - <span style="font-size: small;"><i>hey Chris!</i></span>)</span>;</li>
<li><b>your fellow Amiga-enthusiasts at the Club</b> <span style="font-size: xx-small;">(because they might listen to your theory on what is the root cause of the bug, but they won't fix it anyway)</span>;</li>
<li><b>your neighbor's cat</b> <span style="font-size: xx-small;">(because the poor thing doesn't want to hear anything about "fixing", I guarantee)</span>.</li>
</ul>
Why? Quite simple: if you try to report bugs anywhere else than my mailbox <b>there is zero guarantee that your bug report ever lands on my computer</b>.<br />
<br />
You know, there is some chance that I wake up one day and realize:<br />
<br />
<i>Ah, some Amiga-fan while playing Superfrog on level 6 encountered a graphical glitch which is caused by a mis-used flag dependency in the JIT compiler optimization, so I must fix it. I need coffee!</i><br />
<br />
Yes, there is some chance, <b>very-very-very low chance</b>. (As opposed to there is high chance that I wake up one day and realize: <i>Hrrgrhh... I need coffee!</i>)<br />
<br />
<h3>
Golden Rule</h3>
If you want to <b>get the bug fixed</b> then <b>report it to me</b>, preferably by e-mail.<br />
<br />
Or you can create a ticket at the projects <a href="https://sourceforge.net/p/euaeppcjit/tickets/">SourceForge page</a>.<br />
<br />
(If you really-really must then you can use the contact box on this blog at the right to the post.)<br />
<br />
<h3>
One more tiny thing</h3>
Please do your <b>due-diligence before reporting</b>, if I might ask you to.<br />
<br />
What would I like to ask from you is <b>summarized in the README file</b> (<i>yea, like anybody would read a README file</i>). Here is a link to the <a href="https://sourceforge.net/p/euaeppcjit/code-0/HEAD/tree/trunk/README#l232">current version</a> on SourceForge code repository.<br />
<br />
You can also find my e-mail address at the end of that file. <br />
<br />
<i>Thank you for your attention! Now go back sipping your cocktail, the dinner will be served at 6pm. Wearing Boing Ball pin is mandatory.</i><br />
<br />Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com7tag:blogger.com,1999:blog-5052591504201077738.post-91244478684657510272014-05-21T21:22:00.000+12:002014-05-22T19:35:38.226+12:00PPCJITBETA03 (Switch to Ludicrous Speed)Welcome back, long time no see, my friend. Please be seated.<br />
<br />
I can tell you I have some good news to you again: here comes <b>Beta #3</b>!<br />
<br />
Get it here if you must:<br />
<br />
<div style="text-align: center;">
<a href="https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA03"><span style="font-size: large;">https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA03</span></a></div>
<br />
I held this release back for a while just to fix the <a href="https://sourceforge.net/p/euaeppcjit/tickets/26/">emulated cache checksum</a> feature, but I have been chasing a bug for two weeks without any success. So, that fix is postponed to the next beta, in the meanwhile you can enjoy some significant speed enhancement and increased stability.<br />
<br />
Without going into the details regarding the changes (see the included README for all changes) I would like to mention the most important change:<br />
<br />
<h3>
Vroom-vroom</h3>
The major feature of this beta release is the <b>register and flag optimization fix</b>. You can turn it on in the configuration, just set <b>comp_optimize</b> to <b>true</b>.<br />
<br />
If you are interested in the details I explained it already how the optimization works in <a href="http://euaejit.blogspot.com/2012/08/optimize-it.html">an earlier post</a>, but in case you are too lazy to read through that post: here is my old diagram (just because it is beautiful, you know):<br />
<br />
<table align="center" cellpadding="0" cellspacing="0" class="tr-caption-container" style="margin-left: auto; margin-right: auto; text-align: center;"><tbody>
<tr><td style="text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhbyafIMq8VVaxea06aIM__ICCHcwSGn2hP7tEsCOO2qeMleWG3J6yBAR294noXhZS0PlS9DdMhQZNOtlKCcwEj34yEgrJvqodT_KMsoUqRMbrF1FtVigMnOpoxtVKOrO5quZYBs_KS3sg/s1600/code_generation_diagram.png" imageanchor="1" style="margin-left: auto; margin-right: auto;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhbyafIMq8VVaxea06aIM__ICCHcwSGn2hP7tEsCOO2qeMleWG3J6yBAR294noXhZS0PlS9DdMhQZNOtlKCcwEj34yEgrJvqodT_KMsoUqRMbrF1FtVigMnOpoxtVKOrO5quZYBs_KS3sg/s1600/code_generation_diagram.png" height="308" width="640" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;">Code translation flow diagram</td></tr>
</tbody></table>
<br />
<b>Let me summarize it for you</b>: the JIT compiler is collecting information about data-flow dependencies between the various macroblocks and tries to <b>remove </b>the ones which <b>won't have any effect on the outcome</b> of a certain block of macroblocks.<br />
This is not a new feature in the JIT implementation, but previously a few (<i>tons of</i>) bugs prevented it from working on more complex codes than my <a href="https://sourceforge.net/projects/euaeppcjit/files/m68k_testfiles/">Mandelbrot test</a>.<br />
<br />
In this release I have fixed every issue I have found so far with the optimization and it seems working quite nicely. You can boot the AmigaOS and it runs just fine, also games and demos will benefit from this feature too.<br />
I was planing to do a comparison video where the speedup is clearly shown, but I haven't had too much time yet, so this is your job now, <i>dear EUAEPPCJIT fans</i>! Just post the links to the videos into the comments here. :)<br />
<br />
<h3>
PPC970 aka G5</h3>
Not everything is sunshine and happiness, though. Supporting G5 processor architecture target turned to be <b>much more complicated</b> than I thought, especially because I don't have any hardware to test on.<br />
<br />
In the previous release the MacOSX G5 binary was not working properly on G5 (neither on any other PowerPC as matter of fact). Thanks to <b>Luigi Burdo</b> for the report and <b>Tobias Netzel</b> (again) for the help with the compiler. <b>This is fixed in this release</b>, hopefully. (Fingers crossed, I still don't have hardware to test on.)<br />
<br />
While the situation with the MorphOS G5 version is not that hunky-dory: as it seems there is <b>no official compiler with G5 support yet</b> in the MorphOS SDK and it is rather complicated and unreliable to compile any source for that processor. Until this situation is improved the G5 version for MorphOS won't be available from the beta binaries.<br />
<br />
However, nothing stop you from compiling your own version from the sources, as these are always available at <a href="https://sourceforge.net/p/euaeppcjit/code-0/HEAD/tree/trunk/">SourceForge</a>.<br />
<br />
<h3>
Upcoming</h3>
As I mentioned: I postponed the fix for the block checksum to the next release and also picked up some things to do. You can find the planned list here:<br />
<br />
<div style="text-align: center;">
<b><a href="https://sourceforge.net/p/euaeppcjit/tickets/milestone/PPCJITBETA04">https://sourceforge.net/p/euaeppcjit/tickets/milestone/PPCJITBETA04</a></b></div>
<br />
I also had a look on what is planned for the first stable release and moved some items around the various milestones. If you are curious just click at the milestones on the Sourceforge page.Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com24tag:blogger.com,1999:blog-5052591504201077738.post-19545659299819499192014-03-15T12:57:00.002+13:002014-03-16T17:28:41.931+13:00PPCJITBETA02 (The Beginning of a Beautiful Friendship)<h4>
</h4>
We have just arrived to another exciting milestone on the long road: all the <b>important instructions for the initial release are implemented</b> under the JIT compiling.<span style="font-size: x-small;">*</span><br />
<br />
Lots of bugs were fixed, the emulator is much more stable now than the initial beta release.<br />
<br />
Some new features are added too: I have merged the <b>SAM440EP/Flex </b>support (thanks to Soft3) and the <b>CGX overlay for MorphOS </b>(thanks to Thunder and Fab). See configuration documentation regarding how to set the overlay up.<br />
<br />
As I already mentioned in the <a href="http://euaejit.blogspot.com/2014/02/stepping-into-third-year.html">previous post</a>: this beta release was delayed for a couple weeks due to a <a href="https://sourceforge.net/p/euaeppcjit/tickets/30/">bug</a> that slipped into the code base long time ago. It was discovered on Mac first, but I was able to reproduce it on MorphOS too. Took me a while to figure out what was going on, but it is fixed now.<br />
This was a very tricky bug, it could be blamed for random crashes and endless loops also, not only on Mac, but on all supported platforms. It was triggered randomly based on the distance between the main application code and the code buffer in memory. (Thanks to Mike for discovering this right before I released the beta.)<br />
<br />
I have spent a significant amount of time on figuring out how can I do the build for all supported platforms (<i>AmigaOS4</i>, <i>MorphOS </i>and <i>MacOSX-PPC</i>) using my environments. It wasn't easy, but finally I managed to do most of the release on my own.<br />
As it seems MorphOS SDK does not support G5 yet, so I was not able to do the compiling by myself, but thanks to <b>Fab </b>the G5 executable is also available in the release package.<br />
So, as of now users on all major supported platforms can grab the package and start using the right version.<br />
(Sorry, <i>Linux </i>and <i>BSD </i>folks, you are still on your own.)<br />
<h4>
</h4>
<h4>
And the World trembled...</h4>
...or at least that tiny part which I am involved in when I am wearing my crazy <i>latex suit</i> <i>with a huge letter "A" on my chest</i> for my secret identity: the <i>Amiga Software Developer</i>.<br />
<br />
After the first beta release forum posts, emails, news sites, blogs had risen in an enormous unmanageable thunderstorm, struck on me with insane amount of communication. (<i>While the rest of the World barely noticed what have just happened</i>.)<br />
Finally I crawled through messages from every possible (and impossible) source and answered the questions to my best knowledge, accepted the good advices, kindly rejected some nonsense.<br />
<h4>
</h4>
<h4>
Aftermath</h4>
Since I received tons of feedback (good and bad), I inclined to draw some conclusions from the reaction to the very first beta release. Here is the summary for your benefit:<br />
<br />
Some people don't understand how the JIT works and what is the exact purpose of it. All I can say is: <b>please read the documentation</b>... Some other (<i>knowledgeable</i>) folks stood up on the forums and educated the others, <b>well done</b>! I hope this helps, because I really don't have time to deal with it.<br />
<br />
Many of the users have <b>irrational expectations</b> for how much the JIT compiling will speed up the emulator. (According to somebody: it supposed to be "<i>ten times faster than the interpretive</i>"... Err... Not likely. How did they come up with any number anyway?)<br />
<br />
Well, <b>the implementation is not finished yet</b>, some of you guys don't really understand the concept of "<a href="http://en.wikipedia.org/wiki/Beta_release#Beta">beta release</a>". <b>Okay, I admit </b>I was cheating a bit: technically the JIT compiler wasn't feature-complete when the first beta was done. Yet the remaining pieces were related to not too often used instructions anyway.<br />
For the second beta the instructions are <i>done</i>*, yet there is clearly room for improvement regarding some bugs. Probably as soon as I will be able to fix up the <b>optimization of the register- and flag-flow</b> there will be a significant bump for the speed. (No, not "<i>ten times</i>" fold.)<br />
<br />
It is hard to measure how much faster the programs are running and some lovely people baffled on this too. Since there is usually no obvious visual clue for the speedup and a 30%-50% increase in the processor speed is probably hard to notice while your favorite jump-and-run game is jumping and running.<br />
Yet, you can feel that the whole emulation is more snappy than before probably even when you simply run Workbench. Except when it crashes. But even then: <b>it crashes 30%-50% faster</b>! :)<br />
<br />
Too bad that some good souls are obsessed with their <b>favourite game/program</b> and keep saying that the JIT is worthless because it doesn't make any difference for that particular piece of software. As it seems this JIT compiling is not for you then.<br />
<br />
There was one more interesting thing what I have noticed too late unfortunately: <b>G5 support for MorphOS</b>. Since I don't have a G5 machine I never considered that there is a need for that. But there were some murmur about the speed of the MorphOS version on G5 on some forums. No wonder: it needs a special version, which can be compiled from the sources for some time now. (<a href="http://euaejit.blogspot.com/2012/10/jinxed-it-more-apples.html">Thanks to <b>Tobias Netzel</b></a> and to <b>Fab </b>for the special build.)<br />
Probably the same applies to the <b>PA Semi </b>processor and the Amiga X1000, but I don't have that one either. (Donations? :)<br />
Also the mysterious support for SAM440EP/Flex, what I have never heard of before. No wonder it was missed. <br />
<br />
<i>Fun fact from the Outer World: I tried to explain to my colleagues how I spent my Summer vacation. However, I am significantly older than almost any of them, so they were looking at me with confusion in their eyes mixed with a little pity. "</i>Yea, my father loves fooling around with those old machines too!<i>" - was one of the comments. Well put, Sir, well put. </i><br />
<h4>
</h4>
<h4>
Anyway...</h4>
To make you (some other geeks around the World) happy: <b>here is the new beta...</b><br />
<br />
<div style="text-align: center;">
<span style="font-size: large;"><a href="https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA02">https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA02</a></span> </div>
<h4>
</h4>
<br />
In case you stop reading here (or you already skipped the first cheesy part):<br />
as always, <b>please read the README</b> for your comfort and safety. Thanks.<br />
<br />
Since I bought an iBook for 50 NZD, now I can produce the MorphOS and the MacOSX versions too which were also included in this release together with the AmigaOS4 version. (<i>And by buying a Mac I broke one of my principles: no Apple product crosses the door of my house. I hope you guys are content what you were doing...)</i><br />
<br />
You can find the changes since the last beta in the README file, or in the changesets at the <a href="https://sourceforge.net/p/euaeppcjit/code-0/67/log">SourceForge repository from R67 down to R53</a>.<br />
<h4>
</h4>
<h4>
Fragmentation </h4>
I must admit I have learned a lot in the past month about the <b>sorry state of the E-UAE project</b>. I didn't know what is the current situation of the various binary releases until I received some references to<b> modified AmigaOS4 and MorphOS</b> binary versions.<br />
I guess this is the destiny of any abandoned open source project: lots of good people is trying to improve it, but nobody is standing up and takes over the maintenance of the project.<br />
<br />
Well, I am of the same kind, as it seems. It was <b>never my goal to take the ownership of the E-UAE project</b> or fork it into a new iteration.<br />
However, as soon as I released the first beta of the JIT compiled version the <b>watching eye of the public</b> turned to my little scared pet project and I received lot of questions about whether this-or-that particular fix from various developers were included or not. (Mostly not.)<br />
<br />
To satisfy at least some part of the user base I tried to gather the various fixes from every corner of the Internet and applied them on the source code. This means<b> no way new base source repository for the E-UAE project</b>, but at least it will help whoever wants to grab the torch and probably it will be useful for you, dear user in the meanwhile in the form of the beta releases.<br />
<h4>
</h4>
<h4>
Progress indicator</h4>
As of now I switch from <b>batch release strategy</b> to <b>immediate update</b>. This means: I will <b>commit each change </b>one by one to the SourceForge repository as soon as the change is ready instead of buffering up lots of changes locally and commit them in a big changeset.<br />
So, if you look for the repository changesets and the tickets then you can watch the progress of the project closely.<br />
<br />
I also make use of the tickets in the completion of the various fixes and tasks:<br />
<br />
<a href="https://sourceforge.net/p/euaeppcjit/tickets">https://sourceforge.net/p/euaeppcjit/tickets</a><br />
<br />
I added milestones to the tickets, so you can get a feeling of the upcoming beta and the included changes, fixes.<br />
<b>Open </b>tickets are defining the majority of the outstanding work. I am currently working on the <b>accepted </b>ticket, while <b>pending</b> tickets are already committed to the repository, but not released in binary form yet. Released tickets are the <b>closed </b>ones.<br />
<br />
For PPCJITBET03 you can find the planned changes here:<br />
<br />
<a href="https://sourceforge.net/p/euaeppcjit/tickets/milestone/PPCJITBETA03">https://sourceforge.net/p/euaeppcjit/tickets/milestone/PPCJITBETA03</a> <br />
<br />
There is also a milestone named "<b>PARKED</b>" which is a holding box for the various bugs and problems that are not considered for this project (yet).<br />
<h4>
</h4>
<h4>
Thanks</h4>
Finally, big thanks goes to: <b>Thunder</b>, <b>kas1e</b>, <b>MickJT, </b><b><b>Fab, </b>Tobias Netzel </b>and<b> Mike Blackburn</b> for helping me with lots of things regarding bug finding, fixing, platform support and constantly watching out for the updates on the repository.<br />
<br />
I am still waiting for any (detailed) bug reports, just have a good read of the README file before you jump to your email client.<br />
<br />
<span style="font-size: x-small;"><i>Footnote</i></span><br />
<span style="font-size: x-small;">*<i>There is a fine print here: I was
struggling with CMP2 instruction and finally I gave up after a couple
days. The binary code for the instruction is bundled with CHK2 and I
couldn't figure out how solve the exception handling for that. So, this
instruction remains unimplemented for now, not a big deal luckily.</i></span>Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com26tag:blogger.com,1999:blog-5052591504201077738.post-91036937641506163992014-02-23T17:16:00.001+13:002014-02-23T17:18:23.289+13:00Stepping into the fourth year<div style="text-align: center;">
And here we are again: the development of the PowerPC JIT compiling for E-UAE</div>
<div style="text-align: center;">
<b>passed the third year, stepping into the fourth</b>.</div>
<br />
<table align="center" cellpadding="0" cellspacing="0" class="tr-caption-container" style="margin-left: auto; margin-right: auto; text-align: center;"><tbody>
<tr><td style="text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgPCF-e43-mZegncCOrtNWcQbgS0WMmQIy5jzdPd7Hyuv60Hxrnq40o5mbQoD3iLFxYWOmzr4FVNfJfV3B0_RxRHpiaCtEAgcAmlfZIDqSWDsZKide9Gb_dsGgjmj-dn0TZJPFxcQv3xCw/s1600/cake3year.jpg" imageanchor="1" style="margin-left: auto; margin-right: auto;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgPCF-e43-mZegncCOrtNWcQbgS0WMmQIy5jzdPd7Hyuv60Hxrnq40o5mbQoD3iLFxYWOmzr4FVNfJfV3B0_RxRHpiaCtEAgcAmlfZIDqSWDsZKide9Gb_dsGgjmj-dn0TZJPFxcQv3xCw/s1600/cake3year.jpg" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;"><span style="font-size: xx-small;">Original image by <a href="http://openclipart.org/detail/161305/3-candle-cake-by-dakhath">OpenClipart</a></span></td></tr>
</tbody></table>
<br />
<br />
<b>But what a year!</b> Yes, finally we are getting very close to the <i>Real Thing(tm)</i>. Even a <a href="https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA01/">beta version</a> is available from the project, although probably it is not particularly useful to anybody who is not the adventurous type. There are many bugs to chase and also there is room to improve.<br />
<br />
I know everybody is eagerly waiting for the second beta. It was prepared <b>more than two weeks ago</b>, the sources are released to SourceForge, the post is ready to launch...<br />
<br />
But then suddenly <b>Mike Blackburn</b> came back to me (big thanks for that) and <b>mentioned a <a href="https://sourceforge.net/p/euaeppcjit/tickets/30/">show-stopper bug on Mac</a></b>. In the meanwhile I confirmed that the same bug does exist on MorphOS too, so probably it is just a coincidence that the emulation works on AmigaOS4.<br />
<br />
Right now I am trying to figure out what is going on, but for that I needed access to a Mac. So, it took me a while to set up everything and getting ready to debug this. After spending a couple days on chasing my own tail already I am no closer to the solution yet, but I promise I put all my free time into this.<br />
<br />
Please relax and enjoy the beautiful <b>Summer </b>at the Southern Hemisphere and try not to freeze to death in the <b>Winter </b>at the North.Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com5tag:blogger.com,1999:blog-5052591504201077738.post-71070841056698806472014-01-04T09:41:00.000+13:002014-01-04T09:41:49.608+13:00PPCJITBETA01-MorphOSJust quickly: the MorphOS build of the first Beta is available from SourceForge:<br />
<br />
<div style="text-align: center;">
<span style="font-size: large;"><a href="https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA01">https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA01</a></span></div>
<br />
Thanks to Thunder for the MorphOS build!Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com6tag:blogger.com,1999:blog-5052591504201077738.post-37448027561894345342014-01-01T17:44:00.001+13:002014-03-09T12:17:13.687+13:00PPCJITBETA01 (Happy New Year 2014)<span style="font-family: inherit;">First of all:</span><br />
<span style="font-family: inherit;"><br /></span>
<br />
<div style="text-align: center;">
<span style="font-family: inherit;"><span style="font-size: large;">I wish all of you guys an <b>awesome happy new year for 2014</b>!</span></span></div>
<span style="font-family: inherit;"><br /></span>
<span style="font-family: inherit;">We made it this far, there was no <i>nuclear holocaust</i> yet, which is an amazing achievement for the human race considering our lovely nature. <u>Well done</u>.</span><br />
<span style="font-family: inherit;"><br /></span>
<span style="font-family: inherit;">And now something completely different, but almost equally exciting (probably for much less human beings, can't speak for aliens)...</span><br />
<span style="font-family: inherit;"><br /></span>
<span style="font-family: inherit;">I woke up in the morning and had a look at the clock and it showed me:</span><br />
<span style="font-family: inherit;"><br /></span>
<br />
<div style="text-align: center;">
<span style="font-family: inherit;"><span style="font-size: x-large;"><b>BETA TIME!</b></span></span></div>
<div style="text-align: left;">
<span style="font-family: inherit;"><br /></span></div>
<div style="text-align: left;">
<span style="font-family: inherit;">Yes, it is unbelievable, I know. After this long-long waiting finally here it comes.</span><br />
<span style="font-family: inherit;"><b>And it even comes with bugs! Lots of it!</b></span></div>
<div style="text-align: left;">
<span style="font-family: inherit;"><br /></span></div>
<div style="text-align: left;">
<span style="font-family: inherit;">Now seriously, if you are interested in testing the PowerPC JIT then<b> go and get your binary release from the SourceForge page</b>:</span><br />
<br /></div>
<div style="text-align: left;">
<div style="text-align: center;">
<span style="font-family: inherit;"><span style="font-size: large;"><a href="https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA01">https://sourceforge.net/projects/euaeppcjit/files/0.8.29-PPCJITBETA01</a> </span></span></div>
<br />
<span style="font-family: inherit;"><i>Tiny catch: at the moment only the AmigaOS4 version is available. See below.</i></span><br />
<br />
You might also need a <b>previous distribution which includes all the tools</b>, like <i>transrom, mousehack</i>, <i>make-hdf, etc</i>. I tried to compile these, but somehow the cross-compiling failed and I ran out of patience.</div>
<div style="text-align: left;">
<h3>
<span style="font-family: inherit;">
What is included in beta01?</span></h3>
<span style="font-family: inherit;">Before you fire up your favorite Amiga software in the emulator, please <b><u>DO READ</u></b> the <b>README </b>file! It will save you (and me) lots of wasted time, I guarantee.</span></div>
<div style="text-align: left;">
<span style="font-family: inherit;"><br /></span></div>
<div style="text-align: left;">
<span style="font-family: inherit;">The very first thing I have to mention is that although I had done my best I was not able to finish implementing all the planned instructions. We are very close, according to the statistics <b>95.09%</b> of the instructions (368 out of 387) are done.</span><br />
<span style="font-family: inherit;">The reason is quite simple: the recently implemented instructions were the most complex ones. Well, you know this is exactly why you <b>must not </b><span data-dobid="hdw"><b>procrastinate</b> <b>the hardest part</b> of the job just because it makes you nervous even simply thinking about it...</span></span><br />
<span style="font-family: inherit;"><span data-dobid="hdw">I have spent <i>days</i> on implementing <i>BFINS </i>and the exception handling for <i>division by zero</i> and I am still not convinced that it worth the effort. Anyway...</span></span></div>
<div style="text-align: left;">
<span style="font-family: inherit;">The following instructions are still emulated by the interpretive:</span></div>
<ul>
<li><span style="font-family: inherit;">long versions of the division and multiplication instructions (DIVU.L/DIVS.L, MULU.L/MULS.L);</span></li>
<li><span style="font-family: inherit;">compare against bounds instructions (CMP2);</span></li>
<li><span style="font-family: inherit;">all the decimal data handling instructions (ABCD, SBCD, NBCD, PACK, UNPK).</span></li>
</ul>
<span style="font-family: inherit;">The comparison and the decimal data handling is not that important, but the long division-multiplication are used quite often.</span><br />
<span style="font-family: inherit;">So that is sill a sore point, yet I have decided that I will release the beta without these instructions to get some feedback.</span><br />
<span style="font-family: inherit;">The missing instructions will be implemented soon, probably in the next beta release. </span><br />
<h3>
<span style="font-family: inherit;">
</span></h3>
<h3>
<span style="font-family: inherit;">
What is new in the sources?</span></h3>
<h4>
<span style="font-family: inherit;">
</span></h4>
<h4>
<span style="font-family: inherit;">
Fixes and more </span></h4>
<span style="font-family: inherit;">Since my last update I have managed to complete some more instructions and lots of bug fixes (thanks to <b>Philippe Ferrucci</b> and <b>Davide Palombo</b>, who insisted to demonstrate the JIT compiling at <i>Alchimie </i>and <i>Pianeta Amiga </i>shows, so I had to fix the most obvious bugs).</span><br />
<span style="font-family: inherit;">I don't want to bore you with the details regarding the current changes, have a look at <a href="https://sourceforge.net/p/euaeppcjit/code-0/39/">this update</a> if you are interested.</span><br />
<h4>
<span style="font-family: inherit;">
</span></h4>
<h4>
<span style="font-family: inherit;">
Source alignment</span></h4>
<span style="font-family: inherit;">Another important change was: I have merged the <b>final sources for E-UAE 0.8.29</b> over my changes.</span><br />
<span style="font-family: inherit;">Many thanks to <b>Michael Trebilcock</b> (MickJT) for driving my attention to the fact that I was using an outdated source version (0.8.29-WIP4) instead of the latest from the CVS (dated to 20/08/2008).</span><br />
<span style="font-family: inherit;">For the changes please have a look at these two updates: <a href="https://sourceforge.net/p/euaeppcjit/code-0/40/">original source</a>, <a href="https://sourceforge.net/p/euaeppcjit/code-0/44/">fix for audio</a>.</span><br />
<h4>
<span style="font-family: inherit;"> </span></h4>
<h4>
<span style="font-family: inherit;">
The LED (round#2)</span></h4>
<span style="font-family: inherit;">Philippe Ferrucci pointed out that sometimes it is hard to tell whether the JIT is available and working or not, in spite of the already available JIT LED.</span><br />
<span style="font-family: inherit;">He suggested that the LED might also indicate other states of the JIT compiling, and I had found that a really useful idea.</span><br />
<span style="font-family: inherit;">Now, you can identify three distinct states of the JIT compiling from the LED colors:</span><br />
<span style="font-family: inherit;">1. <b>Blinking green with "<i>JIT</i>" text on it:</b> JIT compiling is active and the compiled code is executed.</span><br />
<span style="font-family: inherit;">The level of green shows you how active is the JIT compiled code compared to the interpretive-executed. (Same as before.) </span><br />
<div class="separator" style="clear: both; text-align: center;">
<span style="font-family: inherit;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjG6PK9rrNRo2CB48vWFkKyRB6DyR4bnhKQusmFO8_cEzc5EWmgUE5SWd6zcOgLkPYKi3hyphenhyphenfz3PeJqjt-Lw5DFnbG2qUF_aQG0u0l33On-6ZpsuNNMKHtVa5an1FFRuBT3GCBX3_n8koKY/s1600/jit_led_on.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjG6PK9rrNRo2CB48vWFkKyRB6DyR4bnhKQusmFO8_cEzc5EWmgUE5SWd6zcOgLkPYKi3hyphenhyphenfz3PeJqjt-Lw5DFnbG2qUF_aQG0u0l33On-6ZpsuNNMKHtVa5an1FFRuBT3GCBX3_n8koKY/s1600/jit_led_on.png" /></a></span></div>
<span style="font-family: inherit;"><br /></span>
<span style="font-family: inherit;">2. <b>Solid red with "<i>JIT</i>" text on it:</b> the JIT compiling was set up, but the processor cache is turned off by the currently running software in the emulator, JIT compiling is not done while the cache is not turned on.</span><br />
<div class="separator" style="clear: both; text-align: center;">
<span style="font-family: inherit;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgZ3v-0dBRwctDxHZV1F6dsCogG-emeDgBU068svPu-0pJ617LOPA83mFbINNtWnm9URC4ZY9Q_8eDYhFT2qJFZaSwANHfdFlGaPN4YR_8dfOP4bDHkh4sVtnZ_3XnrDS8et5cHCP1fLNw/s1600/jit_led_off.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgZ3v-0dBRwctDxHZV1F6dsCogG-emeDgBU068svPu-0pJ617LOPA83mFbINNtWnm9URC4ZY9Q_8eDYhFT2qJFZaSwANHfdFlGaPN4YR_8dfOP4bDHkh4sVtnZ_3XnrDS8et5cHCP1fLNw/s1600/jit_led_off.png" /></a></span></div>
<span style="font-family: inherit;"><br /></span>
<span style="font-family: inherit;">3. <b>Solid black without "<i>JIT</i>" text on it:</b> due to the emulator configuration the JIT compiling is not available.</span><br />
<span style="font-family: inherit;">Either no code cache was set up or specified processor type does not support the processor cache.</span><br />
<div class="separator" style="clear: both; text-align: center;">
<span style="font-family: inherit;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgKaG4GkEF_uhcHaQuU0JATNn9DT6FUzSS6YlUl0xzZEFcQLdaI3tDAXlPqP03J2Ggy0zCi8kQ3tamLwSdR0ZWKdHuCusER-Ris7Zt8hIDSUE5WvDlQtRrjMbJWKIKfD86QIyxAwEpq0Hc/s1600/jit_led_unavail.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgKaG4GkEF_uhcHaQuU0JATNn9DT6FUzSS6YlUl0xzZEFcQLdaI3tDAXlPqP03J2Ggy0zCi8kQ3tamLwSdR0ZWKdHuCusER-Ris7Zt8hIDSUE5WvDlQtRrjMbJWKIKfD86QIyxAwEpq0Hc/s1600/jit_led_unavail.png" /></a></span></div>
<span style="font-family: inherit;"><br /></span>
<span style="font-family: inherit;"><br /></span>
<br />
<h4>
<span style="font-family: inherit;">
Some help needed</span></h4>
<span style="font-family: inherit;">Unfortunately, I have no idea how to compile the sources for other platforms than AmigaOS4. If you feel like you know enough about how to compile these sources <b>please get in touch with me</b>. I am looking for MorphOS, MacOSX PPC, Linux PPC versions especially, but any other supported platforms are welcome. (<i>Thunder? Tobias? Mike? </i>:)</span><br />
<span style="font-family: inherit;"><br /></span>
<span style="font-family: inherit;">If you feel like there is a bug and you want to report it badly then please <u><b>DO READ</b></u> the <i>How to report a bug</i> section from the <b>README </b>before you jump on your mail client. Thanks.</span><br />
<br />
<h4>
<span style="font-family: inherit;">
Final words</span></h4>
<span style="font-family: inherit;"><b>It is a good start for a year, isn't it?</b> I hope I can keep up and finally you can enjoy the benefits of the JIT compiling on your PowerPC machine.</span>Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com12tag:blogger.com,1999:blog-5052591504201077738.post-24150621076051640442013-12-25T14:49:00.001+13:002013-12-25T14:49:30.830+13:00Happy Holidays!<div style="text-align: center;">
<span style="font-size: large;">I wish Happy Holidays to all the Amigans around the globe!</span></div>
<div style="text-align: center;">
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<span style="font-size: large;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg2DXnaKghTND8wWYoKGb92f57qd3RedqI_DHLV8oDFXw9Rv1Eqp8UyZ-CR5KnejRsBFUCtmJbKN1zQ0x8MCQkHPgufnenyuAZh8DaJDbtPWkkWXFUw1_nUDVqAmgi3uispe_0Z07C3iP4/s1600/boing_xmas_tree.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="640" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg2DXnaKghTND8wWYoKGb92f57qd3RedqI_DHLV8oDFXw9Rv1Eqp8UyZ-CR5KnejRsBFUCtmJbKN1zQ0x8MCQkHPgufnenyuAZh8DaJDbtPWkkWXFUw1_nUDVqAmgi3uispe_0Z07C3iP4/s640/boing_xmas_tree.jpg" width="495" /></a></span></div>
<br />
<div class="separator" style="clear: both; text-align: center;">
</div>
<div style="text-align: center;">
<i>Are you still hoping for a late Santa? Wink, wink... ;)</i></div>
Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com2tag:blogger.com,1999:blog-5052591504201077738.post-49545016006873412682013-11-04T21:46:00.001+13:002013-11-04T21:46:23.717+13:00On a collision courseSo, where are we at with the recent <a href="http://sourceforge.net/p/euaeppcjit/code-0/38/">update</a>? 349 out of 387: no, it is not 100% yet, but a nice, fat <b>90.1%</b>!<br />
<br />
Quickly, what was done this time and let's jump to conclusions right after that:<br />
<ul>
<li>Implementation of BFINS Dx,Da{y,z}, BFFFO Dx{y,z},Da, BFEXTS Dx{y,z},Da, BFEXTU Dx{y,z},Da, BFCLR Dx{y,z}, BFTST Dx{y,z}, BFSET Dx{y,z}, BFCHG Dx{y,z}, ROXR.x Dy,Dz, ROXR.W mem, ROXR.x #imm,Dy, ROXL.x Dy,Dz, ROXL.W mem, ROXL.x #imm,Dy, ASR.W mem, ASL.W mem, LSR.W mem, LSL.W mem, ROR.W mem, ROL.W mem instructions.</li>
<li>Opcode compiler fucntions for different operation sizes are unified, unnecessary helper functions were removed.</li>
<li>Macroblock protos are generated from the opcode table file rather than used the manually prepared file.</li>
<li>Fixed wrong function name for the CNTLZW PowerPC instruction emitter.</li>
<li>Fixed missing input register in C and X flag extraction macroblock which is used in some shift instructions.</li>
<li>Fixed register dependency in ASR.x Dy,Dz and LSR.x Dy,Dz instructions.</li>
</ul>
<i>(Slightly unrelated: I have found a bug in the original E-UAE code for BFINS and flags, if I will have enough patience I will fix that. And another one in Petunia, that will be fixed too...)</i><br />
<br />
Now, we are getting dangerously close to the <b>beta stage</b>. It is really hard not to give you guys any promises what I cannot keep later on... (Summer is coming, you know... ;)<br />
<br />
Anyway, my plans for the near future (<i>read: when it is done</i>) are:<br />
<ol>
<li>After I have finished with the implementation of all instructions which were anticipated earlier I am going to stabilize the emulator a bit and clean up the code if needed.</li>
<li>I will try to release a compiled beta version and put together some documentation for using/testing it.</li>
<li>There are some outstanding issues, one of the most critical one is fixing the problems with the macroblock optimizer.</li>
</ol>
So much for the crystal ball and now... <br />
<h4>
Something completely different </h4>
I have to admit that my posts were not that interesting to read recently. Earlier I invested more effort into the posts and it was probably more fun to read, especially to the developers.<br />
I would like to bring back that tradition, so for this update I came up with a few interesting thoughts on:<br />
<br />
<b>How to avoid the decisions</b><br />
<br />
I know that many developers love to <i>procrastinate anything</i>, including (but not limited to) decisions. But what I am about to write is not how lazy my fellow developers are, but rather how to get around a situation <b>when it is not ideal to do a comparison and branch according to the result</b>.<br />
<br />
Why would that be important at all?<br />
There are a number of reasons why it is better to avoid branching, <a href="http://obligement.free.fr/articles_traduction/powerpc_singular_architecture_en.php">this article </a>lists many examples for that and also explains the reasons. It basically boils down to the following reasons:<br />
<ul>
<li>branching can cause <a href="http://en.wikipedia.org/wiki/Cache_miss#Cache_miss">cache misses</a>;</li>
<li>the branching instruction is a useless overhead and it can be even slow on certain architectures;</li>
<li>conditional branching disrupts the <a href="http://en.wikipedia.org/wiki/Instruction_pipeline">pipelining of the execution</a> (although there are <a href="http://en.wikipedia.org/wiki/Branch_predictor">pretty sophisticated techniques</a> available to deal with that).</li>
</ul>
In our case none of these reasons apply, but unfortunately <b>branching is not really possible due to the <a href="http://euaejit.blogspot.com/2012/04/foundations-of-house.html">static flow analysis</a> on the macroblock list</b>.<br />
<br />
To put it simply: each macroblock is depending on the results of the previously executed macroblocks, if we skip ahead then it is impossible to tell whether those required macroblocks were executed or not before the dependent macroblocks.<br />
<br />
Why does this cause any trouble? Because sometimes it is <b>pretty hard</b> to avoid conditions inside the instruction implementations.<br />
<br />
I already faced this issue earlier, when I started to work on the conditional branching and setting instructions (<i>Bcc </i>and <i>Scc</i>). There was no possible way to avoid the conditional branching for these instructions due to its very nature of the instructions.<br />
I ended up creating a very specific macroblock which embeds the condition checking and branching, so the "inter-macroblock" flow analysis remains intact.<br />
<br />
In the recent update you can find many <b>bit field instructions</b> which were complicated enough already and then the very same issue came up again:<br />
<br />
For bit field instructions 0 (zero) bit field width means 32 bit actually. This doesn't sound that bad, however sometimes the bit field width is coming from an emulated data register instead of a statically encoded constant. In this case the decision must be done in the emulated code instead of in compiling time.<br />
<br />
Not in every case, but quite often it is possible to <b>calculate the result </b>instead of making a comparison and branching.<br /><br />
For the bit field instructions the solution was (written in C code, just because it is easier to understand):<br />
<br />
<span style="font-family: "Courier New",Courier,monospace;">temp = width - 1;</span><br />
<span style="font-family: "Courier New",Courier,monospace;">width = width | (temp & 32);</span><br />
<br />
<i>(There is one condition, though: the width must be between 0 (zero) and 31 before this operation starts.)</i><br />
<br />
Now, think about it a little bit and figure out on your own why does it work. I am not going to explain it. :)<br />
<br />
See you soon.Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com7tag:blogger.com,1999:blog-5052591504201077738.post-4408182784111819112013-10-02T21:30:00.000+13:002013-10-02T21:30:19.779+13:00Back on trackFinally, I am back on track with the development after the house move. There were two updates since the last post; one was a <a href="http://sourceforge.net/p/euaeppcjit/code-0/36/">follow-up to the previous code refactoring</a>; the <a href="http://sourceforge.net/p/euaeppcjit/code-0/37/">other</a> was a massive list of improvements:<br />
<ul>
<li>Implementation of NEGX.x mem, NEGX.x Dy, SUBX.x -(Ay),-(Az), ADDX.x -(Ay),-(Az), MOVE CCR,mem, MOVE CCR,Dx, EOR #imm,CCR, OR #imm,CCR, AND #imm,CCR, RTR, MOVE mem,CCR, MOVE Dx,CCR, MOVE #imm,CCR, ASR.x Dy,Dz, RTD, MULU.W mem,Dx, MULU.W #imm,Dx, MULS.W mem,Dx, MULS.W #imm,Dx, SUBX.x Dy,Dz, ADDX.x Dy,Dz, MOVEM.x regs,mem, MOVEM.x mem,regs, MOVEM.x (Ay)+,regs, CMPM.x (Ax)+,(Ay)+ instructions.</li>
<li>Added dependency tracking for non-volatile PowerPC registers.</li>
<li>Fixed X flag handling in register-based shifting instructions, previously the X flag was cleared together with the C flag if the shift steps were zero.</li>
<li>Removed RTM from the list of the potentially supported opcodes.</li>
<li>Added RTR back to the list of the potentially supported opcodes.</li>
<li>Optimized temporary register usage in MULU.W Dx,Dy and MULS.W Dx,Dy instructions.</li>
<li>Introduced tracking of the extension words after the instructions, it is needed for adjusting the PC before certain addressing modes are processed.</li>
<li>Fixed register dependency and order of register storage for MOVEM.x regs,-(Ay) when direct memory access is enabled.</li>
<li>Implemented stack-like concept for register saving into the context.</li>
<li>Code cleanup: removed unused reference, fixed some warnings regarding misformatted and unused code lines.</li>
</ul>
So, things are getting together slowly. The number of the implemented instructions went up to <b>321</b> out of the planned 387! That is roughly <b>82%</b>... Getting closer and closer... :)<br />
<br />
Recently I faced an interesting problem, I am not quite sure how can I solve: <b>division by zero</b>. My beloved math teacher already told me: who is trying to divide by zero is an idiot. (Well, <a href="http://www.mathsisfun.com/calculus/limits.html">that is not quite right</a>, as we know it.) Yet, some programs might try it.<br />
Why is that a problem? Because it triggers an exception inside a compiled block. It also needs branching (skip the exception triggering if the divisor is not null, for a change) which contradicts the macroblock register flow tracking. Well, here is the challenge, but I am pretty sure I will solve it somehow.<br />
<br />
'Til then the usual: <b>watch this space</b>.<br />
<br />Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com3tag:blogger.com,1999:blog-5052591504201077738.post-71320879648667661552013-08-18T19:58:00.001+12:002013-08-18T19:58:48.925+12:00Moving stuff around<i>Long time no see!</i> No wonder: we just moved to a new house, which usually means lots of things to deal with and boxes wherever I look. (I hate this soo much! I badly need my daily routine, but how can I find my stuff?!) Finally, we are getting settled again and I was able to dig up the good ol' Amiga again under the pile of boxes. And this new house is just awesome, so it worth all the pain we went through.<br />
<br />
Interesting coincidence, but right before we started the whole move house craziness (seems like ages ago, BTW) I decided to refactor some code in E-UAE JIT. Namely the handling of the temporary registers.<br />
It was such a bad design, or rather no design at all: I used the number of the allocated temporary registers to index a couple arrays with the relevant data in it. Can you believe this? In 2013? This was unacceptable even in the '70s. There are so many reasons why you shouldn't do that.<br />
Also what is the point of using a strongly typed language, if we don't use distinct types? In this case all the temporary registers along with the actually mapped PowerPC processor registers are passed to the functions as integers. Very easy to misuse. Bad, bad, bad.<br />
<br />
In the <a href="http://sourceforge.net/p/euaeppcjit/code-0/35/">recent changes</a> I have managed to introduce the concept of a temporary register-specific type structure, which is also able to carry around the mapped PowerPC processor register number and the register dependency map for the macroblocks.<br />
<br />This new structure can be used when the macroblocks are collected (so mostly in the helper functions), but the code emitters for the macroblocks are dealing with the mapped PowerPC registers only. Now, I still need to solve that one: at the moment these are still passed to the functions as integers.<br />
<br />
And what is the visible output for you guys? Nothing, if we are lucky. ;)<br />
Yea, I know. It is always hard to justify the time to the business owners what was spent on solving <a href="http://en.wikipedia.org/wiki/Technical_debt">technical debts</a>. But this was a long outstanding one and I always had the itch of fixing it.<br />
<br />
So, enjoy your Summer while it lasts and bear with me.<br />
<br />Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com1tag:blogger.com,1999:blog-5052591504201077738.post-24857875732359948762013-06-30T19:38:00.000+12:002013-06-30T19:38:43.072+12:00The Hot and the ColdI just realized the last update was more than a month ago. Time flies, especially when we have fun, right? :)<br />
Well, we had some fun at least: a short holiday in the (unusually) hot Hungarian summer. <b>38 degrees Celsius</b>, it was almost unbearable for us after we got used to the cooler kiwi climate.<br />
Then we came back to the (unusually) cold New Zealand Winter. <b>8 degrees Celsius</b>, almost unbearable for us now. Hard to please, you might say. ;)<br />
<br />
Anyway, back to business: since I was barely here this month the <a href="http://sourceforge.net/p/euaeppcjit/code-0/34/">update</a> is less impressive than the last time. Yet, I managed to implement some more missing instructions:<br />
<ul>
<li>Implementation of ASL.x Dy,Dz, LSR.x Dy,Dz, LSL.x Dy,Dz, ROR.x Dy,Dz, ROL.x Dy,Dz, SUBA.x mem,Ay, SUB.x mem,Dy, SUBQ.x #imm,mem, SUB.x #imm,mem, SUB.x Dy,mem, SUBQ.x #imm,Ay, SUBQ.x #imm,Dy, SUB.x #imm,Dy instructions.</li>
<li>Removed not required TODO from ROL/ROR.x #imm, Dy instruction.</li>
</ul>
So, nothing much to see, move along.Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com3tag:blogger.com,1999:blog-5052591504201077738.post-2017856756137195062013-05-19T20:57:00.000+12:002013-05-19T21:03:06.016+12:00One small step for mankind, a giant leap for the projectI have no idea how did I manage to achieve this much in this <a href="http://sourceforge.net/p/euaeppcjit/code-0/33/">update</a>, but it is certainly a confident step forward. For this time the list is long and diversified:<br />
<ul>
<li>Implementation of Bcc.x addr, BCHG.B Dx,mem, BCHG.L Dx,Dy, BCLR.B Dx,mem, BCLR.L Dx,Dy, BRA.x abs, BSET.B Dx,mem, BSET.L Dx,Dy, BSR.x abs, BTST.B #imm,mem, BTST.B Dx,#imm, BTST.B Dx,mem, BTST.L Dx,Dy, CMP.x #imm,mem, CMP.x mem,Dy, CMP.x reg,Dy, CMPA.L reg,Ax, CMPA.W reg,Ax, CMPA.x mem,Ay, DBF.W Dx,addr, EOR.x #imm,mem, JMP.L abs, JMP.L mem, JSR.L abs, JSR.L mem, NEG.x mem, NOT.x mem, RTS, TAS.B Dx, TAS.B mem instructions.</li>
<li>Cache invalidation fix for OSX 10.3.9 and below. (Thanks to <b>Mike Blackburn</b> again.)</li>
<li>Fixed mask handling in BCHG.B Dx,mem instruction.</li>
<li>Fixed missing register mapping in ASL.x #imm,Dy implementation.</li>
<li>Fixed input dependency overwriting in certain memory-related allocation functions.</li>
<li>Fixed dependency for destination memory pointer register in special memory reading.</li>
<li>Fixed post address handler for condition code addressing modes, previously it might crash or call some random handler from the other addressing modes.</li>
<li>Fixed instructions where temporary registers are allocated but not free'ed.</li>
<li>Optimized masking for register to register bit instruction.</li>
<li>Optimized the temporary register usage in helper_test_bit_register_register function.</li>
<li>Optimized flag extraction in several shifting operation.</li>
<li>Branch scheduling is more flexible: adding multiple interleaved branches is possible.</li>
<li>Comment on missing implementation for an exception on loading odd address into PC.</li>
</ul>
<h3>
A few highlights</h3>
First of all, let me brag around a little bit about the number of freshly implemented instructions. Right now <b>237 </b>instructions are implemented out of <b>388</b>,<b> a solid 61% is done</b>. (<a href="http://euaejit.blogspot.com/2013/04/locations-locations-locations.html">Previously</a> the ratio was ~46%.) <br />
<br />
More MacOSX versions are supported now, Mike fixed up the cache flushing a little bit and added <b>the pre-10.4 versions</b> too. <i>Please read the included README file regarding the compiling instructions.</i><br />
<br />
While I was working on the instructions I discovered a few bugs and glitches, which are now fixed in this release thus improving the overall stability.<br />
<br />
I have also managed to optimize the compiled code for some instructions. Together with the implementation of some yet missing instructions the results for the Mandelbrot test (<i>mandel_though_hw.kick.gz</i> among the <a href="http://sourceforge.net/projects/euaeppcjit/files/m68k_testfiles/">test kick files</a>) improved a bit compared to the <a href="http://euaejit.blogspot.com/2012/08/optimize-it.html">previous results</a>:<br />
<br />
<b>Interpretive: 108 seconds (no change there...);</b><br />
<b>JIT compiled without optimization: 44 seconds (previously it was 52 seconds);</b><br />
<b>JIT compiled with optimization: 27 seconds </b><b><b>(previously it was 32 seconds)</b>.</b><br />
<br />
That was the time for the self-polishing and now back to work...<br />
<br />Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com15tag:blogger.com,1999:blog-5052591504201077738.post-69407162139836234942013-04-28T20:28:00.001+12:002013-04-28T20:28:05.733+12:00Locations, locations, locationsIn the last month I was trying to hang on my sanity while we were on house-hunting in Auckland (nuff' said). Wasn't easy and apparently it is not even close to be finished. :/<br />
<br />
Anyway, I managed to do some work on the E-UAE JIT in the stolen moments.<br />
<br />
In the <a href="http://sourceforge.net/p/euaeppcjit/code-0/32/">update</a> for this month you will find these little eggs:<br />
<ul>
<li>Implementation of ADD.x Dy,mem, ADD.x mem,Dy, ADD.x #imm,mem, ADDA.x mem,Ay, ADDQ.x #imm,mem,<br />AND.x mem,Dy, AND.x reg,mem, ANDI.x #imm,mem,<br />BCLR.B #imm,mem, BCHG.B #imm,mem, BCHG.L #imm,reg, BSET.B #imm,mem,<br />NEG.x Dy,<br />OR.x Dy,mem, OR.x mem,Dy, ORI.x #imm,mem,<br />UNLK.x Ay instructions.</li>
</ul>
<ul>
<li>Fixed unintended modification of the source register for some register to memory operations.<br /> </li>
<li>Memory read helper tweaked to use R3 register as the result register, no need to copy the data back-and-forth. (More optimal compiled code.)<br /> </li>
<li>Memory reader and writer helper function cleaned up to be more independent from caller data.</li>
</ul>
It might seem a bit random how I choose which instructions are implemented, but there is always a recurring theme. Right now this theme was the memory access. As you can see most of these instructions are manipulating the memory, which was a little bit scary earlier but I came around creating some functions which can be reused for (almost) all memory accessing instructions.<br />
The tricky part was accessing the memory while the allocated temporary registers remain accessible somehow. With a minor workaround for saving and occasionally reloading the temporary registers after the memory access this is solved now.<br />
<br />
I am not too happy about how the whole register mapping works, unfortunately there are some limitations of the C language which makes it complicated to come up with a more robust solution. So, right now the whole thing is just a bit hacky and wacky. Maybe in the future it would need an overhaul.<br />
<br />
I get the question most of the times:<b> how many instructions are left to implement</b>. There is an easy way to find out the progress: check the <span style="font-family: "Courier New",Courier,monospace;">table68k_comp</span> descriptor file.<br />
Each (to be) supported instructions for the JIT compiling is already listed there, next to the name of the instruction there is a number: 0 or 1. The 1 means it is already done, 0 remains to be implemented.<br />
The instructions which will not be supported by the JIT compiling (so the interpretive will handle these) are not listed in this file.<br />
<br />
So, all we need to do is counting the instructions which are already supported and what remains to be done. The current state without the FPU instructions is: 181 is done out of 388 (~46% is done).<br />
As you can see there is more work to do, but it is really hard to tell how long does it take. What I can see is that the time I have to spend with each instruction is shorter and shorter, due to the infrastructure which had to be built first but now it is mostly done. Also some instructions are very similar, I can simply reuse parts of an already finished instruction.<br />
<br />
We are not there yet, but the donkey is not that stubborn anymore. Giddy-up buddy!<br />
<br />Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com4tag:blogger.com,1999:blog-5052591504201077738.post-35334336040203337622013-04-24T19:45:00.001+12:002013-04-24T19:57:06.092+12:00Mac and cheese... err... LinuxBig thanks to <b>Mike Blackburn</b> for some fixes for the Macintosh support and for implementing the <b>Linux PPC</b> support! Well done, Mike.<br />
<br />
After <a href="http://sourceforge.net/p/euaeppcjit/code-0/30/">this</a> (and <a href="http://sourceforge.net/p/euaeppcjit/code-0/31/">this</a>) update Mac OSX 10.4 is supported too: the instruction cache flush needed a different implementation.<br />
<br />
Also Linux PPC users can benefit from the PowerPC JIT.<br />
<br />
The more the merrier.Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com0tag:blogger.com,1999:blog-5052591504201077738.post-60619681779112753102013-04-01T21:42:00.000+13:002013-04-01T21:42:17.710+13:00After another bump on the bumpy roadI have spent some time fixing bugs and improving the performance of the compiled code and the JIT emulation overall. As a result here is the <a href="http://sourceforge.net/p/euaeppcjit/code-0/29/">recent update</a>:<br />
<ul>
<li>Implementation of TST.x mem, NOT.x Dy, EXT.x Dy</li>
<li>Reverted the change for stopping the compiled block when the special flag is set. This change is not needed for the Kickstart and it doesn't seem to have any effect, but slows down the compiled code.</li>
<li>Removed hack for MOVE.z Ax,-(Ax) and MOVE.z Ax,(Ax)+ instruction implementations.</li>
<li>Fixed pre-decrement and post-increment addressing modes for destination. Re-enabled MOVE.x mem,mem and EOR.x reg,mem instructions, which were disabled previously to let the Kickstart running without the addressing mode fixes.</li>
<li>Fixed register dependency in some memory addressing modes.</li>
<li>Temporarily removed checking for the tiny blocks, ignoring these blocks is just not the right solution for avoiding the overhead of block calling.</li>
<li>Added ignoring blocks of pure unsupported instructions: these will be executed by the interpretive emulation.</li>
<li>Fixed blocking of small blocks, the block was not raised in the cache list.</li>
</ul>
Lots of small changes and fixes as you can see.<br />
<br />
Probably, the most important fix was the one for the <i>pre-decrement</i> and <i>post-increment</i> addressing modes, this was blocking the Kickstart for a while from booting and this is why I had to remove the support of those two instructions I mentioned in the changes list.<br />
As it turned out the root of this bug was a limitation of the implementation. Each addressing mode has two compiler function: one is called before the instruction compiling, one is called after that. But the situation is not always that simple, for example in this case:<br />
<br />
<span style="font-family: "Courier New",Courier,monospace;">MOVE.L (A7),-(A7)</span><br />
<br />
This is a common instruction for copying the memory to a lower address (like moving the content of an array one step toward the beginning, in this case the content of the stack). Seems so innocent, isn't it? :)<br />
Why this one was an issue: the handler for the destination address is called <i>before </i>the instruction and since it is a destination addressing mode it decremented the address in the emulated A7 register. But then the instruction was compiled, which used the address from the A7 register as a source. So, what actually happened was something like this:<br />
<br />
<span style="font-family: "Courier New",Courier,monospace;">MOVE.L -(A7),(A7)</span><br />
<br />
Now you can see: this operation is (mostly) pointless, it copies the data from the one address to the same address. (Although, sometimes it might make sense in the communication with the hardware, but this wasn't the case right now, obviously.)<br />
<br />
What was the fix? Pretty simple: I moved the destination address modification to the address handler which is executed <i>after </i>the instruction was compiled. This was a solution for this specific case, but I also had to make sure that all the other combinations are working which might be possible with the indirect addressing. One of the trickiest was:<br />
<br />
<span style="font-family: "Courier New",Courier,monospace;">MOVE.L (Ax)+,(Ax)</span><br />
<br />
You can try to guess why. :)<br />
<br />
Anyway, finally this bug is out of the way and I can go on with implementing the missing instructions. Some of them are done, but yet lots to go.<br />
<br />
There was one more important change in this update: I removed the limit for the consecutive block length when a special condition was triggered by some instruction. I found it completely pointless, everything seems to be working without this condition. There was a bad side-effect of this limit: after an instruction triggered a special condition for the emulation all the following instructions are compiled one-by-one into separate blocks. The overhead for calling these tiny blocks was huge, this is why I introduced the rule of ignoring any block which was smaller than 3 instructions. But in this case lots of the code was not JIT compiled at all. (As some of you guys mentioned: the JIT LED was mostly dark - lots of blocks were not compiled.) This is fixed now, although I am a bit afraid of the side-effect of delaying the handling of the special conditions. We will see how it goes.<br />
<br />
I also spent some time on updating my old tool: <a href="http://os4depot.net/?function=showfile&file=utility/filetool/diskdaisy.lha">DiskDaisy</a>. The recent updates for AmigaOS4.1 triggered a bug in that app. Sometimes it is nice doing something completely different for a while, you know. :)Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com14tag:blogger.com,1999:blog-5052591504201077738.post-67091168328959582722013-02-21T19:38:00.004+13:002013-02-21T19:39:53.019+13:00After the second yearWell, here we are again. Another year had passed - namely the second - since I started the project.<br />
<br />
Obviously, it is not done yet, otherwise you would see Dancing Bananas around the blog. But we are slowly getting there. There are outstanding bugs and yet a fair share of work is to be done.<br />
Since we passed the first year I gave up giving any estimate on how long will this take. As it seems I am pretty bad in estimates. Yet I hope that <b>third is the charm</b>! :)<br />
<br />
Until then: <b>Keep calm and Amiga On!</b>Álmos Rajnaihttp://www.blogger.com/profile/13385962754685794358noreply@blogger.com11