Commit 2cdf79cafbd11580f5b63cd4993b45c1c4952415
1 parent
7f3d4ee108
Exists in
master
and in
4 other branches
block: get rid of likely/unlikely predictions in merge logic
They tend to depend a lot on the workload, so not a clear-cut likely or unlikely fit. Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Showing 1 changed file with 6 additions and 6 deletions Side-by-side Diff
block/blk-merge.c
... | ... | @@ -149,9 +149,9 @@ |
149 | 149 | static int blk_hw_contig_segment(struct request_queue *q, struct bio *bio, |
150 | 150 | struct bio *nxt) |
151 | 151 | { |
152 | - if (unlikely(!bio_flagged(bio, BIO_SEG_VALID))) | |
152 | + if (!bio_flagged(bio, BIO_SEG_VALID)) | |
153 | 153 | blk_recount_segments(q, bio); |
154 | - if (unlikely(!bio_flagged(nxt, BIO_SEG_VALID))) | |
154 | + if (!bio_flagged(nxt, BIO_SEG_VALID)) | |
155 | 155 | blk_recount_segments(q, nxt); |
156 | 156 | if (!BIOVEC_VIRT_MERGEABLE(__BVEC_END(bio), __BVEC_START(nxt)) || |
157 | 157 | BIOVEC_VIRT_OVERSIZE(bio->bi_hw_back_size + nxt->bi_hw_front_size)) |
158 | 158 | |
... | ... | @@ -312,9 +312,9 @@ |
312 | 312 | q->last_merge = NULL; |
313 | 313 | return 0; |
314 | 314 | } |
315 | - if (unlikely(!bio_flagged(req->biotail, BIO_SEG_VALID))) | |
315 | + if (!bio_flagged(req->biotail, BIO_SEG_VALID)) | |
316 | 316 | blk_recount_segments(q, req->biotail); |
317 | - if (unlikely(!bio_flagged(bio, BIO_SEG_VALID))) | |
317 | + if (!bio_flagged(bio, BIO_SEG_VALID)) | |
318 | 318 | blk_recount_segments(q, bio); |
319 | 319 | len = req->biotail->bi_hw_back_size + bio->bi_hw_front_size; |
320 | 320 | if (BIOVEC_VIRT_MERGEABLE(__BVEC_END(req->biotail), __BVEC_START(bio)) |
321 | 321 | |
... | ... | @@ -352,9 +352,9 @@ |
352 | 352 | return 0; |
353 | 353 | } |
354 | 354 | len = bio->bi_hw_back_size + req->bio->bi_hw_front_size; |
355 | - if (unlikely(!bio_flagged(bio, BIO_SEG_VALID))) | |
355 | + if (!bio_flagged(bio, BIO_SEG_VALID)) | |
356 | 356 | blk_recount_segments(q, bio); |
357 | - if (unlikely(!bio_flagged(req->bio, BIO_SEG_VALID))) | |
357 | + if (!bio_flagged(req->bio, BIO_SEG_VALID)) | |
358 | 358 | blk_recount_segments(q, req->bio); |
359 | 359 | if (BIOVEC_VIRT_MERGEABLE(__BVEC_END(bio), __BVEC_START(req->bio)) && |
360 | 360 | !BIOVEC_VIRT_OVERSIZE(len)) { |