Skip to content

Better data structures for LoopKernel.(domains|inames) #298

Closed
kaushikcfd wants to merge 20 commits intomainfrom
loop_kernel_domains
Closed

Better data structures for LoopKernel.(domains|inames) #298
kaushikcfd wants to merge 20 commits intomainfrom
loop_kernel_domains

Conversation

@kaushikcfd
Copy link
Collaborator

  • Domains: The new LoopKernelDomains class now holds on to some derived variables that are incrementally updated to avoid recomputation during every instantitation.
  • Inames: Stores inames in a sparse-sense.
  • Depends on make LoopKernel.__init__ leaner #293

@kaushikcfd kaushikcfd force-pushed the loop_kernel_domains branch 3 times, most recently from c0956d3 to 6bdf0f4 Compare April 17, 2021 00:29
@kaushikcfd kaushikcfd force-pushed the loop_kernel_domains branch from 9234751 to 241194f Compare April 26, 2021 13:11
@kaushikcfd kaushikcfd force-pushed the loop_kernel_domains branch from 241194f to 584109a Compare June 2, 2021 23:52
kaushikcfd added 20 commits June 2, 2021 19:18
This is done by adding attribute-specific copies so that heavy operations in
LoopKernel.__init__ are invoked only when necessary
* Provides better performance via taking into account incremental updates
* Adds :mod:`pyrsistent` as a dep.
* dict would be a dense data structure that would require lead costly LoopKernel
  copies.
* pyrsistent.PClass doesn't play well with pylint
* adds pyrsistent to list of intersphinx mappings
* LoopKernelDomains.swap(..) exits early if the obtained domain is identical
- there was really no good reason why this was present in the first place
- allowing this is a GOOD idea as it allows to have more flexibility in defining
  fine-grained domains
@kaushikcfd kaushikcfd force-pushed the loop_kernel_domains branch from 584109a to c3112cc Compare June 3, 2021 00:34
@kaushikcfd
Copy link
Collaborator Author

This PR started depending on #372 in that the current code-generation implementation starts doing wonky updates to the domain which doesn't retain certain assumptions this branch makes like each iname belongs to exactly one home domain. I'm closing this in favor of that. The downside is that #372 starts increasing in volume, but there's no good way to keep them separate.

@kaushikcfd kaushikcfd closed this Jun 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant