Making Operating Systems Faster
mbrowling writes "In an article over at kernelthread.com Amit Singh discusses 'Ten Things Apple Did To Make Mac OS X Faster'. The theme seems to be that since you won't run into 'earth-shattering algorithmic breakthroughs' in every OS releases, what're you gonna do to bump your performance numbers higher? Although the example used is OS X, the article points out that Windows uses the same approach."
...to make OS X faster is to stop having it render the GUI through Photoshop filters.
You've got to be kidding me. XP is CRAZY slower than 2k. I suppose thats what happens when you add a Microsoft+ package to Windows 2000. Wanna make it faster? Disable all the useless services and shut off the ugly eye candy. *sigh*.
adventure-today.com
why does my 3ghz p4 choke on spellchecking a 50k doc with a 500mb text editor (Word2k3) ?
why does explorer choke on listing 10,000 files ?
why should i ever upgrade my word processing applications ? or can they type for me now ?
bah, innovation is dead, shame
Hard Drive
Largest bottleneck in any modern system. If you've never had the opportunity to use a 15krpm (or something faster) system, do it now. It flies... I don't care if it is Windows or what... it doesn't matter when you've got usable bandwidth to the biggest chunk of storage out there.
Life is the leading cause of death in America.
So pretty much, Mac and Windows are made faster by using resources when they're not being used already. Not a genius idea, but the hard part is figuring out how to do that, which is what the article discusses.
Check out www.blackviper.com, it's one of the better sites dedicated to tuning and increasing performance of Windows 2000/XP
More hamsters!
"If being a geek means being passionate about something, then I pity those who aren't geeks." - Pike65
And the fact that I won't be discouraged from keeping 10.3 or 10.4 on that system if the next version doesn't support my hardware through annoying EULAs.
I'm in the hole of the broadband donut.
I wish these were incorporated into linux more. I don't care what anyone says, comparing windows and linux on the same machine has always shown to ME that windows seems a lot faster. Applications take longer to load in linux. Mozilla for example, takes longer to load than it did in windows on the same computer. Other applications that I can't compare directly seem to take a while when they're just small apps.
Aparently, windows caches a bunch of stuff and has a bunch other little hacks that allows this. So why can't linux and the kde people do this. They've copied everything else, why not this?
Before you mod me as flamebait or troll, I switched over to linux a while ago and I have no intention on going back to windows. I'm not some ms fanboy bitching about my 10 minute experience with linux. All I'm saying is that here are some points where linux annoys me.
1) Don't install so much crap on your computer. 5 megapixel photos set as wallpaper along with Real Player, Gator Spyware Crap, Quicktime Task, HP scanner registration reminder sofware, webshots, Norton anything, MS office bar etc running on startup will make your nice shiny new computer run like an arthritic snail on sleeping tablets.
2) Turn off some of the eyecandy. All those fades and whooshes and stuff don't actually do anything useful, they just consume CPU cycles and waste your time.
3) Use Ad Aware and SpyBot regularly to keep scumware out of your computer. I had to clean up a PC this morning which had stopped working because the BASTARDS at NewDotNet wrote some software which fucked the TCP/IP stack backwards.
4) Defrag regularly and run MSCONFIG to check what crap is sneaking back on to your Startup scripts.
BTW, Windows 3.1 sitting on MSDOS 6.2 ran like shit of a stick on my old P133. I wonder if/how it would run on a modern system?
Sorry, but my karma just ran over your dogma.
upgrading from 2K to XP on the same hardware will slow you down. Upgreading from OS X 10.2 to 10.3 on the same hardware will give you speed improvements a majority of the time.
I can see how they can write an artice about how apple did this but to claim that Microsoft does it too. I don't see how. Unless Microsoft has improvements but enough of the new things they add slow it down so much more the gain is outweighted by the loss.
Evolution or ID?
Apple, and other system vendors need to consider these types of management issues when making a change. Speed improvements are only good if they are "management friendly"
I dunno about all that but OS X doesn't seem slow at all to me.
... but I do have to admit that in all my computing experiences, OSX seems to be the one OS that is more 'acceptably mediocre', performance wise, than any other.
... that there are 'unutilized registers' in the PPC architecture when it is running OSX.
...
Try running LinuxPPC on your mac some day, and you will see a huge difference in general snappiness.
I'm not saying OSX is un-usably slow, or even slow at all - heck my Rev. A tiBook, beaten and aged, is still all the computer I need, and I am very productive with it
On the register side of things, I can't for the life of me remember the full details, but I believe that the ABI for OSX only uses a sub-set of the PPC's full register set, and thus this means more swaps in/out
This is separate from AltiVec, which is an instruction set, not just a register setup
; -- the corruption of government starts with its secrets. a truly free people keep no secrets. --
The number one thing they should do IMHO is reduce overhead. Using Microsoft Windows as an example, windows 98 has much less overhead than 2k, which in turn has much less than XP. A lot of it is eye-candy, which is all well and good, but those should be options that are OFF by default. XP differs from previous versions because it uses a 'shell' based gui (similar to KDE / GNOME, etc), which, while nice, is going to cause some system slowdown. Using the 'explorer' shell, which is heavily intergrated into the Windows OS, is the fastest, and should be the default. Then if people want to change it to look pretty they can, by sacrificing speed (in slower machines).
Stop adding services / features that are on by default, and you'll see a huge improvement in speed.
Anyway... You are completely correct but...
/usr, /opt partition, whichever one you have all of your applications installed on. Copy the hard drive to the ram drive at bootup. DD can do it quickly if you just zap the whole partition across. I think there are mount options to tell the Linux filesystem buffer not to cache a particular filesystem.
My 2 words are RAM DRIVE. You think you can't justify 4Gb of RAM? Course you can.
Dedicate 2-3Gb of it to a ram drive and mount it as your root,
The difference in performance can be stunning.
Government of the people, by corporate executives, for corporate profits.
Hard Drive is the bottleneck........ Has anyone tried using a RAMdisk as their OS drive? I've read a lot and heard of people trying, but never come across a comprehensive how-to + review. With the amount of ram we can have nowadays (new pc's coming with 6 banks for dual-channel DDR), I'd pay $250 for an extra 2GB of ram in order to have my OS + key apps run off of that. Other solutions? (CF too slow?)...
Early versions of some film scanner software that I worked on were terribly slow. A quick profile of the running code showed that about 10% of the time was spent in a little piece of code called TtoF(). This code parsed and coverted text into floats.
The earliest versions of the software did not convert key preference/calibration/setup files into internally stored numerical values -- instead, anytime the code needed a calibration/setup value, it went to the file, read it, and converted it. Needless to say, that "feature" was quickly corrected.
That's not as bad as an early VAX image processing program that prepped newly allocated file space by setting all the bytes to zero, one byte at a time.
Two wrongs don't make a right, but three lefts do.
Only one optimisation presented is related to hardware drivers, and it is cache of what kernel extensions will probably be loaded. Most of the optimisations (basically lots of caching and dynamic defragmentation) could be implemented in Linux, regardless of the amount of supported hardware.
Rewrite it!
This holds especially for applications, but it definitely applies to operating systems as well. Most modern software is simply bloated beyond belief.
BeOS, by all accounts, is a full-fledged OS, and it takes a Pentium (not Pentium 4, but original Pentium) 15 seconds to boot it, including the GUI. What's up with Windows and OS X taking over a minute on hardware that is several times faster?! On Linux, you could at least skip most of the init stuff and boot in seconds (likely mostly pauses that you have to keep for faulty PC hardware).
Then there's the libraries. glibc is well over 5 megabytes. You are not going to convince me that isn't bloatware. If all that code doesn't eat CPU time, it at least eats memory, which could lead to more swapping. GTK is also typical - ever resize a GTKWindow? It's visibly slow! That doesn't happen to Windows 3.11 on my grandpa's 486! What is that code doing?!
Applications... Firefox is what? 10 megabytes installed size? And that's a light weight browser. What? We need 10 megabytes on top of libc, X, and GTK for parsing a simple markup language and rendering those widgets? Excuse me! Even lynx is hundreds of kilobytes, and it mostly just reads data from a socket, strips the tags, and spits it straight out. What the fsck? Say "OpenOffice.org" or Java and I'll explode.
All we have today is bloatware. I'm *really* tempted to roll my own OS and applications, and I am going to have a shot at it this summer.
Please correct me if I got my facts wrong.
This is technically offtopic, but often much of the 'slowness' we still experience on our computers which people often blame on their 'operating system' isn't really down to the operating system (i.e. kernel), but more the higher level stuff that runs on top of it. It seems that lots of efforts are going into making operating systems more efficient, since there's lots of interest in this area, but that efficiency is more than lost further up. (Not that I should be complaining, since I'm just another person not doing anything about it.)
Try running Windows NT on a new Intel system (say 2-3GHz) for example - it'll run blazingly fast, and with software versions from around the same time it'll still do much of what everyone wants to do - email, web, office, graphics manipulation - but really much faster - things will load practically instantly, rather than after five or ten seconds, and it's all still nice and graphical and everything, just like people want.
Many (but not all) XP machines I meet still seem to take 2-10 seconds even to do basic things such as open My Computer, Internet Explorer or a properties dialog, which one has to wonder is worth the wait for the extra functionality - basically lots of drivers, a couple of extra bundled programs and supported file formats, minor changes to the interface and the other couple of things I'll get flamed for forgetting. Microsoft have no doubt made some improvements to the kernel between releasing NT and releasing XP, but most still seem to be no faster to use, if not slower.
I maintained a school network up until last year which still ran NT and KDE2 on around 2/3 of systems, and then when my replacement went and wiped everything out and replaced it with new machines running XP (with an enormous cost to them), many staff told me that there were lots of things that didn't work any more, and there'd be frequent outages of the entire network.
On a Linux+X system, running X on its own (i.e. just the one program you want) or with a light window manager (fvwm or whatever) is again noticeably faster than running Gnome or KDE. Loading Mozilla or OpenOffice.org means loading the entire frameworks they run in, and often we're loading up a great deal of functionality we don't want in that particular situation. I think a good example is Dillo, a web browser written entirely in C that just does the basics (launches in around 0.7 seconds on this Athlon 700 system, compared to Mozilla, which takes around 5, and Mozilla Firefox, which isn't far off that) - it'd be interesting to see if they could add things like CSS or SSL support and still keep it fast.
Don't take my word for it -- take Ars Technica's review of Panther for example:
"Fundamentalism" isn't about divine morality. It's about human authority.
1. turn on apple II series box.
2. Press Ctrl+break (? it's been a looong time since I used one).
3. You're done.
It takes under 2 seconds. Show me a "new" machine (see: desktop,server or notebook from the last 5 years) that actually boots that fast, please! (not just turns on the monitor)
stuff |
The only thing that's even remotely like what you're talking about is the Mach-O ABI and how it accesses global addresses.
Mach-O the ABI (not to be confused with Mach-O the executable format, which is totally different) accesses global addresses via PC-relative addressing. This design decision was made back in the NeXT days, and made a lot of sense at the time. Unfortunately, the PowerPC doesn't have any support for PC-relative addressing, so the only way to do it is to use several instructions and induce a pipeline stall in the process. Depending on how a program is written, this problem can mean up to a 10% speed hit.
That is the only brain-dead decision in the ABI that I'm aware of. It certainly makes good use of all registers, intelligently defines leaf procedures, and in general makes full use of the PPC architecture other than that one problem.
Altivec includes both instructions and processors. That is one of the things that makes Altivec really cool, is that it has a shitload of vector registers that are totally separate from the other registers, and don't interfere in any way.
Mod down posts with a "Free Mac Mini/iPod" sig, they're spam!
device=himem.sys
device=emm386.exe noems
files=40
buffers=10
smartdrv c+ 10000
There are a huge number of yeast infections in this county. Probably because we're downriver from the bread factory.
Whenever you install new software, you have to wait while the system "optimizes" it, which in fact means checking for applications that need their prebinding redone. On a 700MHz imac - less than 2 years old - this sometimes takes 15 minutes or more. Since I bought it, I've wasted hours, if not days, waiting for installations to complete because of this, which is far longer (and more frustrating) than the total time saved starting programs.
I don't understand why it doesn't just leave the prebinding to be done the first time the program is run.
Eh.. I'd argue differently.
IMHO, the next major revolution in OS design (and performance) will be from an exokernel architecture. For those who aren't familiar with them, it's a completely radical and different approach to kernel design, the main idea behind it is seperate protection from management. If you really think about it, who (I use that term loosely) would know better what resources, scheduling, etc an application will need - the kernel, or the application itself.
Traditional kernel design techniques give the (pretty much) the entire management of resources to the kernel itself and hide it behind a HAL (hardware abstraction layer), allowing the application little to zero say in the matter. Exokernels throw that idea out of the window, taking a completely opposite view on the issue. Once you give the power to the application, it opens a whole new world of OS design.
It's really quite interesting, for more information on different kernel designs you can check out the Microkernel entry at thefreedictionary.com
# fuser -v
#
Step 1: Buy a G5 Mac.
Step 2: There is no step 2!!!
Paizurishitetai desu ka?
There are easier ways to enable these "features" than creating a ton of hoops for BOTH sides of users.
What fucking hoops?
Right-click My Computer->Properties->Advanced->Settings button.
Choose either "Best Performance" or "Best Appearance." Or check each option individually. What a non-issue.
If this was KDE, someone would have already answered with this, but because it's Windows, everyone just nods with the rest of the flock, "Baa, baa, yes, there are hoops to jump through, baa."
Speaking of KDE, talk about fucking hoops. You've got a completely horrible control center, with three different areas for changing the looks of things like window styles, widget styles, and so on. Why the hell isn't that all integrated into one configuration dialog? Oh, I forgot, ease-of-use is a criticism we only reserve for non-issues on the Windows platform like checking a radio button to get rid of a blue theme.
"Sufferin' succotash."
There are two kinds of speed: things that are fast and things that feel fast.
The article and the comments here on /. are mainly talking about true benchmarkable speed. Things that are fast.
But some apps don't really need to be fast. They just have to feel fast. This holds true for most interactive applications. It's all about psycholigy with this one.
Ever wondered why Windows Explorer builds up its icons from the right bottom to the top left? Doesn't matter in real speed, but it just feels faster. Your brain just isn't used to this flow: usually you read from the top left to the bottom right, or you read from the top right to the bottom left. Your eyes immediately focus on the spot your brain expects the icons to appear. But instead the appear in the opposite corner. By the time your brain figures out it has been tricked, the window is already full of icons.
More tricks: ever wondered why windows wastes memory by trying to have some free memory ready all the time? It makes starting new apps faster. But on average the system is slower.
In the Unix world there is only raw, benchmarkable speed. And that's why KDE and Gnome are slow. They aren't slow, they just feel slow.
This is your sig. There are thousands more, but this one is yours.