FoldingAtHome / openmm

OpenMM is a toolkit for molecular simulation using high performance GPU code.
22 stars 4 forks source link

Ensure compute capability is supported by CUDA 9.2 #26

Closed peastman closed 4 years ago

peastman commented 4 years ago

I think this should work, but I've haven't tested it because I don't have access to a machine that can run CUDA at the moment.

jchodera commented 4 years ago

From https://github.com/FoldingAtHome/openmm-core/pull/300#issuecomment-684023158:

It's specified by the CMake variables MAX_MAJOR_COMPUTE_CAPABILITY and MAX_MINOR_COMPUTE_CAPABILITY. It defaults to 7.0, which is the most recent architecture supported by CUDA 9.2.

jchodera commented 4 years ago

@peastman : This works! OK to merge.

Can we add this to the real OpenMM too?

peastman commented 4 years ago

I think we would want to handle this differently in standard OpenMM. The reason we're limiting it to a particular version is that we're bundling a particular version of the CUDA compiler with the core.

jchodera commented 4 years ago

Wouldn't that model work exactly the same with other CUDA-enabled applications as well? If developers want to use CUDA without having users install it, wouldn't bundling the libraries and pinning the max arch version be the right thing to do?

Even for conda distribution, we'll have the same issue---we'll need to do the same thing for the latest arch we support via the available cudatoolkit we use as a dependency, right?

peastman commented 4 years ago

The complication is that we're supporting many different toolkit versions, and each of those versions has a different maximum supported architecture. I'm hoping we can do something more sophisticated, where we automatically select it based on the toolkit version.