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

Side by Side Diff: src/hydrogen-instructions.cc

Issue 12481015: Track Hydrogen statistics on a per-Isolate basis (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « src/hydrogen.cc ('k') | src/isolate.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 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 int HValue::LoopWeight() const { 71 int HValue::LoopWeight() const {
72 const int w = FLAG_loop_weight; 72 const int w = FLAG_loop_weight;
73 static const int weights[] = { 1, w, w*w, w*w*w, w*w*w*w }; 73 static const int weights[] = { 1, w, w*w, w*w*w, w*w*w*w };
74 return weights[Min(block()->LoopNestingDepth(), 74 return weights[Min(block()->LoopNestingDepth(),
75 static_cast<int>(ARRAY_SIZE(weights)-1))]; 75 static_cast<int>(ARRAY_SIZE(weights)-1))];
76 } 76 }
77 77
78 78
79 Isolate* HValue::isolate() const { 79 Isolate* HValue::isolate() const {
80 ASSERT(block() != NULL); 80 ASSERT(block() != NULL);
81 return block()->graph()->isolate(); 81 return block()->isolate();
82 } 82 }
83 83
84 84
85 void HValue::AssumeRepresentation(Representation r) { 85 void HValue::AssumeRepresentation(Representation r) {
86 if (CheckFlag(kFlexibleRepresentation)) { 86 if (CheckFlag(kFlexibleRepresentation)) {
87 ChangeRepresentation(r); 87 ChangeRepresentation(r);
88 // The representation of the value is dictated by type feedback and 88 // The representation of the value is dictated by type feedback and
89 // will not be changed later. 89 // will not be changed later.
90 ClearFlag(kFlexibleRepresentation); 90 ClearFlag(kFlexibleRepresentation);
91 } 91 }
(...skipping 3175 matching lines...) Expand 10 before | Expand all | Expand 10 after
3267 3267
3268 3268
3269 void HCheckFunction::Verify() { 3269 void HCheckFunction::Verify() {
3270 HInstruction::Verify(); 3270 HInstruction::Verify();
3271 ASSERT(HasNoUses()); 3271 ASSERT(HasNoUses());
3272 } 3272 }
3273 3273
3274 #endif 3274 #endif
3275 3275
3276 } } // namespace v8::internal 3276 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/hydrogen.cc ('k') | src/isolate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698