[InstCombine] Signed saturation patterns
[llvm-core.git] / include / llvm / Transforms / Scalar / Scalarizer.h
blob81363130e2e3aa7de619332a20f125b52499da67
1 //===- Scalarizer.h --- Scalarize vector operations -----------------------===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 //
9 /// \file
10 /// This pass converts vector operations into scalar operations, in order
11 /// to expose optimization opportunities on the individual scalar operations.
12 /// It is mainly intended for targets that do not have vector units, but it
13 /// may also be useful for revectorizing code to different vector widths.
15 //===----------------------------------------------------------------------===//
17 #ifndef LLVM_TRANSFORMS_SCALAR_SCALARIZER_H
18 #define LLVM_TRANSFORMS_SCALAR_SCALARIZER_H
20 #include "llvm/IR/PassManager.h"
22 namespace llvm {
24 class ScalarizerPass : public PassInfoMixin<ScalarizerPass> {
25 public:
26 PreservedAnalyses run(Function &F, FunctionAnalysisManager &AM);
29 /// Create a legacy pass manager instance of the Scalarizer pass
30 FunctionPass *createScalarizerPass();
34 #endif /* LLVM_TRANSFORMS_SCALAR_SCALARIZER_H */