1 //===- TransactionSave.h ----------------------------------------*- 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 is a region pass that simply calls Context::save() to save the IR state.
10 //
11 
12 #ifndef LLVM_TRANSFORMS_VECTORIZE_SANDBOXVECTORIZER_PASSES_TRANSACTIONSAVE_H
13 #define LLVM_TRANSFORMS_VECTORIZE_SANDBOXVECTORIZER_PASSES_TRANSACTIONSAVE_H
14 
15 #include "llvm/SandboxIR/Pass.h"
16 #include "llvm/SandboxIR/Region.h"
17 
18 namespace llvm::sandboxir {
19 
20 class TransactionSave : public RegionPass {
21 public:
TransactionSave()22   TransactionSave() : RegionPass("tr-save") {}
23   bool runOnRegion(Region &Rgn, const Analyses &A) final;
24 };
25 
26 } // namespace llvm::sandboxir
27 
28 #endif // LLVM_TRANSFORMS_VECTORIZE_SANDBOXVECTORIZER_PASSES_TRANSACTIONSAVE_H
29