Considering how much functionality is in the .NET Framework and how .NET PE files’ metadata is highly compressed, one would expect most .NET applications to be very small.
You can empirically observe this by trying to create a simple “Hello World” in C#: the resulting executable is just 3.5KB (or even smaller with versions prior to 2.0). The size does not increase by much as you continue adding code and reasonably sized (in functionality) .NET applications are just a couple of hundred KB or even less.
Just the other day I checked to see how big the core part of my P2P BitTorrent app was – 160KB. Hm, this doesn’t look right; I keep this library lean in general, it should be smaller.
So I fired up ILDASM (IL DisAsseMbler) and checked the overall statistics (View->Statistics). Here’s the important part:
File size : 163840
PE header size : 4096 (496 used) ( 2.50%)
PE additional info : 1219 ( 0.74%)
Num.of PE sections : 3
CLR header size : 72 ( 0.04%)
CLR meta-data size : 81268 (49.60%)
CLR additional info : 0 ( 0.00%)
CLR method headers : 11081 ( 6.76%)
Managed code : 54814 (33.46%)
Data : 8192 ( 5.00%)
Unaccounted : 3098 ( 1.89%)
Well, well, well… 50% of the image is actually metadata! Despite heavy metadata “compression” (this is a custom kind of compression) in the .NET Framework, metadata occupies half of the total space, while code takes only 34%. Interesting…
I guess if I obfuscate the image using an IL round-tripping obfuscator that I could get quite a smaller image.
Be the first to rate this post
- Currently 0/5 Stars.
- 1
- 2
- 3
- 4
- 5
I have just received a promotional email from Amazon.fr with a great line
Disques durs externes Stockez sans modération
In English this reads “External hard drives Store without restraint” 
We all keep so much junk thanks to the cheap and large hard drives…
Be the first to rate this post
- Currently 0/5 Stars.
- 1
- 2
- 3
- 4
- 5
I haven’t played a game on a PC since I bought the Xbox (the first one). It really is so much better just to put the DVD in, wait a few seconds, grab a controller and start playing. There are no network issues either thanks to the Xbox Live service.
Still, gaming on a PC has its advantages. The resolution you play is up to you (and is often higher than the resolution on a console, especially close to the end of life of the console) and mouse is a lot better pointing device for FPS than the controller. On the other hand, controller is a much better solution than the keyboard, at least for me.
Just the other day Half-Life 2: Episode 2 came out, AKA The Orange Box. I bought the original game and Episode 1 and played them both on the PC (one of the last few games I played on a PC before switching). I planned to play the Episode 2 on my Xbox 360 for the reasons listed above, but realized I don’t need the extras on the orange box (even though they look cool and are a good value), plus I payed for the previous games already. On a whim, I decided to buy just the Episode 2 and play it on a PC.
The Episode 2 so far is great. I say “so far” because I started playing from the beginning and even though I didn’t plan to, I played through the whole Half-Life 2 and Episode 1 in succession and only then started playing Episode 2. Unfortunately, a year after Vista’s release, several driver revisions and despite the fact that I own previous generation video hardware (NVidia 7600GS), I had and still have graphics glitches in the game.
That said, Valve truly is a great company. Half-Life 2, three years old game, gave me (again) so much fun compared to all the other titles that I’m surprised why the other game designers do not copy more of the concepts from this successful game.
What do these guys do that’s so great?
- Excellent music that starts playing at the appropriate moment (usually just prior to a significant battle), sound design is also top notch, weapons sound great and the voice acting is superb
- Great graphics that run very well (minus driver issues) on a variety of hardware; yes, they are not the top dog in the 3D effects department, but the game looks and plays great while the content is more important anyway
- You are never ever out of the game – there are no cinematics and the story unfolds while you play; this is probably the biggest advantage to the other games
- Sidekick characters are likeable: Barney, Alyx, Vortigaunts, even temporary ones like Father Grigori… they all behave like real people (or aliens); I chuckled several times during Episode 2, there are many times more jokes coming from the sidekicks this time
- Physics puzzles – no other game has physics integrated in the way that Half-Life 2 does
I could go on and on I guess. If you haven’t played Half-Life 2 yet and are even remotely interested in gaming, do yourself a favor and buy this game. Thanks to the Steam content delivery platform, you don’t need to order and keep CDs or DVDs. The games are always just a download away, and Orange box is a great value.
Be the first to rate this post
- Currently 0/5 Stars.
- 1
- 2
- 3
- 4
- 5
Ever since I went digital-only by getting rid of my traditional telecom provider (France telecom here in France) I basically lost the ability to send classical fax. But that’s OK because I need this service very rarely and only because some institutions here are not tech savvy enough to receive the scanned copies by email.
On the other hand my ISP (Free) has recently introduced a new “virtual” fax service for its subscribers. You upload a PDF file through a web form, type in the phone number of the recipient and they get a fax from you. There is a special number derived from your phone number that acts as an originating fax. If somebody sends you a fax back, you’ll get it via email as a PDF attachment.
In theory, all this sounds great. In practice, there was a very irritating problem I ran into. To send some documents, I used my newly purchased Cannon MP600 to scan them straight into PDF files. I verified that the file is nicely readable in Acrobat Reader, but when I tried to send it, instead of email confirmation I got back a message from Free fax service complaining that PDF format cannot be recognized.
It turns out that the PDF produced by Cannon MP600 is a PDF version 1.3 which for some reason Free’s software cannot read. The solution was ridiculously stupid: I “printed” the very same PDF into PDF through a virtual printer driver, producing essentially the same thing but in PDF version 1.4, which worked fine (go figure).
Why would Free reject older, more compatible PDF format in favor of newer is beyond me.
Be the first to rate this post
- Currently 0/5 Stars.
- 1
- 2
- 3
- 4
- 5
This is probably old news to veteran Java developers using Eclipse, but to me it’s new. Eclipse is an IDE (mainly) for Java development, written in Java. Thus you need Java runtime to run Eclipse itself plus the Java compiler to compile your code. Usually you’d just install the JDK and be done with it.
Or at least that’s what I thought… Even if you install just the runtime (JRE), Eclipse will compile your projects! This is somewhat strange because writing compilers is hard and IDE developers do not need yet another problem to solve. On the other hand, most modern IDEs offer code completion and refactoring plus a lot of helpers that warn you about code issues on the fly, while you are typing. To do that, the IDE needs a compiler, but not the “regular” one because this compiler needs to work in the presence of “errors”, that is unfinished code (you are still typing it).
Thus, it is not too strange that Eclipse has internal compiler, but it’s great that it is not just used for advanced editing but also for producing a final executable.
Be the first to rate this post
- Currently 0/5 Stars.
- 1
- 2
- 3
- 4
- 5
At least in Microsoft world, the MVC pattern is back in fashion. Note that I say back and not finally. Bashing Microsoft is popular and many I’m sure believe that the move towards the MVC is just trend following, but it’s not entirely.
If you did any serious programming during nineties in C++ on Windows, you have most likely used MFC. From the very beginning MFC had MVC pattern, albeit a bit weird (it wasn’t clear is the Frame was supposed to be a controller or not). This presents a bit of a challenge for the newcomers as it’s yet another conceptual thing they have to struggle with but pays off in the long run because even rookies write relatively sane structured code from the beginning.
MVC is suspiciously absent from all three major versions of the .NET Framework and I can’t really say why. Without this foundation, most .NET apps end up a mess, or just a group of Forms with scattered business logic, DAL and view mashed up together. There is no excuse for this and I’m really disappointed in this decision.
Good for us though, thanks to the popularity of other frameworks/libraries that do use MVC or simply because MVC proponents in Microsoft finally had their voice heard (or both, or something else entirely) we’ll be (relatively) soon getting MVC for desktop and web development on the .NET platform!
Project Acropolis is bringing MVC into the desktop world (WPF oriented, but supposedly can be bolted on the Winforms as well). Just a couple of days ago Scott Guthrie demonstrated the ASP.NET MVC framework in a surprisingly low-key way during the ALT.NET conference (video of crapish quality but watchable is available here, thanks to Scott Hanselman).
The web framework is quite a bit like Ruby on Rails, but that’s to be expected as RoR is well thought out framework. Thanks to the DLR the new ASP.NET MVC framework will most likely be immediately usable from Python and Ruby too. Great times.
Be the first to rate this post
- Currently 0/5 Stars.
- 1
- 2
- 3
- 4
- 5
I bought 2GB or RAM the other day as I started hitting the 1GB (the amount I got when I bought my laptop 3 years ago) limit quite often lately.
Considering my previous good experience with the beta and RC versions of Vista on this same laptop, I decided to go for Vista as I was planning on rearranging my partitions anyway.
What a mistake. I lost the whole day trying to make the following work:
- Wireless. This was a deal-breaker in the end. Even with the March 2007 drivers from Dell site I was not able to reliably connect to my access point.
- Speedstep just did not work. Turns out that Dell is probably to blame here because random people on the Internet report that their old laptops’ Speedstep started working after the BIOS upgrade from the laptop manufacturer. Obviously, Dell is giving us the nudge in the direction of a new laptop purchase here.
- Modem did not and will never work. I think Microsoft is to blame here, but it doesn’t matter – I need modem very rarely, but when I do need it, I need it badly.
Who knows, maybe I would have discovered even more incompatibilities, but I gave up and reverted back to XP.
Be the first to rate this post
- Currently 0/5 Stars.
- 1
- 2
- 3
- 4
- 5
This post is more “note to self” than anything else. I spent several hours last week recovering from a nasty driver installation that wouldn’t allow me to boot my desktop computer (running 64–bit Vista).
A couple of months ago I let Windows Update install the latest drivers for my NVidia video card. Despite what you might have read on Slashdot, Windows doesn’t need to be restarted all the time – I keep mine on for months.
Ever since I installed that video driver I had issues, I just didn’t connect them with the driver update. Video playback became visibly blocky, as if no interpolation of any kind was done.
A couple of days ago I let Windows Update install the latest driver for my Attansic onboard network chip. It did not ask for a reboot, so I didn’t.
Then, as a desperate move, I decided to resolve the video blockiness by manually installing the latest drivers from NVidia site. This time I had to reboot and… machine froze in the middle of the startup.
Tried again. Then again. OK, safe mode with networking – nope. Hmm. I assumed all along that it was my latest installation of video drivers that caused the problem, but obviously it was the network drivers – I could boot just fine in safe mode without the network.
Here’s where things become strange. Uninstalling the driver and reinstalling the one from the manufacturer’s site (Asus) didn’t work at all – same problem, startup freezes the computer. I let it “frozen” like this and 15 minutes (!) later it actually boots fine, except that the network doesn’t work. Bizarre.
I give up and use the source, err, Google. I find not one, but at least five people describing exactly the same situation. The problem is that the faulty network drivers ruin even the firmware on the mainboard, so uninstall does nothing. You have to unplug your computer from the wall (!), let it like that for at least 15 minutes (I tried first with just a couple of minutes, wasn’t enough), then install the driver.
Needless to day I will never let Windows Update install any drivers on any of my machines.
Be the first to rate this post
- Currently 0/5 Stars.
- 1
- 2
- 3
- 4
- 5