~louis/ubuntu/trusty/clamav/lp799623_fix_logrotate

« back to all changes in this revision

Viewing changes to libclamav/c++/llvm/include/llvm/Transforms/Scalar.h

  • Committer: Bazaar Package Importer
  • Author(s): Scott Kitterman
  • Date: 2010-03-12 11:30:04 UTC
  • mfrom: (0.41.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20100312113004-b0fop4bkycszdd0z
Tags: 0.96~rc1+dfsg-0ubuntu1
* New upstream RC - FFE (LP: #537636):
  - Add OfficialDatabaseOnly option to clamav-base.postinst.in
  - Add LocalSocketGroup option to clamav-base.postinst.in
  - Add LocalSocketMode option to clamav-base.postinst.in
  - Add CrossFilesystems option to clamav-base.postinst.in
  - Add ClamukoScannerCount option to clamav-base.postinst.in
  - Add BytecodeSecurity opiton to clamav-base.postinst.in
  - Add DetectionStatsHostID option to clamav-freshclam.postinst.in
  - Add Bytecode option to clamav-freshclam.postinst.in
  - Add MilterSocketGroup option to clamav-milter.postinst.in
  - Add MilterSocketMode option to clamav-milter.postinst.in
  - Add ReportHostname option to clamav-milter.postinst.in
  - Bump libclamav SO version to 6.1.0 in libclamav6.install
  - Drop clamdmon from clamav.examples (no longer shipped by upstream)
  - Drop libclamav.a from libclamav-dev.install (not built by upstream)
  - Update SO version for lintian override for libclamav6
  - Add new Bytecode Testing Tool, usr/bin/clambc, to clamav.install
  - Add build-depends on python and python-setuptools for new test suite
  - Update debian/copyright for the embedded copy of llvm (using the system
    llvm is not currently feasible)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
//===-- Scalar.h - Scalar Transformations -----------------------*- C++ -*-===//
 
2
//
 
3
//                     The LLVM Compiler Infrastructure
 
4
//
 
5
// This file is distributed under the University of Illinois Open Source
 
6
// License. See LICENSE.TXT for details.
 
7
//
 
8
//===----------------------------------------------------------------------===//
 
9
//
 
10
// This header file defines prototypes for accessor functions that expose passes
 
11
// in the Scalar transformations library.
 
12
//
 
13
//===----------------------------------------------------------------------===//
 
14
 
 
15
#ifndef LLVM_TRANSFORMS_SCALAR_H
 
16
#define LLVM_TRANSFORMS_SCALAR_H
 
17
 
 
18
namespace llvm {
 
19
 
 
20
class FunctionPass;
 
21
class Pass;
 
22
class GetElementPtrInst;
 
23
class PassInfo;
 
24
class TerminatorInst;
 
25
class TargetLowering;
 
26
 
 
27
//===----------------------------------------------------------------------===//
 
28
//
 
29
// ConstantPropagation - A worklist driven constant propagation pass
 
30
//
 
31
FunctionPass *createConstantPropagationPass();
 
32
 
 
33
//===----------------------------------------------------------------------===//
 
34
//
 
35
// SCCP - Sparse conditional constant propagation.
 
36
//
 
37
FunctionPass *createSCCPPass();
 
38
 
 
39
//===----------------------------------------------------------------------===//
 
40
//
 
41
// DeadInstElimination - This pass quickly removes trivially dead instructions
 
42
// without modifying the CFG of the function.  It is a BasicBlockPass, so it
 
43
// runs efficiently when queued next to other BasicBlockPass's.
 
44
//
 
45
Pass *createDeadInstEliminationPass();
 
46
 
 
47
//===----------------------------------------------------------------------===//
 
48
//
 
49
// DeadCodeElimination - This pass is more powerful than DeadInstElimination,
 
50
// because it is worklist driven that can potentially revisit instructions when
 
51
// their other instructions become dead, to eliminate chains of dead
 
52
// computations.
 
53
//
 
54
FunctionPass *createDeadCodeEliminationPass();
 
55
 
 
56
//===----------------------------------------------------------------------===//
 
57
//
 
58
// DeadStoreElimination - This pass deletes stores that are post-dominated by
 
59
// must-aliased stores and are not loaded used between the stores.
 
60
//
 
61
FunctionPass *createDeadStoreEliminationPass();
 
62
 
 
63
//===----------------------------------------------------------------------===//
 
64
//
 
65
// AggressiveDCE - This pass uses the SSA based Aggressive DCE algorithm.  This
 
66
// algorithm assumes instructions are dead until proven otherwise, which makes
 
67
// it more successful are removing non-obviously dead instructions.
 
68
//
 
69
FunctionPass *createAggressiveDCEPass();
 
70
 
 
71
//===----------------------------------------------------------------------===//
 
72
//
 
73
// ScalarReplAggregates - Break up alloca's of aggregates into multiple allocas
 
74
// if possible.
 
75
//
 
76
FunctionPass *createScalarReplAggregatesPass(signed Threshold = -1);
 
77
 
 
78
//===----------------------------------------------------------------------===//
 
79
//
 
80
// InductionVariableSimplify - Transform induction variables in a program to all
 
81
// use a single canonical induction variable per loop.
 
82
//
 
83
Pass *createIndVarSimplifyPass();
 
84
 
 
85
//===----------------------------------------------------------------------===//
 
86
//
 
87
// InstructionCombining - Combine instructions to form fewer, simple
 
88
// instructions. This pass does not modify the CFG, and has a tendency to make
 
89
// instructions dead, so a subsequent DCE pass is useful.
 
90
//
 
91
// This pass combines things like:
 
92
//    %Y = add int 1, %X
 
93
//    %Z = add int 1, %Y
 
94
// into:
 
95
//    %Z = add int 2, %X
 
96
//
 
97
FunctionPass *createInstructionCombiningPass();
 
98
 
 
99
//===----------------------------------------------------------------------===//
 
100
//
 
101
// LICM - This pass is a loop invariant code motion and memory promotion pass.
 
102
//
 
103
Pass *createLICMPass();
 
104
 
 
105
//===----------------------------------------------------------------------===//
 
106
//
 
107
// LoopStrengthReduce - This pass is strength reduces GEP instructions that use
 
108
// a loop's canonical induction variable as one of their indices.  It takes an
 
109
// optional parameter used to consult the target machine whether certain
 
110
// transformations are profitable.
 
111
//
 
112
Pass *createLoopStrengthReducePass(const TargetLowering *TLI = 0);
 
113
 
 
114
//===----------------------------------------------------------------------===//
 
115
//
 
116
// LoopUnswitch - This pass is a simple loop unswitching pass.
 
117
//
 
118
Pass *createLoopUnswitchPass(bool OptimizeForSize = false);
 
119
 
 
120
//===----------------------------------------------------------------------===//
 
121
//
 
122
// LoopUnroll - This pass is a simple loop unrolling pass.
 
123
//
 
124
Pass *createLoopUnrollPass();
 
125
 
 
126
//===----------------------------------------------------------------------===//
 
127
//
 
128
// LoopRotate - This pass is a simple loop rotating pass.
 
129
//
 
130
Pass *createLoopRotatePass();
 
131
 
 
132
//===----------------------------------------------------------------------===//
 
133
//
 
134
// LoopIndexSplit - This pass divides loop's iteration range by spliting loop
 
135
// such that each individual loop is executed efficiently.
 
136
//
 
137
Pass *createLoopIndexSplitPass();
 
138
 
 
139
//===----------------------------------------------------------------------===//
 
140
//
 
141
// PromoteMemoryToRegister - This pass is used to promote memory references to
 
142
// be register references. A simple example of the transformation performed by
 
143
// this pass is:
 
144
//
 
145
//        FROM CODE                           TO CODE
 
146
//   %X = alloca i32, i32 1                 ret i32 42
 
147
//   store i32 42, i32 *%X
 
148
//   %Y = load i32* %X
 
149
//   ret i32 %Y
 
150
//
 
151
FunctionPass *createPromoteMemoryToRegisterPass();
 
152
extern const PassInfo *const PromoteMemoryToRegisterID;
 
153
 
 
154
//===----------------------------------------------------------------------===//
 
155
//
 
156
// DemoteRegisterToMemoryPass - This pass is used to demote registers to memory
 
157
// references. In basically undoes the PromoteMemoryToRegister pass to make cfg
 
158
// hacking easier.
 
159
//
 
160
FunctionPass *createDemoteRegisterToMemoryPass();
 
161
extern const PassInfo *const DemoteRegisterToMemoryID;
 
162
 
 
163
//===----------------------------------------------------------------------===//
 
164
//
 
165
// Reassociate - This pass reassociates commutative expressions in an order that
 
166
// is designed to promote better constant propagation, GCSE, LICM, PRE...
 
167
//
 
168
// For example:  4 + (x + 5)  ->  x + (4 + 5)
 
169
//
 
170
FunctionPass *createReassociatePass();
 
171
 
 
172
//===----------------------------------------------------------------------===//
 
173
//
 
174
// TailDuplication - Eliminate unconditional branches through controlled code
 
175
// duplication, creating simpler CFG structures.
 
176
//
 
177
FunctionPass *createTailDuplicationPass();
 
178
 
 
179
//===----------------------------------------------------------------------===//
 
180
//
 
181
// JumpThreading - Thread control through mult-pred/multi-succ blocks where some
 
182
// preds always go to some succ.
 
183
//
 
184
FunctionPass *createJumpThreadingPass();
 
185
  
 
186
//===----------------------------------------------------------------------===//
 
187
//
 
188
// CFGSimplification - Merge basic blocks, eliminate unreachable blocks,
 
189
// simplify terminator instructions, etc...
 
190
//
 
191
FunctionPass *createCFGSimplificationPass();
 
192
 
 
193
//===----------------------------------------------------------------------===//
 
194
//
 
195
// BreakCriticalEdges - Break all of the critical edges in the CFG by inserting
 
196
// a dummy basic block. This pass may be "required" by passes that cannot deal
 
197
// with critical edges. For this usage, a pass must call:
 
198
//
 
199
//   AU.addRequiredID(BreakCriticalEdgesID);
 
200
//
 
201
// This pass obviously invalidates the CFG, but can update forward dominator
 
202
// (set, immediate dominators, tree, and frontier) information.
 
203
//
 
204
FunctionPass *createBreakCriticalEdgesPass();
 
205
extern const PassInfo *const BreakCriticalEdgesID;
 
206
 
 
207
//===----------------------------------------------------------------------===//
 
208
//
 
209
// LoopSimplify - Insert Pre-header blocks into the CFG for every function in
 
210
// the module.  This pass updates dominator information, loop information, and
 
211
// does not add critical edges to the CFG.
 
212
//
 
213
//   AU.addRequiredID(LoopSimplifyID);
 
214
//
 
215
Pass *createLoopSimplifyPass();
 
216
extern const PassInfo *const LoopSimplifyID;
 
217
 
 
218
//===----------------------------------------------------------------------===//
 
219
//
 
220
// TailCallElimination - This pass eliminates call instructions to the current
 
221
// function which occur immediately before return instructions.
 
222
//
 
223
FunctionPass *createTailCallEliminationPass();
 
224
 
 
225
//===----------------------------------------------------------------------===//
 
226
//
 
227
// LowerSwitch - This pass converts SwitchInst instructions into a sequence of
 
228
// chained binary branch instructions.
 
229
//
 
230
FunctionPass *createLowerSwitchPass();
 
231
extern const PassInfo *const LowerSwitchID;
 
232
 
 
233
//===----------------------------------------------------------------------===//
 
234
//
 
235
// LowerInvoke - This pass converts invoke and unwind instructions to use sjlj
 
236
// exception handling mechanisms.  Note that after this pass runs the CFG is not
 
237
// entirely accurate (exceptional control flow edges are not correct anymore) so
 
238
// only very simple things should be done after the lowerinvoke pass has run
 
239
// (like generation of native code).  This should *NOT* be used as a general
 
240
// purpose "my LLVM-to-LLVM pass doesn't support the invoke instruction yet"
 
241
// lowering pass.
 
242
//
 
243
FunctionPass *createLowerInvokePass(const TargetLowering *TLI = 0);
 
244
extern const PassInfo *const LowerInvokePassID;
 
245
 
 
246
//===----------------------------------------------------------------------===//
 
247
//
 
248
// BlockPlacement - This pass reorders basic blocks in order to increase the
 
249
// number of fall-through conditional branches.
 
250
//
 
251
FunctionPass *createBlockPlacementPass();
 
252
 
 
253
//===----------------------------------------------------------------------===//
 
254
//
 
255
// LCSSA - This pass inserts phi nodes at loop boundaries to simplify other loop
 
256
// optimizations.
 
257
//
 
258
Pass *createLCSSAPass();
 
259
extern const PassInfo *const LCSSAID;
 
260
 
 
261
//===----------------------------------------------------------------------===//
 
262
//
 
263
// GVN - This pass performs global value numbering and redundant load 
 
264
// elimination cotemporaneously.
 
265
//
 
266
FunctionPass *createGVNPass(bool NoLoads = false);
 
267
 
 
268
//===----------------------------------------------------------------------===//
 
269
//
 
270
// MemCpyOpt - This pass performs optimizations related to eliminating memcpy
 
271
// calls and/or combining multiple stores into memset's.
 
272
//
 
273
FunctionPass *createMemCpyOptPass();
 
274
 
 
275
//===----------------------------------------------------------------------===//
 
276
//
 
277
// LoopDeletion - This pass performs DCE of non-infinite loops that it
 
278
// can prove are dead.
 
279
//
 
280
Pass *createLoopDeletionPass();
 
281
  
 
282
//===----------------------------------------------------------------------===//
 
283
//
 
284
/// createSimplifyLibCallsPass - This pass optimizes specific calls to
 
285
/// specific well-known (library) functions.
 
286
FunctionPass *createSimplifyLibCallsPass();
 
287
 
 
288
//===----------------------------------------------------------------------===//
 
289
//
 
290
/// createSimplifyHalfPowrLibCallsPass - This is an experimental pass that
 
291
/// optimizes specific half_pow functions.
 
292
FunctionPass *createSimplifyHalfPowrLibCallsPass();
 
293
 
 
294
//===----------------------------------------------------------------------===//
 
295
//
 
296
// CodeGenPrepare - This pass prepares a function for instruction selection.
 
297
//
 
298
FunctionPass *createCodeGenPreparePass(const TargetLowering *TLI = 0);
 
299
 
 
300
//===----------------------------------------------------------------------===//
 
301
//
 
302
// InstructionNamer - Give any unnamed non-void instructions "tmp" names.
 
303
//
 
304
FunctionPass *createInstructionNamerPass();
 
305
extern const PassInfo *const InstructionNamerID;
 
306
  
 
307
//===----------------------------------------------------------------------===//
 
308
//
 
309
// SSI - This pass converts instructions to Static Single Information form
 
310
// on demand.
 
311
//
 
312
FunctionPass *createSSIPass();
 
313
 
 
314
//===----------------------------------------------------------------------===//
 
315
//
 
316
// SSI - This pass converts every non-void instuction to Static Single
 
317
// Information form.
 
318
//
 
319
FunctionPass *createSSIEverythingPass();
 
320
 
 
321
//===----------------------------------------------------------------------===//
 
322
//
 
323
// GEPSplitter - Split complex GEPs into simple ones
 
324
//
 
325
FunctionPass *createGEPSplitterPass();
 
326
 
 
327
//===----------------------------------------------------------------------===//
 
328
//
 
329
// SCCVN - Aggressively eliminate redundant scalar values
 
330
//
 
331
FunctionPass *createSCCVNPass();
 
332
 
 
333
//===----------------------------------------------------------------------===//
 
334
//
 
335
// ABCD - Elimination of Array Bounds Checks on Demand
 
336
//
 
337
FunctionPass *createABCDPass();
 
338
 
 
339
} // End llvm namespace
 
340
 
 
341
#endif