Posts Tagged ‘assembly’

Itanium tutorial

May 12, 2010 in Personal | Comments (0)

Tags: , ,

I’ll make a research-​​oriented entry before long; I prom­ise. I’m start­ing to get towards writ­ing up some of the cool stuff in my thesis.

I’ve star­ted writ­ing an Itanium tutorial. That doc­u­ment will magic­ally update every now and then as I write more. On the one hand it’s slightly embar­rass­ing how much I’ve writ­ten — it’s almost half as much as I’ve writ­ten for my thesis so far — but it’s an entirely dif­fer­ent kind of writ­ing. There’s really no rigour at all to it. I don’t have to worry about prov­ing things or cit­ing things; I’ve never proofread any of it. I just write whatever pops into my head, which makes it very quick and easy. Primar­ily it’s for my bene­fit, so I don’t for­get any­thing and so that it forces me to fig­ure things out more con­cretely than I would otherwise.

(more…)


Itanium in possession!

May 3, 2010 in Personal,Research | Comments (0)

Tags: ,

This is a follow-​​up to this post. Mark was mag­nan­im­ously amaz­ing and bought an Itanium machine for “the lab”. It’s cur­rently sit­ting in my apart­ment. I’ll make another post tomor­row, I expect, where I actu­ally get to play with it prop­erly, but I thought at the very least I’d make a post about the head­aches of actu­ally get­ting it working.

Go through the pic­tures and read the run­ning com­ment­ary because I’m not going to repeat the pic­tures here.

Sadly the machine is noisy and relatedly prob­ably quite a power sucker. It’s in the corner of the liv­ing room, not far from where Jasna’s office is so I’m not going to be able to leave it on very often, I don’t think. The noise would prob­ably drive Jasna crazy.

I should say I still haven’t got a chance to really sit down and play with it — namely play with the assem­bler — like I planned because HP-​​UX needs so much more set­ting up. I’m going to have to install pretty well the entire GNU user­land because HP’s user­land is abso­lute garbage.


Itanium

April 6, 2010 in Personal,Research | Comments (5)

Tags: , ,

Yes, I’m a com­puter archi­tec­ture nerd. I expect this won’t sur­prise anyone.

The recent story on Microsoft end­ing sup­port for Itanium (side note: this is hardly news. No one ran Win­dows on Itanium in the first place) rekindled my love affair with the Itanium archi­tec­ture. Every six to twelve months I become infatu­ated with it all over again.

My infatu­ation usu­ally dies down when I real­ize the Itanium is out of reach for mere mor­tals. Some­times I day dream about when I’ve acci­dent­ally stumbled into money and I’m able to afford one. It’s hard to find a new Itanium server for under $30k and play­ing around with the online con­fig­ur­at­ors it’s not hard to run your­self into the half a mil­lion dol­lar range.

Today’s dif­fer­ent, though: today I decided to check out Ebay. Used Itanium serv­ers are actu­ally very cheap. Here’s one for $340. It’s only about 6 or 7 years out-​​of-​​date, too. Being out-​​of-​​date with Itanium isn’t such a big deal since they were never in-​​date to begin with. The pro­spect that I might be able to buy myself one as a gradu­ation present — when I have time to play with it — is exciting.

I won’t bore you with the details of Itanium and why it failed in its prom­ise to be the next big saviour, the one com­puter archi­tec­ture to bind them all. I was actu­ally going to write about why I love the Itanium so much, but before I knew it I’d writ­ten six para­graphs about how beau­ti­ful the archi­tec­ture is and real­ized no one but me would ever care to read it. Suf­fice it to say it’s the nicest archi­tec­ture I’ve ever seen, from the per­spect­ive of someone who truly enjoys writ­ing assembly code, the per­fect bal­ance between expos­ing the archi­tec­ture and hid­ing away the mundane details that some­time plagued RISC archi­tec­tures. Whenever someone fool­ishly asks me about Itanium — don’t worry, I’m usu­ally able to restrain myself — I describe it as “everything SPARC should have been”, SPARC being one of the more eleg­ant RISC archi­tec­tures to date.

For my pur­poses it doesn’t mat­ter if Itanium is prac­tical or pop­u­lar or well-​​fabricated or none of the above since it’s just for my own enjoy­ment. One of the biggest prob­lems is that no one’s man­aged to write a suit­able com­piler for it. That suits me just fine since I’d rather be writ­ing assembly code by hand or writ­ing my own com­piler for it. I’m actu­ally half con­vinced that if any­one actu­ally is going to write a bril­liant com­piler for Itanium, one that intel­li­gently takes advant­age of all its spec­u­lat­ive loads and rotat­ing register win­dows and sim­ilar toys that I like to drool over, it’s going to be a com­piler that has a ser­i­ous leg up in static ana­lysis, maybe for a lan­guage that’s been ser­i­ously restric­ted, for which my research would be appropriate.

Well I’m not so arrog­ant as to think that I can write a com­piler for Itanium where so some of the world’s top back-​​end developers have failed before. Even if fail­ure is nigh guar­an­teed, it would be a really fun chal­lenge, and it’s always more fun when the chal­lenge is inher­ent in the beauty of what you’re work­ing with. I think I may have to ser­i­ously put aside a few hun­dred dol­lars for after gradu­ation so I have this to play with.


New 256 byte demo

September 10, 2009 in Personal | Comments (0)

Tags:

I des­per­ately miss the demo­scene. Towards the end of the 1990s when per­sonal com­puters got power­ful enough to do, well, just about any­thing, I star­ted turn­ing my interests else­where. It’s still alive, though, and pick­ing up some amaz­ing coders. The latest jaw-​​dropping demo to be released is a 256 byte demo from Řrřola, a coder in the Czech Repub­lic. Here’s the You­tube ver­sion of it for those of you that don’t have DOS installed:

This is one of the most tech­nic­ally impress­ive demos I’ve ever seen in my life. What he’s done should be flat-​​out impossible to do in 256 bytes. As a red­dit com­ment poin­ted out, tak­ing a single screen­shot of the demo in action will yield a file 96 times lar­ger than the demo itself. A simple “hello world!” writ­ten in SPARC assembly, as taught by our uni­ver­sity, is over 2.6 times as large than this demo (2.59 times as large if you’re clever about filling delay slots). Hell it takes over 1/​20 the size of this demo just to rep­res­ent the string “hello world!”. From an inform­a­tion the­ory it boggles the mind that that video can effect­ively be com­pressed down to 256 bytes.

Any­way, if all of this weren’t excit­ing enough, it gets even more excit­ing due to the fact that he’s released the source code. More excit­ing still is the fact that the com­ments are writ­ten in (very clear) Eng­lish instead of Czech. I don’t think it will be pos­sible for me to res­ist fig­ur­ing out how he did this. Parts like this:

  push 09FCEh   ;<aligns with the screen ;-)
  pop  es
  mov  bh,56h   ; xyz addressing trick from neon_station
                ; vecNN = (words){[5600h+N] [5656h+N] [56ACh+N]}
;frame loop - prepare constants
;ax=key bx=5600h bp=dx=0 cx=3 si=100h di=-2 sp=-4 word[5700h]=T

are going to have me stumped for a long while, I think, but I’m pretty psyched about it. Tak­ing a quick 5-​​minute pass through the source code I under­stand a sur­pris­ingly large amount of it, just not the parts that really count. Tra­cing through it sort of brings me back to my demo­scene days, except now I have the lux­ury of going through source code instead of try­ing to deal with DOS Debug. One of my first thoughts read­ing through this was “he’s using float­ing point instruc­tions? That’s so cheat­ing. Who has the money for a math co-​​processor‽”