| OLD | NEW |
| 1 //===- subzero/src/IceGlobalContext.cpp - Global context defs -------------===// | 1 //===- subzero/src/IceGlobalContext.cpp - Global context defs -------------===// |
| 2 // | 2 // |
| 3 // The Subzero Code Generator | 3 // The Subzero Code Generator |
| 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 // This file defines aspects of the compilation that persist across | 10 // This file defines aspects of the compilation that persist across |
| (...skipping 295 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 306 } | 306 } |
| 307 | 307 |
| 308 Constant *GlobalContext::getConstantFloat(float ConstantFloat) { | 308 Constant *GlobalContext::getConstantFloat(float ConstantFloat) { |
| 309 return ConstPool->Floats.getOrAdd(this, IceType_f32, ConstantFloat); | 309 return ConstPool->Floats.getOrAdd(this, IceType_f32, ConstantFloat); |
| 310 } | 310 } |
| 311 | 311 |
| 312 Constant *GlobalContext::getConstantDouble(double ConstantDouble) { | 312 Constant *GlobalContext::getConstantDouble(double ConstantDouble) { |
| 313 return ConstPool->Doubles.getOrAdd(this, IceType_f64, ConstantDouble); | 313 return ConstPool->Doubles.getOrAdd(this, IceType_f64, ConstantDouble); |
| 314 } | 314 } |
| 315 | 315 |
| 316 Constant *GlobalContext::getConstantSym(Type Ty, int64_t Offset, | 316 Constant *GlobalContext::getConstantSym(Type Ty, RelocOffsetT Offset, |
| 317 const IceString &Name, | 317 const IceString &Name, |
| 318 bool SuppressMangling) { | 318 bool SuppressMangling) { |
| 319 return ConstPool->Relocatables.getOrAdd( | 319 return ConstPool->Relocatables.getOrAdd( |
| 320 this, Ty, RelocatableTuple(Offset, Name, SuppressMangling)); | 320 this, Ty, RelocatableTuple(Offset, Name, SuppressMangling)); |
| 321 } | 321 } |
| 322 | 322 |
| 323 Constant *GlobalContext::getConstantUndef(Type Ty) { | 323 Constant *GlobalContext::getConstantUndef(Type Ty) { |
| 324 return ConstPool->Undefs.getOrAdd(this, Ty); | 324 return ConstPool->Undefs.getOrAdd(this, Ty); |
| 325 } | 325 } |
| 326 | 326 |
| (...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 455 } | 455 } |
| 456 | 456 |
| 457 TimerMarker::TimerMarker(TimerIdT ID, const Cfg *Func) | 457 TimerMarker::TimerMarker(TimerIdT ID, const Cfg *Func) |
| 458 : ID(ID), Ctx(Func->getContext()), | 458 : ID(ID), Ctx(Func->getContext()), |
| 459 Active(Func->getFocusedTiming() || Ctx->getFlags().SubzeroTimingEnabled) { | 459 Active(Func->getFocusedTiming() || Ctx->getFlags().SubzeroTimingEnabled) { |
| 460 if (Active) | 460 if (Active) |
| 461 Ctx->pushTimer(ID); | 461 Ctx->pushTimer(ID); |
| 462 } | 462 } |
| 463 | 463 |
| 464 } // end of namespace Ice | 464 } // end of namespace Ice |
| OLD | NEW |