Skip to content

Commit 15f1082

Browse files
seven-milelanza
authored andcommitted
[CIR][CodeGen][NFC] Break the missing feature flag for OpenCL into smaller pieces (#902)
The missing feature flag for OpenCL has very few occurrences now. This PR rearranges them into proper pieces to better track them.
1 parent 8790612 commit 15f1082

File tree

3 files changed

+2
-3
lines changed

3 files changed

+2
-3
lines changed

clang/include/clang/CIR/MissingFeatures.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ struct MissingFeatures {
154154
static bool CGFPOptionsRAII() { return false; }
155155
static bool getFPFeaturesInEffect() { return false; }
156156
static bool cxxABI() { return false; }
157-
static bool openCL() { return false; }
157+
static bool openCLCXX() { return false; }
158158
static bool openCLBuiltinTypes() { return false; }
159159
static bool CUDA() { return false; }
160160
static bool openMP() { return false; }

clang/lib/CIR/CodeGen/CIRGenCXX.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ static void buildDeclDestroy(CIRGenFunction &CGF, const VarDecl *D) {
253253
if (Record && (CanRegisterDestructor || UsingExternalHelper)) {
254254
assert(!D->getTLSKind() && "TLS NYI");
255255
assert(!Record->hasTrivialDestructor());
256-
assert(!MissingFeatures::openCL());
256+
assert(!MissingFeatures::openCLCXX());
257257
CXXDestructorDecl *Dtor = Record->getDestructor();
258258
// In LLVM OG codegen this is done in registerGlobalDtor, but CIRGen
259259
// relies on LoweringPrepare for further decoupling, so build the

clang/lib/CIR/CodeGen/CIRGenDecl.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ CIRGenFunction::AutoVarEmission
3636
CIRGenFunction::buildAutoVarAlloca(const VarDecl &D,
3737
mlir::OpBuilder::InsertPoint ip) {
3838
QualType Ty = D.getType();
39-
assert(!MissingFeatures::openCL());
4039
assert(
4140
Ty.getAddressSpace() == LangAS::Default ||
4241
(Ty.getAddressSpace() == LangAS::opencl_private && getLangOpts().OpenCL));

0 commit comments

Comments
 (0)