Граф коммитов

98 Коммитов

Автор SHA1 Сообщение Дата
Kagami Sascha Rosylight 2b5d45e396 Bug 1768189 - Part 6: Apply modernize-concat-nested-namespaces to dom/bindings/RootedDictionary.h ... r=andi
Depends on D145739

Differential Revision: https://phabricator.services.mozilla.com/D145740
2022-05-09 20:41:05 +00:00
Steve Fink e0df89a627 Bug 1720422 - Switch DOM bindings typed arrays to using JSAPI templates r=jonco,smaug
Differential Revision: https://phabricator.services.mozilla.com/D119858
2021-09-08 23:47:00 +00:00
Andi-Bogdan Postelnicu 250fa0d795 Bug 1725145 - header files fixes in the hybrid build env. r=valentin
Differential Revision: https://phabricator.services.mozilla.com/D122343
2021-08-22 10:21:55 +00:00
Narcis Beleuzu e61a054602 Backed out 13 changesets (bug 1720422) for hazards bustages on Cache.cpp
Backed out changeset 94293ba5a5a5 (bug 1720422)
Backed out changeset ccb7a164fe32 (bug 1720422)
Backed out changeset 44c3e9e78d0a (bug 1720422)
Backed out changeset 6880cf8c51bc (bug 1720422)
Backed out changeset 23cc649c6e14 (bug 1720422)
Backed out changeset 16695064a637 (bug 1720422)
Backed out changeset b5bafd6f08d3 (bug 1720422)
Backed out changeset f212ab757312 (bug 1720422)
Backed out changeset 180daaed9cc8 (bug 1720422)
Backed out changeset 410e13fdf4e5 (bug 1720422)
Backed out changeset 677e4aa42b4d (bug 1720422)
Backed out changeset ae5f6b9ecf4a (bug 1720422)
Backed out changeset 77ff4529ea3e (bug 1720422)
2021-08-13 07:02:45 +03:00
Steve Fink bf7140eaa9 Bug 1720422 - Switch DOM bindings typed arrays to using JSAPI templates r=jonco,smaug
Differential Revision: https://phabricator.services.mozilla.com/D119858
2021-08-12 20:44:18 +00:00
Jan de Mooij 41621582c6 Bug 1674777 part 3 - Change Get*LengthAndData outparam from uint32_t to size_t. r=sfink,aosmond
Differential Revision: https://phabricator.services.mozilla.com/D103275
2021-01-31 08:35:40 +00:00
Jan de Mooij e6456075d7 Bug 1674777 part 1 - Change JS::NewArrayBuffer and JS_New*Array size argument from uint32_t to size_t. r=sfink
A later patch will add a jsapi-test for this.

Differential Revision: https://phabricator.services.mozilla.com/D103273
2021-01-28 15:53:44 +00:00
Jan de Mooij 8d290159a6 Bug 1688616 part 2 - Check for large ArrayBuffer{View}s in WebIDL bindings. r=edgar,lth
The dom::TypedArray type currently represents its length as uint32_t. Changing
that to size_t/uint64_t would cause problems (truncation) for many 'Length()' callers.
Instead of requiring a length check for each of those call sites, for now check for
and reject large array buffers and views in the generated bindings.

Code and tests are based on the implementation of the [AllowShared] attribute.
Additional tests for the new JSAPIs will be added as part of bug 1674777.

Differential Revision: https://phabricator.services.mozilla.com/D102912
2021-01-31 07:33:41 +00:00
Butkovits Atila 80ba5dd933 Backed out 2 changesets (bug 1688616) for casing failures on test_large_arraybuffers.html. CLOSED TREE
Backed out changeset 560718ce8d2c (bug 1688616)
Backed out changeset 7985fd012bc7 (bug 1688616)
2021-01-30 18:10:09 +02:00
Jan de Mooij 2192481240 Bug 1688616 part 2 - Check for large ArrayBuffer{View}s in WebIDL bindings. r=edgar,lth
The dom::TypedArray type currently represents its length as uint32_t. Changing
that to size_t/uint64_t would cause problems (truncation) for many 'Length()' callers.
Instead of requiring a length check for each of those call sites, for now check for
and reject large array buffers and views in the generated bindings.

