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

Side by Side Diff: src/ic.cc

Issue 173963002: Remove all uses of field-tracking flags that do not make decisions but are subject to existing info… (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: More flags removed Created 6 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 | Annotate | Revision Log
« no previous file with comments | « src/ia32/stub-cache-ia32.cc ('k') | src/json-parser.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 1826 matching lines...) Expand 10 before | Expand all | Expand 10 after
1837 int new_unused = transition->unused_property_fields(); 1837 int new_unused = transition->unused_property_fields();
1838 int new_size = old_storage->length() + new_unused + 1; 1838 int new_size = old_storage->length() + new_unused + 1;
1839 Object* result; 1839 Object* result;
1840 MaybeObject* maybe_result = old_storage->CopySize(new_size); 1840 MaybeObject* maybe_result = old_storage->CopySize(new_size);
1841 if (!maybe_result->ToObject(&result)) return maybe_result; 1841 if (!maybe_result->ToObject(&result)) return maybe_result;
1842 1842
1843 FixedArray* new_storage = FixedArray::cast(result); 1843 FixedArray* new_storage = FixedArray::cast(result);
1844 1844
1845 Object* to_store = value; 1845 Object* to_store = value;
1846 1846
1847 if (FLAG_track_double_fields) { 1847 DescriptorArray* descriptors = transition->instance_descriptors();
1848 DescriptorArray* descriptors = transition->instance_descriptors(); 1848 PropertyDetails details = descriptors->GetDetails(transition->LastAdded());
1849 PropertyDetails details = descriptors->GetDetails(transition->LastAdded()); 1849 if (details.representation().IsDouble()) {
1850 if (details.representation().IsDouble()) { 1850 MaybeObject* maybe_storage =
1851 MaybeObject* maybe_storage = 1851 isolate->heap()->AllocateHeapNumber(value->Number());
1852 isolate->heap()->AllocateHeapNumber(value->Number()); 1852 if (!maybe_storage->To(&to_store)) return maybe_storage;
1853 if (!maybe_storage->To(&to_store)) return maybe_storage;
1854 }
1855 } 1853 }
1856 1854
1857 new_storage->set(old_storage->length(), to_store); 1855 new_storage->set(old_storage->length(), to_store);
1858 1856
1859 // Set the new property value and do the map transition. 1857 // Set the new property value and do the map transition.
1860 object->set_properties(new_storage); 1858 object->set_properties(new_storage);
1861 object->set_map(transition); 1859 object->set_map(transition);
1862 1860
1863 // Return the stored value. 1861 // Return the stored value.
1864 return value; 1862 return value;
(...skipping 948 matching lines...) Expand 10 before | Expand all | Expand 10 after
2813 #undef ADDR 2811 #undef ADDR
2814 }; 2812 };
2815 2813
2816 2814
2817 Address IC::AddressFromUtilityId(IC::UtilityId id) { 2815 Address IC::AddressFromUtilityId(IC::UtilityId id) {
2818 return IC_utilities[id]; 2816 return IC_utilities[id];
2819 } 2817 }
2820 2818
2821 2819
2822 } } // namespace v8::internal 2820 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/ia32/stub-cache-ia32.cc ('k') | src/json-parser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698