Wednesday, March 3, 2010

blupdate

You know... like blog and update in one word.... whatever.


Again, I have nothing fancy to tell.
Wanted to work on my assembler-program since I actually wanted to have a working prototype by tomorrow and completely forgot about it, but instead I wasted have of my time playing Call of Duty 2.
I have the basic flesh of the assembler done, now I only need to implement the pseudo-Ops (probably the hardest :P) and decent file parsing. I don't think my current one works fine, even under the circumstances that I didn't spend enough time with it.


I also wanted to code a lock-free queue for ViruZ, so I can easily implement my different looping-method (one thread renders, others update), but I did something wrong and now it only draws one virus :P
A lock-free queue is basically a queue you can do stuffs on without having to wait for other operations to finish.
You need to wait for other operations to finish if you're working with threads sharing data, as the possibility exists that one thread might read some data while the other one is writing to it at the same time. And that can be catastrophic.
A queue is like a waiting-line you know in real-life. You can stack various stuff into it and the first thing that got in is the first thing that's going to get out. The last thing in will be the last thing out.

I have another algorithm for the lock-free queue in mind, though it's a bit more complex. Dunno if I will bother as I don't know if this even is a bottleneck in my code.


I've also read some stuff about shaders in OpenGL and I'm ready to give my first shader a try. I just need to find some time.
When I begin implementing OpenGL and using that as my rendering-backend things should get faster by themselves.


Oh, I also created the tag 'ViruZ' and added it to all my ViruZ-related posts.

No comments: