Skip to content

Commit c6c04fe

Browse files
rossmotleyrobtaylor
authored andcommitted
macOS simulation fixes (#26)
* Update to newest yowasp-yosys with fixes (0.40.0.68.post721.dev0). Needs override because of chipflow-lib version. * Updated cxxrtl_server.h
1 parent fc79f6f commit c6c04fe

File tree

3 files changed

+23
-17
lines changed

3 files changed

+23
-17
lines changed

my_design/sim/vendor/cxxrtl/cxxrtl_server.h

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -291,9 +291,10 @@ enum class simulation_status {
291291
};
292292

293293
enum class diagnostic_type: uint32_t {
294-
print = 1 << 0,
295-
assertion = 1 << 1, // avoid name clash with `assert`
296-
assumption = 1 << 2,
294+
breakpoint = 1 << 0, // avoid name clash with `break`
295+
print = 1 << 1,
296+
assertion = 1 << 2, // avoid name clash with `assert`
297+
assumption = 1 << 3,
297298
};
298299

299300
enum class pause_reason {
@@ -920,14 +921,16 @@ class server {
920921
return build_error("invalid_args", "The `run_simulation` command requires the `until_diagnostics` argument to be an array.");
921922
until_diagnostics = 0;
922923
for (json &json_diagnostic_type : packet.at("until_diagnostics"))
923-
if (json_diagnostic_type == "print")
924+
if (json_diagnostic_type == "break")
925+
until_diagnostics |= (uint32_t)diagnostic_type::breakpoint;
926+
else if (json_diagnostic_type == "print")
924927
until_diagnostics |= (uint32_t)diagnostic_type::print;
925928
else if (json_diagnostic_type == "assert")
926929
until_diagnostics |= (uint32_t)diagnostic_type::assertion;
927930
else if (json_diagnostic_type == "assume")
928931
until_diagnostics |= (uint32_t)diagnostic_type::assumption;
929932
else
930-
return build_error("invalid_args", "The `run_simulation` command supports the following diagnostic types: `print`, `assert`, `assume`.");
933+
return build_error("invalid_args", "The `run_simulation` command supports the following diagnostic types: `break`, `print`, `assert`, `assume`.");
931934
packet.erase("until_diagnostics");
932935
if (!(packet.contains("sample_item_values") && packet.at("sample_item_values").is_boolean()))
933936
return build_error("invalid_args", "The `run_simulation` command requires the `sample_item_values` argument to be a boolean.");

pdm.lock

Lines changed: 12 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,3 +36,6 @@ test = [
3636
[tool.pdm.scripts]
3737
_.env_file = ".env.toolchain"
3838
test.cmd = "pytest"
39+
40+
[tool.pdm.resolution.overrides]
41+
yowasp-yosys = "0.40.0.68.post721.dev0"

0 commit comments

Comments
 (0)