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

code redundancy: magma_[cdsz]shell_sort and magma_[cdsz]symbolic_ilu #23

Open
jeffhammond opened this issue Dec 10, 2024 · 4 comments
Open

Comments

@jeffhammond
Copy link

magma_[cdsz]shell_sort and magma_[cdsz]symbolic_ilu are identical. perhaps they should be renamed without the [cdsz] and consolidated.

magma_[cdsz]shell_sort use the variable name max, which is dangerous, since you have an almost-global macro for that, and it's also a standard-library symbols in the std namespace.

@nbeams
Copy link
Contributor

nbeams commented Dec 10, 2024

By default, almost all of the files in MAGMA are auto-generated from the z version, which does often lead to code duplication. We are considering a major overhaul of this process, with templates where needed and unique versions where not. But the max issue is indeed more critical.

Both of these routines are in MAGMA sparse -- are you wanting to use the sparse component for something? I ask because we are planning to deprecate a large chunk of MAGMA-sparse in this upcoming release. Most of the features now have cleaner and better-maintained implementations over in the Ginkgo library (https://github.com/ginkgo-project/ginkgo). But if you need MAGMA-sparse specifically, it would be good for us to know which routines you want to use.

@jeffhammond
Copy link
Author

Honestly, I was just trying to get the whole project to compile on my machine. I only need some of the dense stuff, but I didn't see a way to conditionally compile a subset.

@nbeams
Copy link
Contributor

nbeams commented Dec 10, 2024

make lib should only build the dense library (then you can do make sparse if you want sparse). The sparse component gets built into its own library, anyway, so libmagma will be the same either way. But you can save on some build time!

@jeffhammond
Copy link
Author

awesome. thanks!

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

No branches or pull requests

2 participants