Commit 100c648
committed
fix event caching
L0 requires the adapter to use a variety of different events, depending
on the specific use case and configuration. Events are also unique for
devices.
And, because the adapter wants to avoid unnecessarily allocating new
events from the driver, this necessities an event caching solution that
can separate the different event type and device combinations.
When counter-based events were introduced the event caching was
not properly expanded to take that event type into consideration,
presumably with the assumption that normal and counter based events
will never coexist. Unfortunately that is not true for the current
adapter implementation.
This patch simplifies the event caching logic, ensuring that
each unique event type and device combination has its own
event cache.1 parent db83117 commit 100c648
File tree
3 files changed
+61
-43
lines changed- source/adapters/level_zero
- test
3 files changed
+61
-43
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
565 | 565 | | |
566 | 566 | | |
567 | 567 | | |
568 | | - | |
569 | | - | |
| 568 | + | |
| 569 | + | |
| 570 | + | |
| 571 | + | |
| 572 | + | |
| 573 | + | |
570 | 574 | | |
| 575 | + | |
571 | 576 | | |
572 | 577 | | |
573 | 578 | | |
574 | | - | |
575 | | - | |
576 | | - | |
577 | 579 | | |
578 | 580 | | |
579 | 581 | | |
| 582 | + | |
| 583 | + | |
| 584 | + | |
| 585 | + | |
| 586 | + | |
| 587 | + | |
580 | 588 | | |
581 | 589 | | |
582 | 590 | | |
| |||
588 | 596 | | |
589 | 597 | | |
590 | 598 | | |
591 | | - | |
592 | | - | |
| 599 | + | |
| 600 | + | |
| 601 | + | |
| 602 | + | |
| 603 | + | |
| 604 | + | |
| 605 | + | |
593 | 606 | | |
594 | 607 | | |
595 | 608 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
169 | 169 | | |
170 | 170 | | |
171 | 171 | | |
172 | | - | |
173 | | - | |
174 | | - | |
175 | | - | |
176 | | - | |
177 | | - | |
178 | | - | |
179 | | - | |
180 | | - | |
181 | 172 | | |
182 | 173 | | |
183 | 174 | | |
| |||
313 | 304 | | |
314 | 305 | | |
315 | 306 | | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
316 | 323 | | |
317 | | - | |
318 | | - | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
319 | 328 | | |
320 | | - | |
321 | | - | |
322 | | - | |
323 | | - | |
324 | | - | |
325 | | - | |
326 | | - | |
327 | | - | |
328 | | - | |
329 | | - | |
330 | | - | |
331 | | - | |
332 | | - | |
333 | | - | |
334 | | - | |
335 | | - | |
336 | | - | |
337 | | - | |
338 | | - | |
339 | | - | |
340 | | - | |
341 | | - | |
342 | | - | |
343 | | - | |
344 | | - | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
345 | 333 | | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
346 | 346 | | |
347 | 347 | | |
348 | 348 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
20 | 25 | | |
21 | 26 | | |
22 | 27 | | |
| |||
0 commit comments