Googles appar
Huvudmeny

Post a Comment On: cbloom rants

"09-03-10 - Page file on Ramdrive = 3LIT3"

6 Comments -

1 – 6 of 6
Blogger won3d said...

Back in the DOS FAT compression days, I would make a compressed ramdisk and save the image to HD. Good times.

Yeah, moving SQLite to a ramdisk is lame-ish to me. Maybe you want to keep your state pristine, and that sounds nice, but honestly you know when you're being frisky and should just use the private browsing feature.

But most of all, it isn't slow because it is hitting disk, but because it is putting on airs, pretending to be a real database, and tries to be all transactional and sync-heavy. I don't use FF that often, but I had it configured so that fsync was ignored using libeatmydata. On Windows you could probably do something like that with Detours or equivalent RAD stuff (I vaguely remember Jeff mentioning this..?)

Oh, and not sure if you did this to your laptop, but you can enable the "advanced performance" delayed write cache. I think that was originally designed for DB-like loads, and is a nice inherited-from-server feature. Should be reasonably safe since laptops are inherently resistant to sudden power failure.

September 3, 2010 at 10:37 PM

Blogger cbloom said...

"But most of all, it isn't slow because it is hitting disk, but because it is putting on airs, pretending to be a real database, and tries to be all transactional and sync-heavy."

Yeah, seriously. The main thing that FF uses SQL for is just to store key:data pairs, which you do not need a full damn database for.

Obviously it's a hack, but I prefer it to trying to dig around in how to make SQL work better.

"Oh, and not sure if you did this to your laptop, but you can enable the "advanced performance" delayed write cache"

Hmm.. I assume that just makes it flush the write cache less often? I'm actually pretty opposed to write caching in general. I've had some severe disk corruption in the past due to that.

Write caching + developers who can hard crash their machine at any moment = bad combo

Once in a while when I was being smart I would make a separate partition for development and would have my test programs write data there.

September 4, 2010 at 10:52 AM

Blogger won3d said...

Chrome uses SQLite and doesn't have these problems for whatever reason, but the thing was built from the ground-up to have good interactive performance. I think it is possible to configure SQLite through FF. Apparently, you can do stuff like:

http://lifehacker.com/5344418/make-firefox-faster-by-vacuuming-your-database

and:

https://bugzilla.mozilla.org/show_bug.cgi?id=421482#c28

It has been quite a long time since I've hard-crashed a machine; maybe a few years ago when I was doing more stuff with virtual machines on Windows. I suppose that during your day-to-day you risk a video driver going nuts. I don't know anything about the new Vista/Windows 7 user-mode drivers. Does that make things more reliable?

September 4, 2010 at 1:15 PM

Blogger cbloom said...

"It has been quite a long time since I've hard-crashed a machine; maybe a few years ago when I was doing more stuff with virtual machines on Windows. I suppose that during your day-to-day you risk a video driver going nuts. I don't know anything about the new Vista/Windows 7 user-mode drivers. Does that make things more reliable?"

Yeah, video is still the main way to hard crash. It's way way better than it used to be, Vista/Win7 is really pretty good.

Perhaps more common than real hard crashes now is that you can still get yourself into a state where your machine is not able to shut down properly and you have to hard power it. I guess in those cases I could do the manual "please flush write caches now" thingy.

September 4, 2010 at 1:34 PM

Blogger Aaron said...

I think you mentioned this before but Win7 totally fucked up the ctrl-alt-delete. It used to be like super authoritative. Now if explorer has crashed or there's something really hogging CPU god help you if you can get ctrl-alt-del to work. Rrrr.

September 4, 2010 at 4:54 PM

Blogger cbloom said...

In other news, do NOT start running procmon and investigating WTF your machine is doing when you think it's doing nothing at all. I need to just pretend I don't know about it or I'll get sucked into a world of painful Windows feature disablements. La la la I see nothing...

September 4, 2010 at 5:01 PM

You can use some HTML tags, such as <b>, <i>, <a>

This blog does not allow anonymous comments.

Comment moderation has been enabled. All comments must be approved by the blog author.

You will be asked to sign in after submitting your comment.