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

Side by Side Diff: runtime/vm/intermediate_language_x64.cc

Issue 738453002: Add missing verified write on x64; extend test coverage (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 1 month 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
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_X64. 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_X64.
6 #if defined(TARGET_ARCH_X64) 6 #if defined(TARGET_ARCH_X64)
7 7
8 #include "vm/intermediate_language.h" 8 #include "vm/intermediate_language.h"
9 9
10 #include "vm/dart_entry.h" 10 #include "vm/dart_entry.h"
(...skipping 1235 matching lines...) Expand 10 before | Expand all | Expand 10 after
1246 if ((index_scale() == 1) && index.IsRegister()) { 1246 if ((index_scale() == 1) && index.IsRegister()) {
1247 __ SmiUntag(index.reg()); 1247 __ SmiUntag(index.reg());
1248 } 1248 }
1249 switch (class_id()) { 1249 switch (class_id()) {
1250 case kArrayCid: 1250 case kArrayCid:
1251 if (ShouldEmitStoreBarrier()) { 1251 if (ShouldEmitStoreBarrier()) {
1252 Register value = locs()->in(2).reg(); 1252 Register value = locs()->in(2).reg();
1253 __ StoreIntoObject(array, element_address, value); 1253 __ StoreIntoObject(array, element_address, value);
1254 } else if (locs()->in(2).IsConstant()) { 1254 } else if (locs()->in(2).IsConstant()) {
1255 const Object& constant = locs()->in(2).constant(); 1255 const Object& constant = locs()->in(2).constant();
1256 __ StoreObject(element_address, constant, PP); 1256 __ StoreIntoObjectNoBarrier(array, element_address, constant, PP);
1257 } else { 1257 } else {
1258 Register value = locs()->in(2).reg(); 1258 Register value = locs()->in(2).reg();
1259 __ StoreIntoObjectNoBarrier(array, element_address, value); 1259 __ StoreIntoObjectNoBarrier(array, element_address, value);
1260 } 1260 }
1261 break; 1261 break;
1262 case kTypedDataInt8ArrayCid: 1262 case kTypedDataInt8ArrayCid:
1263 case kTypedDataUint8ArrayCid: 1263 case kTypedDataUint8ArrayCid:
1264 case kExternalTypedDataUint8ArrayCid: 1264 case kExternalTypedDataUint8ArrayCid:
1265 case kOneByteStringCid: 1265 case kOneByteStringCid:
1266 if (locs()->in(2).IsConstant()) { 1266 if (locs()->in(2).IsConstant()) {
(...skipping 583 matching lines...) Expand 10 before | Expand all | Expand 10 after
1850 } 1850 }
1851 1851
1852 if (ShouldEmitStoreBarrier()) { 1852 if (ShouldEmitStoreBarrier()) {
1853 Register value_reg = locs()->in(1).reg(); 1853 Register value_reg = locs()->in(1).reg();
1854 __ StoreIntoObject(instance_reg, 1854 __ StoreIntoObject(instance_reg,
1855 FieldAddress(instance_reg, offset_in_bytes_), 1855 FieldAddress(instance_reg, offset_in_bytes_),
1856 value_reg, 1856 value_reg,
1857 CanValueBeSmi()); 1857 CanValueBeSmi());
1858 } else { 1858 } else {
1859 if (locs()->in(1).IsConstant()) { 1859 if (locs()->in(1).IsConstant()) {
1860 __ StoreObject(FieldAddress(instance_reg, offset_in_bytes_), 1860 __ StoreIntoObjectNoBarrier(instance_reg,
1861 locs()->in(1).constant(), PP); 1861 FieldAddress(instance_reg, offset_in_bytes_),
1862 locs()->in(1).constant(), PP);
1862 } else { 1863 } else {
1863 Register value_reg = locs()->in(1).reg(); 1864 Register value_reg = locs()->in(1).reg();
1864 __ StoreIntoObjectNoBarrier(instance_reg, 1865 __ StoreIntoObjectNoBarrier(instance_reg,
1865 FieldAddress(instance_reg, offset_in_bytes_), value_reg); 1866 FieldAddress(instance_reg, offset_in_bytes_), value_reg);
1866 } 1867 }
1867 } 1868 }
1868 __ Bind(&skip_store); 1869 __ Bind(&skip_store);
1869 } 1870 }
1870 1871
1871 1872
(...skipping 4396 matching lines...) Expand 10 before | Expand all | Expand 10 after
6268 __ movq(R10, Immediate(kInvalidObjectPointer)); 6269 __ movq(R10, Immediate(kInvalidObjectPointer));
6269 __ movq(RBX, Immediate(kInvalidObjectPointer)); 6270 __ movq(RBX, Immediate(kInvalidObjectPointer));
6270 #endif 6271 #endif
6271 } 6272 }
6272 6273
6273 } // namespace dart 6274 } // namespace dart
6274 6275
6275 #undef __ 6276 #undef __
6276 6277
6277 #endif // defined TARGET_ARCH_X64 6278 #endif // defined TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « runtime/vm/flow_graph_compiler_x64.cc ('k') | tests/lib/convert/streamed_conversion_json_utf8_decode_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698