Code and tests are based on the implementation of the [AllowShared] attribute.
Additional tests for the new JSAPIs will be added as part of bug 1674777.

Depends on D102911

Differential Revision: https://phabricator.services.mozilla.com/D102912
2021-01-27 14:01:44 +00:00
Narcis Beleuzu 1fbccc0d6c Backed out 3 changesets (bug 1680607, bug 1685588, bug 1685586) for SM bustages. CLOSED TREE
Backed out changeset 0382d66d1f7a (bug 1685588)
Backed out changeset bdd7ddb19a48 (bug 1685586)
Backed out changeset cc6fbd4db752 (bug 1680607)
2021-01-27 18:16:33 +02:00
Steve Fink 2fa74ce8a6 Bug 1680607 - Mark dom::TypedArray_base as not allowing GC r=jonco
Differential Revision: https://phabricator.services.mozilla.com/D100430
2021-01-13 22:18:00 +00:00
Steve Fink 4bf3434c15 Bug 1686532 - Add dom::TypedArray_base::Reset() as a signal to the hazard analysis that no invalidatable data is being held onto r=jonco
Differential Revision: https://phabricator.services.mozilla.com/D100429
2021-01-13 22:18:00 +00:00
Steve Fink a75149f6b8 Bug 1684123 - Implement GetArrayBufferViewFixedData and dom::TypedArray_base::FixedData(). r=jonco
Differential Revision: https://phabricator.services.mozilla.com/D100426
2021-01-13 22:17:40 +00:00
Mihai Alexandru Michis bf411e8d30 Backed out 2 changesets (bug 1684123, bug 1682068) for causing bustages.
CLOSED TREE

Backed out changeset e6df68a131a3 (bug 1682068)
Backed out changeset 91ad893cc4d4 (bug 1684123)
2021-01-13 20:34:56 +02:00
Steve Fink 7f06a7503b Bug 1684123 - Implement GetArrayBufferViewFixedData and dom::TypedArray_base::FixedData(). r=jonco
Differential Revision: https://phabricator.services.mozilla.com/D100426
2021-01-13 18:03:25 +00:00
Sylvestre Ledru 843f943758 Bug 1519636 - Reformat recent changes to the Google coding style r=andi
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D85678
2020-08-02 15:29:15 +00:00
Jeff Walden e8f3f74ef6 Bug 1656411 - Move typed array, ArrayBuffer, and dataview-related functions out of jsfriendapi.h to two new headers. r=mgaudet,jgilbert
Differential Revision: https://phabricator.services.mozilla.com/D85524
2020-07-31 16:37:27 +00:00
Simon Giesecke 8fc0c81644 Bug 1613985 - Use default for equivalent-to-default constructors/destructors in dom/bindings. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D63137

--HG--
extra : moz-landing-system : lando
2020-02-20 15:47:53 +00:00
Edgar Chen 9e846bd48a bug 1610296 - Rename TypedArray_base::ComputeLengthAndData to TypedArray_base::ComputeState; r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D60514

--HG--
extra : moz-landing-system : lando
2020-01-23 03:22:06 +00:00
Edgar Chen c4e4fdbd64 Bug 1575425 - Part 5: Remove DataAllowShared and LengthAllowShared from TypedArray bindings; r=bzbarsky
There's no need for two explicit APIs as we get safety from the IDL layer. And
treating a SharedArrayBuffer as an empty buffer is wrong too.

Differential Revision: https://phabricator.services.mozilla.com/D60003

