January 11, 2006
I just updated my post The Bloated World of Managed Code with baseline memory footprints for Console and Winforms apps in .NET 2.0.
I'll admit I am a bit of a hypocrite when it comes to managed code apps. Now that tiny, native BitTorrent clients are available such as uTorrent and BitComet, I just can't force myself to suffer through the Java (Azeureus) and Python (ABC) clients. They're nice enough, but I want small, clean and fast for this kind of app. And where's the .NET BitTorrent client, anyway?
Managed code can be plenty fast, but I've always said that managed code isn't appropriate for every kind of application. It's another tool in your toolbox, but not the only one.
One particularly egregious example of managed code misuse, however, is in ATI's Catalyst video card drivers. The "control center" is a client app which allows you to manipulate the settings. It's written in .NET 1.1 and launched via a button in the graphics driver tab.
It's a reasonable concept, but in practice-- it sucks. Even on a clean Pentium 4 3.2 machine with 1gb of RAM, loading the control center for the first time feels like almost a full minute of waiting for something to happen. As commenters on Junfeng Zhang's log point out, this is likely due more to poor coding than anything else. But what really irks me is that all I want to do is adjust a few minor video card settings. Is it really appropriate to have such a heavyweight app for such a simple task?
Which brings me back to using managed code in appropriate places. Although there was a bit of a hubbub about managed code and Vista last year, Microsoft is pursuing managed code aggressively, as Dan Fernandez notes in Debunking the Microsoft's not using Manged Code Myth. He provides a succinct list of recent Microsoft products and the number of lines of managed code in each one:
- Visual Studio 2005: 7.5 million lines
- SQL Server 2005: 3 million lines
- BizTalk Server: 2 million lines
- Visual Studio Team System: 1.7 million lines
- Windows Presentation Foundation: 900K lines
- Windows Sharepoint Services: 750K lines
- Expression Interactive Designer: 250K lines
- Sharepoint Portal Server: 200K lines
- Content Management Server: 100K lines
Managed code is great. But a world where everything is managed code-- including the operating system and essential utilities-- is still pretty far off.
Posted by Jeff Atwood
"Managed code is great. But a world where everything is managed code-- including the operating system and essential utilities-- is still pretty far off."
You're probably right. And this isn't helped by the problem that end-users don't care whether their code is managed or not. Nor should they care if it's written in assembler, Java, Python, or C#. For every developer bloviating and chattering excitedly about the promise of managed code (and make no mistake, it's going to be great when we eventually go managed all the way), there's ten end-users who couldn't care less. They just want things to *work*.
Put another way, nobody really needs Notepad.NET with all its bells and whistles when plain old Start Run "notepad" still works just fine.
Yeah, but users also want to stop hearing about vulnerabilities caused by buffer overruns and underruns and sideruns.
It's not impossible with managed code, but much more unlikely. I think any one of us could write a simple little video card control center that would be snappy, performant, and nearly indistinguishable from unmanaged code.
Save the unmanaged code for device drivers and such I say. Microsoft will invest heavily in perf tuning managed code, and we'll get the benefits for free.
when plain old Start Run "notepad" still works just fine.
For very small values of "fine", perhaps..
Save the unmanaged code for device drivers and such I say
I just wonder if the ATI developers had created a the Catalyst Control Center in C++, would it have been this slow to launch and use?
Here is some discussion about the unmanaged DVD Maker in Vista:
I guess Eric isn't allowed to really tell us why it's unmanaged, but we all have an idea.
Uggh... I was thinking that the next video card I bought would be from ATI. I am sick and tired of nVidia's belief that their crappy drivers should be taking over my entire machine. It's a video driver for pete's sake!
But now that you tell me ATI pulled this kind of stunt, maybe I'm better off sticking with nVidia. How stupid do these people have to be? Requiring .NET for a video driver? Especially when .NET typically ISN'T installed on the OS by the time you install the video driver. What do they do then?
I'm a huge fan of .NET and even Java for enterprise applications. But it is becoming quite apparent to me that .NET isn't the technology that you use for consumer applets like this.
ATI's Control Centre is an optional add-on to the standard driver which already has the usual dozens of settings.
Perhaps if you have spec-i-a-l-i-st needs for gaming or CAD or some such you might need it, but I am happily using my computer for DVD playback, calibrated photo editing and 3D rendering and have so far had no need of it.
BTW Jeff: You have a 'questionable content' filter that rejects the word "spec-i-a-l-i-st".
As of the latest Catalyst driver version, the Control Center is mandatory, as they removed the probably-written-in-C++ control applet.
I've been avoiding the CC like the plague, but now it's on machine, sucking about 14 megs of memory for no real reason.
And why does it launch so many CLI.exe instances?
Oh, and it doesn't work with .NET 2.0.
I love this topic. I was going to post something like this on my own Blog.
I cannot agree more with this topic. The ATI catalyst app is HORRIBLE. It takes a good 2 minutes for that POS to come up on my 1gb AMD64 3200 box. It uses memory like its going out of style!
Is this what all managed apps are like?
One thing that always seems to be missed out of the "Microsoft using .NET internally" lists is the Windows Media Center shell "ehome.exe" which is currently .NET 1.1. The first version (MCE 2004) was .NET 1.0. I'm sure all the swishy graphics etc are probably C++ GDI code but the main engine is .NET. In fact people are hacking ehome using ILASM/ILDASM in order to get the Media Center shell running on Windows XP Pro or Windows Server 2003. See: a href="http://www.thegreenbutton.com/community/shwmessage.aspx?ForumID=27MessageID=78447"http://www.thegreenbutton.com/community/shwmessage.aspx?ForumID=27MessageID=78447/a
Is this what all managed apps are like?
Nope. Discreet Cleaner XL is managed code, loads very quickly and uses (relatively) little memory.
I just think the ATI guys don't know what the hell they're doing.
"Oh, and it doesn't work with .NET 2.0."
This seems to be one of the biggest issues. I wonder if Microsoft has determined that this is a deal breaker for using .NET within key components of the Vista OS?
I don't think that you can get around this issue when dealing with managed environments. Java suffers from this problem as well. In a recent post to a popular Java forum, someone asked "how many different versions of the Java VM do you have on your machine?". The typical response was around 5 or more. This does not include Java appications that attempt to package a specific version of the VM locally into the application directory.
I wonder if .NET will suffer the same fate? Will every user eventually have version 1.1, 2.0, 2.1, 2.2, 3.0, 3.1, and 4.0 of the .NET framework installed on their machines?
Offhand, I'm going to guess the only reason it doesn't work with 2.0 is that they didn't add a .config file saying it's allowed to try. 2.0 is supposed to be fully backwards-compatible...
I'm withdrawing my earlier comments having just discovered that with the latest version of Catalyst the new control centre is no longer an optional extra (they obviously kept the old dialogs in parallel for a while before dropping them).
Yes, this is HORRIBLE. The whole interface design is amateurish, the programmer equivalent of a child with writing word documents with too many fonts, or Homer Simpson's web page. Bad graphics used to excess, even in the selection tree.
Particularly careless is stretching the standard display dialog to another inch of blank space making the layout of all the other panes ugly just to add a single button. Then in the control centre, they skimp on the selection tree, making it half the width it needs to be so you have to keep scrolling the tree within a peep hole.
Add to this the nonstandard controls, it's a UI disaster.
And that's before you even get to the performance issues.
This is a good example of what you should not do to your customers - suddenly drop your standards so that the criteria they used to choose your product are no longer valid. Talk about having the rug pulled out from under you.
One of the minor details I really hate is the insistance that the phrase ATI CATALYST(R) has to be shoved in your face every where you look. In the feedback, I explained to them that I did not pay thousands for a computer just to admire their trademark. In pratical terms, it is like flashing HTML elements - it makes it hard to scan a context menu for what you are looking for when one item is always shouting "look at me!".
Fortunately, not being a gamer, I can go back to an earlier version.
On the subject of managed code taking over - it has been said that .NET need not be used for everything, yet, the disturbing thought is that MS does not have a product for creating unmanaged code any more (unless C++.NET can do it, but that isn't my field).
Paul, all recent versions of Visual Studio (2002, 2003, 2005) continue to ship with the Microsoft Visual C++ compiler which continues to produce regular, unmanaged machine code. Only unmanged code generation for Visual Basic was discontinued.
I'm really glad I found this thread (and thanks to everyone who contributed a comment). I've been reconfiguring, deleting old programs, optimizing, etc. and only NOW do I know what's causing my PC to boot so slowly. It's the danged Catalyst app. Everything comes up in under a minute, desktop, quicklaunch bar, system tray, then the hard drive runs for another 1 or 2 minutes. I can't really launch an application until the HD activity settles down. Sure enough, lots of CLI.EXE activity. Couple that with McAfee and they've reduced the value of my computer by several hundred bucks! I was ready to go out and get another processor and MB. Nope. Gonna get a new video card instead. Bye Bye ATI....
Ah, I meant to update this thread, too.
There *is* a way to avoid the bloated Catalyst .NET control panel.
1) Either disable Catalyst at startup, or only install the 'minimal' driver set from ATI which does not include it.
2) Download the ATI Tray Tools:
Now you can control all your video card settings from a nice, lightweight C++ app again. The only settings I ever need to tweak are the AA (anti-aliasing) and AF (anisotropic filtering) related ones.
I cannot even run the control center on my Athlon64 3000+ @ 2600MHz it jams up my startup and everything else including Antivirus realtime scanning WILL NOT load at all because of it. This is without a doubt the worst software I have ever seen in my life! I refuse to install it period! It slows down 3DMark scores by about 10% as well but this could be because of the drivers themselves.
5.9 Catalyst for XP 32-bit
5.11 for x64
These are the last drivers that install with Control Panel and are far superior to anything those kids at ATI are pumping out now, I guess ATI knows they're garbage but are commited to them because of the millions of dollars it cost them to get to the level of crappiness that they're at today. Poor poor ATI.
I installed the Cat drivers(BETA)on Vista RC1, the total size of the control center is 80.3mb download and 360+mb's installed, the software cannot even recognize my X800 Pro! Impossible to run any 3D apps without complete screen artifacts! WAY TO GO ATI!!! good job!
Thanks goodness that I find this page through Google; I was close to format my handdisk and re-install the Win2000 on my PC.
I am a company executive and I always need to switch around in different video modes for doing business presentations. The Catalyst Control Center is a piece of crap. I was very happy with the quick response of the previous ATI control application, until I had had to upgrade the ATI video driver for a new application.
I hate C#... in my mind it exists for only 2 reasons 1) so that apps run **ONLY** on Microsoft OS (that Mono stuff is just garbage and just another Microsoft trap... besides C++ runs on **ANY** OS under the sun) and 2) So Microsoft can **CONTROL** it's own language (that committe thing with C# is just "smoke and mirrors").... **HOWEVER** the reason Catalyst Control Center sucks has NOTHING to do with C# which (other than the fact that I hate it) is a VERY capable language... the reason Catalyst Control Center sucks is that nobody at ATI (now AMD) actually knows how to write code... the company is filled wall-to-wall with politicians (like many big company's) instead of good engineers.
I stopped thinking about CCC and just hope that I never care enough about a setting to want to run it. I always download the driver only distribution.
People have said for a long time that it's not the language, its the coders. They've said that for ages with Java and similiar interpreted languages from Microsoft. My counter to this is I've never used a Java/managed code application that I liked, does real work and is not as slow as crap.
I know of many that worked just fine and actually had a more user friendly look and feel until they were "rewritten" in a new language with memory consumption increasing several times and performance decreasing by the same margin.
Some good examples are in the list above "SQL 2005", "Visual Studio 2005" and of course CCC.
As a consumer I don't care what its written in. I just want it to work and save time not waste it.
A bit late but wanted to say thank you Simon!
What possible reason could there be to add a control center menu item to the Explorer window? It was infuriating for those of us who Alt-F to the New submenu. Then, if you mess up and don't down arrow twice it takes 30 seconds for control center to open before you can shut it down.
This sounds minor but the bigger issue is that programmers need to analyze a feature before just throwing it into the codebase. Especially something as brain dead and useless as the menu item. Really makes you wonder what other goodies are lurking under the hood.
I know this thread is a bit dated but I just spent a day downloading, installing then uninstalling the latest drivers with Catalyst Control Center.
The Control Center is probably a good example of how even the best framework (which I think .NET is) cannot compensate for lack of ability.
I will have to give ATI(AMD?) the benefit of the doubt and believe Control Center must have started life as some 'make work' project for some junior developers?
Sandy, read my comments on January 12, 2007 12:26 PM.
That is the clue why CCC is garbage.
Well, not only people at ATI do not understand short and elegant code, but they also insist on defacing right click menus all over by adding an item "ATI CATALYST(R) Control Center" at the top of options.
This is also programming horror : hi-jacking the general interface and littering menus is akin to creating malware.
By the way, here is the single item (ACE) to remove with regedit to throw this piece of crap where it belongs : in the garbage bin.
Haven't you noticed how often harware nowadays comes with crapware ? Especially from China. Probably cultural differences. Or do they dispise so much software that they have teenagers do this on the side ?
Many thanks to Simon Menashy. I've been plagued by the ATI CATALYST(R) Control Center context menu option for some time now. Every suggestion I've tried to remove it until now didn't work. Yours did the trick. Thanks!
Not only is Catalyst bloatware in and of itself.
The packaging and deployment compounds the crime by littering hard drives with multiple copies of EVERYTHING.
Can't find it in the path? No problem! Make another copy!
And the file names. Only someone who never operates at the command line would consider using those huge path names.
Another example of the current crop of cut and paste programmers.
Obviously, the ATI folks picked the wrong Development language to develop the app (or thier code suffers from a lot of inefficiencies), or thier test machines were dual processor pentium xeno machines and they never noticed the app start up time.
Anyway, .NET is a great development environment but it's not the be all end all. If I'm developing a missile guidance system, chances are the development language will be C or Assembly, not .Net. Lower level (unmanaged) languages have purpose, especially with systems that need to do heavy processing at real time and need to be close to the hardware. Most applications do not have to be close to the hardware (DB, business app), so .NET is a good choice.
I was actually just trashing Catalyst online with a buddy of mine the other day; the biggest issue we had was "why" would they write it in managed code? Just to say "hey, we wrote it in managed code?" More than likely yes, as this type of app has no business being written in anything but VC++, reason being is that it probably makes a gazillion p/invoke/external/interop calls on startup, and doing that from .Net takes many more cycles then just calling stuff natively from C++. I hate it too, and I also hate that when I upgrade it, all my previous settings are set back to defaults. Silly ATI developers...they need to stick to what they do best, and that's cranking out kickass video cards.
I just wonder if the ATI developers had created a the Catalyst Control Center in C++, would it have been this slow to launch and use?
Probably, and it would have the added benefit of crashing with heap corruption and exposing the classic vulnerabilities so often associated with C/C++
Haacked is right. A lot of developers (including myself) could write that thing in C# and you wouldn't be able to tell it from an unmanaged app. I've been writing managed code for almost five years now (I was fortunate enough to work on a new application when the .net EAP started) and when there's that obvious of a performance problem, it's typically not .net, it's the program.
I am using currently using an ATI-based card. I have been satisfied with it until recently.
My next card will most likely be based on an nVidia chip.
The one single reason for me to swith from ATI is the bloat called Catalyst Control Center. Prevsiously I could download the standard control panel but since this is no longer the case ATI lost me and many others as customers.
I am a programmer and I also believe managed code is great, but not in all cases.
Thanks for your comments, everyone.
A bit of Googling found me an old forum post about how to get rid of the irritating "ATI CATALYST(R) Control Center" option at the top of the context menu. Just run regedit and delete the following key, and it should disappear immediately:
Fantastic! Hope this helps others too.