Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(334)

Side by Side Diff: include/llvm/Transforms/NaCl.h

Issue 927493002: PNaCl: Impl the other atomicrmw operations: nand, max, min, umax, and umin. Base URL: https://chromium.googlesource.com/native_client/pnacl-llvm.git@master
Patch Set: Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « include/llvm/InitializePasses.h ('k') | lib/Analysis/NaCl/CMakeLists.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 //===-- NaCl.h - NaCl Transformations ---------------------------*- C++ -*-===// 1 //===-- NaCl.h - NaCl Transformations ---------------------------*- C++ -*-===//
2 // 2 //
3 // The LLVM Compiler Infrastructure 3 // The LLVM Compiler Infrastructure
4 // 4 //
5 // This file is distributed under the University of Illinois Open Source 5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details. 6 // License. See LICENSE.TXT for details.
7 // 7 //
8 //===----------------------------------------------------------------------===// 8 //===----------------------------------------------------------------------===//
9 9
10 #ifndef LLVM_TRANSFORMS_NACL_H 10 #ifndef LLVM_TRANSFORMS_NACL_H
11 #define LLVM_TRANSFORMS_NACL_H 11 #define LLVM_TRANSFORMS_NACL_H
12 12
13 #include "llvm/CodeGen/Passes.h" 13 #include "llvm/CodeGen/Passes.h"
14 #include "llvm/IR/Instructions.h" 14 #include "llvm/IR/Instructions.h"
15 #include "llvm/IR/LLVMContext.h" 15 #include "llvm/IR/LLVMContext.h"
16 #include "llvm/IR/PassManager.h"
16 17
17 namespace llvm { 18 namespace llvm {
18 19
19 class BasicBlockPass; 20 class BasicBlockPass;
20 class Function; 21 class Function;
21 class FunctionPass; 22 class FunctionPass;
22 class FunctionType; 23 class FunctionType;
23 class Instruction; 24 class Instruction;
24 class ModulePass; 25 class ModulePass;
25 class Triple; 26 class Triple;
26 class Use; 27 class Use;
27 class Value; 28 class Value;
28 29
29 BasicBlockPass *createConstantInsertExtractElementIndexPass(); 30 BasicBlockPass *createConstantInsertExtractElementIndexPass();
30 BasicBlockPass *createExpandGetElementPtrPass(); 31 BasicBlockPass *createExpandGetElementPtrPass();
31 BasicBlockPass *createExpandShuffleVectorPass(); 32 BasicBlockPass *createExpandShuffleVectorPass();
32 BasicBlockPass *createFixVectorLoadStoreAlignmentPass(); 33 BasicBlockPass *createFixVectorLoadStoreAlignmentPass();
33 BasicBlockPass *createPromoteI1OpsPass(); 34 BasicBlockPass *createPromoteI1OpsPass();
34 BasicBlockPass *createSimplifyAllocasPass(); 35 BasicBlockPass *createSimplifyAllocasPass();
35 FunctionPass *createBackendCanonicalizePass(); 36 FunctionPass *createBackendCanonicalizePass();
36 FunctionPass *createExpandConstantExprPass(); 37 FunctionPass *createExpandConstantExprPass();
37 FunctionPass *createExpandLargeIntegersPass(); 38 FunctionPass *createExpandLargeIntegersPass();
38 FunctionPass *createExpandStructRegsPass(); 39 FunctionPass *createExpandStructRegsPass();
39 FunctionPass *createInsertDivideCheckPass(); 40 FunctionPass *createInsertDivideCheckPass();
40 FunctionPass *createNormalizeAlignmentPass(); 41 FunctionPass *createNormalizeAlignmentPass();
41 FunctionPass *createRemoveAsmMemoryPass(); 42 FunctionPass *createRemoveAsmMemoryPass();
42 FunctionPass *createResolvePNaClIntrinsicsPass(); 43 FunctionPass *createResolvePNaClIntrinsicsPass();
44 FunctionPass *createRewriteAtomicsPass();
43 ModulePass *createAddPNaClExternalDeclsPass(); 45 ModulePass *createAddPNaClExternalDeclsPass();
44 ModulePass *createCanonicalizeMemIntrinsicsPass(); 46 ModulePass *createCanonicalizeMemIntrinsicsPass();
45 ModulePass *createCleanupUsedGlobalsMetadataPass(); 47 ModulePass *createCleanupUsedGlobalsMetadataPass();
46 ModulePass *createExpandArithWithOverflowPass(); 48 ModulePass *createExpandArithWithOverflowPass();
47 ModulePass *createExpandByValPass(); 49 ModulePass *createExpandByValPass();
48 ModulePass *createExpandCtorsPass(); 50 ModulePass *createExpandCtorsPass();
49 ModulePass *createExpandIndirectBrPass(); 51 ModulePass *createExpandIndirectBrPass();
50 ModulePass *createExpandSmallArgumentsPass(); 52 ModulePass *createExpandSmallArgumentsPass();
51 ModulePass *createExpandTlsConstantExprPass(); 53 ModulePass *createExpandTlsConstantExprPass();
52 ModulePass *createExpandTlsPass(); 54 ModulePass *createExpandTlsPass();
53 ModulePass *createExpandVarArgsPass(); 55 ModulePass *createExpandVarArgsPass();
54 ModulePass *createFlattenGlobalsPass(); 56 ModulePass *createFlattenGlobalsPass();
55 ModulePass *createGlobalCleanupPass(); 57 ModulePass *createGlobalCleanupPass();
56 ModulePass *createGlobalizeConstantVectorsPass(); 58 ModulePass *createGlobalizeConstantVectorsPass();
57 ModulePass *createInternalizeUsedGlobalsPass(); 59 ModulePass *createInternalizeUsedGlobalsPass();
58 ModulePass *createPNaClSjLjEHPass(); 60 ModulePass *createPNaClSjLjEHPass();
59 ModulePass *createPromoteIntegersPass(); 61 ModulePass *createPromoteIntegersPass();
60 ModulePass *createReplacePtrsWithIntsPass(); 62 ModulePass *createReplacePtrsWithIntsPass();
61 ModulePass *createResolveAliasesPass(); 63 ModulePass *createResolveAliasesPass();
62 ModulePass *createRewriteAtomicsPass();
63 ModulePass *createRewriteLLVMIntrinsicsPass(); 64 ModulePass *createRewriteLLVMIntrinsicsPass();
64 ModulePass *createRewritePNaClLibraryCallsPass(); 65 ModulePass *createRewritePNaClLibraryCallsPass();
65 ModulePass *createSimplifyStructRegSignaturesPass(); 66 ModulePass *createSimplifyStructRegSignaturesPass();
66 ModulePass *createStripAttributesPass(); 67 ModulePass *createStripAttributesPass();
67 ModulePass *createStripMetadataPass(); 68 ModulePass *createStripMetadataPass();
68 ModulePass *createStripModuleFlagsPass(); 69 ModulePass *createStripModuleFlagsPass();
69 ModulePass *createStripDanglingDISubprogramsPass(); 70 ModulePass *createStripDanglingDISubprogramsPass();
70 71
71 // Emscripten passes: 72 // Emscripten passes:
72 FunctionPass *createExpandInsertExtractElementPass(); 73 FunctionPass *createExpandInsertExtractElementPass();
73 ModulePass *createExpandI64Pass(); 74 ModulePass *createExpandI64Pass();
74 ModulePass *createLowerEmAsyncifyPass(); 75 ModulePass *createLowerEmAsyncifyPass();
75 ModulePass *createLowerEmExceptionsPass(); 76 ModulePass *createLowerEmExceptionsPass();
76 ModulePass *createLowerEmSetjmpPass(); 77 ModulePass *createLowerEmSetjmpPass();
77 ModulePass *createNoExitRuntimePass(); 78 ModulePass *createNoExitRuntimePass();
78 // Emscripten passes end. 79 // Emscripten passes end.
79 80
81
80 void PNaClABISimplifyAddPreOptPasses(Triple *T, PassManagerBase &PM); 82 void PNaClABISimplifyAddPreOptPasses(Triple *T, PassManagerBase &PM);
81 void PNaClABISimplifyAddPostOptPasses(Triple *T, PassManagerBase &PM); 83 void PNaClABISimplifyAddPostOptPasses(Triple *T, PassManagerBase &PM);
82 84
83 Instruction *PhiSafeInsertPt(Use *U); 85 Instruction *PhiSafeInsertPt(Use *U);
84 void PhiSafeReplaceUses(Use *U, Value *NewVal); 86 void PhiSafeReplaceUses(Use *U, Value *NewVal);
85 87
86 // Copy debug information from Original to New, and return New. 88 // Copy debug information from Original to New, and return New.
87 template <typename T> T *CopyDebug(T *New, Instruction *Original) { 89 template <typename T> T *CopyDebug(T *New, Instruction *Original) {
88 New->setDebugLoc(Original->getDebugLoc()); 90 New->setDebugLoc(Original->getDebugLoc());
89 return New; 91 return New;
(...skipping 10 matching lines...) Expand all
100 // In order to change a function's type, the function must be 102 // In order to change a function's type, the function must be
101 // recreated. RecreateFunction() recreates Func with type NewType. 103 // recreated. RecreateFunction() recreates Func with type NewType.
102 // It copies or moves across everything except the argument values, 104 // It copies or moves across everything except the argument values,
103 // which the caller must update because the argument types might be 105 // which the caller must update because the argument types might be
104 // different. 106 // different.
105 Function *RecreateFunction(Function *Func, FunctionType *NewType); 107 Function *RecreateFunction(Function *Func, FunctionType *NewType);
106 108
107 } 109 }
108 110
109 #endif 111 #endif
OLDNEW
« no previous file with comments | « include/llvm/InitializePasses.h ('k') | lib/Analysis/NaCl/CMakeLists.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698