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

Side by Side Diff: src/IceGlobalContext.cpp

Issue 428733003: A couple of fixes for using Makefile.standalone on Mac. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: line wrap Created 6 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 | « Makefile.standalone ('k') | src/IceTargetLowering.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 //===- subzero/src/IceGlobalContext.cpp - Global context defs ---*- C++ -*-===// 1 //===- subzero/src/IceGlobalContext.cpp - Global context defs ---*- C++ -*-===//
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
11 // multiple functions. 11 // multiple functions.
12 // 12 //
13 //===----------------------------------------------------------------------===// 13 //===----------------------------------------------------------------------===//
14 14
15 #include <ctype.h> // isdigit(), isupper() 15 #include <ctype.h> // isdigit(), isupper()
16 #include <locale> // locale
16 17
17 #include "IceDefs.h" 18 #include "IceDefs.h"
18 #include "IceTypes.h" 19 #include "IceTypes.h"
19 #include "IceCfg.h" 20 #include "IceCfg.h"
20 #include "IceGlobalContext.h" 21 #include "IceGlobalContext.h"
21 #include "IceOperand.h" 22 #include "IceOperand.h"
22 #include "IceTargetLowering.h" 23 #include "IceTargetLowering.h"
23 24
24 namespace Ice { 25 namespace Ice {
25 26
(...skipping 28 matching lines...) Expand all
54 E = Pool.end(); 55 E = Pool.end();
55 I != E; ++I) { 56 I != E; ++I) {
56 Constants.push_back(I->second); 57 Constants.push_back(I->second);
57 } 58 }
58 return Constants; 59 return Constants;
59 } 60 }
60 61
61 private: 62 private:
62 typedef std::pair<Type, KeyType> TupleType; 63 typedef std::pair<Type, KeyType> TupleType;
63 struct TupleCompare { 64 struct TupleCompare {
64 bool operator()(const TupleType &A, const TupleType &B) { 65 bool operator()(const TupleType &A, const TupleType &B) const {
65 if (A.first != B.first) 66 if (A.first != B.first)
66 return A.first < B.first; 67 return A.first < B.first;
67 if (KeyTypeHasFP) 68 if (KeyTypeHasFP)
68 return memcmp(&A.second, &B.second, sizeof(KeyType)) < 0; 69 return memcmp(&A.second, &B.second, sizeof(KeyType)) < 0;
69 return A.second < B.second; 70 return A.second < B.second;
70 } 71 }
71 }; 72 };
72 typedef std::map<const TupleType, ValueType *, TupleCompare> ContainerType; 73 typedef std::map<const TupleType, ValueType *, TupleCompare> ContainerType;
73 ContainerType Pool; 74 ContainerType Pool;
74 uint32_t NextPoolID; 75 uint32_t NextPoolID;
(...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after
373 374
374 void Timer::printElapsedUs(GlobalContext *Ctx, const IceString &Tag) const { 375 void Timer::printElapsedUs(GlobalContext *Ctx, const IceString &Tag) const {
375 if (Ctx->isVerbose(IceV_Timing)) { 376 if (Ctx->isVerbose(IceV_Timing)) {
376 // Prefixing with '#' allows timing strings to be included 377 // Prefixing with '#' allows timing strings to be included
377 // without error in textual assembly output. 378 // without error in textual assembly output.
378 Ctx->getStrDump() << "# " << getElapsedUs() << " usec " << Tag << "\n"; 379 Ctx->getStrDump() << "# " << getElapsedUs() << " usec " << Tag << "\n";
379 } 380 }
380 } 381 }
381 382
382 } // end of namespace Ice 383 } // end of namespace Ice
OLDNEW
« no previous file with comments | « Makefile.standalone ('k') | src/IceTargetLowering.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698