HD cache and performance?

  • Thread starter =?ISO-8859-1?Q?Peter_Bj=F8rn_Perls=F8?=
  • Start date
?

=?ISO-8859-1?Q?Peter_Bj=F8rn_Perls=F8?=

How much does the size of the HD cache affect performance of a given
hard drive?

I have been unable to find any good articles about this. Please advise.
 
R

Rod Speed

Peter Bjørn Perlsø said:
How much does the size of the HD cache affect performance of a given hard drive?

So little you wouldnt be able to pick it in a proper double blind trial with a modern OS.
 
A

Arno Wagner

Previously Peter Bjørn Perlsø said:
How much does the size of the HD cache affect performance of a given
hard drive?
I have been unable to find any good articles about this. Please advise.

The difference is very, very marginal. Any modern OS does writhe
buffering and read cahcing as well, but usually with much more memory.
For example, Linux uses all free memory for the buffer-cache.

Arno
 
D

De Moni

Arno said:
The difference is very, very marginal. Any modern OS does writhe
buffering and read cahcing as well, but usually with much more memory.
For example, Linux uses all free memory for the buffer-cache.

It depends.
I recently replaced 80Gb Seagate (2Mb cache) to 160Gb Samsung (8Mb
cache). I didn't notice any performance boosts in normal use but
difference was quite noticeable when copying large files from partition
to another on same physical drive.
 
A

Arno Wagner

It depends.
I recently replaced 80Gb Seagate (2Mb cache) to 160Gb Samsung (8Mb
cache). I didn't notice any performance boosts in normal use but
difference was quite noticeable when copying large files from partition
to another on same physical drive.

Which might just be beacuese the lager disk has a higher throughput.
Buffer/cache memory does nothing for streaming performance.
Copying large files is a lot like streaming.

Without knowing the exact models, I cannot be sure, but I have
some older seagate 80GB drivesm that give me about 35MB/s
throughput. I also have a more current 160GB Samsung,
that has 55MB/s throughput. Both at the beginning of the
disk.

It is true though, that newer disk models tend to be faster
and tend to have more disk memory.

Arno
 
E

Ed Light

Arno,

I was wondering if when a HD is copying small files (like 1000 shortcuts)
from one partition to another if, instead of going back and forth
file-by-file, it intelligently fills its cache, then goes and writes that.


--
Ed Light

Bring the Troops Home:
http://bringthemhomenow.org
http://antiwar.com

Send spam to the FTC at
(e-mail address removed)
Thanks, robots.
 
E

Ed Light

My new WD with 16Mb cache amazes me over my older 2Mb Samsung, in opening
the My Documents folder in file lists. The first time in a session, the
Samsung takes way longer, much longer than the 50% increase in serial reads
on the WD could explain. I don't know how much of that is the cache. The My
Documents contains thousands of cookies and favorites, all tiny. The My
Documents were at nearly the same position on both disks.


--
Ed Light

Bring the Troops Home:
http://bringthemhomenow.org
http://antiwar.com

Send spam to the FTC at
(e-mail address removed)
Thanks, robots.
 
A

Arno Wagner

Previously Ed Light said:
My new WD with 16Mb cache amazes me over my older 2Mb Samsung, in opening
the My Documents folder in file lists. The first time in a session, the
Samsung takes way longer, much longer than the 50% increase in serial reads
on the WD could explain. I don't know how much of that is the cache. The My
Documents contains thousands of cookies and favorites, all tiny. The My
Documents were at nearly the same position on both disks.

Actually on first operning the cache cannot give you any improvement.
It can only speed up re-reads, but the OS is doing that already.

Maybe less fragmentation on the new disk? Or a different filesystem?

Arno
 
A

Arno Wagner

Previously Ed Light said:
I was wondering if when a HD is copying small files (like 1000 shortcuts)
from one partition to another if, instead of going back and forth
file-by-file, it intelligently fills its cache, then goes and writes that.

That is called command-queuing. And yes, modern SATA disks (and old SCSI
disks) can do that. This is the one speed-up the OS cannot do as well,
since it does not know the real HDD geometry. However at least
OSes intended to be used in servers (e.g. Linux) do this as well to
some degree.

Well, for that more memory in the HDD might actually make a difference,
since it could defer more writes and optimize better.

Hmmm. OK, if wer are talking about SATA drives here with native (!)
command queuing, that could give a boost in speed when writing.

