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

Side by Side Diff: src/runtime/runtime-typedarray.cc

Issue 1617503003: [Atomics] code stubs for atomic operations (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: merge master + reduce kSlotIndexBits Created 4 years, 8 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/runtime/runtime-atomics.cc ('k') | src/x64/code-stubs-x64.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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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 #include "src/runtime/runtime-utils.h" 5 #include "src/runtime/runtime-utils.h"
6 6
7 #include "src/arguments.h" 7 #include "src/arguments.h"
8 #include "src/factory.h" 8 #include "src/factory.h"
9 #include "src/messages.h" 9 #include "src/messages.h"
10 #include "src/objects-inl.h" 10 #include "src/objects-inl.h"
(...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after
390 RUNTIME_FUNCTION(Runtime_IsSharedIntegerTypedArray) { 390 RUNTIME_FUNCTION(Runtime_IsSharedIntegerTypedArray) {
391 HandleScope scope(isolate); 391 HandleScope scope(isolate);
392 DCHECK(args.length() == 1); 392 DCHECK(args.length() == 1);
393 if (!args[0]->IsJSTypedArray()) { 393 if (!args[0]->IsJSTypedArray()) {
394 return isolate->heap()->false_value(); 394 return isolate->heap()->false_value();
395 } 395 }
396 396
397 Handle<JSTypedArray> obj(JSTypedArray::cast(args[0])); 397 Handle<JSTypedArray> obj(JSTypedArray::cast(args[0]));
398 return isolate->heap()->ToBoolean(obj->GetBuffer()->is_shared() && 398 return isolate->heap()->ToBoolean(obj->GetBuffer()->is_shared() &&
399 obj->type() != kExternalFloat32Array && 399 obj->type() != kExternalFloat32Array &&
400 obj->type() != kExternalFloat64Array); 400 obj->type() != kExternalFloat64Array &&
401 obj->type() != kExternalUint8ClampedArray);
401 } 402 }
402 403
403 404
404 RUNTIME_FUNCTION(Runtime_IsSharedInteger32TypedArray) { 405 RUNTIME_FUNCTION(Runtime_IsSharedInteger32TypedArray) {
405 HandleScope scope(isolate); 406 HandleScope scope(isolate);
406 DCHECK(args.length() == 1); 407 DCHECK(args.length() == 1);
407 if (!args[0]->IsJSTypedArray()) { 408 if (!args[0]->IsJSTypedArray()) {
408 return isolate->heap()->false_value(); 409 return isolate->heap()->false_value();
409 } 410 }
410 411
(...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after
626 DATA_VIEW_SETTER(Uint16, uint16_t) 627 DATA_VIEW_SETTER(Uint16, uint16_t)
627 DATA_VIEW_SETTER(Int16, int16_t) 628 DATA_VIEW_SETTER(Int16, int16_t)
628 DATA_VIEW_SETTER(Uint32, uint32_t) 629 DATA_VIEW_SETTER(Uint32, uint32_t)
629 DATA_VIEW_SETTER(Int32, int32_t) 630 DATA_VIEW_SETTER(Int32, int32_t)
630 DATA_VIEW_SETTER(Float32, float) 631 DATA_VIEW_SETTER(Float32, float)
631 DATA_VIEW_SETTER(Float64, double) 632 DATA_VIEW_SETTER(Float64, double)
632 633
633 #undef DATA_VIEW_SETTER 634 #undef DATA_VIEW_SETTER
634 } // namespace internal 635 } // namespace internal
635 } // namespace v8 636 } // namespace v8
OLDNEW
« no previous file with comments | « src/runtime/runtime-atomics.cc ('k') | src/x64/code-stubs-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698