Polly 22.0.0git
Simplify.h
Go to the documentation of this file.
1//===------ Simplify.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// Simplify a SCoP by removing unnecessary statements and accesses.
10//
11//===----------------------------------------------------------------------===//
12
13#ifndef POLLY_TRANSFORM_SIMPLIFY_H
14#define POLLY_TRANSFORM_SIMPLIFY_H
15
16#include "llvm/ADT/SmallVector.h"
17
18namespace polly {
19class MemoryAccess;
20class Scop;
21class ScopStmt;
22
23/// Return a vector that contains MemoryAccesses in the order in
24/// which they are executed.
25///
26/// The order is:
27/// - Implicit reads (BlockGenerator::generateScalarLoads)
28/// - Explicit reads and writes (BlockGenerator::generateArrayLoad,
29/// BlockGenerator::generateArrayStore)
30/// - In block statements, the accesses are in order in which their
31/// instructions are executed.
32/// - In region statements, that order of execution is not predictable at
33/// compile-time.
34/// - Implicit writes (BlockGenerator::generateScalarStores)
35/// The order in which implicit writes are executed relative to each other is
36/// undefined.
37llvm::SmallVector<MemoryAccess *, 32> getAccessesInOrder(ScopStmt &Stmt);
38
39bool runSimplify(Scop &S, int CallNo);
40} // namespace polly
41
42#endif /* POLLY_TRANSFORM_SIMPLIFY_H */
Represent memory accesses in statements.
Definition ScopInfo.h:426
Statement of the Scop.
Definition ScopInfo.h:1135
Static Control Part.
Definition ScopInfo.h:1625
#define S(TYPE, NAME)
llvm::SmallVector< MemoryAccess *, 32 > getAccessesInOrder(ScopStmt &Stmt)
Return a vector that contains MemoryAccesses in the order in which they are executed.
Definition Simplify.cpp:765
bool runSimplify(Scop &S, int CallNo)
Definition Simplify.cpp:783