--HG--
extra : moz-landing-system : lando
2020-01-22 13:09:49 +00:00
Edgar Chen 7572e4a211 Bug 1575425 - Part 2: Merge ArrayBuffer and SharedArrayBuffer in DOM binding; r=bzbarsky,jwalden
We need this for upcoming change which supports having [AllowShared] on
ArrayBuffer type in WebIDL.

Differential Revision: https://phabricator.services.mozilla.com/D59989

--HG--
extra : moz-landing-system : lando
2020-01-23 13:48:02 +00:00
Emilio Cobos Álvarez 256c124f94 Bug 1609996 - Reorder some includes affected by the previous patches. r=froydnj
This was done by:

This was done by applying:

```
diff --git a/python/mozbuild/mozbuild/code-analysis/mach_commands.py b/python/mozbuild/mozbuild/code-analysis/mach_commands.py
index 789affde7bbf..fe33c4c7d4d1 100644
--- a/python/mozbuild/mozbuild/code-analysis/mach_commands.py
+++ b/python/mozbuild/mozbuild/code-analysis/mach_commands.py
@@ -2007,7 +2007,7 @@ class StaticAnalysis(MachCommandBase):
         from subprocess import Popen, PIPE, check_output, CalledProcessError

         diff_process = Popen(self._get_clang_format_diff_command(commit), stdout=PIPE)
-        args = [sys.executable, clang_format_diff, "-p1", "-binary=%s" % clang_format]
+        args = [sys.executable, clang_format_diff, "-p1", "-binary=%s" % clang_format, '-sort-includes']

         if not output_file:
             args.append("-i")
```

Then running `./mach clang-format -c <commit-hash>`

Then undoing that patch.

Then running check_spidermonkey_style.py --fixup

Then running `./mach clang-format`

I had to fix four things:

 * I needed to move <utility> back down in GuardObjects.h because I was hitting
   obscure problems with our system include wrappers like this:

0:03.94 /usr/include/stdlib.h:550:14: error: exception specification in declaration does not match previous declaration
0:03.94 extern void *realloc (void *__ptr, size_t __size)
0:03.94              ^
0:03.94 /home/emilio/src/moz/gecko-2/obj-debug/dist/include/malloc_decls.h:53:1: note: previous declaration is here
0:03.94 MALLOC_DECL(realloc, void*, void*, size_t)
0:03.94 ^
0:03.94 /home/emilio/src/moz/gecko-2/obj-debug/dist/include/mozilla/mozalloc.h:22:32: note: expanded from macro 'MALLOC_DECL'
0:03.94     MOZ_MEMORY_API return_type name##_impl(__VA_ARGS__);
0:03.94                                ^
0:03.94 <scratch space>:178:1: note: expanded from here
0:03.94 realloc_impl
0:03.94 ^
0:03.94 /home/emilio/src/moz/gecko-2/obj-debug/dist/include/mozmemory_wrap.h:142:41: note: expanded from macro 'realloc_impl'
0:03.94 #define realloc_impl mozmem_malloc_impl(realloc)

   Which I really didn't feel like digging into.

 * I had to restore the order of TrustOverrideUtils.h and related files in nss
   because the .inc files depend on TrustOverrideUtils.h being included earlier.

 * I had to add a missing include to RollingNumber.h

 * Also had to partially restore include order in JsepSessionImpl.cpp to avoid
   some -WError issues due to some static inline functions being defined in a
   header but not used in the rest of the compilation unit.

Differential Revision: https://phabricator.services.mozilla.com/D60327

--HG--
extra : moz-landing-system : lando
2020-01-20 16:19:48 +00:00
Emilio Cobos Álvarez aa3a695712 Bug 1609996 - Remove mozilla/Move.h. r=froydnj
rg -l 'mozilla/Move.h' | xargs sed -i 's/#include "mozilla\/Move.h"/#include <utility>/g'

Further manual fixups and cleanups to the include order incoming.

Differential Revision: https://phabricator.services.mozilla.com/D60323

