Skip to content

Commit 4dcd896

Browse files
committed
Merge from 'master' to 'sycl-web' (#1)
CONFLICT (content): Merge conflict in clang/lib/Sema/SemaSYCL.cpp CONFLICT (content): Merge conflict in clang/include/clang/Sema/Sema.h
2 parents 62ea9a2 + 40df06c commit 4dcd896

File tree

191 files changed

+5001
-1621
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

191 files changed

+5001
-1621
lines changed

clang/docs/CommandGuide/clang.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -385,7 +385,7 @@ Code Generation Options
385385
:option:`-Og` Like :option:`-O1`. In future versions, this option might
386386
disable different optimizations in order to improve debuggability.
387387

388-
:option:`-O` Equivalent to :option:`-O2`.
388+
:option:`-O` Equivalent to :option:`-O1`.
389389

390390
:option:`-O4` and higher
391391

clang/include/clang/Basic/Diagnostic.td

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ class TextSubstitution<string Text> {
4545
// diagnostics
4646
string Component = "";
4747
string CategoryName = "";
48+
bit Deferrable = 0;
4849
}
4950

5051
// Diagnostic Categories. These can be applied to groups or individual
@@ -83,6 +84,7 @@ class Diagnostic<string text, DiagClass DC, Severity defaultmapping> {
8384
bit AccessControl = 0;
8485
bit WarningNoWerror = 0;
8586
bit ShowInSystemHeader = 0;
87+
bit Deferrable = 0;
8688
Severity DefaultSeverity = defaultmapping;
8789
DiagGroup Group;
8890
string CategoryName = "";
@@ -106,6 +108,14 @@ class SuppressInSystemHeader {
106108
bit ShowInSystemHeader = 0;
107109
}
108110

111+
class Deferrable {
112+
bit Deferrable = 1;
113+
}
114+
115+
class NonDeferrable {
116+
bit Deferrable = 0;
117+
}
118+
109119
// FIXME: ExtWarn and Extension should also be SFINAEFailure by default.
110120
class Error<string str> : Diagnostic<str, CLASS_ERROR, SEV_Error>, SFINAEFailure {
111121
bit ShowInSystemHeader = 1;

clang/include/clang/Basic/DiagnosticAST.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ namespace clang {
1515
namespace diag {
1616
enum {
1717
#define DIAG(ENUM, FLAGS, DEFAULT_MAPPING, DESC, GROUP, SFINAE, NOWERROR, \
18-
SHOWINSYSHEADER, CATEGORY) \
18+
SHOWINSYSHEADER, DEFERRABLE, CATEGORY) \
1919
ENUM,
2020
#define ASTSTART
2121
#include "clang/Basic/DiagnosticASTKinds.inc"

clang/include/clang/Basic/DiagnosticAnalysis.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ namespace clang {
1515
namespace diag {
1616
enum {
1717
#define DIAG(ENUM, FLAGS, DEFAULT_MAPPING, DESC, GROUP, SFINAE, NOWERROR, \
18-
SHOWINSYSHEADER, CATEGORY) \
18+
SHOWINSYSHEADER, DEFERRABLE, CATEGORY) \
1919
ENUM,
2020
#define ANALYSISSTART
2121
#include "clang/Basic/DiagnosticAnalysisKinds.inc"

clang/include/clang/Basic/DiagnosticComment.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ namespace clang {
1515
namespace diag {
1616
enum {
1717
#define DIAG(ENUM, FLAGS, DEFAULT_MAPPING, DESC, GROUP, SFINAE, NOWERROR, \
18-
SHOWINSYSHEADER, CATEGORY) \
18+
SHOWINSYSHEADER, DEFERRABLE, CATEGORY) \
1919
ENUM,
2020
#define COMMENTSTART
2121
#include "clang/Basic/DiagnosticCommentKinds.inc"

clang/include/clang/Basic/DiagnosticCrossTU.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ namespace clang {
1515
namespace diag {
1616
enum {
1717
#define DIAG(ENUM, FLAGS, DEFAULT_MAPPING, DESC, GROUP, SFINAE, NOWERROR, \
18-
SHOWINSYSHEADER, CATEGORY) \
18+
SHOWINSYSHEADER, DEFERRABLE, CATEGORY) \
1919
ENUM,
2020
#define CROSSTUSTART
2121
#include "clang/Basic/DiagnosticCrossTUKinds.inc"

clang/include/clang/Basic/DiagnosticDriver.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ namespace clang {
1515
namespace diag {
1616
enum {
1717
#define DIAG(ENUM, FLAGS, DEFAULT_MAPPING, DESC, GROUP, SFINAE, NOWERROR, \
18-
SHOWINSYSHEADER, CATEGORY) \
18+
SHOWINSYSHEADER, DEFERRABLE, CATEGORY) \
1919
ENUM,
2020
#define DRIVERSTART
2121
#include "clang/Basic/DiagnosticDriverKinds.inc"

clang/include/clang/Basic/DiagnosticFrontend.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ namespace clang {
1515
namespace diag {
1616
enum {
1717
#define DIAG(ENUM, FLAGS, DEFAULT_MAPPING, DESC, GROUP, SFINAE, NOWERROR, \
18-
SHOWINSYSHEADER, CATEGORY) \
18+
SHOWINSYSHEADER, DEFERRABLE, CATEGORY) \
1919
ENUM,
2020
#define FRONTENDSTART
2121
#include "clang/Basic/DiagnosticFrontendKinds.inc"

clang/include/clang/Basic/DiagnosticIDs.h

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,8 +64,9 @@ namespace clang {
6464

6565
// Get typedefs for common diagnostics.
6666
enum {
67-
#define DIAG(ENUM,FLAGS,DEFAULT_MAPPING,DESC,GROUP,\
68-
SFINAE,CATEGORY,NOWERROR,SHOWINSYSHEADER) ENUM,
67+
#define DIAG(ENUM, FLAGS, DEFAULT_MAPPING, DESC, GROUP, SFINAE, CATEGORY, \
68+
NOWERROR, SHOWINSYSHEADER, DEFFERABLE) \
69+
ENUM,
6970
#define COMMONSTART
7071
#include "clang/Basic/DiagnosticCommonKinds.inc"
7172
NUM_BUILTIN_COMMON_DIAGNOSTICS
@@ -280,6 +281,13 @@ class DiagnosticIDs : public RefCountedBase<DiagnosticIDs> {
280281
/// are not SFINAE errors.
281282
static SFINAEResponse getDiagnosticSFINAEResponse(unsigned DiagID);
282283

284+
/// Whether the diagnostic message can be deferred.
285+
///
286+
/// For single source offloading languages, a diagnostic message occurred
287+
/// in a device host function may be deferred until the function is sure
288+
/// to be emitted.
289+
static bool isDeferrable(unsigned DiagID);
290+
283291
/// Get the string of all diagnostic flags.
284292
///
285293
/// \returns A list of all diagnostics flags as they would be written in a

clang/include/clang/Basic/DiagnosticLex.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ namespace clang {
1515
namespace diag {
1616
enum {
1717
#define DIAG(ENUM, FLAGS, DEFAULT_MAPPING, DESC, GROUP, SFINAE, NOWERROR, \
18-
SHOWINSYSHEADER, CATEGORY) \
18+
SHOWINSYSHEADER, DEFERRABLE, CATEGORY) \
1919
ENUM,
2020
#define LEXSTART
2121
#include "clang/Basic/DiagnosticLexKinds.inc"

0 commit comments

Comments
 (0)