Slashdot Mirror


Reverse Engineering IRIX Multithreading For NetBSD

Anonymous Coward writes "Onlamp.com publishes the sixth paper of Emmanuel Dreyfus's series on NetBSD's IRIX binary compatibility implementation. This time, this is about reverse engineering IRIX multithreading and the odd virtual memory features involved with it. It's an adventure at kernel and userland boundaries, with a debugger as the sole weapon. A must read!"

32 comments

  1. TIMOTHY by Anonymous Coward · · Score: -1, Troll

    Stop ignoring me! I really do love you! Just because I say dirty things in public doesnt mean I think less of you! C'mon, lets get together for a nice dinner and I'll eat your butt out later. It'll be fun!

    Love you

    *giggle*

  2. This sounds like fun by Anonymous Coward · · Score: 0

    Nothing is more fun than reverse engineering multithreading! Sounds so totally easy too. I want in! Oh please let me reverse engineer mulitthreading!

  3. IRIX? by cpeterso · · Score: 1


    ok, so SGI is moving from IRIX to Windows and Linux. So how many IRIX users will be transitioning from IRIX to NetBSD?

    1. Re:IRIX? by Anonymous Coward · · Score: 1, Informative

      ok, so cpeterso hasn't been paying attention for the past couple years. Windows is no more at SGI, and Linux is only on Itanium Origins / Altix at the moment, and no indication (at the moment) that it's going anywhere else. Non-hobbyist (except perhaps the most quirky commercial-type) IRIX users will not be transitioning to NetBSD until NetBSD has the graphics and scaleability capabilities that they require.

    2. Re:IRIX? by zzyp · · Score: 1

      What's the point of doing IRIX compat anyway? Not many IRIX users, and is it useful?

    3. Re:IRIX? by vesamies · · Score: 0

      about 1000000... waiting for 20 seconds to pass...

    4. Re:IRIX? by fyonn · · Score: 4, Insightful

      remember this isn't the commercial software world. no-one's been tasked with providing irix compatibility. someone's doing it because they want it and thats reason enough, isn't it?

      dave

    5. Re:IRIX? by Anonymous Coward · · Score: 2, Insightful

      I think most of Slashdot contributors miss the article point: it is not an advertising for running NetBSD instead of IRIX, it is a technical paper on the actual implementation and the reverse engineering techniques used to reveal IRIX undocumented secrets.

      IRIX binary compatibility is not sexy, indeed. But IMHO, the tricks exposed in the paper are quite interesting. There is not that much documentation on kernel programming and reverse engineering available around there.

    6. Re:IRIX? by Anonymous Coward · · Score: 0

      I just put NetBSD on two old Indigo2's this weekend.

    7. Re:IRIX? by Anonymous Coward · · Score: 0

      And do you plan to try out IRIX binary compatiblity?

    8. Re:IRIX? by Anonymous Coward · · Score: 0

      Hobbiests, academics, researchers, even IT staff who have older SGI machines would be interested in this. They may wish to run current software for server or workstation purposes, but are having trouble with some software running on IRIX. They may be having trouble maintaining IRIX on MIPS hardware. Yet they may want to run some non-open source software as well - this is likely to be software that is only compiled for IRIX/MIPS, not for NetBSD/MIPS. More importantly, it is a great excercise for improving both the NetBSD kernel and the NetBSD kernel programmers! And best of all, it improves the Swiss Army Knife qualities of NetBSD!

  4. Doubtful IMHO by BuBu_ · · Score: 1

    I doubt very many will. Don't forget, just because it has the bin compat. doesn't mean that SGI won't be porting all of their good solid IRIX apps. over to their Linux distros. I'd say that if anything, most IRIX guys are going to be heading to Linux in the future, if SGI is definte on phasing out IRIX (ie I haven't read up on it at all). NetBSD's bin compat. with IRIX is going to be quite useful because hopefully it will let some other people cut their teeth on IRIX apps. that might not have access to an actual IRIX machine.

    1. Re:Doubtful IMHO by LizardKing · · Score: 1

      hopefully it will let some other people cut their teeth on IRIX apps. that might not have access to an actual IRIX machine.

      Note that this effectively maps IRIX system calls to NetBSD ones, but you're still going to have to run this on a suitable MIPS machine.

      Chris

  5. Eeer, Should of been a reply to cpeterso's post. by BuBu_ · · Score: 1

    topic.

  6. *BSD is dying by Anonymous Coward · · Score: -1, Flamebait
    It is official; Netcraft now confirms: *BSD is dying

    One more crippling bombshell hit the already beleaguered *BSD community when IDC confirmed that *BSD market share has dropped yet again, now down to less than a fraction of 1 percent of all servers. Coming on the heels of a recent Netcraft survey which plainly states that *BSD has lost more market share, this news serves to reinforce what we've known all along. *BSD is collapsing in complete disarray, as fittingly exemplified by failing dead last in the recent Sys Admin comprehensive networking test.

    You don't need to be a Kreskin to predict *BSD's future. The hand writing is on the wall: *BSD faces a bleak future. In fact there won't be any future at all for *BSD because *BSD is dying. Things are looking very bad for *BSD. As many of us are already aware, *BSD continues to lose market share. Red ink flows like a river of blood.

    FreeBSD is the most endangered of them all, having lost 93% of its core developers. The sudden and unpleasant departures of long time FreeBSD developers Jordan Hubbard and Mike Smith only serve to underscore the point more clearly. There can no longer be any doubt: FreeBSD is dying.

    Let's keep to the facts and look at the numbers.

    OpenBSD leader Theo states that there are 7000 users of OpenBSD. How many users of NetBSD are there? Let's see. The number of OpenBSD versus NetBSD posts on Usenet is roughly in ratio of 5 to 1. Therefore there are about 7000/5 = 1400 NetBSD users. BSD/OS posts on Usenet are about half of the volume of NetBSD posts. Therefore there are about 700 users of BSD/OS. A recent article put FreeBSD at about 80 percent of the *BSD market. Therefore there are (7000+1400+700)*4 = 36400 FreeBSD users. This is consistent with the number of FreeBSD Usenet posts.

    Due to the troubles of Walnut Creek, abysmal sales and so on, FreeBSD went out of business and was taken over by BSDI who sell another troubled OS. Now BSDI is also dead, its corpse turned over to yet another charnel house.

    All major surveys show that *BSD has steadily declined in market share. *BSD is very sick and its long term survival prospects are very dim. If *BSD is to survive at all it will be among OS dilettante dabblers. *BSD continues to decay. Nothing short of a miracle could save it at this point in time. For all practical purposes, *BSD is dead.

    Fact: *BSD is dying

    1. Re:*BSD is dying by Anonymous Coward · · Score: -1

      Funny how *BSD is dying yet the US Military uses it and is now helping fund it because nothing else compares.

  7. The Truth Comes Out: The End of FreeBSD by Anonymous Coward · · Score: -1, Flamebait
    The End of FreeBSD

    [ed. note: in the following text, former FreeBSD developer Mike Smith gives his reasons for abandoning FreeBSD]

    When I stood for election to the FreeBSD core team nearly two years ago, many of you will recall that it was after a long series of debates during which I maintained that too much organisation, too many rules and too much formality would be a bad thing for the project.

    Today, as I read the latest discussions on the future of the FreeBSD project, I see the same problem; a few new faces and many of the old going over the same tired arguments and suggesting variations on the same worthless schemes. Frankly I'm sick of it.

    FreeBSD used to be fun. It used to be about doing things the right way. It used to be something that you could sink your teeth into when the mundane chores of programming for a living got you down. It was something cool and exciting; a way to spend your spare time on an endeavour you loved that was at the same time wholesome and worthwhile.

    It's not anymore. It's about bylaws and committees and reports and milestones, telling others what to do and doing what you're told. It's about who can rant the longest or shout the loudest or mislead the most people into a bloc in order to legitimise doing what they think is best. Individuals notwithstanding, the project as a whole has lost track of where it's going, and has instead become obsessed with process and mechanics.

    So I'm leaving core. I don't want to feel like I should be "doing something" about a project that has lost interest in having something done for it. I don't have the energy to fight what has clearly become a losing battle; I have a life to live and a job to keep, and I won't achieve any of the goals I personally consider worthwhile if I remain obligated to care for the project.

    Discussion

    I'm sure that I've offended some people already; I'm sure that by the time I'm done here, I'll have offended more. If you feel a need to play to the crowd in your replies rather than make a sincere effort to address the problems I'm discussing here, please do us the courtesy of playing your politics openly.

    From a technical perspective, the project faces a set of challenges that significantly outstrips our ability to deliver. Some of the resources that we need to address these challenges are tied up in the fruitless metadiscussions that have raged since we made the mistake of electing officers. Others have left in disgust, or been driven out by the culture of abuse and distraction that has grown up since then. More may well remain available to recruitment, but while the project is busy infighting our chances for successful outreach are sorely diminished.

    There's no simple solution to this. For the project to move forward, one or the other of the warring philosophies must win out; either the project returns to its laid-back roots and gets on with the work, or it transforms into a super-organised engineering project and executes a brilliant plan to deliver what, ultimately, we all know we want.

    Whatever path is chosen, whatever balance is struck, the choosing and the striking are the important parts. The current indecision and endless conflict are incompatible with any sort of progress.

    Trying to dissect the above is far beyond the scope of any parting shot, no matter how distended. All I can really ask of you all is to let go of the minutiae for a moment and take a look at the big picture. What is the ultimate goal here? How can we get there with as little overhead as possible? How would you like to be treated by your fellow travellers?

    Shouts

    To the Slashdot "BSD is dying" crowd - big deal. Death is part of the cycle; take a look at your soft, pallid bodies and consider that right this very moment, parts of you are dying. See? It's not so bad.

    To the bulk of the FreeBSD committerbase and the developer community at large - keep your eyes on the real goals. It'

  8. Elegy for *BSD by Anonymous Coward · · Score: -1, Flamebait

    Elegy For *BSD


    I am a *BSD user
    and I try hard to be brave
    That is a tall order
    *BSD's foot is in the grave.

    I tap at my toy keyboard
    and whistle a happy tune
    but keeping happy's so hard,
    *BSD died so soon.

    Each day I wake and softly sob
    Nightfall finds me crying
    Not only am I a zit faced slob
    but *BSD is dying.

    1. Re:Elegy for *BSD by more+fool+you · · Score: 0, Offtopic
      good poets can spell eulogy
      therefore you are not a good poet

      can anyone tell i've been programming prolog? (prolog is dead blah blah blah)

    2. Re:Elegy for *BSD by Anonymous Coward · · Score: -1, Flamebait

      Hey, you dumbass motherfucker, elegy is a word. See here for proof. Don't fucking post if you don't know what the shit you're talking about. Assholes like you are what's wrong with Slashdot. Go back to sucking Taco's cock and stfu. plzdiekthxbye!

  9. no offense, but... by BortQ · · Score: 0, Flamebait
    A must read!
    hahahahahahahahahahaha. I think not.
    --

    A Multiplayer Strategy Game for Mac OS X, Windows, and Linux
    1. Re:no offense, but... by Anonymous Coward · · Score: -1, Troll

      Hey, FUCK YOU

  10. NEW GUIDE: OPENBSD FOR FAGS by Anonymous Coward · · Score: -1, Troll

    OH WAIT OPENBSD ALREADY IS FOR FAGS.
    THEO TAKES IT IN THE POOPER HOLE PEOPLE.
    text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio.
    text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio .
    text added to fuck with caps ratio text added to fuck with caps ratio text added to fuck with caps ratio .
    asdfasd homo homo errotica flaming anus wedge
    i will defeat these filters

  11. Some people are missing the point. by LizardKing · · Score: 3, Insightful

    Slashdot's usual bunch of Linux fanboys are missing the point of these articles. So SGI might move to Linux and might drop IRIX. They might port there apps to Linux (their developers are certainly experienced enough). However, SGI's future operating system strategy has little bearing on NetBSD.

    NetBSD has a strong following in the academic world (I'm talking about researchers and postgrads here, not undergrads running Linux file sharing apps in their dorm). The BSD license, along with clear and well documented source make Net an ideal choice for academic work. However, a lot of cutting edge work takes place outside academia, often in companies like Sun and SGI. Often this work is not publicly documented.

    Reverse engineering things like IRIX's kernel can give valuable insights into advancements made by SGI. These can then suggest new avenues for research that may have been overlooked otherwise.

    So those questioning the utility of IRIX binary compatability, are missing the primary motivation for such work. Of course someone may find the ability to run IRIX apps useful one day - after all, who would have thought that NetBSD's emulation of a niche operating system like Linux would have proved so useful ;-).

    Chris

    1. Re:Some people are missing the point. by Anonymous Coward · · Score: 2, Insightful

      Indeed reverse engineering IRIX gave NetBSD folks some ideas. The libc provided signal trampoline described in part 4 is a very good example.

      It removes one of the needs of an executable stack. Running with a non executable stack would be a great step forward: stack overflows exploits would not work anymore.

    2. Re:Some people are missing the point. by Anonymous Coward · · Score: 0

      foo bar baz

    3. Re:Some people are missing the point. by Anonymous Coward · · Score: 0

      I worked in a university's "computer museum" for a while, anyone who ever looked a scientist carying a stack of crummy old punchcards containing that "importand piece of data" in the eyes will quickly learn the virtues of being able to emulate virtualy anything on anything...
      for prosperity...

    4. Re:Some people are missing the point. by jo42 · · Score: 1

      :s/fanboys/fagboys/g

  12. support "legacy" users (Re:IRIX?) by Anonymous Coward · · Score: 1, Insightful

    SGI may be moving, but what about all its IRIX customers. Some may be happy running what they have now. This way even if the OS is no longer supported by SGI, the users can still run their apps on NetBSD.

  13. NETBSD ROCKS!!! SEE WHT YOU CAN DO ONCE YOU by Anonymous Coward · · Score: 0

    JETTISON THE FILTH LIKE THEO DRAADT FROM YOUR PROJECT?!?!?!?
    ==
    -[morelame.cmd]
    asdfa j;k jadf uip jkadfu i j;asdklfu ;kasd fuiwekl mzx asdkf iu kaj;sd iou z/xjc iou sd;
    asdf pu/sf

  14. Elegy for *BSD by Anonymous Coward · · Score: -1, Troll

    Elegy For *BSD


    I am a *BSD user
    and I try hard to be brave
    That is a tall order
    *BSD's foot is in the grave.

    I tap at my toy keyboard
    and whistle a happy tune
    but keeping happy's so hard,
    *BSD died so soon.

    Each day I wake and softly sob
    Nightfall finds me crying
    Not only am I a zit faced slob
    but *BSD is dying.

  15. FUCK YOU WINTEL by Anonymous Coward · · Score: 0

    SGI RULEZ!!!!!

    SGI!! - DON\t BEND DOWN TO THE POWER OF T3H D4RK SIDE!!! STICK TO YOUR OWN CPUs - YER OWN MOBOS AND YER OWN OS!!!

    Death to x86!!!! 11 1 1 1