blob: c588f72a239829f2f11bee184e3e41c333b1f5d8 [file] [log] [blame]
Chris Lattner2f7c9632001-06-06 20:29:01 +00001//===- ConstantHandling.cpp - Implement ConstantHandling.h ----------------===//
2//
3// This file implements the various intrinsic operations, on constant values.
4//
5//===----------------------------------------------------------------------===//
6
Chris Lattnerd42d4922001-06-30 04:36:40 +00007#include "llvm/Optimizations/ConstantHandling.h"
8
9namespace opt {
Chris Lattner2f7c9632001-06-06 20:29:01 +000010
Chris Lattner61607ee2001-09-09 21:01:20 +000011AnnotationID ConstRules::AID(AnnotationManager::getID("opt::ConstRules",
12 &ConstRules::find));
13
Chris Lattner2f7c9632001-06-06 20:29:01 +000014//===----------------------------------------------------------------------===//
15// TemplateRules Class
16//===----------------------------------------------------------------------===//
17//
18// TemplateRules - Implement a subclass of ConstRules that provides all
19// operations as noops. All other rules classes inherit from this class so
20// that if functionality is needed in the future, it can simply be added here
21// and to ConstRules without changing anything else...
22//
23// This class also provides subclasses with typesafe implementations of methods
24// so that don't have to do type casting.
25//
26template<class ArgType, class SubClassName>
27class TemplateRules : public ConstRules {
28
29 //===--------------------------------------------------------------------===//
30 // Redirecting functions that cast to the appropriate types
31 //===--------------------------------------------------------------------===//
32
Chris Lattner3462ae32001-12-03 22:26:30 +000033 virtual Constant *op_not(const Constant *V) const {
Chris Lattner2f7c9632001-06-06 20:29:01 +000034 return SubClassName::Not((const ArgType *)V);
35 }
36
37
Chris Lattner3462ae32001-12-03 22:26:30 +000038 virtual Constant *add(const Constant *V1,
39 const Constant *V2) const {
Chris Lattner2f7c9632001-06-06 20:29:01 +000040 return SubClassName::Add((const ArgType *)V1, (const ArgType *)V2);
41 }
42
Chris Lattner3462ae32001-12-03 22:26:30 +000043 virtual Constant *sub(const Constant *V1,
44 const Constant *V2) const {
Chris Lattner2f7c9632001-06-06 20:29:01 +000045 return SubClassName::Sub((const ArgType *)V1, (const ArgType *)V2);
46 }
47
Chris Lattner3462ae32001-12-03 22:26:30 +000048 virtual Constant *mul(const Constant *V1,
49 const Constant *V2) const {
Chris Lattner4f6031f2001-07-20 19:15:36 +000050 return SubClassName::Mul((const ArgType *)V1, (const ArgType *)V2);
51 }
52
Chris Lattner3462ae32001-12-03 22:26:30 +000053 virtual ConstantBool *lessthan(const Constant *V1,
54 const Constant *V2) const {
Chris Lattner2f7c9632001-06-06 20:29:01 +000055 return SubClassName::LessThan((const ArgType *)V1, (const ArgType *)V2);
56 }
57
Chris Lattner55406842001-07-21 19:10:49 +000058 // Casting operators. ick
Chris Lattner3462ae32001-12-03 22:26:30 +000059 virtual ConstantBool *castToBool(const Constant *V) const {
Chris Lattner55406842001-07-21 19:10:49 +000060 return SubClassName::CastToBool((const ArgType*)V);
61 }
Chris Lattner3462ae32001-12-03 22:26:30 +000062 virtual ConstantSInt *castToSByte(const Constant *V) const {
Chris Lattner55406842001-07-21 19:10:49 +000063 return SubClassName::CastToSByte((const ArgType*)V);
64 }
Chris Lattner3462ae32001-12-03 22:26:30 +000065 virtual ConstantUInt *castToUByte(const Constant *V) const {
Chris Lattner55406842001-07-21 19:10:49 +000066 return SubClassName::CastToUByte((const ArgType*)V);
67 }
Chris Lattner3462ae32001-12-03 22:26:30 +000068 virtual ConstantSInt *castToShort(const Constant *V) const {
Chris Lattner55406842001-07-21 19:10:49 +000069 return SubClassName::CastToShort((const ArgType*)V);
70 }
Chris Lattner3462ae32001-12-03 22:26:30 +000071 virtual ConstantUInt *castToUShort(const Constant *V) const {
Chris Lattner55406842001-07-21 19:10:49 +000072 return SubClassName::CastToUShort((const ArgType*)V);
73 }
Chris Lattner3462ae32001-12-03 22:26:30 +000074 virtual ConstantSInt *castToInt(const Constant *V) const {
Chris Lattner55406842001-07-21 19:10:49 +000075 return SubClassName::CastToInt((const ArgType*)V);
76 }
Chris Lattner3462ae32001-12-03 22:26:30 +000077 virtual ConstantUInt *castToUInt(const Constant *V) const {
Chris Lattner55406842001-07-21 19:10:49 +000078 return SubClassName::CastToUInt((const ArgType*)V);
79 }
Chris Lattner3462ae32001-12-03 22:26:30 +000080 virtual ConstantSInt *castToLong(const Constant *V) const {
Chris Lattner55406842001-07-21 19:10:49 +000081 return SubClassName::CastToLong((const ArgType*)V);
82 }
Chris Lattner3462ae32001-12-03 22:26:30 +000083 virtual ConstantUInt *castToULong(const Constant *V) const {
Chris Lattner55406842001-07-21 19:10:49 +000084 return SubClassName::CastToULong((const ArgType*)V);
85 }
Chris Lattner3462ae32001-12-03 22:26:30 +000086 virtual ConstantFP *castToFloat(const Constant *V) const {
Chris Lattner55406842001-07-21 19:10:49 +000087 return SubClassName::CastToFloat((const ArgType*)V);
88 }
Chris Lattner3462ae32001-12-03 22:26:30 +000089 virtual ConstantFP *castToDouble(const Constant *V) const {
Chris Lattner55406842001-07-21 19:10:49 +000090 return SubClassName::CastToDouble((const ArgType*)V);
91 }
Chris Lattner3462ae32001-12-03 22:26:30 +000092 virtual ConstantPointer *castToPointer(const Constant *V,
93 const PointerType *Ty) const {
Chris Lattner977f0042001-11-01 05:55:13 +000094 return SubClassName::CastToPointer((const ArgType*)V, Ty);
95 }
Chris Lattner55406842001-07-21 19:10:49 +000096
Chris Lattner2f7c9632001-06-06 20:29:01 +000097 //===--------------------------------------------------------------------===//
98 // Default "noop" implementations
99 //===--------------------------------------------------------------------===//
100
Chris Lattner3462ae32001-12-03 22:26:30 +0000101 inline static Constant *Not(const ArgType *V) { return 0; }
Chris Lattner2f7c9632001-06-06 20:29:01 +0000102
Chris Lattner3462ae32001-12-03 22:26:30 +0000103 inline static Constant *Add(const ArgType *V1, const ArgType *V2) {
Chris Lattner2f7c9632001-06-06 20:29:01 +0000104 return 0;
105 }
Chris Lattner3462ae32001-12-03 22:26:30 +0000106 inline static Constant *Sub(const ArgType *V1, const ArgType *V2) {
Chris Lattner2f7c9632001-06-06 20:29:01 +0000107 return 0;
108 }
Chris Lattner3462ae32001-12-03 22:26:30 +0000109 inline static Constant *Mul(const ArgType *V1, const ArgType *V2) {
Chris Lattner4f6031f2001-07-20 19:15:36 +0000110 return 0;
111 }
Chris Lattner3462ae32001-12-03 22:26:30 +0000112 inline static ConstantBool *LessThan(const ArgType *V1, const ArgType *V2) {
Chris Lattner2f7c9632001-06-06 20:29:01 +0000113 return 0;
114 }
Chris Lattner55406842001-07-21 19:10:49 +0000115
116 // Casting operators. ick
Chris Lattner3462ae32001-12-03 22:26:30 +0000117 inline static ConstantBool *CastToBool (const Constant *V) { return 0; }
118 inline static ConstantSInt *CastToSByte (const Constant *V) { return 0; }
119 inline static ConstantUInt *CastToUByte (const Constant *V) { return 0; }
120 inline static ConstantSInt *CastToShort (const Constant *V) { return 0; }
121 inline static ConstantUInt *CastToUShort(const Constant *V) { return 0; }
122 inline static ConstantSInt *CastToInt (const Constant *V) { return 0; }
123 inline static ConstantUInt *CastToUInt (const Constant *V) { return 0; }
124 inline static ConstantSInt *CastToLong (const Constant *V) { return 0; }
125 inline static ConstantUInt *CastToULong (const Constant *V) { return 0; }
126 inline static ConstantFP *CastToFloat (const Constant *V) { return 0; }
127 inline static ConstantFP *CastToDouble(const Constant *V) { return 0; }
128 inline static ConstantPointer *CastToPointer(const Constant *,
129 const PointerType *) {return 0;}
Chris Lattner2f7c9632001-06-06 20:29:01 +0000130};
131
132
133
134//===----------------------------------------------------------------------===//
135// EmptyRules Class
136//===----------------------------------------------------------------------===//
137//
138// EmptyRules provides a concrete base class of ConstRules that does nothing
139//
Chris Lattner3462ae32001-12-03 22:26:30 +0000140struct EmptyRules : public TemplateRules<Constant, EmptyRules> {
Chris Lattner61607ee2001-09-09 21:01:20 +0000141};
Chris Lattner2f7c9632001-06-06 20:29:01 +0000142
143
144
145//===----------------------------------------------------------------------===//
146// BoolRules Class
147//===----------------------------------------------------------------------===//
148//
149// BoolRules provides a concrete base class of ConstRules for the 'bool' type.
150//
Chris Lattner3462ae32001-12-03 22:26:30 +0000151struct BoolRules : public TemplateRules<ConstantBool, BoolRules> {
Chris Lattner2f7c9632001-06-06 20:29:01 +0000152
Chris Lattner3462ae32001-12-03 22:26:30 +0000153 inline static Constant *Not(const ConstantBool *V) {
154 return ConstantBool::get(!V->getValue());
Chris Lattner2f7c9632001-06-06 20:29:01 +0000155 }
156
Chris Lattner3462ae32001-12-03 22:26:30 +0000157 inline static Constant *Or(const ConstantBool *V1,
158 const ConstantBool *V2) {
159 return ConstantBool::get(V1->getValue() | V2->getValue());
Chris Lattner2f7c9632001-06-06 20:29:01 +0000160 }
161
Chris Lattner3462ae32001-12-03 22:26:30 +0000162 inline static Constant *And(const ConstantBool *V1,
163 const ConstantBool *V2) {
164 return ConstantBool::get(V1->getValue() & V2->getValue());
Chris Lattner2f7c9632001-06-06 20:29:01 +0000165 }
Chris Lattner61607ee2001-09-09 21:01:20 +0000166};
Chris Lattner2f7c9632001-06-06 20:29:01 +0000167
168
169//===----------------------------------------------------------------------===//
Chris Lattner977f0042001-11-01 05:55:13 +0000170// PointerRules Class
171//===----------------------------------------------------------------------===//
172//
173// PointerRules provides a concrete base class of ConstRules for pointer types
174//
Chris Lattner3462ae32001-12-03 22:26:30 +0000175struct PointerRules : public TemplateRules<ConstantPointer, PointerRules> {
176 inline static ConstantBool *CastToBool (const Constant *V) {
177 if (V->isNullValue()) return ConstantBool::False;
Chris Lattner977f0042001-11-01 05:55:13 +0000178 return 0; // Can't const prop other types of pointers
179 }
Chris Lattner3462ae32001-12-03 22:26:30 +0000180 inline static ConstantSInt *CastToSByte (const Constant *V) {
181 if (V->isNullValue()) return ConstantSInt::get(Type::SByteTy, 0);
Chris Lattner977f0042001-11-01 05:55:13 +0000182 return 0; // Can't const prop other types of pointers
183 }
Chris Lattner3462ae32001-12-03 22:26:30 +0000184 inline static ConstantUInt *CastToUByte (const Constant *V) {
185 if (V->isNullValue()) return ConstantUInt::get(Type::UByteTy, 0);
Chris Lattner977f0042001-11-01 05:55:13 +0000186 return 0; // Can't const prop other types of pointers
187 }
Chris Lattner3462ae32001-12-03 22:26:30 +0000188 inline static ConstantSInt *CastToShort (const Constant *V) {
189 if (V->isNullValue()) return ConstantSInt::get(Type::ShortTy, 0);
Chris Lattner977f0042001-11-01 05:55:13 +0000190 return 0; // Can't const prop other types of pointers
191 }
Chris Lattner3462ae32001-12-03 22:26:30 +0000192 inline static ConstantUInt *CastToUShort(const Constant *V) {
193 if (V->isNullValue()) return ConstantUInt::get(Type::UShortTy, 0);
Chris Lattner977f0042001-11-01 05:55:13 +0000194 return 0; // Can't const prop other types of pointers
195 }
Chris Lattner3462ae32001-12-03 22:26:30 +0000196 inline static ConstantSInt *CastToInt (const Constant *V) {
197 if (V->isNullValue()) return ConstantSInt::get(Type::IntTy, 0);
Chris Lattner977f0042001-11-01 05:55:13 +0000198 return 0; // Can't const prop other types of pointers
199 }
Chris Lattner3462ae32001-12-03 22:26:30 +0000200 inline static ConstantUInt *CastToUInt (const Constant *V) {
201 if (V->isNullValue()) return ConstantUInt::get(Type::UIntTy, 0);
Chris Lattner977f0042001-11-01 05:55:13 +0000202 return 0; // Can't const prop other types of pointers
203 }
Chris Lattner3462ae32001-12-03 22:26:30 +0000204 inline static ConstantSInt *CastToLong (const Constant *V) {
205 if (V->isNullValue()) return ConstantSInt::get(Type::LongTy, 0);
Chris Lattner977f0042001-11-01 05:55:13 +0000206 return 0; // Can't const prop other types of pointers
207 }
Chris Lattner3462ae32001-12-03 22:26:30 +0000208 inline static ConstantUInt *CastToULong (const Constant *V) {
209 if (V->isNullValue()) return ConstantUInt::get(Type::ULongTy, 0);
Chris Lattner977f0042001-11-01 05:55:13 +0000210 return 0; // Can't const prop other types of pointers
211 }
Chris Lattner3462ae32001-12-03 22:26:30 +0000212 inline static ConstantFP *CastToFloat (const Constant *V) {
213 if (V->isNullValue()) return ConstantFP::get(Type::FloatTy, 0);
Chris Lattner977f0042001-11-01 05:55:13 +0000214 return 0; // Can't const prop other types of pointers
215 }
Chris Lattner3462ae32001-12-03 22:26:30 +0000216 inline static ConstantFP *CastToDouble(const Constant *V) {
217 if (V->isNullValue()) return ConstantFP::get(Type::DoubleTy, 0);
Chris Lattner977f0042001-11-01 05:55:13 +0000218 return 0; // Can't const prop other types of pointers
219 }
220
Chris Lattner3462ae32001-12-03 22:26:30 +0000221 inline static ConstantPointer *CastToPointer(const ConstantPointer *V,
222 const PointerType *PTy) {
Chris Lattner977f0042001-11-01 05:55:13 +0000223 if (V->isNullValue())
Chris Lattner3462ae32001-12-03 22:26:30 +0000224 return ConstantPointerNull::get(PTy);
Chris Lattner977f0042001-11-01 05:55:13 +0000225 return 0; // Can't const prop other types of pointers
226 }
227};
228
229
230//===----------------------------------------------------------------------===//
Chris Lattner2f7c9632001-06-06 20:29:01 +0000231// DirectRules Class
232//===----------------------------------------------------------------------===//
233//
234// DirectRules provides a concrete base classes of ConstRules for a variety of
235// different types. This allows the C++ compiler to automatically generate our
236// constant handling operations in a typesafe and accurate manner.
237//
Chris Lattner3462ae32001-12-03 22:26:30 +0000238template<class ConstantClass, class BuiltinType, Type **Ty>
Chris Lattner2f7c9632001-06-06 20:29:01 +0000239struct DirectRules
Chris Lattner3462ae32001-12-03 22:26:30 +0000240 : public TemplateRules<ConstantClass,
241 DirectRules<ConstantClass, BuiltinType, Ty> > {
Chris Lattner2f7c9632001-06-06 20:29:01 +0000242
Chris Lattner3462ae32001-12-03 22:26:30 +0000243 inline static Constant *Not(const ConstantClass *V) {
244 return ConstantClass::get(*Ty, !(BuiltinType)V->getValue());;
Chris Lattner2f7c9632001-06-06 20:29:01 +0000245 }
246
Chris Lattner3462ae32001-12-03 22:26:30 +0000247 inline static Constant *Add(const ConstantClass *V1,
248 const ConstantClass *V2) {
Chris Lattner2f7c9632001-06-06 20:29:01 +0000249 BuiltinType Result = (BuiltinType)V1->getValue() +
250 (BuiltinType)V2->getValue();
Chris Lattner3462ae32001-12-03 22:26:30 +0000251 return ConstantClass::get(*Ty, Result);
Chris Lattner2f7c9632001-06-06 20:29:01 +0000252 }
253
Chris Lattner3462ae32001-12-03 22:26:30 +0000254 inline static Constant *Sub(const ConstantClass *V1,
255 const ConstantClass *V2) {
Chris Lattner2f7c9632001-06-06 20:29:01 +0000256 BuiltinType Result = (BuiltinType)V1->getValue() -
257 (BuiltinType)V2->getValue();
Chris Lattner3462ae32001-12-03 22:26:30 +0000258 return ConstantClass::get(*Ty, Result);
Chris Lattner2f7c9632001-06-06 20:29:01 +0000259 }
260
Chris Lattner3462ae32001-12-03 22:26:30 +0000261 inline static Constant *Mul(const ConstantClass *V1,
262 const ConstantClass *V2) {
Chris Lattner4f6031f2001-07-20 19:15:36 +0000263 BuiltinType Result = (BuiltinType)V1->getValue() *
264 (BuiltinType)V2->getValue();
Chris Lattner3462ae32001-12-03 22:26:30 +0000265 return ConstantClass::get(*Ty, Result);
Chris Lattner4f6031f2001-07-20 19:15:36 +0000266 }
267
Chris Lattner3462ae32001-12-03 22:26:30 +0000268 inline static ConstantBool *LessThan(const ConstantClass *V1,
269 const ConstantClass *V2) {
Chris Lattner2f7c9632001-06-06 20:29:01 +0000270 bool Result = (BuiltinType)V1->getValue() < (BuiltinType)V2->getValue();
Chris Lattner3462ae32001-12-03 22:26:30 +0000271 return ConstantBool::get(Result);
Chris Lattner2f7c9632001-06-06 20:29:01 +0000272 }
Chris Lattner55406842001-07-21 19:10:49 +0000273
Chris Lattner3462ae32001-12-03 22:26:30 +0000274 inline static ConstantPointer *CastToPointer(const ConstantClass *V,
275 const PointerType *PTy) {
Chris Lattner977f0042001-11-01 05:55:13 +0000276 if (V->isNullValue()) // Is it a FP or Integral null value?
Chris Lattner3462ae32001-12-03 22:26:30 +0000277 return ConstantPointerNull::get(PTy);
Chris Lattner977f0042001-11-01 05:55:13 +0000278 return 0; // Can't const prop other types of pointers
279 }
280
Chris Lattner55406842001-07-21 19:10:49 +0000281 // Casting operators. ick
282#define DEF_CAST(TYPE, CLASS, CTYPE) \
Chris Lattner3462ae32001-12-03 22:26:30 +0000283 inline static CLASS *CastTo##TYPE (const ConstantClass *V) { \
Chris Lattnerbbb22962001-09-07 16:40:34 +0000284 return CLASS::get(Type::TYPE##Ty, (CTYPE)(BuiltinType)V->getValue()); \
Chris Lattner55406842001-07-21 19:10:49 +0000285 }
286
Chris Lattner3462ae32001-12-03 22:26:30 +0000287 DEF_CAST(Bool , ConstantBool, bool)
288 DEF_CAST(SByte , ConstantSInt, signed char)
289 DEF_CAST(UByte , ConstantUInt, unsigned char)
290 DEF_CAST(Short , ConstantSInt, signed short)
291 DEF_CAST(UShort, ConstantUInt, unsigned short)
292 DEF_CAST(Int , ConstantSInt, signed int)
293 DEF_CAST(UInt , ConstantUInt, unsigned int)
294 DEF_CAST(Long , ConstantSInt, int64_t)
295 DEF_CAST(ULong , ConstantUInt, uint64_t)
296 DEF_CAST(Float , ConstantFP , float)
297 DEF_CAST(Double, ConstantFP , double)
Chris Lattner55406842001-07-21 19:10:49 +0000298#undef DEF_CAST
Chris Lattner2f7c9632001-06-06 20:29:01 +0000299};
300
301//===----------------------------------------------------------------------===//
302// DirectRules Subclasses
303//===----------------------------------------------------------------------===//
304//
305// Given the DirectRules class we can now implement lots of types with little
306// code. Thank goodness C++ compilers are great at stomping out layers of
307// templates... can you imagine having to do this all by hand? (/me is lazy :)
308//
Chris Lattner2f7c9632001-06-06 20:29:01 +0000309
310// ConstRules::find - Return the constant rules that take care of the specified
Chris Lattner61607ee2001-09-09 21:01:20 +0000311// type.
Chris Lattner2f7c9632001-06-06 20:29:01 +0000312//
Chris Lattner61607ee2001-09-09 21:01:20 +0000313Annotation *ConstRules::find(AnnotationID AID, const Annotable *TyA, void *) {
314 assert(AID == ConstRules::AID && "Bad annotation for factory!");
Chris Lattner8f191122001-10-01 18:26:53 +0000315 const Type *Ty = cast<Type>((const Value*)TyA);
Chris Lattner61607ee2001-09-09 21:01:20 +0000316
Chris Lattner2f7c9632001-06-06 20:29:01 +0000317 switch (Ty->getPrimitiveID()) {
Chris Lattner977f0042001-11-01 05:55:13 +0000318 case Type::BoolTyID: return new BoolRules();
319 case Type::PointerTyID: return new PointerRules();
Chris Lattner61607ee2001-09-09 21:01:20 +0000320 case Type::SByteTyID:
Chris Lattner3462ae32001-12-03 22:26:30 +0000321 return new DirectRules<ConstantSInt, signed char , &Type::SByteTy>();
Chris Lattner61607ee2001-09-09 21:01:20 +0000322 case Type::UByteTyID:
Chris Lattner3462ae32001-12-03 22:26:30 +0000323 return new DirectRules<ConstantUInt, unsigned char , &Type::UByteTy>();
Chris Lattner61607ee2001-09-09 21:01:20 +0000324 case Type::ShortTyID:
Chris Lattner3462ae32001-12-03 22:26:30 +0000325 return new DirectRules<ConstantSInt, signed short, &Type::ShortTy>();
Chris Lattner61607ee2001-09-09 21:01:20 +0000326 case Type::UShortTyID:
Chris Lattner3462ae32001-12-03 22:26:30 +0000327 return new DirectRules<ConstantUInt, unsigned short, &Type::UShortTy>();
Chris Lattner61607ee2001-09-09 21:01:20 +0000328 case Type::IntTyID:
Chris Lattner3462ae32001-12-03 22:26:30 +0000329 return new DirectRules<ConstantSInt, signed int , &Type::IntTy>();
Chris Lattner61607ee2001-09-09 21:01:20 +0000330 case Type::UIntTyID:
Chris Lattner3462ae32001-12-03 22:26:30 +0000331 return new DirectRules<ConstantUInt, unsigned int , &Type::UIntTy>();
Chris Lattner61607ee2001-09-09 21:01:20 +0000332 case Type::LongTyID:
Chris Lattner3462ae32001-12-03 22:26:30 +0000333 return new DirectRules<ConstantSInt, int64_t , &Type::LongTy>();
Chris Lattner61607ee2001-09-09 21:01:20 +0000334 case Type::ULongTyID:
Chris Lattner3462ae32001-12-03 22:26:30 +0000335 return new DirectRules<ConstantUInt, uint64_t , &Type::ULongTy>();
Chris Lattner61607ee2001-09-09 21:01:20 +0000336 case Type::FloatTyID:
Chris Lattner3462ae32001-12-03 22:26:30 +0000337 return new DirectRules<ConstantFP , float , &Type::FloatTy>();
Chris Lattner61607ee2001-09-09 21:01:20 +0000338 case Type::DoubleTyID:
Chris Lattner3462ae32001-12-03 22:26:30 +0000339 return new DirectRules<ConstantFP , double , &Type::DoubleTy>();
Chris Lattner61607ee2001-09-09 21:01:20 +0000340 default:
341 return new EmptyRules();
Chris Lattner2f7c9632001-06-06 20:29:01 +0000342 }
Chris Lattner2f7c9632001-06-06 20:29:01 +0000343}
Chris Lattnerd42d4922001-06-30 04:36:40 +0000344
345
346} // End namespace opt