async fast path
Asked Answered
P

2

6

Here is an article on how the Async CTP refresh can take advantage of the async "fast path".

It mentions things like greater efficiency etc, but I dont even know what the "fast path" is? I would like to determine whether the tips in the article are relevant to me, but could not really find an explanation of "fast path"?

Photozincography answered 7/1, 2012 at 11:29 Comment(0)
K
8

The "fast path" is when the Task being awaited has already completed by the time it is awaited.

If this happens, then there is no point in await returning from your method because the next continuation will be queued immediately.

So in the "fast path", await does not yield and execution continues in your method.

Karlsbad answered 7/1, 2012 at 11:34 Comment(0)
N
1

I may be wrong, but my understanding here is that the "fast path" is the scenario when the task turns out to be completed already at the point you want to do an await continuation. Since it is already complete, a lot of the overhead in setting up the continuation and leaving the current method can be avoided.

Nannettenanni answered 7/1, 2012 at 11:36 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.