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

Side by Side Diff: src/objects.h

Issue 1305383003: Move runtime helper for JSArrayBuffer onto objects. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@local_cleanup-runtime-helpers-2
Patch Set: Self-nit. Created 5 years, 3 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/factory.cc ('k') | src/objects.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 #ifndef V8_OBJECTS_H_ 5 #ifndef V8_OBJECTS_H_
6 #define V8_OBJECTS_H_ 6 #define V8_OBJECTS_H_
7 7
8 #include <iosfwd> 8 #include <iosfwd>
9 9
10 #include "src/allocation.h" 10 #include "src/allocation.h"
(...skipping 9501 matching lines...) Expand 10 before | Expand all | Expand 10 after
9512 inline bool was_neutered(); 9512 inline bool was_neutered();
9513 inline void set_was_neutered(bool value); 9513 inline void set_was_neutered(bool value);
9514 9514
9515 inline bool is_shared(); 9515 inline bool is_shared();
9516 inline void set_is_shared(bool value); 9516 inline void set_is_shared(bool value);
9517 9517
9518 DECLARE_CAST(JSArrayBuffer) 9518 DECLARE_CAST(JSArrayBuffer)
9519 9519
9520 void Neuter(); 9520 void Neuter();
9521 9521
9522 static void Setup(Handle<JSArrayBuffer> array_buffer, Isolate* isolate,
9523 bool is_external, void* data, size_t allocated_length,
9524 SharedFlag shared = SharedFlag::kNotShared);
9525
9526 static bool SetupAllocatingData(Handle<JSArrayBuffer> array_buffer,
9527 Isolate* isolate, size_t allocated_length,
9528 bool initialize = true,
9529 SharedFlag shared = SharedFlag::kNotShared);
9530
9522 // Dispatched behavior. 9531 // Dispatched behavior.
9523 DECLARE_PRINTER(JSArrayBuffer) 9532 DECLARE_PRINTER(JSArrayBuffer)
9524 DECLARE_VERIFIER(JSArrayBuffer) 9533 DECLARE_VERIFIER(JSArrayBuffer)
9525 9534
9526 static const int kBackingStoreOffset = JSObject::kHeaderSize; 9535 static const int kBackingStoreOffset = JSObject::kHeaderSize;
9527 static const int kByteLengthOffset = kBackingStoreOffset + kPointerSize; 9536 static const int kByteLengthOffset = kBackingStoreOffset + kPointerSize;
9528 static const int kBitFieldSlot = kByteLengthOffset + kPointerSize; 9537 static const int kBitFieldSlot = kByteLengthOffset + kPointerSize;
9529 #if V8_TARGET_LITTLE_ENDIAN || !V8_HOST_ARCH_64_BIT 9538 #if V8_TARGET_LITTLE_ENDIAN || !V8_HOST_ARCH_64_BIT
9530 static const int kBitFieldOffset = kBitFieldSlot; 9539 static const int kBitFieldOffset = kBitFieldSlot;
9531 #else 9540 #else
(...skipping 794 matching lines...) Expand 10 before | Expand all | Expand 10 after
10326 } else { 10335 } else {
10327 value &= ~(1 << bit_position); 10336 value &= ~(1 << bit_position);
10328 } 10337 }
10329 return value; 10338 return value;
10330 } 10339 }
10331 }; 10340 };
10332 10341
10333 } } // namespace v8::internal 10342 } } // namespace v8::internal
10334 10343
10335 #endif // V8_OBJECTS_H_ 10344 #endif // V8_OBJECTS_H_
OLDNEW
« no previous file with comments | « src/factory.cc ('k') | src/objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698