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

Side by Side Diff: src/objects-inl.h

Issue 888613002: Initial switch to Chromium-style CHECK_* and DCHECK_* macros. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: CHECK_NULL/NOT_NULL is back. Created 5 years, 10 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 | « src/objects-debug.cc ('k') | src/optimizing-compiler-thread.cc » ('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 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 // 4 //
5 // Review notes: 5 // Review notes:
6 // 6 //
7 // - The use of macros in these inline functions may seem superfluous 7 // - The use of macros in these inline functions may seem superfluous
8 // but it is absolutely needed to make sure gcc generates optimal 8 // but it is absolutely needed to make sure gcc generates optimal
9 // code. gcc is not happy when attempting to inline too deep. 9 // code. gcc is not happy when attempting to inline too deep.
10 // 10 //
(...skipping 2933 matching lines...) Expand 10 before | Expand all | Expand 10 after
2944 if (current_hash > hash) { 2944 if (current_hash > hash) {
2945 if (out_insertion_index != NULL) *out_insertion_index = sorted_index; 2945 if (out_insertion_index != NULL) *out_insertion_index = sorted_index;
2946 return T::kNotFound; 2946 return T::kNotFound;
2947 } 2947 }
2948 if (current_hash == hash && entry->Equals(name)) return sorted_index; 2948 if (current_hash == hash && entry->Equals(name)) return sorted_index;
2949 } 2949 }
2950 if (out_insertion_index != NULL) *out_insertion_index = len; 2950 if (out_insertion_index != NULL) *out_insertion_index = len;
2951 return T::kNotFound; 2951 return T::kNotFound;
2952 } else { 2952 } else {
2953 DCHECK(len >= valid_entries); 2953 DCHECK(len >= valid_entries);
2954 DCHECK_EQ(NULL, out_insertion_index); // Not supported here. 2954 DCHECK_NULL(out_insertion_index); // Not supported here.
2955 for (int number = 0; number < valid_entries; number++) { 2955 for (int number = 0; number < valid_entries; number++) {
2956 Name* entry = array->GetKey(number); 2956 Name* entry = array->GetKey(number);
2957 uint32_t current_hash = entry->Hash(); 2957 uint32_t current_hash = entry->Hash();
2958 if (current_hash == hash && entry->Equals(name)) return number; 2958 if (current_hash == hash && entry->Equals(name)) return number;
2959 } 2959 }
2960 return T::kNotFound; 2960 return T::kNotFound;
2961 } 2961 }
2962 } 2962 }
2963 2963
2964 2964
(...skipping 4630 matching lines...) Expand 10 before | Expand all | Expand 10 after
7595 #undef READ_SHORT_FIELD 7595 #undef READ_SHORT_FIELD
7596 #undef WRITE_SHORT_FIELD 7596 #undef WRITE_SHORT_FIELD
7597 #undef READ_BYTE_FIELD 7597 #undef READ_BYTE_FIELD
7598 #undef WRITE_BYTE_FIELD 7598 #undef WRITE_BYTE_FIELD
7599 #undef NOBARRIER_READ_BYTE_FIELD 7599 #undef NOBARRIER_READ_BYTE_FIELD
7600 #undef NOBARRIER_WRITE_BYTE_FIELD 7600 #undef NOBARRIER_WRITE_BYTE_FIELD
7601 7601
7602 } } // namespace v8::internal 7602 } } // namespace v8::internal
7603 7603
7604 #endif // V8_OBJECTS_INL_H_ 7604 #endif // V8_OBJECTS_INL_H_
OLDNEW
« no previous file with comments | « src/objects-debug.cc ('k') | src/optimizing-compiler-thread.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698