@@ -16,39 +16,39 @@ resource-specific operations such as work submission and synchronization.
1616
1717All policies support three construction patterns:
1818
19- **Initialization with explicit resources **: Construct the policy with an explicit
20- vector of resources to manage:
19+ 1. **Initialization with explicit resources ** - Construct the policy with an explicit
20+ vector of resources to manage:
2121
22- .. code :: cpp
22+ .. code :: cpp
2323
24- namespace ex = oneapi::dpl::experimental;
25- std::vector<resource_type> r {/* resources */};
26- ex::round_robin_policy policy{r};
24+ namespace ex = oneapi::dpl::experimental;
25+ std::vector<resource_type> r {/* resources */};
26+ ex::round_robin_policy policy{r};
2727
28- **Default initialization **: Construct the policy without arguments, allowing the
29- backend to select default resources:
28+ 2. **Default initialization ** - Construct the policy without arguments, allowing the
29+ backend to select default resources:
3030
31- .. code :: cpp
31+ .. code :: cpp
3232
33- namespace ex = oneapi::dpl::experimental;
34- ex::round_robin_policy policy{}; // uses backend's default resources
33+ namespace ex = oneapi::dpl::experimental;
34+ ex::round_robin_policy policy{}; // uses backend's default resources
3535
36- **Deferred initialization **: Construct the policy in an uninitialized state, then
37- initialize it later by calling ``initialize() ``:
36+ 3. **Deferred initialization ** - Construct the policy in an uninitialized state, then
37+ initialize it later by calling ``initialize() ``:
3838
39- .. code :: cpp
39+ .. code :: cpp
4040
41- namespace ex = oneapi::dpl::experimental;
42- ex::round_robin_policy policy{ex::deferred_initialization};
43- // ... later, when resources are available ...
44- policy.initialize(resources);
41+ namespace ex = oneapi::dpl::experimental;
42+ ex::round_robin_policy policy{ex::deferred_initialization};
43+ // ... later, when resources are available ...
44+ policy.initialize(resources);
4545
46- Deferred initialization is useful when the policy must be constructed before
47- execution resources are available, such as during early program setup or when
48- resources depend on runtime configuration.
46+ Deferred initialization is useful when the policy must be constructed before
47+ execution resources are available, such as during early program setup or when
48+ resources depend on runtime configuration.
4949
50- Attempting to use a deferred-initialization policy before calling ``initialize() ``
51- will throw ``std::logic_error ``.
50+ Attempting to use a deferred-initialization policy before calling ``initialize() ``
51+ will throw ``std::logic_error ``.
5252
5353Once policies are initialized, work can be submitted via the submit
5454:doc: `free functions <functions >`: ``submit ``, ``submit_and_wait ``, or ``try_submit ``,
0 commit comments