Skip to contentSkip to conversation

Add the Elevator I/O scheduler

PATCH Al Boldi 2 participants 2 messages Aug 4, 2006

lore
Share & tools
lore

Al Boldi

author
#0 lore raw
Quoted 1 line · Nate Diller

This is the Elevator I/O scheduler. It is a simple one-way elevator,

Thanks for yet another attempt to achieve an efficient 2.6 elevator.

Quoted 1 line

+static inline char contig_char(struct el_request *e)

You probably meant el_req. Check the rest.

Review

Quoted 5 lines
(quoted diff) +5 -0
+static void print_queue(struct request_queue *q, struct el_data *el)
+{
+       struct el_req *e;
+
+       printel(el);

Should be print_el_data.

Applied against 2.6.17, it boots with this:
io scheduler elevator registered (default)
elevator: forced dispatching is broken (nr_sorted=13), please report this

Review

Quoted 3 lines
(quoted diff) +3 -0
+In pure form its largest weakness is starvation of other processes due to
+one process writing a very large number of contiguous requests (e.g.
+tarring a very large tar file while other processes are trying to run).

cat /dev/hda > /dev/null starves the rest of the system.

Review

Quoted 5 lines
(quoted diff) +5 -0
+The max_contig and max_write tunables are two (imperfect) solutions. They
+
+These two tunables are still under construction, but they have proven
+somewhat useful in practice.  Usually, max_contig should be the same size
+(in bytes) as ra_pages.

It's 0 by default. Setting it to ra_pages prints this:
nate 1977: max_contig went backwards

Quoted 6 lines
(quoted diff) +4 -0
+
+  SSTF
+
+The SSTF feature was added on a whim.  It ignores the tunables, and

probably +breaks tracing. I didn't ever see it perform better than SCAN, but who +knows?

Starves too.

Thanks!

--
Al

#1 lore raw
Quoted 4 lines · Al Boldi
Quoted 1 line · Nate Diller

This is the Elevator I/O scheduler. It is a simple one-way elevator,

Thanks for yet another attempt to achieve an efficient 2.6 elevator.

hopefully it's useful for you, I'd love to see performance results one way or the other.

Quoted 13 lines
Quoted 2 lines

+static inline char contig_char(struct el_request *e)

You probably meant el_req. Check the rest.

Review

Quoted 5 lines
(quoted diff) +5 -0
+static void print_queue(struct request_queue *q, struct el_data *el)
+{
+       struct el_req *e;
+
+       printel(el);

Should be print_el_data.

Quoted 3 lines

Applied against 2.6.17, it boots with this:
io scheduler elevator registered (default)
elevator: forced dispatching is broken (nr_sorted=13), please report this

damn, i thought i fixed that.

Quoted 6 lines

Review

Quoted 4 lines
(quoted diff) +3 -0
+In pure form its largest weakness is starvation of other processes due to
+one process writing a very large number of contiguous requests (e.g.
+tarring a very large tar file while other processes are trying to run).

cat /dev/hda > /dev/null starves the rest of the system.

yeah, that can be worse on some systems than others, it seems to vary a bit with file system and device driver. some setups cause more "breaks" in the stream of requests.

Quoted 9 lines

Review

Quoted 6 lines
(quoted diff) +5 -0
+The max_contig and max_write tunables are two (imperfect) solutions. They
+
+These two tunables are still under construction, but they have proven
+somewhat useful in practice.  Usually, max_contig should be the same size
+(in bytes) as ra_pages.

It's 0 by default. Setting it to ra_pages prints this:
nate 1977: max_contig went backwards

hmmm, haven't tested this recently. dunno why that would have broken...

Quoted 9 lines
Quoted 7 lines
(quoted diff) +4 -0
+
+  SSTF
+
+The SSTF feature was added on a whim.  It ignores the tunables, and

probably +breaks tracing. I didn't ever see it perform better than SCAN, but who +knows?

Starves too.

oh, yeah, definitely, this algorithm is only suitable for a workload where you want latency over fairness. suppose i should mention that.

Thanks for your comments and testing

NATE