Live data from Hacker News

The ~200 Line Linux Kernel Patch That Does Wonders

phoronix.com

61–70 of 98 posts

Re: The ~200 Line Linux Kernel Patch That Does Wonders

#61
post #46

Earlier quoted context omitted.

OT: is "make -j64" overkill unless you have dozens of cores or am I missing something?

How many simultaneous threads will your next computer be able to run? Chances are it already runs at least two, most probably four. It's not unreasonable to see 4 and 8-threads as the norm. Also keep in mind we are only considering x86s. SPARCs, IIRC, can do up to 64 on a single socket. ARM-based servers should follow a similar path. BTW, a fully-comfigured MacPro does 12. A single-socket i7 machine can do 12. I neve…

Dual-socket i7 is called Xeon.

There are dual-socket and even quad-socket 8-core hyperthreaded xeons (the Xeon L75xx series). A 1U Intel with 64 threads will set you back about $20k.

AMD has 12-core chips, so you can get 48 cores in 4 sockets there. (But I think they only have one thread per core)

Re: The ~200 Line Linux Kernel Patch That Does Wonders

#62
post #51

Earlier quoted context omitted.

Should I be pulling in the source from apt and applying the patch that way? I am forced to use nvidia's drivers, and I fear the vanilla kernel may not work.

Don't be too afraid. Nvidia's driver come as a module. There's lots of documention out there, how to make them work.

How do you stay up to date with Ubuntu's changes?

Re: The ~200 Line Linux Kernel Patch That Does Wonders

#64
post #7

I am newbie when it comes to compiling kernel. Is it a pain to do with stock ubuntu 10.10? Sometimes I run something heavy on my laptop and desktop freezes annoy me. If this patch will allow me to get around it - I would be glad to try it out. Anyone having url of some niuce tutorial to compile new kernel for ubuntu 10.10?

The hardest parts will be A> Getting the patch in correctly and B> actually getting the OS image you compile into the correct area for the bootloader if it doesn't work. The actual kernel compile these days are pretty easy aside from picking the correct options for your system (which while easier, still isn't a cakewalk).

Re: The ~200 Line Linux Kernel Patch That Does Wonders

#65
post #49
post #32

Earlier quoted context omitted.

I know the subject is pretty much Apple's and oranges but i'm currently running: - Terminal with 2 tabs - firefox with 2 tabs - chrome with about 9 - gaim and skype - iTunes streaming soma.fm - Netbeans with an opened project - jEdit - Colloquy - Postgres instance and as soon as i booted Windows XP in VMware, well, took me a while to be able to reply to this post (after the vm settled). I also that you might be sayin…

Your typical workload sounds almost exactly the same to mine - right down to VMware temporarily killing OS X performance. Not that Anonymous Guy On HN is worth much, but get an SSD - it'll be the best upgrade you've ever purchased. (Or maybe I just needed to sidegrade to Linux. :)

Do you have a suggestion on a good and large SSD? And what did you install it into?

Re: The ~200 Line Linux Kernel Patch That Does Wonders

#66

Earlier quoted context omitted.

You're right - but that was the point. The patch was trying to fix problems with the process scheduler, and "-j64" is going to make lots of processes that want to do work and need scheduling.

thanks, but then the "that is my tipical workload" thingy does not hold, as you rarely have >60 cpu bound processes running at the same time. Well, flash player in chrome notwithstanding ;)

It probably approximates Linus's typical workload, which I imagine involves constant compiling and testing while compiling. He's probably still CPU bound.

Re: The ~200 Line Linux Kernel Patch That Does Wonders

#67
post #19
post #15

Earlier quoted context omitted.

Yes, it's indeed quite easy to compile your own kernel, and virtualbox is a good idea. (For compiling you won't actually need the virtualbox, but for booting from it without worries that you broke something, virtualbox sure comes in handy.) I use "sudo make menuconfig", which gives you a text-based menu, there may also be a graphical version. I would not recommend "sudo make config", as that only gives you a long lis…

# sudo make xconfig should give you a point-and-click interface to the same menu. I haven't used it in years, but it was pretty clunky back then. It's just nicer to poke around in than the text-mode menu.

You don't need to be root to compile a Tk application and run it! You also don't need to be root to compile the kernel.

You only need root to copy vmlinux to /boot and copy the modules to /lib.

Re: The ~200 Line Linux Kernel Patch That Does Wonders

#68

Earlier quoted context omitted.

You're right - but that was the point. The patch was trying to fix problems with the process scheduler, and "-j64" is going to make lots of processes that want to do work and need scheduling.

thanks, but then the "that is my tipical workload" thingy does not hold, as you rarely have >60 cpu bound processes running at the same time. Well, flash player in chrome notwithstanding ;)

If you're the head of the world's largest computer OS project, the root of the maintainer tree as it were, I would make no assumption about what his typical CPU workload is like. :)

Re: The ~200 Line Linux Kernel Patch That Does Wonders

#69
post #27
post #22

So what's the downside? You almost never get optimizations like this for free. The post hints that this is also good for server workloads, but what suffers? Realtime would, but realtime usually involves a different scheduler anyway.

There isn't one. It's an existing option in the kernel, you can configure cgroups that way already, but most people don't do this so the feature is wasted. All this patch does is roughly approximate a decent-looking cgroup configuration by splitting processes by tty automatically.

Of course there will be a regression if you change the scheduler policy. ck tried something similar to this and mplayer performance suffered with it (though I don't remember the details). It also broke gnome-startup because it assumed some specific schedule ordering, though this patch is more limited so it might not.

Re: The ~200 Line Linux Kernel Patch That Does Wonders

#70

Earlier quoted context omitted.

You can afford a MacBook Pro but you can't afford an SSD that costs 25% of that? (A really fast expensive SSD is around $400.)

Spending a thousand or two on a computer is a hell of a lot easier to justify than spending several hundred on a harddrive. Particularly when you can find less fancy harddrives for a fraction of that. SSDs are far more of a luxury item than laptops.

Agreed. My lizard brain tells me that too. When we buy a faster processor, we are valuing our time against the cost of the processor. I just have to convince the lizard inside to do the same with disk wait times.
Post reply on HN