For reading, the native command queuing could also give a significant
speed improvement, but here the amount of available memory does not
matter so much, since the data is not stored in it, just the (very
small) requests.

So probably your observed speed improvement is really a combination
of a) far faster disk b) native command queuing and c) (minor effect)
more memory in the drive.

Arno
 
R

Rod Speed

De Moni said:
Arno Wagner wrote
It depends.
Nope.

I recently replaced 80Gb Seagate (2Mb cache) to 160Gb Samsung (8Mb cache).

Useless comparison, you arent JUST comparing the cache size with those two.
I didn't notice any performance boosts in normal use but
difference was quite noticeable when copying large files from partition to another on same
physical drive.

Nothing to do with the cache size.
 
R

Rod Speed

Ed Light said:
My new WD with 16Mb cache amazes me over my older 2Mb Samsung, in opening the My Documents folder
in file lists. The first time in a session, the Samsung takes way longer, much longer than the 50%
increase in serial reads on the WD could explain.
I don't know how much of that is the cache.
None.

The My Documents contains thousands of cookies and favorites, all tiny.

The hard drive cache is completely irrelevant, its the OS level cache that matters.
The My Documents were at nearly the same position on both disks.

The difference isnt due to the hard drive cache size difference.
 
R

Rod Speed

Ed Light said:
I was wondering if when a HD is copying small files (like 1000 shortcuts) from one partition to
another if, instead of going back and forth file-by-file, it intelligently fills its cache, then
goes and writes that.

No it doesnt, the HD cache size is completely
irrelevant in that particular situation.

Essentially because the HD cache wont even be used in that situation.
 
E

Ed Light

Arno Wagner said:
Actually on first operning the cache cannot give you any improvement.
It can only speed up re-reads, but the OS is doing that already.

Maybe less fragmentation on the new disk? Or a different filesystem?

They're both NTFS, Win XP Home, defgragmented about once a week.

Modern technology, I guess. Maybe better access algorithms.
--
Ed Light

Bring the Troops Home:
http://bringthemhomenow.org
http://antiwar.com

Send spam to the FTC at
(e-mail address removed)
Thanks, robots.
 
E

Ed Light

Arno Wagner said:
So probably your observed speed improvement is really a combination
of a) far faster disk b) native command queuing and c) (minor effect)
more memory in the drive.

That was interesting!
So, by "native" command queuing, you mean something the drive does unto
itself as part of its basic algorithms without explicitly having the extra
commercially named "NCQ" and an "NCQ" controller to run it?

--
Ed Light

Bring the Troops Home:
http://bringthemhomenow.org
http://antiwar.com

Send spam to the FTC at
(e-mail address removed)
Thanks, robots.
 
D

De Moni

Arno said:
Which might just be beacuese the lager disk has a higher throughput.
Buffer/cache memory does nothing for streaming performance.
Copying large files is a lot like streaming.

Then what does hard drive cache do if it doesn't do anything in your
opinion? Just a advertisement gimmick, eh? Previous Seagate was
Barracuda 7200.7 ST380013A and current Samsung is SP1614N.

HDTach showed about the same average read speed (48MB/s) for both drives
and access times weren't that much different either. Still Samsung is
able to maintain its performance better the bigger test data get where
Seagate started to choke.

Could you please explain how does hard drive cache actually work, if it
doesn't work like I'd imagine it to work and you seem to know better? I
have thought that data is read into the buffer and then data is written
from buffer when it's full. A dummy like me would think that this
reduces the need for heads to jump from place to another and increases
performance as drive is able to move bigger chunks of data at once. So
when (for example) copying large files from place A to place B drive
with bigger cache would be faster, because its heads don't need to move
back and forth so much as with drive with smaller cache.
 
A

Arno Wagner

That was interesting!
So, by "native" command queuing, you mean something the drive does unto
itself as part of its basic algorithms without explicitly having the extra
commercially named "NCQ" and an "NCQ" controller to run it?

NCQ is ''Native Command Queuing''.

NCQ for SATA actually needs (for some reason that eludes me) the
support of the controller as well. SCSI has been doing this for a
long time without any controller support whatsoever. Maybe a standard
SATA controller can only send one command and has to wait until
it is completed before sending the next...

Non-native command queuing is what the OS can do, e.g. a general
elevator strategy for the accesses.

Arno
 
D

De Moni

Rod said:
Useless comparison, you arent JUST comparing the cache size with those two.

