blob: 24159588675a8d1dc49f531e48302755a23d4bfe [file] [log] [blame]
Reid Spencerdac69c82004-06-07 17:53:43 +00001//===-- BytecodeHandler.cpp - Parsing Handler -------------------*- C++ -*-===//
2//
3// The LLVM Compiler Infrastructure
4//
5// This file was developed by Reid Spencer and is distributed under the
6// University of Illinois Open Source License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
9//
10// This header file defines the BytecodeHandler class that gets called by the
11// AbstractBytecodeParser when parsing events occur.
12//
13//===----------------------------------------------------------------------===//
14
15#include "BytecodeHandler.h"
16
17using namespace llvm;
18
19bool BytecodeHandler::handleError(const std::string& str )
20{
21 return false;
22}
23
24void BytecodeHandler::handleStart()
25{
26}
27
28void BytecodeHandler::handleFinish()
29{
30}
31
32void BytecodeHandler::handleModuleBegin(const std::string& id)
33{
34}
35
36void BytecodeHandler::handleModuleEnd(const std::string& id)
37{
38}
39
40void BytecodeHandler::handleVersionInfo(
41 unsigned char RevisionNum, ///< Byte code revision number
42 Module::Endianness Endianness, ///< Endianness indicator
43 Module::PointerSize PointerSize ///< PointerSize indicator
44)
45{
46}
47
48void BytecodeHandler::handleModuleGlobalsBegin()
49{
50}
51
52void BytecodeHandler::handleGlobalVariable(
53 const Type* ElemType, ///< The type of the global variable
54 bool isConstant, ///< Whether the GV is constant or not
55 GlobalValue::LinkageTypes ///< The linkage type of the GV
56)
57{
58}
59
60void BytecodeHandler::handleInitializedGV(
61 const Type* ElemType, ///< The type of the global variable
62 bool isConstant, ///< Whether the GV is constant or not
63 GlobalValue::LinkageTypes,///< The linkage type of the GV
64 unsigned initSlot ///< Slot number of GV's initializer
65)
66{
67}
68
69void BytecodeHandler::handleType( const Type* Ty )
70{
71}
72
73void BytecodeHandler::handleFunctionDeclaration(
74 const Type* FuncType ///< The type of the function
75)
76{
77}
78
79void BytecodeHandler::handleModuleGlobalsEnd()
80{
81}
82
83void BytecodeHandler::handleCompactionTableBegin()
84{
85}
86
87void BytecodeHandler::handleCompactionTablePlane(
88 unsigned Ty,
89 unsigned NumEntries
90)
91{
92}
93
94void BytecodeHandler::handleCompactionTableType(
95 unsigned i,
96 unsigned TypSlot,
97 const Type*
98)
99{
100}
101
102void BytecodeHandler::handleCompactionTableValue(
103 unsigned i,
104 unsigned ValSlot,
105 const Type*
106)
107{
108}
109
110void BytecodeHandler::handleCompactionTableEnd()
111{
112}
113
114void BytecodeHandler::handleSymbolTableBegin()
115{
116}
117
118void BytecodeHandler::handleSymbolTablePlane(
119 unsigned Ty,
120 unsigned NumEntries,
121 const Type* Typ
122)
123{
124}
125
126void BytecodeHandler::handleSymbolTableType(
127 unsigned i,
128 unsigned slot,
129 const std::string& name
130)
131{
132}
133
134void BytecodeHandler::handleSymbolTableValue(
135 unsigned i,
136 unsigned slot,
137 const std::string& name
138)
139{
140}
141
142void BytecodeHandler::handleSymbolTableEnd()
143{
144}
145
146void BytecodeHandler::handleFunctionBegin(
147 const Type* FType,
148 GlobalValue::LinkageTypes linkage
149)
150{
151}
152
153void BytecodeHandler::handleFunctionEnd(
154 const Type* FType
155)
156{
157}
158
159void BytecodeHandler::handleBasicBlockBegin(
160 unsigned blocknum
161)
162{
163}
164
165bool BytecodeHandler::handleInstruction(
166 unsigned Opcode,
167 const Type* iType,
168 std::vector<unsigned>& Operands
169)
170{
171 return false;
172}
173
174void BytecodeHandler::handleBasicBlockEnd(unsigned blocknum)
175{
176}
177
178void BytecodeHandler::handleGlobalConstantsBegin()
179{
180}
181
182void BytecodeHandler::handleConstantExpression(
183 unsigned Opcode,
184 const Type* Typ,
185 std::vector<std::pair<const Type*,unsigned> > ArgVec
186 )
187{
188}
189
190void BytecodeHandler::handleConstantValue( Constant * c )
191{
192}
193
194void BytecodeHandler::handleConstantArray(
195 const ArrayType* AT,
196 std::vector<unsigned>& Elements )
197{
198}
199
200void BytecodeHandler::handleConstantStruct(
201 const StructType* ST,
202 std::vector<unsigned>& ElementSlots)
203{
204}
205
206void BytecodeHandler::handleConstantPointer(
207 const PointerType* PT, unsigned Slot)
208{
209}
210
211void BytecodeHandler::handleConstantString( const ConstantArray* CA )
212{
213}
214
215
216void BytecodeHandler::handleGlobalConstantsEnd()
217{
218}
219
220// vim: sw=2