Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Capabilities System: Capabilities Generator should generate capabilities (precompute) as serialized UIntSet buffers #4163

Closed
ArielG-NV opened this issue May 14, 2024 · 0 comments · Fixed by #4269
Assignees
Labels
goal:quality & productivity Quality issues and issues that impact our productivity coding day to day inside slang kind:performance things we wish were faster

Comments

@ArielG-NV
Copy link
Collaborator

ArielG-NV commented May 14, 2024

Generator should precompute relationships into serialized/ready-to-use UIntSet buffers. This should make loading capabilities faster through being more direct

-> ~2% of stdlib compile time

@ArielG-NV ArielG-NV added kind:performance things we wish were faster goal:quality & productivity Quality issues and issues that impact our productivity coding day to day inside slang labels May 14, 2024
@ArielG-NV ArielG-NV changed the title Capabilities System: Generator should compact relationships into a list of UintSet.m_buffers Capabilities System: Generator should compact relationships into the generated header as a list of UIntSet.m_buffers May 14, 2024
@ArielG-NV ArielG-NV assigned ArielG-NV and unassigned ArielG-NV May 14, 2024
@ArielG-NV ArielG-NV changed the title Capabilities System: Generator should compact relationships into the generated header as a list of UIntSet.m_buffers Capabilities System: Generator should precompute relationships into serialized/ready-to-use UIntSet buffers May 29, 2024
@ArielG-NV ArielG-NV changed the title Capabilities System: Generator should precompute relationships into serialized/ready-to-use UIntSet buffers Capabilities System: Capabilities Generator should generate capabilities (precompute) as serialized UIntSet buffers Jun 3, 2024
ArielG-NV added a commit to ArielG-NV/slang that referenced this issue Jun 4, 2024
Precompute UIntSet from individual capabilities inside generator (removes intermediate form of capabilities).

note:
1. I still expand capabilities which are missing `target` and `stage` atoms.
ArielG-NV added a commit to ArielG-NV/slang that referenced this issue Jun 4, 2024
Precompute UIntSet from individual capabilities inside generator (removes intermediate form of capabilities).

note:
1. I still expand capabilities which are missing `target` and `stage` atoms.
ArielG-NV added a commit that referenced this issue Jun 7, 2024
* fixes: #4163

Precompute UIntSet from individual capabilities inside generator (removes intermediate form of capabilities).

note:
1. I still expand capabilities which are missing `target` and `stage` atoms.

* fix compile warning<->error with clang

* address review

preallocate the pregenerated UIntSet's

* disable incorrect warning of 'unreachable code'

The warning is wrong since, when `out` has 0 elements (does not start `for` loop), the `return` is reached.

* fix clang warnings

1. use unsigned long for the buffer serializer
2. braces around scalar init

* address review

added work around to avoid warning with `for(...) return; return;` pattern

`else if constexpr` addition instead of cascading blocks

* push fix for use of `_BitScanForward`

* cleanup

* move around assert for proper checking

* syntax error

* use SLANG_ASSERT instead of assert

* test for why SLANG_ASSERT caused CI to fail with linux-arm builds

* test if `SLANG_ASSERT` really is causing a build issue for linux-arm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
goal:quality & productivity Quality issues and issues that impact our productivity coding day to day inside slang kind:performance things we wish were faster
Projects
None yet
1 participant