V8 Project
v8::ShellArrayBufferAllocator Class Reference
+ Inheritance diagram for v8::ShellArrayBufferAllocator:
+ Collaboration diagram for v8::ShellArrayBufferAllocator:

Public Member Functions

virtual void * Allocate (size_t length)
 Allocate |length| bytes. More...
 
virtual void * AllocateUninitialized (size_t length)
 Allocate |length| bytes. More...
 
virtual void Free (void *data, size_t)
 Free the memory block of size |length|, pointed to by |data|. More...
 
- Public Member Functions inherited from v8::ArrayBuffer::Allocator
virtual ~Allocator ()
 

Detailed Description

Definition at line 1525 of file d8.cc.

Member Function Documentation

◆ Allocate()

virtual void* v8::ShellArrayBufferAllocator::Allocate ( size_t  length)
inlinevirtual

Allocate |length| bytes.

Return NULL if allocation is not successful. Memory should be initialized to zeroes.

Implements v8::ArrayBuffer::Allocator.

Definition at line 1527 of file d8.cc.

1527  {
1528  void* data = AllocateUninitialized(length);
1529  return data == NULL ? data : memset(data, 0, length);
1530  }
virtual void * AllocateUninitialized(size_t length)
Allocate |length| bytes.
Definition: d8.cc:1531
enable harmony numeric enable harmony object literal extensions Optimize object Array DOM strings and string trace pretenuring decisions of HAllocate instructions Enables optimizations which favor memory size over execution speed maximum source size in bytes considered for a single inlining maximum cumulative number of AST nodes considered for inlining trace the tracking of allocation sites deoptimize every n garbage collections perform array bounds checks elimination analyze liveness of environment slots and zap dead values flushes the cache of optimized code for closures on every GC allow uint32 values on optimize frames if they are used only in safe operations track concurrent recompilation artificial compilation delay in ms do not emit check maps for constant values that have a leaf deoptimize the optimized code if the layout of the maps changes enable context specialization in TurboFan execution budget before interrupt is triggered max percentage of megamorphic generic ICs to allow optimization enable use of SAHF instruction if enable use of VFP3 instructions if available enable use of NEON instructions if enable use of SDIV and UDIV instructions if enable use of MLS instructions if enable loading bit constant by means of movw movt instruction enable unaligned accesses for enable use of d16 d31 registers on ARM this requires VFP3 force all emitted branches to be in long enable alignment of csp to bytes on platforms which prefer the register to always be NULL

References NULL.

◆ AllocateUninitialized()

virtual void* v8::ShellArrayBufferAllocator::AllocateUninitialized ( size_t  length)
inlinevirtual

Allocate |length| bytes.

Return NULL if allocation is not successful. Memory does not have to be initialized.

Implements v8::ArrayBuffer::Allocator.

Definition at line 1531 of file d8.cc.

1531 { return malloc(length); }

◆ Free()

virtual void v8::ShellArrayBufferAllocator::Free ( void *  data,
size_t  length 
)
inlinevirtual

Free the memory block of size |length|, pointed to by |data|.

That memory is guaranteed to be previously allocated by |Allocate|.

Implements v8::ArrayBuffer::Allocator.

Definition at line 1532 of file d8.cc.

1532 { free(data); }

The documentation for this class was generated from the following file: