Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 0 additions & 17 deletions clang/lib/Sema/SemaExpr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13874,20 +13874,6 @@ inline QualType Sema::CheckBitwiseOperands(ExprResult &LHS, ExprResult &RHS,
return ResultTy;
}

static inline bool IsAMDGPUPredicateBI(Expr *E) {
if (!E->getType()->isVoidType())
return false;

if (auto *CE = dyn_cast<CallExpr>(E)) {
if (auto *BI = CE->getDirectCallee())
if (BI->getName() == "__builtin_amdgcn_processor_is" ||
BI->getName() == "__builtin_amdgcn_is_invocable")
return true;
}

return false;
}

// C99 6.5.[13,14]
inline QualType Sema::CheckLogicalOperands(ExprResult &LHS, ExprResult &RHS,
SourceLocation Loc,
Expand Down Expand Up @@ -13992,9 +13978,6 @@ inline QualType Sema::CheckLogicalOperands(ExprResult &LHS, ExprResult &RHS,
// The following is safe because we only use this method for
// non-overloadable operands.

if (IsAMDGPUPredicateBI(LHS.get()) && IsAMDGPUPredicateBI(RHS.get()))
return Context.VoidTy;

// C++ [expr.log.and]p1
// C++ [expr.log.or]p1
// The operands are both contextually converted to type bool.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
// HIPSTDPAR-PRE: Running pass: EntryExitInstrumenterPass
// HIPSTDPAR-PRE-NEXT: Running pass: EntryExitInstrumenterPass
// HIPSTDPAR-PRE-NOT: Running pass: HipStdParAcceleratorCodeSelectionPass
// HIPSTDPAR-PRE-NEXT: Running pass: AMDGPUExpandFeaturePredicatesPass
// HIPSTDPAR-PRE-NEXT: Running pass: AlwaysInlinerPass

// Ensure Pass HipStdParAcceleratorCodeSelectionPass is invoked in PostLink.
Expand Down
21 changes: 0 additions & 21 deletions clang/test/SemaHIP/amdgpu-is-invocable.hip

This file was deleted.

21 changes: 0 additions & 21 deletions clang/test/SemaHIP/amdgpu-processor-is.hip

This file was deleted.

9 changes: 0 additions & 9 deletions llvm/lib/Target/AMDGPU/AMDGPU.h
Original file line number Diff line number Diff line change
Expand Up @@ -483,15 +483,6 @@ extern char &AMDGPUPrintfRuntimeBindingID;
void initializeAMDGPUResourceUsageAnalysisWrapperPassPass(PassRegistry &);
extern char &AMDGPUResourceUsageAnalysisID;

struct AMDGPUExpandFeaturePredicatesPass
: PassInfoMixin<AMDGPUExpandFeaturePredicatesPass> {
const AMDGPUTargetMachine &TM;
AMDGPUExpandFeaturePredicatesPass(const AMDGPUTargetMachine &ATM) : TM(ATM) {}
PreservedAnalyses run(Module &M, ModuleAnalysisManager &AM);

static bool isRequired() { return true; }
};

struct AMDGPUPrintfRuntimeBindingPass
: OptionalPassInfoMixin<AMDGPUPrintfRuntimeBindingPass> {
PreservedAnalyses run(Module &M, ModuleAnalysisManager &AM);
Expand Down
170 changes: 0 additions & 170 deletions llvm/lib/Target/AMDGPU/AMDGPUExpandFeaturePredicates.cpp

This file was deleted.

4 changes: 0 additions & 4 deletions llvm/lib/Target/AMDGPU/AMDGPUPassRegistry.def
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@
#ifndef MODULE_PASS
#define MODULE_PASS(NAME, CREATE_PASS)
#endif
MODULE_PASS("amdgpu-expand-feature-predicates",
AMDGPUExpandFeaturePredicatesPass(*this))
MODULE_PASS("amdgpu-always-inline", AMDGPUAlwaysInlinePass())
MODULE_PASS("amdgpu-export-kernel-runtime-handles", AMDGPUExportKernelRuntimeHandlesPass())
MODULE_PASS("amdgpu-lower-buffer-fat-pointers",
Expand All @@ -33,8 +31,6 @@ MODULE_PASS("amdgpu-printf-runtime-binding", AMDGPUPrintfRuntimeBindingPass())
MODULE_PASS("amdgpu-remove-incompatible-functions", AMDGPURemoveIncompatibleFunctionsPass(*this))
MODULE_PASS("amdgpu-lower-exec-sync", AMDGPULowerExecSyncPass())
MODULE_PASS("amdgpu-sw-lower-lds", AMDGPUSwLowerLDSPass(*this))
MODULE_PASS("amdgpu-expand-feature-predicates",
AMDGPUExpandFeaturePredicatesPass(*this))
#undef MODULE_PASS

#ifndef MODULE_PASS_WITH_PARAMS
Expand Down
10 changes: 0 additions & 10 deletions llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -969,16 +969,6 @@ void AMDGPUTargetMachine::registerPassBuilderCallbacks(PassBuilder &PB) {
#define GET_PASS_REGISTRY "AMDGPUPassRegistry.def"
#include "llvm/Passes/TargetPassRegistry.inc"

PB.registerPipelineStartEPCallback(
[this](ModulePassManager &PM, OptimizationLevel Level) {
PM.addPass(AMDGPUExpandFeaturePredicatesPass(*this));
});

PB.registerFullLinkTimeOptimizationEarlyEPCallback(
[this](ModulePassManager &PM, OptimizationLevel Level) {
PM.addPass(AMDGPUExpandFeaturePredicatesPass(*this));
});

PB.registerPipelineParsingCallback(
[this](StringRef Name, CGSCCPassManager &PM,
ArrayRef<PassBuilder::PipelineElement> Pipeline) {
Expand Down
1 change: 0 additions & 1 deletion llvm/lib/Target/AMDGPU/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ add_llvm_target(AMDGPUCodeGen
AMDGPUCodeGenPrepare.cpp
AMDGPUCombinerHelper.cpp
AMDGPUCtorDtorLowering.cpp
AMDGPUExpandFeaturePredicates.cpp
AMDGPUExportClustering.cpp
AMDGPUExportKernelRuntimeHandles.cpp
AMDGPUFrameLowering.cpp
Expand Down
Loading
Loading