clang 23.0.0git
PointerFlowAnalysis.h
Go to the documentation of this file.
1//===- PointerFlowAnalysis.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// Defines PointerFlowAnalysisResult — the whole-program pointer-flow graph
10// aggregated from per-translation-unit EdgeSet summaries.
11//
12//===----------------------------------------------------------------------===//
13
14#ifndef LLVM_CLANG_SCALABLESTATICANALYSISFRAMEWORK_ANALYSES_POINTERFLOW_POINTERFLOWANALYSIS_H
15#define LLVM_CLANG_SCALABLESTATICANALYSISFRAMEWORK_ANALYSES_POINTERFLOW_POINTERFLOWANALYSIS_H
16
21#include "llvm/ADT/StringRef.h"
22#include <map>
23
24namespace clang::ssaf {
25
26constexpr llvm::StringLiteral PointerFlowAnalysisResultName =
27 "PointerFlowAnalysisResult";
28
29/// The whole-program pointer-flow graph. Each directed edge 'src -> dest'
30/// records a static assignment site where 'src' (the LHS / assignee) is
31/// assigned the value of 'dest' (the RHS / assigned value).
32///
33/// This edge direction matches property-propagation direction: if a property
34/// (such as a bounds requirement) holds for 'src', it must also hold for
35/// 'dest', because 'dest' supplies the value that 'src' will hold.
40
41 std::map<EntityId, EdgeSet> Edges;
42};
43
44} // namespace clang::ssaf
45
46#endif // LLVM_CLANG_SCALABLESTATICANALYSISFRAMEWORK_ANALYSES_POINTERFLOW_POINTERFLOWANALYSIS_H
Uniquely identifies a whole-program analysis and the AnalysisResult it produces.
Base class for whole-program analysis results.
constexpr llvm::StringLiteral PointerFlowAnalysisResultName
The whole-program pointer-flow graph.
std::map< EntityId, EdgeSet > Edges