Wasabi: good idea or not?



  • I was reading this article on Joel on Software, about how they basically wrote their own compiler, called Wasabi, for a product of theirs (FogBugz).

    My first thought was that it seemed a little excessive - Joel basically seemed to be saying that it was the best way of being cross-platform, when there are cross-platform languages like Java or Python available. His argument is that with their own compiler they can basically generate code which will run natively on Windows / *nix and not have to install Java or anything on there. They want something which runs 'Out of the Box', and installing software such as the .NET runtime on servers just over complicates things. I'm not convinced by this argument, it shouldn't be too hard to include a copy of the JVM if you wanted (this is what a lot of Oracle products do, for example), I don't know what it would be like providing binaries for other languages.

    The advantage to writing your own compiler is that you can basically put in whatever features you like, which could be really useful.

    To be honest I'm not sure either way on this, I just wondered if anyone had any thoughts!


  • Discourse touched me in a no-no place

    @PhillS said:

    To be honest I'm not sure either way on this, I just wondered if anyone had any thoughts!

    My first ones: (1)Not Invented Here. (2)Reinventing the Wheel.

    Then I thought... "Hang on..." and did a bit of googling.

    Happily Joel has also written an article on these two things.

    Sadly it's defending them.
     



  • So they
    A: made a language and a compiler that only they use.
    B: Said language actually compiles to another language that has the problem that they were trying to avoid in the first place.
    C: Why not use C libraries for this? It's fairly portable and there's a number of libraries dedicated to being portable across each operating system.


    Also compiling a single file to be run on multiple operating systems, that means each operation system requires a program to run the program.


  • ♿ (Parody)

    Even more interesting is that less than 20% of the customer base is on non-Windows and these customers account for the majority of the support calls. Personally, I'd drop support. If they're a small customer (smaller than a few thousand bucks), how can they be worth the hassle? If they're a bigger customer, they can afford to spend a few hundred bucks on a Windows server. I know that, if they all of a sudden dropped support for Windows, I'd certainly spend the few hundred bucks on a linux server just for fogbugz.



  • Well, their code was originally written in VB or VB.net (don't remember).  Then they realized that the *nix community was a market they couldn't get into unless they ported their software.  So they had 2 choices:

    1. Have two codebases (one in VB and another in a *nix language)
    2. Port VB code to a platform independent language

    Of course they chose #3... write a translator.  Maybe in their eyes it was the easier choice.  Depends on how much code they had to deal with.

     I worked at a company that firmly believed in the "not invented here" ideology.  We wrote our own replacement for xml, our own scripting language (twice), our own bug tracking system, and potentially others that I've blocked from my memory.

    Personally I would have converted their code to a different language, as I've seen some of their FogBugz code.  Not so purty.  Of course this was their little add-on to attach SVN/CVS commits to a bug tracking #, so they might not have "gone the extra mile" for those.  Rewrote that 120 line piece of beauty in about 20 lines of shell script :/

     



  • @skippy said:

    Maybe in their eyes it was the easier choice.  Depends on how much code they had to deal with.

    To add to this a little bit more (and not hit the edit timeout) when you have large customers and you're trying to support them as well as do a complete rewrite things can get out of control very easily.  Now, imaging taking FogBugz, which is a fairly large piece of software, and converting it over to a completely different language.  I'll pull a number out of my ass and say it'll take 12 months to complete.  Now during that time they have to do bug fixes, custom work for large customers, new features, etc to the VB codebase.  Things can get out of hand pretty fast.  Same thing happened to us years back.  We were maybe a month away from completely rewriting a product, but because of customer features, bug fixes, etc, we had to maintain the old codebase, and 5 years later it's still there.  We just dropped the new one.  So in this sense, I can understand Joel's decision.  At least with a code converter, you can do it anytime, with the most current codebase. 



  • @PJH said:

    My first ones: (1)Not Invented Here. (2)Reinventing the Wheel.

    Then I thought... "Hang on..." and did a bit of googling.

    Happily Joel has also written an article on these two things.

    Sadly it's defending them.

    My first thought was that Joel wrote an article on how terrible the practice of rewriting is; I guess he's not so frugal in his own house. He might make a distinction between tearing down an unmaintainable spaghetti code base, and writing a custom compiler because it's a "brand new need," but I'm not convinced.

    Of course, the real root of all this is that Joel hates Java. He's not a rabid anti-Java zealot, but he's repeatedly made it clear that he doesn't like it.


  • Discourse touched me in a no-no place

    @VGR said:

    @PJH said:

    My first ones: (1)Not Invented Here. (2)Reinventing the Wheel.

    Then I thought... "Hang on..." and did a bit of googling.

    Happily Joel has also written an article on these two things.

    Sadly it's defending them.

    My first thought was that Joel wrote an article on how terrible the practice of rewriting is; I guess he's not so frugal in his own house. He might make a distinction between tearing down an unmaintainable spaghetti code base, and writing a custom compiler because it's a "brand new need," but I'm not convinced.

    The thing I (deliberately) left out of my post was I wasn't looking for a Joel article when I googled (those terms.) It serendipitiously(!) came very high in the particular search I asked for.

    Hence my dissappointment.

     

    No, I don't read Joel on a regular basis. I came across one of his articles ages ago, thought 'that's good' and thought nothing of it (the hungarian notation one.) I (think I) mentioned it on here in a thread, and someone said something derogatory about quoting Joel. I then went back to look at some of the other articles. I've also since read others' opinions about him/his company/his articles.

    I'm of the opinion that I got lucky the first time, and not since.



  • @PhillS said:

    The advantage to writing your own compiler is that you can basically put in whatever features you like, which could be really useful.

    To be honest I'm not sure either way on this, I just wondered if anyone had any thoughts!

    It's an old question and the answer is actually well-known in certain circles.

    Writing your own compiler is always the slickest way and gets the best performance out of the result, in every respect. It is also five to ten years of extra work, most of which is spent trying to get it to generate code which is both correct and efficient. There is usually a much faster way to solve your problem that gives results which are almost as good. Doing a half-arsed job of writing your own compiler, in a few weeks or months, is never the best way and usually quite a poor way.

    The gains simply have to be massive in order to justify the expense of writing a compiler.

    (Designing your own generalish-purpose language is the same, only measured in decades instead of years)



  • @PJH said:

    No, I don't read Joel on a regular basis. I came across one of his articles ages ago, thought 'that's good' and thought nothing of it (the hungarian notation one.) I (think I) mentioned it on here in a thread, and someone said something derogatory about quoting Joel. I then went back to look at some of the other articles. I've also since read others' opinions about him/his company/his articles.

    I'm of the opinion that I got lucky the first time, and not since.

    That's pretty much the problem with his site. It's a mixture of good advice, bad advice, useless advice, and dangerous advice, and there's no particular way to tell which parts are which without carefully studying the material. Smart people point out the good bits to their friends, those friends then go on to read all the other bits and point them out to their friends, and before you can say "It looks like you're writing a letter. Would you like help?" you've got a culture of stupidity sprung up around the thing and everybody has stopped thinking about what they're doing.

    The lesson here is that just because a person writes a paragraph that begins with the most insightful, useful sentence you have ever read, this doesn't mean that the rest of the paragraph isn't a load of nonsense. Genius and stupidity are often found in close proximity.



  • @asuffield said:

    @PJH said:

    No, I don't read Joel on a regular basis. I came across one of his articles ages ago, thought 'that's good' and thought nothing of it (the hungarian notation one.) I (think I) mentioned it on here in a thread, and someone said something derogatory about quoting Joel. I then went back to look at some of the other articles. I've also since read others' opinions about him/his company/his articles.

    I'm of the opinion that I got lucky the first time, and not since.

    That's pretty much the problem with his site. It's a mixture of good advice, bad advice, useless advice, and dangerous advice, and there's no particular way to tell which parts are which without carefully studying the material. Smart people point out the good bits to their friends, those friends then go on to read all the other bits and point them out to their friends, and before you can say "It looks like you're writing a letter. Would you like help?" you've got a culture of stupidity sprung up around the thing and everybody has stopped thinking about what they're doing.

    The lesson here is that just because a person writes a paragraph that begins with the most insightful, useful sentence you have ever read, this doesn't mean that the rest of the paragraph isn't a load of nonsense. Genius and stupidity are often found in close proximity.

    That is the best synopsis of Joel on Software on the internet. 



  • So the wtf is that they chose a vendor specific language in the first place?



  • IMO, writing a general-purpose language is a pointless effort. Specialised languages, which do just one thing well, can be usefull for some time. But in the long run, they will always starting lacking those features that the big boys implement in their languages in the meantime.



  • While very hard trying to avoid getting into 'what is a language' discussions.

    I wanted to add, that on some situations you will be forced to write half a language because you want to give a customer a simplified programmable interface to do something.
    For instance when writing a businessrule engine with heavy feature creep, at one point you will have implemented half a language. Its of course extremely specific , but not really a WTF.

    However i would say that when you think that inventing a new language to create a program/application, you should probably think twice, or perhaps five times before actually doing it. Because while i can certainly think up freak circumstances where  inventing a new language would be a valid possibility, in most cases its probably better to go find that half forgotten language that overlaps with your scope. (unless thats malbolge or brainfuck)


Log in to reply