Skip to content

Commit

Permalink
[NFC] Move FPBuiltinFnSelection pass to Transforms (#14339)
Browse files Browse the repository at this point in the history
This moves the FPBuiltinFnSelection pass to the
llvm/lib/Transforms/Scalar directory. This is needed to enable future
changes that will run this pass as part of the main pipeline for device
compilation. With this pass in CodeGen, the slibs build would fail.
  • Loading branch information
Andy Kaylor authored Jul 3, 2024
1 parent 66a0199 commit 403cea0
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion llvm/include/llvm/Passes/CodeGenPassBuilder.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
#include "llvm/CodeGen/DwarfEHPrepare.h"
#include "llvm/CodeGen/ExpandMemCmp.h"
#include "llvm/CodeGen/ExpandReductions.h"
#include "llvm/CodeGen/FPBuiltinFnSelection.h"
#include "llvm/CodeGen/GCMetadata.h"
#include "llvm/CodeGen/GlobalMerge.h"
#include "llvm/CodeGen/IndirectBrExpand.h"
Expand Down Expand Up @@ -65,6 +64,7 @@
#include "llvm/Target/TargetMachine.h"
#include "llvm/Transforms/CFGuard.h"
#include "llvm/Transforms/Scalar/ConstantHoisting.h"
#include "llvm/Transforms/Scalar/FPBuiltinFnSelection.h"
#include "llvm/Transforms/Scalar/LoopPassManager.h"
#include "llvm/Transforms/Scalar/LoopStrengthReduce.h"
#include "llvm/Transforms/Scalar/LowerConstantIntrinsics.h"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//===- FPBuiltinFnSelection.h - Pre-ISel intrinsic lowering pass ----------===//
//===- FPBuiltinFnSelection.h - fpbuiltin intrinsic lowering pass ---------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
Expand All @@ -10,8 +10,8 @@
// llvm.fpbuiltin.* intrinsics.
//
//===----------------------------------------------------------------------===//
#ifndef LLVM_CODEGEN_FPBUILTINFNSELECTION_H
#define LLVM_CODEGEN_FPBUILTINFNSELECTION_H
#ifndef LLVM_TRANSFORMS_SCALAR_FPBUILTINFNSELECTION_H
#define LLVM_TRANSFORMS_SCALAR_FPBUILTINFNSELECTION_H

#include "llvm/IR/PassManager.h"

Expand All @@ -25,4 +25,4 @@ struct FPBuiltinFnSelectionPass : PassInfoMixin<FPBuiltinFnSelectionPass> {

} // end namespace llvm

#endif // LLVM_CODEGEN_FPBUILTINFNSELECTION_H
#endif // LLVM_TRANSFORMS_SCALAR_FPBUILTINFNSELECTION_H
1 change: 0 additions & 1 deletion llvm/lib/CodeGen/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ add_llvm_component_library(LLVMCodeGen
ExpandVectorPredication.cpp
FaultMaps.cpp
FEntryInserter.cpp
FPBuiltinFnSelection.cpp
FinalizeISel.cpp
FixupStatepointCallerSaved.cpp
FuncletLayout.cpp
Expand Down
1 change: 1 addition & 0 deletions llvm/lib/Transforms/Scalar/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ add_llvm_component_library(LLVMScalarOpts
EarlyCSE.cpp
FlattenCFGPass.cpp
Float2Int.cpp
FPBuiltinFnSelection.cpp
GuardWidening.cpp
GVN.cpp
GVNHoist.cpp
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//===- FPBuiltinFnSelection.cpp - Pre-ISel intrinsic lowering pass --------===//
//===- FPBuiltinFnSelection.cpp - fpbuiltin intrinsic lowering pass -------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
Expand All @@ -11,7 +11,7 @@
//
//===----------------------------------------------------------------------===//

#include "llvm/CodeGen/FPBuiltinFnSelection.h"
#include "llvm/Transforms/Scalar/FPBuiltinFnSelection.h"
#include "llvm/Analysis/TargetLibraryInfo.h"
#include "llvm/Analysis/TargetTransformInfo.h"
#include "llvm/CodeGen/Passes.h"
Expand Down

0 comments on commit 403cea0

Please sign in to comment.