Page MenuHomePhabricator

[CUDA] Assume the latest known CUDA version if we've found an unknown one.
ClosedPublic

Authored by tra on Wed, Jan 22, 2:19 PM.

Details

Summary

This makes clang somewhat forward-compatible with new CUDA releases without
having to patch it for every minor release without adding any new functionality.

If an unknown version is found, clang issues a warning (can be disabled with -Wno-cuda-unknown-version)
and assumes that it has detected the latest known version. CUDA releases are usually supersets
of older ones feature-wise, so it should be sufficient to keep released clang versions
working with minor CUDA updates without having to upgrade clang, too.

Diff Detail

Event Timeline

tra created this revision.Wed, Jan 22, 2:19 PM
Herald added a project: Restricted Project. · View Herald TranscriptWed, Jan 22, 2:19 PM
yaxunl accepted this revision.Mon, Jan 27, 8:32 AM

LGTM. Thanks.

This revision is now accepted and ready to land.Mon, Jan 27, 8:32 AM
tra updated this revision to Diff 240731.Mon, Jan 27, 4:44 PM
tra edited the summary of this revision. (Show Details)

Use std::string instead of Twine which can't be stored.

yaxunl accepted this revision.Tue, Jan 28, 9:40 AM

LGTM

This revision was automatically updated to reflect the committed changes.
tra edited the summary of this revision. (Show Details)Tue, Jan 28, 10:22 AM
tra added a subscriber: hans.

@hans : that's another candidate for 10.x cherry-pick, if you're OK with it.

hans added a comment.Wed, Jan 29, 12:22 PM
In D73231#1845096, @tra wrote:

@hans : that's another candidate for 10.x cherry-pick, if you're OK with it.

Sounds good to me. Cherry-picked in 5777899f146aaa53f598e6978702a7a2725200d7