Skip to content

Commit 3b695ec

Browse files
committed
domains: Move domain configs to elaborate configs
Signed-off-by: Krishnan Winter <krishnan.winter@unsw.edu.au>
1 parent 952ff18 commit 3b695ec

3 files changed

Lines changed: 14 additions & 28 deletions

File tree

build_sdk.py

Lines changed: 9 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -465,29 +465,6 @@ class KernelPath:
465465
}
466466
},
467467
),
468-
# TODO: This is experimental for now, do this in a better way
469-
ConfigInfo(
470-
name="release_domains",
471-
debug=False,
472-
kernel_options={
473-
"KernelNumDomains": 256,
474-
"KernelNumDomainSchedules": 256,
475-
},
476-
kernel_options_arch={},
477-
),
478-
ConfigInfo(
479-
name="debug_domains",
480-
debug=True,
481-
kernel_options={
482-
"KernelDebugBuild": True,
483-
"KernelPrinting": True,
484-
"KernelVerificationBuild": False,
485-
"KernelNumDomains": 256,
486-
"KernelNumDomainSchedules": 256,
487-
},
488-
kernel_options_arch={},
489-
),
490-
491468
)
492469

493470

@@ -512,6 +489,15 @@ def elaborate_all_board_configs(board: BoardInfo) -> list[ConfigInfo]:
512489
}
513490
elaborated_configs.append(config)
514491

492+
for config in SUPPORTED_CONFIGS:
493+
config = copy.deepcopy(config)
494+
config.name = f"domain-{config.name}"
495+
config.kernel_options |= {
496+
"KernelNumDomains": 64,
497+
"KernelNumDomainSchedules": 128,
498+
}
499+
elaborated_configs.append(config)
500+
515501
return elaborated_configs
516502

517503

docs/manual.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1143,9 +1143,9 @@ The `end` element has the following attributes:
11431143
The `id` is passed to the PD in the `notified` and `protected` entry points.
11441144
The `id` should be passed to the `microkit_notify` and `microkit_ppcall` functions.
11451145

1146-
## `domain_schedule` (experimental)
1146+
## `domain_schedule`
11471147

1148-
The `domain_schedule` element, by default, has a list of up to 256 `domain` child elements. This can be configured by changing the number of schedule entries defined in the `release_domains` and `debug_domains` configs in `build_sdk.py`. Each child specifies a particular timeslice in the domain schedule and the order of the child elements specifies the order in which the timeslices will be scheduled. A domain may be named more than once in the schedule, in which case the domain will have multiple timeslices in the schedule.
1148+
The `domain_schedule` element, by default, has a list of up to 128 `domain` child elements (bounded by the kernel config). This can be configured by changing the number of schedule entries defined in `elaborate_all_board_configs` in `build_sdk.py`. Each child specifies a particular timeslice in the domain schedule and the order of the child elements specifies the order in which the timeslices will be scheduled. A domain may be named more than once in the schedule, in which case the domain will have multiple timeslices in the schedule.
11491149

11501150
The `domain` element has the following attributes:
11511151

@@ -1161,7 +1161,7 @@ The `domain_idx_shift` element has the following attribute:
11611161
The `domain_start` element has the following attribute:
11621162
* `index`: This is the start index of the domain schedule. When the kernel reaches the end of the domain schedule, it will wrap around to this index again. This index is an offset into the user defined schedule, and not an absolute index. If no domain start index is set, then the Microkit tool will set this to 0 by default.
11631163

1164-
The `domain_schedule` element is only valid if the using one of the domain configs (`release_domains`, `debug_domains`).
1164+
The `domain_schedule` element is only valid if the using one of the domain configs (`domain-release`, `domain-debug`, `domain-benchmark`).
11651165

11661166
# Board Support Packages {#bsps}
11671167

tool/microkit/src/capdl/packaging.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,9 @@ pub fn pack_spec_into_initial_task(
5252

5353
for named_obj in output_spec.objects.iter_mut() {
5454
match build_config {
55-
"smp-debug" | "debug" | "debug_domains" => {}
55+
"smp-debug" | "debug" | "domain-debug" => {}
5656
// We don't copy over the object names as there is no debug printing in these configuration to save memory.
57-
"release" | "release_domains" | "benchmark" | "smp-release" | "smp-benchmark" => {
57+
"release" | "benchmark" | "smp-release" | "smp-benchmark" | "domain-release" | "domain-benchmark" => {
5858
named_obj.name = None
5959
}
6060
_ => panic!("unknown configuration {build_config}"),

0 commit comments

Comments
 (0)