--HG--
extra : moz-landing-system : lando
2020-01-20 16:18:20 +00:00
Emilio Cobos Álvarez 4d059556c2 Bug 1607406 - Add TypedArray::Create(Span<T>) and remove an ugly cast in TextEncoder. r=bzbarsky
The bounds check becomes needed now, though it should hopefully be optimized
away too as all the involved calls that you need to know about to determine that
it can't happen are inline.

Differential Revision: https://phabricator.services.mozilla.com/D58909

--HG--
extra : moz-landing-system : lando
2020-01-07 15:42:19 +00:00
Jeff Walden 3f385ffa33 Bug 1532005 - Implement a new js/public/ArrayBuffer.h header to centralize functionality for creating and interacting with ArrayBuffers. r=sfink
Differential Revision: https://phabricator.services.mozilla.com/D21827

--HG--
extra : rebase_source : 833bbfce12d90bcb92f7cd88ec65247e48c024c0
2019-03-04 15:19:16 -08:00
Razvan Maries 65e4948ca0 Backed out 4 changesets (bug 1532005, bug 1531638) for causing perma fails and Spidermonkey fail. CLOSED TREE
Backed out changeset 4913d941de92 (bug 1532005)
Backed out changeset 9635abe5bf24 (bug 1532005)
Backed out changeset 738cf4b1126a (bug 1532005)
Backed out changeset e5d9f2ee7ac7 (bug 1531638)
2019-03-05 01:07:28 +02:00
Jeff Walden ecb4e10bda Bug 1532005 - Implement a new js/public/ArrayBuffer.h header to centralize functionality for creating and interacting with ArrayBuffers. r=sfink
Differential Revision: https://phabricator.services.mozilla.com/D21827

--HG--
extra : rebase_source : 36c43233ad6d804bd691c8c40d6a6984331c7162
2019-02-28 17:00:56 -08:00
Sylvestre Ledru 265e672179 Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format
# ignore-this-changeset

