Age/Gender: 19, Male
Location: concave boxes
Job: chivalrous knight
i am the planetary destroyer. go away.
Newgrounds Stats
Whistle Status: Normal
Exp. Points: 945 / 1,110
Exp. Rank #: 38,662
Voting Pow.: 5.19 votes
BBS Posts: 3,101 (1.27 per day)
Flash Reviews: 36
Music Reviews: 0
Trophies: 0
Stickers: 0
Latest News
For all the Java people out there, you might be surprised to know you're going to get Phasers in the future. Get ready for battle. Unfortunately, Proton Torpedo's didn't make the cut. Sorry.
On a side note, I've been working on a little virtual machine. So far, it is incomplete although there is only 1 part left to do before I probably make a 0.1 release, it works.
Documentation on the overall structure of the virtual machine and some benchmarks are here:
http://thoughtpolice.stringsandints.co m/misc/vm_notes.html
From the benchmarks, you can see it runs FizzBuzz 10,000,000 times in about 12 seconds when compiled with gcc -O3 -fomit-frame-pointer and when there's no output buffering to cause an I/O bottleneck. If compiled with output enabled, there are almost no speed improvements regardless of compiler flags since printf takes most of the time.
The resulting code of the VM when using gcc -O3 is quite desirable and efficient since it (largely) eliminates branch misprediction using direct jumps to register values, while instead there are just a lot of 'jne/je' instructions if compiled with say, -O0 or -O1.
I'm probably going to code up a C version of fizzbuzz without output as well to see how it compares to native C. I expect to be dominated.
Addendum: I wrote an C program equivalent to my example bytecode program - or as close as I could get it. Excellent results: With gcc -O3 -fomit-frame-pointer it can do 10,000,000 iterations in approximately a half a second. Major smackdown, right there.
I'll probably be blogging on my other blog about this in the future, in case you want to keep track of it.
All News Posts 6 comments | Log in to comment! | Share this!