Then what specs matter the most?
Both drives have rotational speed of 7200rpm.
Both drives were in UDMA5-mode.
Seek times seem to have marginal differences.
Only bigger difference seems to be cache size 2Mb vs. 8Mb which would
explain why Samsung performs better when copying large files.

I know short answers make you look smart but it would be nice to hear a
bit more detailed explanations to back up your opinions.

OS cache may speed things up by keeping smaller files in memory for
faster access, but copying large files is that I was talking about and
there OS cache doesn't seem to help much.
 
R

Rod Speed

De Moni said:
Arno Wagner wrote
Then what does hard drive cache do if it doesn't do anything in your opinion?

Any effect it has is swamped by the OS level
cache for the ops you claim to see a difference with.
Just a advertisement gimmick, eh?

Yep, the size commonly seen with hard drives goes up as the cost drops.
Previous Seagate was Barracuda 7200.7 ST380013A and current Samsung is SP1614N.

They are quite different drives performance wise.
HDTach showed about the same average read speed (48MB/s) for both drives and access times weren't
that much different either.

You need to look at say the storagereview benchmarks.
http://www.storagereview.com/php/be...&numDrives=1&devID_0=252&devID_1=241&devCnt=2

The Samsung is 30% better on the benchmarks that matter,
SR Office DriveMark 2002 etc
Still Samsung is able to maintain its performance better the bigger test data get where Seagate
started to choke.

Thats just due to the quite different physical characteristics of those two drives.

The hard drive cache isnt even relevant for the movement
of large files from one partition to another on the same drive.
Could you please explain how does hard drive cache actually work, if
it doesn't work like I'd imagine it to work and you seem to know better?

See just above.
I have thought that data is read into the buffer and then data is written from buffer when it's
full.

Nope, hard drive cache use is MUCH more complicated than that.
A dummy like me would think that this reduces the need for heads to jump from place to another

Nope, that isnt what the hard drive cache is for and that wont happen with your
movement of large files from one partition to another on the same drive anyway.
and increases performance as drive is able to move bigger chunks of data at once.

In your test the data has to move into memory and back out again
in much bigger chunks than the size of the hard drive cache.
So when (for example) copying large files from place A to place B drive with bigger cache would be
faster,
because its heads don't need to move back and forth so much as with drive with smaller cache.

That would only be true if the hard drive itself is doing
the copying. It isnt, that happens at the OS level and
the files have to be moved from the platter to the ram
on the motherboard and back out again.
 
R

Rod Speed

De Moni said:
Rod Speed wrote
Then what specs matter the most?

Depends on the operation you are comparing the drives
with. With your movement of large files from one partition
to another on the same drive its the thruput rate.
Both drives have rotational speed of 7200rpm.

Thats just one factor in the drive's physical characteristics.
The other crucial one is the sectors per track. Those two drives
are very different in that regard with the Samsung much better,
essentially because its got more data per surface and per track.
Both drives were in UDMA5-mode.

That one isnt really important at all, its the drive physical
characteristics that matters much more, in this case the
sectors per track since the RPM is the same with both drives.
Seek times seem to have marginal differences.
Correct.

Only bigger difference seems to be cache size 2Mb vs. 8Mb

Nope, the important difference is sectors per track.
which would explain why Samsung performs better when copying large files.

Nope, its the sectors per track that matters FAR more.
I know short answers make you look smart but it would be nice to hear a bit more detailed
explanations to back up your opinions.

It isnt an opinion, its fact, as shown in
http://www.storagereview.com/php/be...&numDrives=1&devID_0=252&devID_1=241&devCnt=2
OS cache may speed things up by keeping smaller files in memory for faster access, but copying
large files is that I was talking about and there OS cache doesn't seem to help much.

True, but the hard drive cache doesnt help any in that test either.

Its the sectors per track that matter and the Samsung is much better there.
 
D

De Moni

Rod said:
The Samsung is 30% better on the benchmarks that matter,
SR Office DriveMark 2002 etc

So Samsung should overally be faster than Seagate in everything.
It's strange then that I haven't noticed performance increase in any
other use than copying large files. WinXP boot time is about the same,
games don't load any faster etc.

Oh, well. The reason anyway I upgraded hard drive was that it felt like
it took half a day for Seagate to author DVD, which requires copying
gigs of data. Now Samsung does it a lot faster, even if 8Mb cache has
nothing to do with it :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top