LLVM 20.0.0git
DeadStoreElimination.h
Go to the documentation of this file.
1//===- DeadStoreElimination.h - Fast Dead Store Elimination -----*- C++ -*-===//
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// This file implements a trivial dead store elimination that only considers
10// basic-block local redundant stores.
11//
12// FIXME: This should eventually be extended to be a post-dominator tree
13// traversal. Doing so would be pretty trivial.
14//
15//===----------------------------------------------------------------------===//
16
17#ifndef LLVM_TRANSFORMS_SCALAR_DEADSTOREELIMINATION_H
18#define LLVM_TRANSFORMS_SCALAR_DEADSTOREELIMINATION_H
19
20#include "llvm/IR/PassManager.h"
21
22namespace llvm {
23
24class Function;
25
26/// This class implements a trivial dead store elimination. We consider
27/// only the redundant stores that are local to a single Basic Block.
28class DSEPass : public PassInfoMixin<DSEPass> {
29public:
31};
32
33} // end namespace llvm
34
35#endif // LLVM_TRANSFORMS_SCALAR_DEADSTOREELIMINATION_H
#define F(x, y, z)
Definition: MD5.cpp:55
FunctionAnalysisManager FAM
This header defines various interfaces for pass management in LLVM.
A container for analyses that lazily runs them and caches their results.
Definition: PassManager.h:253
This class implements a trivial dead store elimination.
PreservedAnalyses run(Function &F, FunctionAnalysisManager &FAM)
A set of analyses that are preserved following a run of a transformation pass.
Definition: Analysis.h:111
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:18
A CRTP mix-in to automatically provide informational APIs needed for passes.
Definition: PassManager.h:69