--HG--
extra : amend_source : 4d301d3b0b8711c4692392aa76088ba7fd7d1022
2018-11-30 11:46:48 +01:00
Jan de Mooij b79494e142 Bug 1479363 part 2 - Use JSAutoRealm instead of JSAutoRealmAllowCCW in dom/bindings. r=bz 2018-08-02 08:48:50 +02:00
Jan de Mooij 80adc67aba Bug 1478955 part 1 - Rename JSAutoRealm to JSAutoRealmAllowCCW. r=luke 2018-07-28 12:12:26 +02:00
Andi-Bogdan Postelnicu 88cc63910d Bug 1453795 - DOM - Initialize member fields in classes/ structures. r=peterv
--HG--
extra : rebase_source : 249fc26e50bded4e94f5effa4308af0f1e54b908
2018-06-16 17:21:46 +03:00
Emilio Cobos Álvarez fffb25b74f Bug 1465585: Switch from mozilla::Move to std::move. r=froydnj
This was done automatically replacing:

  s/mozilla::Move/std::move/
  s/ Move(/ std::move(/
  s/(Move(/(std::move(/

Removing the 'using mozilla::Move;' lines.

And then with a few manual fixups, see the bug for the split series..

MozReview-Commit-ID: Jxze3adipUh
2018-06-01 10:45:27 +02:00
Jan de Mooij 80e44e8003 Bug 1461292 part 1 - Rename JSAutoCompartment to JSAutoRealm. r=bz,luke 2018-05-16 10:53:16 +02:00
Sebastian Hengst 0819f35e51 Backed out 4 changesets (bug 525063) on request from Andi. a=backout
Backed out changeset 516c4fb1e4b8 (bug 525063)
Backed out changeset 6ff8aaef2866 (bug 525063)
Backed out changeset bf13e4103150 (bug 525063)
Backed out changeset d7d2f08e051c (bug 525063)
2018-04-13 16:01:28 +03:00
Tristan Bourvon a3a77c0312 Bug 525063 - Initialize uninitialized class attributes in m-c. r=ehsan 2018-04-10 21:11:02 +02:00
Till Schneidereit fb21cc09de Bug 1384513 - Change all public APIs to take JS::AutoRequireNoGC instead of JS::AutoCheckCannotGC. r=jonco
Additionally, change the base class of AutoSuppressGCAnalysis from AutoAssertNoAlloc to AutoAssertNoGC.

In combination, these chances enable passing either JS::AutoCheckCannotGC or JS::AutoSuppressGCAnalysis, depending on whether suppressing the GC analysis is desired or not.

MozReview-Commit-ID: Eg1cl28ezeJ
* * *
Bug 1384513 - Follow-up to fix bustage from template usage of functions with a changed signature, on a CLOSED TREE. r=bustage

MozReview-Commit-ID: 5SsI4DoDwAT
2017-07-26 12:20:59 +02:00
Andrea Marchesini 351d938b86 Bug 1128959 - Implement the WHATWG Streams spec - part 1 - WebIDL Bindings, r=bz 2017-08-10 18:04:54 -07:00
Jan de Mooij bbe72b0768 Backed out changeset 78859e22ce17 (bug 1384513) for perf regressions.
--HG--
extra : rebase_source : fd6063fc8c2f0b9677e5dee4fbbe1c85c210dd7c
2017-08-01 10:41:43 +02:00
Till Schneidereit 6f4ae4701b Bug 1384513 - Follow-up to fix bustage from template usage of functions with a changed signature, on a CLOSED TREE. r=bustage
MozReview-Commit-ID: 5SsI4DoDwAT
2017-07-26 15:02:01 +02:00
Boris Zbarsky 165cfab86b Bug 1371424 - Trace the right thing in TypedArray's TraceSelf implementation. r=mccr8 2017-06-08 16:56:43 -04:00
Boris Zbarsky 94dfa592a5 Bug 1323721 part 3. Remove the vestigial mention of Promise from TypedArray.h. r=till 2016-12-19 15:38:42 -08:00
Lars T Hansen 76c7159be5 Bug 1246597 - DOM comment change. r=me
--HG--
extra : rebase_source : 26794fefac6d5296b20ab54abba61f5e06bb872f
2016-11-24 14:16:17 +01:00
Jan de Mooij c33bac8363 Bug 1292892 part 5 - Replace most nsContentUtils::RootingCx calls with dom::RootingCx. r=bz,terrence 2016-08-11 14:39:23 +02:00
Ehsan Akhgari 4923320e0a Bug 1242210 - Mark RootedTypedArray as final; r=baku 2016-01-25 10:15:45 -05:00
Terrence Cole 3a07971436 Bug 1238786 - Part 2: We no longer need to null check before using trace APIs; r=smaug
--HG--
extra : rebase_source : 5fdbdaa7be739afd93294b729d878ed33c55b5ce
2016-01-12 13:07:54 -08:00
Terrence Cole fd0fcea703 Bug 1235923 - Part 2: Use new Root tracing APIs in Gecko; r=smaug 2015-12-30 11:31:16 -08:00
Terrence Cole 97c4c6520f Backout 7621c3ea95cb11e1c376a9f705accc0f90057c0a (bug 1235923) for build bustage on a CLOSED TREE.
--HG--
extra : rebase_source : 6c54aa7e1af75c270ab2b6833b56c780c537e297
2016-01-06 12:05:06 -08:00
Terrence Cole d38e840e6f Bug 1235923 - Part 2: Use new Root tracing APIs in Gecko; r=smaug 2015-12-30 11:31:16 -08:00
Lars T Hansen b62493634b Bug 1176214 - Part 11: Changes to DOM, except for WebGL. r=bz, r=clb
--HG--
extra : rebase_source : 9c9d3f493822d68be20597d9974292ed5ec4ab70
2015-11-25 19:04:50 +01:00