perf: make Equiv transfer instances more reduced#41002
Conversation
|
!radar |
|
Benchmark results for 80eb309 against 9e46613 are in. No significant results found. @JovanGerb
Medium changes (2✅)
Small changes (6✅)
|
PR summary d04eef70aeImport changes for modified filesNo significant changes to the import graph Import changes for all files
|
| @[to_additive (dont_translate := R) (attr := simps! apply symm_apply) | ||
| /-- `MonoidAlgebra.coeff` as a linear equiv. -/] | ||
| def coeffLinearEquiv : S[M] ≃ₗ[R] M →₀ S := | ||
| coeffEquiv.linearEquiv _ | ||
| def coeffLinearEquiv : S[M] ≃ₗ[R] M →₀ S where | ||
| __ := coeffEquiv | ||
| __ := coeffEquiv.addEquiv (β := M →₀ S) | ||
| map_smul' m x := (coeffEquiv.linearEquiv R (β := M →₀ S) :).map_smul m x |
There was a problem hiding this comment.
This strange rewrite of this definition was needed because otherwise the simps! lemmas would turn out very wrong.
|
awaiting-author |
Co-authored-by: Whysoserioushah <109107491+Whysoserioushah@users.noreply.github.com>
Co-authored-by: Whysoserioushah <109107491+Whysoserioushah@users.noreply.github.com>
YaelDillies
left a comment
There was a problem hiding this comment.
Thanks! 🚀
maintainer merge
|
🚀 Pull request has been placed on the maintainer queue by YaelDillies. |
This pr speeds up the instances that are tranferred through
Equivs by using the projections.toFunand.invFundirectly in the data.I think that we should eventually deprecate these instances, and instead have a metaprogram that creates these instances for us in each use case.