array_buffer_builder.cc in src <https://cs.chromium.org/chromium/src/>/ third_party <https://cs.chromium.org/chromium/src/third_party/>/blink <https://cs.chromium.org/chromium/src/third_party/blink/>/renderer <https://cs.chromium.org/chromium/src/third_party/blink/renderer/>/platform <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/>/ wtf <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/> /typed_arrays <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/> /array_buffer_builder.cc <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_builder.cc> the ArrayBufferBuilder <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_builder.h?l=44&ct=xref_jump_to_def&gsn=ArrayBufferBuilder> ::Append <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_builder.cc?l=74&gs=kythe%253A%252F%252Fchromium%253Flang%253Dc%25252B%25252B%253Fpath%253Dsrc%252Fthird_party%252Fblink%252Frenderer%252Fplatform%252Fwtf%252Ftyped_arrays%252Farray_buffer_builder.cc%2523NFGzJegTouRzc7WYe5NO52sD3rtLZRfs3mHeMLIQn8I%25253D&gsn=Append&ct=xref_usages> method will be called through a view on top of the arraybuffer? something like, there's a arraybuffer of 30bytes in length and we define a view on top of it (so a typedarray) wehn i call on the new typedarray object the .append method it will call ArrayBufferBuilder <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_builder.h?l=44&ct=xref_jump_to_def&gsn=ArrayBufferBuilder> ::Append <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_builder.cc?l=74&gs=kythe%253A%252F%252Fchromium%253Flang%253Dc%25252B%25252B%253Fpath%253Dsrc%252Fthird_party%252Fblink%252Frenderer%252Fplatform%252Fwtf%252Ftyped_arrays%252Farray_buffer_builder.cc%2523NFGzJegTouRzc7WYe5NO52sD3rtLZRfs3mHeMLIQn8I%25253D&gsn=Append&ct=xref_usages> and then inside it's code it will execute ArrayBufferBuilder <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_builder.h?l=44&ct=xref_jump_to_def&gsn=ArrayBufferBuilder> ::ExpandCapacity <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_builder.cc?l=45&gs=kythe%253A%252F%252Fchromium%253Flang%253Dc%25252B%25252B%253Fpath%253Dsrc%252Fthird_party%252Fblink%252Frenderer%252Fplatform%252Fwtf%252Ftyped_arrays%252Farray_buffer_builder.cc%2523Fu6GnwJLuMqh5Thz%25252BDq0LStBEA8HzkICqnAPtIOPIhY%25253D&gsn=ExpandCapacity&ct=xref_usages> if it needs to reallocate the array ?
if so inside the expandCapacity definition bytes_used <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_builder.h?l=92&ct=xref_jump_to_def&gsn=bytes_used_> referes to the elements inside the actual arraybuffer so if i have a arraybuffer which is 8 bytes in length [ ][ ][ ][ ][ ][ ][ ][ ] and i fill in only 3 bytes so [1][2][3][ ][ ][ ][ ][ ] the bytes_used <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_builder.h?l=92&ct=xref_jump_to_def&gsn=bytes_used_> when retrieved will be set to 3 bytes ?? ArrayBufferBuilder <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_builder.h?l=44&ct=xref_jump_to_def&gsn=ArrayBufferBuilder>::ArrayBufferBuilder <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_builder.cc?l=40&gs=kythe%253A%252F%252Fchromium%253Flang%253Dc%25252B%25252B%253Fpath%253Dsrc%252Fthird_party%252Fblink%252Frenderer%252Fplatform%252Fwtf%252Ftyped_arrays%252Farray_buffer_builder.cc%2523lcp23D0sHKN2WnDoJe7UbBQtgQbZY3lJ%25252Bn9qnDlawck%25253D&gsn=ArrayBufferBuilder&ct=xref_usages>() : bytes_used_ <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_builder.h?l=92&ct=xref_jump_to_def&gsn=bytes_used_>(0), variable_capacity_ <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_builder.h?l=93&ct=xref_jump_to_def&gsn=variable_capacity_>(true) { buffer_ <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_builder.h?l=94&ct=xref_jump_to_def&gsn=buffer_> = <https://cs.chromium.org/chromium/src/base/memory/scoped_refptr.h?l=226&ct=xref_jump_to_def&gsn=%3D> ArrayBuffer <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer.h?l=42&ct=xref_jump_to_def&gsn=ArrayBuffer>::Create <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer.h?l=125&ct=xref_jump_to_def&gsn=Create>(kDefaultBufferCapacity <https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/wtf/typed_arrays/array_buffer_builder.cc?l=38&ct=xref_jump_to_def&gsn=kDefaultBufferCapacity>, 1);} here buffer_ will be equal to an arraybuffer of 32768 bytes in length ? since the KdefaultBuffer... is set to that value. is std::numeric_limits <https://cs.chromium.org/chromium/src/buildtools/third_party/libc%2B%2B/trunk/include/limits?l=442&ct=xref_jump_to_def&gsn=numeric_limits><unsigned>::max <https://cs.chromium.org/chromium/src/buildtools/third_party/libc%2B%2B/trunk/include/limits?l=450&ct=xref_jump_to_def&gsn=max>(); referring to the max unsigned int value ? cause the source code won't find it -- -- v8-users mailing list v8-users@googlegroups.com http://groups.google.com/group/v8-users --- You received this message because you are subscribed to the Google Groups "v8-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to v8-users+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.