This is an archive of the discontinued LLVM Phabricator instance.

[C++4OpenCL] Add run line standard aliases clc++1.0 and CLC++1.0
ClosedPublic

Authored by Topotuna on Jul 19 2021, 5:05 AM.

Details

Summary

The commit renames language standard from openclcpp to openclcpp10.
It also enables run line arguments -cl-std=clc++1.0 and
-cl-std=CLC++1.0.

Diff Detail

Event Timeline

Topotuna created this revision.Jul 19 2021, 5:05 AM
Topotuna requested review of this revision.Jul 19 2021, 5:05 AM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptJul 19 2021, 5:05 AM
Anastasia added inline comments.Jul 19 2021, 2:56 PM
clang/include/clang/Basic/LangStandards.def
187

I am not sure we should move it into the deprecated category yet... for now let's just use LANGSTANDARD_ALIAS.

clang/test/Driver/unknown-std.cl
14

does it not print clc++ anymore?

Topotuna updated this revision to Diff 360059.Jul 20 2021, 2:28 AM

clc++ made no longer deprecated

clang/include/clang/Basic/LangStandards.def
187

You are right. I tried to closely follow how cl1.0 version is regarded on line 169, but it is a slightly different case because cl has more than one version already.

clang/test/Driver/unknown-std.cl
14

The error messages here are derived from language definitions in file Basic/LangStandards.def, so both files need to be modified accordingly.

Anastasia accepted this revision.Jul 21 2021, 11:24 AM

LGTM! Thanks!

This revision is now accepted and ready to land.Jul 21 2021, 11:24 AM

Quick note to prevent some confusion: I saw this patch and realized that the LLDB change was only necessary because some Clang code got copy pasted into LLDB. I removed that copy in https://reviews.llvm.org/D106537 so if you see merge conflicts while merging this, you can just drop the LLDB changes as they shouldn't be necessary once my patch landed. Thanks!

That is good to know. Thank you for sorting it out

This revision was landed with ongoing or failed builds.Jul 30 2021, 1:20 AM
This revision was automatically updated to reflect the committed changes.