Sujet : Re: Is Parallel Programming Hard, And, If So, What Can You Do About It?
De : sfuld (at) *nospam* alumni.cmu.edu.invalid (Stephen Fuld)
Groupes : comp.archDate : 20. May 2025, 19:35:15
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <100ii13$2b6j8$1@dont-email.me>
References : 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
User-Agent : Mozilla Thunderbird
On 5/20/2025 10:42 AM, BGB wrote:
On 5/20/2025 9:49 AM, Stefan Monnier wrote:
You need RAM to make this work, and a few MB of HDD side cache isn't a huge
cost if one would have already needed the same stuff to make the HDD work.
>
Indeed, AFAIK, what we call "HDD cache" is actually just the RAM used
by the embedded CPU inside the drive for its operation.
I expect this is used to store the information about in-flight requests
(e.g. most importantly the data about the write requests received but
that haven't yet reached the platters), but I also expects it holds data
that happened to fly recently by the read-head, just in case.
>
Probably.
Again, a caveat that my knowledge is pretty old, and may have been superseded.
The drive certainly needs some DRAM for its internal operations, but as has been pointed out, the cost of making this larger and using that extra for cache is pretty small. I just checked and a current Seagate drive has 512 MB of cache. That cache is used on both reads and writes.
For reads, the vendor can specify the max amount to prefetch, which then determines the number of segments the cache is divided into. i.e. you might not want to cache the rest of the track since that might force not keeping the data from a previous read. You can also specify the minimum to prefetch, which can be zero, which determines how soon the drive can move the heads for another request.
For writes, even if no write caching is allowed, the DRAM is used to accept the write data before the heads have arrived at the requested track and the disk has spun to the required sector. This allows for a faster response in the case that the heads arrive on track in the "middle" of the requested write area so the drive can write the last part of the transfer to the disk before the first part. (i.e. you overlap the time to transfer the last part of the request to the disk with the rotation.) Of course, if write caching is enabled, the DRAM is used to hold the write data until it can be written to the disk.
As I understand it, it is this, along with a certain amount of "read prefetch", which is granted, typically the data for the rest of the track as the drive spins around;
Perhaps. See above.
And, keeping some copies of previously read content around, which can be read again from this cache if they happen to be requested.
As I understand it, also more modern HDDs tend to be "density per area" rather than angular slices (as it was on much older HDDs and floppies, *), so there would be more sectors on outer tracks vs on inner tracks.
This has been done for well over 30 years. It allows the disk capacity to be increased by about 1/3 without any increased cost of the disk, hence lowers cost per gigabyte of the disk. Of course it requires an interface, such as, originally SCSI, but now also SATA that is block oriented not cyl/head/record oriented.
-- - Stephen Fuld(e-mail address disguised to prevent spam)
Date | Sujet | # | | Auteur |
10 May 25 | Is Parallel Programming Hard, And, If So, What Can You Do About It? | 91 | | Thomas Koenig |
11 May 25 |  Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 60 | | MitchAlsup1 |
11 May 25 |   Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 59 | | Al Kossow |
12 May 25 |    Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 58 | | Lawrence D'Oliveiro |
12 May 25 |     Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 57 | | MitchAlsup1 |
12 May 25 |      Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 56 | | Lawrence D'Oliveiro |
12 May 25 |       Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 2 | | MitchAlsup1 |
12 May 25 |        Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Lawrence D'Oliveiro |
12 May 25 |       Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 53 | | Terje Mathisen |
12 May 25 |        Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 3 | | Anton Ertl |
12 May 25 |         Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Lawrence D'Oliveiro |
13 May 25 |         Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Stephen Fuld |
12 May 25 |        Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 49 | | Lawrence D'Oliveiro |
13 May 25 |         Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 4 | | Stefan Monnier |
13 May 25 |          Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 3 | | Lawrence D'Oliveiro |
13 May 25 |           Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Stefan Monnier |
13 May 25 |           Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Stephen Fuld |
13 May 25 |         Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 43 | | Anton Ertl |
13 May 25 |          Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 42 | | Lawrence D'Oliveiro |
13 May 25 |           Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 41 | | Stephen Fuld |
14 May 25 |            Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 36 | | Lawrence D'Oliveiro |
14 May 25 |             Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 33 | | Stephen Fuld |
18 May02:35 |              Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 32 | | Lawrence D'Oliveiro |
19 May01:10 |               Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 6 | | Lynn Wheeler |
19 May21:46 |                Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 5 | | Vir Campestris |
19 May22:58 |                 Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 4 | | Stephen Fuld |
20 May11:22 |                  Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Vir Campestris |
21 May03:38 |                  Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 2 | | Lynn Wheeler |
21 May04:49 |                   Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Stephen Fuld |
19 May01:18 |               Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 25 | | MitchAlsup1 |
20 May00:33 |                Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 24 | | MitchAlsup1 |
20 May01:36 |                 Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 23 | | Lawrence D'Oliveiro |
20 May06:16 |                  Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 22 | | BGB |
20 May15:49 |                   Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 20 | | Stefan Monnier |
20 May18:42 |                    Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 2 | | BGB |
20 May19:35 |                     Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Stephen Fuld |
21 May01:29 |                    Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 17 | | Lawrence D'Oliveiro |
21 May02:08 |                     Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 12 | | BGB |
21 May04:46 |                      Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 11 | | Lawrence D'Oliveiro |
21 May04:58 |                       Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 10 | | Stephen Fuld |
21 May18:19 |                        Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 9 | | Anton Ertl |
22 May03:19 |                         Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 7 | | George Neuner |
22 May07:51 |                          Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 6 | | BGB |
22 May13:12 |                           Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 5 | | Torbjorn Lindgren |
22 May18:39 |                            Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 4 | | BGB |
22 May23:41 |                             Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 3 | | Lawrence D'Oliveiro |
23 May00:36 |                              Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 2 | | BGB |
23 May15:21 |                               Re: the power of junk, Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | John Levine |
22 May12:32 |                         Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Dan Cross |
21 May04:54 |                     Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 4 | | Stephen Fuld |
21 May06:39 |                      Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 3 | | Lawrence D'Oliveiro |
21 May07:42 |                       Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Stephen Fuld |
21 May08:08 |                       Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | BGB |
21 May01:57 |                   Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Lawrence D'Oliveiro |
14 May 25 |             Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 2 | | John Levine |
14 May 25 |              Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Thomas Koenig |
23 May01:18 |            Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 4 | | Waldek Hebisch |
23 May06:35 |             Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 3 | | Lawrence D'Oliveiro |
23 May07:09 |              Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 2 | | BGB |
23 May13:36 |               Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | MitchAlsup1 |
18 May00:57 |         Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Lawrence D'Oliveiro |
19 May22:33 |  Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 29 | | quadibloc |
20 May01:43 |   Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 28 | | Lawrence D'Oliveiro |
20 May19:19 |    Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 27 | | BGB |
20 May21:06 |     Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 23 | | Stefan Monnier |
20 May23:11 |      Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 20 | | MitchAlsup1 |
21 May01:34 |       Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Lawrence D'Oliveiro |
21 May02:00 |       Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Lawrence D'Oliveiro |
21 May02:30 |       Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 8 | | George Neuner |
21 May02:39 |        Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 7 | | Chris M. Thomasson |
21 May04:41 |         Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 4 | | Lawrence D'Oliveiro |
21 May17:09 |          Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | George Neuner |
21 May20:30 |          Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 2 | | Stefan Monnier |
22 May03:45 |           Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Lawrence D'Oliveiro |
21 May18:06 |         Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 2 | | Lynn Wheeler |
21 May22:32 |          Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | jseigh |
21 May08:05 |       Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 2 | | Anton Ertl |
22 May03:48 |        Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Lawrence D'Oliveiro |
21 May13:23 |       Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 7 | | Stefan Monnier |
21 May15:08 |        Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 6 | | MitchAlsup1 |
22 May03:49 |         Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 5 | | Lawrence D'Oliveiro |
22 May18:34 |          Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 3 | | MitchAlsup1 |
22 May23:42 |           Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Lawrence D'Oliveiro |
23 May02:54 |           Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | MitchAlsup1 |
23 May04:47 |          Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | George Neuner |
21 May01:32 |      Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 2 | | Lawrence D'Oliveiro |
21 May02:29 |       Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Chris M. Thomasson |
21 May02:04 |     Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 3 | | Chris M. Thomasson |
23 May00:49 |      Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 2 | | Chris M. Thomasson |
23 May02:04 |       Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Chris M. Thomasson |
21 May02:31 |  Re: Is Parallel Programming Hard, And, If So, What Can You Do About It? | 1 | | Chris M. Thomasson |