Merge mozilla-central to autoland. CLOSED TREE
authorNarcis Beleuzu <nbeleuzu@mozilla.com>
Thu, 04 Oct 2018 18:58:42 +0300
changeset 495373 757135609fdb585335559ad5dd77162969562039
parent 495372 0a653b330b03ec8ce30b31275fa083061d698cc4 (current diff)
parent 495358 f66e525e6978c2fbc7351501936711876261b546 (diff)
child 495374 67c81aab154d1f3e2f54a4141beae04ca7995144
push id9984
push userffxbld-merge
push dateMon, 15 Oct 2018 21:07:35 +0000
treeherdermozilla-beta@183d27ea8570 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
milestone64.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Merge mozilla-central to autoland. CLOSED TREE
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -528,17 +528,17 @@ name = "crossbeam-utils"
 version = "0.3.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cfg-if 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "cssparser"
-version = "0.24.0"
+version = "0.24.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cssparser-macros 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "dtoa-short 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "itoa 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "matches 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "phf 0.7.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "proc-macro2 0.4.9 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -904,17 +904,17 @@ dependencies = [
  "zip 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "geckoservo"
 version = "0.0.1"
 dependencies = [
  "atomic_refcell 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.24.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.24.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "cstr 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "malloc_size_of 0.0.1",
  "nsstring 0.1.0",
  "num-traits 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "parking_lot 0.6.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "selectors 0.20.0",
@@ -1326,17 +1326,17 @@ dependencies = [
  "cfg-if 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "malloc_size_of"
 version = "0.0.1"
 dependencies = [
  "app_units 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.24.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.24.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "hashglobe 0.1.0",
  "selectors 0.20.0",
  "servo_arc 0.1.1",
  "smallbitvec 2.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "thin-slice 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "void 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1897,17 +1897,17 @@ dependencies = [
 name = "rayon-core"
 version = "1.4.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "crossbeam-deque 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)",
  "num_cpus 1.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "rand 0.3.22 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rand 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "redox_syscall"
 version = "0.1.32"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
@@ -2068,17 +2068,17 @@ dependencies = [
  "syn 0.15.7 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "selectors"
 version = "0.20.0"
 dependencies = [
  "bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.24.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.24.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "fxhash 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "matches 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "phf 0.7.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "phf_codegen 0.7.21 (registry+https://github.com/rust-lang/crates.io-index)",
  "precomputed-hash 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "servo_arc 0.1.1",
  "smallvec 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -2235,17 +2235,17 @@ version = "0.0.1"
 dependencies = [
  "app_units 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "arrayvec 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "atomic_refcell 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "bindgen 0.39.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "cfg-if 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.24.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.24.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fallible 0.0.1",
  "fxhash 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "hashglobe 0.1.0",
  "itertools 0.7.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "itoa 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -2291,30 +2291,30 @@ dependencies = [
 ]
 
 [[package]]
 name = "style_traits"
 version = "0.0.1"
 dependencies = [
  "app_units 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.24.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.24.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.19.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "malloc_size_of 0.0.1",
  "malloc_size_of_derive 0.0.1",
  "selectors 0.20.0",
  "servo_arc 0.1.1",
 ]
 
 [[package]]
 name = "stylo_tests"
 version = "0.0.1"
 dependencies = [
  "atomic_refcell 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "cssparser 0.24.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "cssparser 0.24.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "cstr 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "env_logger 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "geckoservo 0.0.1",
  "libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "malloc_size_of 0.0.1",
  "num-traits 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "regex 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -3044,17 +3044,17 @@ dependencies = [
 "checksum cranelift-wasm 0.20.1 (registry+https://github.com/rust-lang/crates.io-index)" = "2a9d3454bf60ee6c3d1f54d6cf9ed82cfc1a2e7efb9ec1b16666bf2987c88bfa"
 "checksum crc 1.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "bd5d02c0aac6bd68393ed69e00bbc2457f3e89075c6349db7189618dc4ddc1d7"
 "checksum crossbeam-deque 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "f739f8c5363aca78cfb059edf753d8f0d36908c348f3d8d1503f03d8b75d9cf3"
 "checksum crossbeam-deque 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "fe8153ef04a7594ded05b427ffad46ddeaf22e63fd48d42b3e1e3bb4db07cae7"
 "checksum crossbeam-epoch 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "927121f5407de9956180ff5e936fe3cf4324279280001cd56b669d28ee7e9150"
 "checksum crossbeam-epoch 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)" = "2af0e75710d6181e234c8ecc79f14a97907850a541b13b0be1dd10992f2e4620"
 "checksum crossbeam-utils 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "2760899e32a1d58d5abb31129f8fae5de75220bc2176e77ff7c627ae45c918d9"
 "checksum crossbeam-utils 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "d636a8b3bcc1b409d7ffd3facef8f21dcb4009626adbd0c5e6c4305c07253c7b"
-"checksum cssparser 0.24.0 (registry+https://github.com/rust-lang/crates.io-index)" = "495beddc39b1987b8e9f029354eccbd5ef88eb5f1cd24badb764dce338acf2e0"
+"checksum cssparser 0.24.1 (registry+https://github.com/rust-lang/crates.io-index)" = "b200a7193703a615c8d2751fed1ede39b9c4b3905e09d1ec7064a24688c190fc"
 "checksum cssparser-macros 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "f3a5383ae18dbfdeb569ed62019f5bddb2a95cd2d3833313c475a0d014777805"
 "checksum cstr 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "b6557bdb1dc9647eae1cf7f5601b14cd45fc3c7ccf2df618387416fe542da6ea"
 "checksum cstr-macros 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "0472c17c83d3ec1af32fb6ee2b3ad56ae0b6e69355d63d1d30602055c34324a8"
 "checksum cubeb 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)" = "8a3502aafa1bf95c524f65d2ba46d8741700c6a8a9543ea52c6da3d8b69a2896"
 "checksum cubeb-backend 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)" = "fdcac95519416d9ec814db2dc40e6293e7da25b906023d93f48b87f0587ab138"
 "checksum cubeb-core 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "37f7b20f757a4e4b6aa28863236551bff77682dc6db192eba15af615492b5445"
 "checksum cubeb-sys 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "653b9e245d35dbe2a2da7c4586275cee75ff656ddeb02d4a73b4afdfa6d67502"
 "checksum darling 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "2a78af487e4eb8f4421a1770687b328af6bb4494ca93435210678c6eea875c11"
--- a/accessible/base/ARIAMap.cpp
+++ b/accessible/base/ARIAMap.cpp
@@ -33,1233 +33,1233 @@ static const uint32_t kGenericAccType = 
  *
  *  When no Role enum mapping exists for an ARIA role, the role will be exposed
  *  via the object attribute "xml-roles".
  */
 
 static const nsRoleMapEntry sWAIRoleMaps[] =
 {
   { // alert
-    &nsGkAtoms::alert,
+    nsGkAtoms::alert,
     roles::ALERT,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eAlert,
     kNoReqStates
   },
   { // alertdialog
-    &nsGkAtoms::alertdialog,
+    nsGkAtoms::alertdialog,
     roles::DIALOG,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // application
-    &nsGkAtoms::application,
+    nsGkAtoms::application,
     roles::APPLICATION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // article
-    &nsGkAtoms::article,
+    nsGkAtoms::article,
     roles::ARTICLE,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eReadonlyUntilEditable
   },
   { // banner
-    &nsGkAtoms::banner,
+    nsGkAtoms::banner,
     roles::NOTHING,
     kUseNativeRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // blockquote
-    &nsGkAtoms::blockquote,
+    nsGkAtoms::blockquote,
     roles::BLOCKQUOTE,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
   },
   { // button
-    &nsGkAtoms::button,
+    nsGkAtoms::button,
     roles::PUSHBUTTON,
     kUseMapRole,
     eNoValue,
     ePressAction,
     eNoLiveAttr,
     eButton,
     kNoReqStates
     // eARIAPressed is auto applied on any button
   },
   { // caption
-    &nsGkAtoms::caption,
+    nsGkAtoms::caption,
     roles::CAPTION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
   },
   { // cell
-    &nsGkAtoms::cell,
+    nsGkAtoms::cell,
     roles::CELL,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eTableCell,
     kNoReqStates
   },
   { // checkbox
-    &nsGkAtoms::checkbox,
+    nsGkAtoms::checkbox,
     roles::CHECKBUTTON,
     kUseMapRole,
     eNoValue,
     eCheckUncheckAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eARIACheckableMixed,
     eARIAReadonly
   },
   { // columnheader
-    &nsGkAtoms::columnheader,
+    nsGkAtoms::columnheader,
     roles::COLUMNHEADER,
     kUseMapRole,
     eNoValue,
     eSortAction,
     eNoLiveAttr,
     eTableCell,
     kNoReqStates,
     eARIASelectableIfDefined,
     eARIAReadonlyOrEditableIfDefined
   },
   { // combobox, which consists of text input and popup
-    &nsGkAtoms::combobox,
+    nsGkAtoms::combobox,
     roles::EDITCOMBOBOX,
     kUseMapRole,
     eNoValue,
     eOpenCloseAction,
     eNoLiveAttr,
     eCombobox,
     states::COLLAPSED | states::HASPOPUP,
     eARIAAutoComplete,
     eARIAReadonly,
     eARIAOrientation
   },
   { // complementary
-    &nsGkAtoms::complementary,
+    nsGkAtoms::complementary,
     roles::NOTHING,
     kUseNativeRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // contentinfo
-    &nsGkAtoms::contentinfo,
+    nsGkAtoms::contentinfo,
     roles::NOTHING,
     kUseNativeRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // dialog
-    &nsGkAtoms::dialog,
+    nsGkAtoms::dialog,
     roles::DIALOG,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // directory
-    &nsGkAtoms::directory,
+    nsGkAtoms::directory,
     roles::LIST,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eList,
     states::READONLY
   },
   { // doc-abstract
-    &nsGkAtoms::docAbstract,
+    nsGkAtoms::docAbstract,
     roles::SECTION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // doc-acknowledgments
-    &nsGkAtoms::docAcknowledgments,
+    nsGkAtoms::docAcknowledgments,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-afterword
-    &nsGkAtoms::docAfterword,
+    nsGkAtoms::docAfterword,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-appendix
-    &nsGkAtoms::docAppendix,
+    nsGkAtoms::docAppendix,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-backlink
-    &nsGkAtoms::docBacklink,
+    nsGkAtoms::docBacklink,
     roles::LINK,
     kUseMapRole,
     eNoValue,
     eJumpAction,
     eNoLiveAttr,
     kGenericAccType,
     states::LINKED
   },
   { // doc-biblioentry
-    &nsGkAtoms::docBiblioentry,
+    nsGkAtoms::docBiblioentry,
     roles::LISTITEM,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     states::READONLY
   },
   { // doc-bibliography
-    &nsGkAtoms::docBibliography,
+    nsGkAtoms::docBibliography,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-biblioref
-    &nsGkAtoms::docBiblioref,
+    nsGkAtoms::docBiblioref,
     roles::LINK,
     kUseMapRole,
     eNoValue,
     eJumpAction,
     eNoLiveAttr,
     kGenericAccType,
     states::LINKED
   },
   { // doc-chapter
-    &nsGkAtoms::docChapter,
+    nsGkAtoms::docChapter,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-colophon
-    &nsGkAtoms::docColophon,
+    nsGkAtoms::docColophon,
     roles::SECTION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // doc-conclusion
-    &nsGkAtoms::docConclusion,
+    nsGkAtoms::docConclusion,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-cover
-    &nsGkAtoms::docCover,
+    nsGkAtoms::docCover,
     roles::GRAPHIC,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // doc-credit
-    &nsGkAtoms::docCredit,
+    nsGkAtoms::docCredit,
     roles::SECTION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // doc-credits
-    &nsGkAtoms::docCredits,
+    nsGkAtoms::docCredits,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-dedication
-    &nsGkAtoms::docDedication,
+    nsGkAtoms::docDedication,
     roles::SECTION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // doc-endnote
-    &nsGkAtoms::docEndnote,
+    nsGkAtoms::docEndnote,
     roles::LISTITEM,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     states::READONLY
   },
   { // doc-endnotes
-    &nsGkAtoms::docEndnotes,
+    nsGkAtoms::docEndnotes,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-epigraph
-    &nsGkAtoms::docEpigraph,
+    nsGkAtoms::docEpigraph,
     roles::SECTION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // doc-epilogue
-    &nsGkAtoms::docEpilogue,
+    nsGkAtoms::docEpilogue,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-errata
-    &nsGkAtoms::docErrata,
+    nsGkAtoms::docErrata,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-example
-    &nsGkAtoms::docExample,
+    nsGkAtoms::docExample,
     roles::SECTION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // doc-footnote
-    &nsGkAtoms::docFootnote,
+    nsGkAtoms::docFootnote,
     roles::FOOTNOTE,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-foreword
-    &nsGkAtoms::docForeword,
+    nsGkAtoms::docForeword,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-glossary
-    &nsGkAtoms::docGlossary,
+    nsGkAtoms::docGlossary,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-glossref
-    &nsGkAtoms::docGlossref,
+    nsGkAtoms::docGlossref,
     roles::LINK,
     kUseMapRole,
     eNoValue,
     eJumpAction,
     eNoLiveAttr,
     kGenericAccType,
     states::LINKED
   },
   { // doc-index
-    &nsGkAtoms::docIndex,
+    nsGkAtoms::docIndex,
     roles::NAVIGATION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-introduction
-    &nsGkAtoms::docIntroduction,
+    nsGkAtoms::docIntroduction,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-noteref
-    &nsGkAtoms::docNoteref,
+    nsGkAtoms::docNoteref,
     roles::LINK,
     kUseMapRole,
     eNoValue,
     eJumpAction,
     eNoLiveAttr,
     kGenericAccType,
     states::LINKED
   },
   { // doc-notice
-    &nsGkAtoms::docNotice,
+    nsGkAtoms::docNotice,
     roles::NOTE,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // doc-pagebreak
-    &nsGkAtoms::docPagebreak,
+    nsGkAtoms::docPagebreak,
     roles::SEPARATOR,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // doc-pagelist
-    &nsGkAtoms::docPagelist,
+    nsGkAtoms::docPagelist,
     roles::NAVIGATION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-part
-    &nsGkAtoms::docPart,
+    nsGkAtoms::docPart,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-preface
-    &nsGkAtoms::docPreface,
+    nsGkAtoms::docPreface,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-prologue
-    &nsGkAtoms::docPrologue,
+    nsGkAtoms::docPrologue,
     roles::LANDMARK,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // doc-pullquote
-    &nsGkAtoms::docPullquote,
+    nsGkAtoms::docPullquote,
     roles::SECTION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // doc-qna
-    &nsGkAtoms::docQna,
+    nsGkAtoms::docQna,
     roles::SECTION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // doc-subtitle
-    &nsGkAtoms::docSubtitle,
+    nsGkAtoms::docSubtitle,
     roles::HEADING,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // doc-tip
-    &nsGkAtoms::docTip,
+    nsGkAtoms::docTip,
     roles::NOTE,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // doc-toc
-    &nsGkAtoms::docToc,
+    nsGkAtoms::docToc,
     roles::NAVIGATION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // document
-    &nsGkAtoms::document,
+    nsGkAtoms::document,
     roles::NON_NATIVE_DOCUMENT,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eReadonlyUntilEditable
   },
   { // feed
-    &nsGkAtoms::feed,
+    nsGkAtoms::feed,
     roles::GROUPING,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // figure
-    &nsGkAtoms::figure,
+    nsGkAtoms::figure,
     roles::FIGURE,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // form
-    &nsGkAtoms::form,
+    nsGkAtoms::form,
     roles::FORM,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // graphics-document
-    &nsGkAtoms::graphicsDocument,
+    nsGkAtoms::graphicsDocument,
     roles::NON_NATIVE_DOCUMENT,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eReadonlyUntilEditable
   },
   { // graphics-object
-    &nsGkAtoms::graphicsObject,
+    nsGkAtoms::graphicsObject,
     roles::GROUPING,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // graphics-symbol
-    &nsGkAtoms::graphicsSymbol,
+    nsGkAtoms::graphicsSymbol,
     roles::GRAPHIC,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // grid
-    &nsGkAtoms::grid,
+    nsGkAtoms::grid,
     roles::TABLE,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eSelect | eTable,
     kNoReqStates,
     eARIAMultiSelectable,
     eARIAReadonlyOrEditable,
     eFocusableUntilDisabled
   },
   { // gridcell
-    &nsGkAtoms::gridcell,
+    nsGkAtoms::gridcell,
     roles::GRID_CELL,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eTableCell,
     kNoReqStates,
     eARIASelectable,
     eARIAReadonlyOrEditableIfDefined
   },
   { // group
-    &nsGkAtoms::group,
+    nsGkAtoms::group,
     roles::GROUPING,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // heading
-    &nsGkAtoms::heading,
+    nsGkAtoms::heading,
     roles::HEADING,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // img
-    &nsGkAtoms::img,
+    nsGkAtoms::img,
     roles::GRAPHIC,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // key
-    &nsGkAtoms::key,
+    nsGkAtoms::key,
     roles::KEY,
     kUseMapRole,
     eNoValue,
     ePressAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eARIAPressed
   },
   { // link
-    &nsGkAtoms::link,
+    nsGkAtoms::link,
     roles::LINK,
     kUseMapRole,
     eNoValue,
     eJumpAction,
     eNoLiveAttr,
     kGenericAccType,
     states::LINKED
   },
   { // list
-    &nsGkAtoms::list_,
+    nsGkAtoms::list_,
     roles::LIST,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eList,
     states::READONLY
   },
   { // listbox
-    &nsGkAtoms::listbox,
+    nsGkAtoms::listbox,
     roles::LISTBOX,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eListControl | eSelect,
     states::VERTICAL,
     eARIAMultiSelectable,
     eARIAReadonly,
     eFocusableUntilDisabled,
     eARIAOrientation
   },
   { // listitem
-    &nsGkAtoms::listitem,
+    nsGkAtoms::listitem,
     roles::LISTITEM,
     kUseMapRole,
     eNoValue,
     eNoAction, // XXX: should depend on state, parent accessible
     eNoLiveAttr,
     kGenericAccType,
     states::READONLY
   },
   { // log
-    &nsGkAtoms::log_,
+    nsGkAtoms::log_,
     roles::NOTHING,
     kUseNativeRole,
     eNoValue,
     eNoAction,
     ePoliteLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // main
-    &nsGkAtoms::main,
+    nsGkAtoms::main,
     roles::NOTHING,
     kUseNativeRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // marquee
-    &nsGkAtoms::marquee,
+    nsGkAtoms::marquee,
     roles::ANIMATION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eOffLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // math
-    &nsGkAtoms::math,
+    nsGkAtoms::math,
     roles::FLAT_EQUATION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // menu
-    &nsGkAtoms::menu,
+    nsGkAtoms::menu,
     roles::MENUPOPUP,
     kUseMapRole,
     eNoValue,
     eNoAction, // XXX: technically accessibles of menupopup role haven't
                // any action, but menu can be open or close.
     eNoLiveAttr,
     kGenericAccType,
     states::VERTICAL,
     eARIAOrientation
   },
   { // menubar
-    &nsGkAtoms::menubar,
+    nsGkAtoms::menubar,
     roles::MENUBAR,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     states::HORIZONTAL,
     eARIAOrientation
   },
   { // menuitem
-    &nsGkAtoms::menuitem,
+    nsGkAtoms::menuitem,
     roles::MENUITEM,
     kUseMapRole,
     eNoValue,
     eClickAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // menuitemcheckbox
-    &nsGkAtoms::menuitemcheckbox,
+    nsGkAtoms::menuitemcheckbox,
     roles::CHECK_MENU_ITEM,
     kUseMapRole,
     eNoValue,
     eClickAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eARIACheckableMixed,
     eARIAReadonly
   },
   { // menuitemradio
-    &nsGkAtoms::menuitemradio,
+    nsGkAtoms::menuitemradio,
     roles::RADIO_MENU_ITEM,
     kUseMapRole,
     eNoValue,
     eClickAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eARIACheckableBool,
     eARIAReadonly
   },
   { // navigation
-    &nsGkAtoms::navigation,
+    nsGkAtoms::navigation,
     roles::NOTHING,
     kUseNativeRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // none
-    &nsGkAtoms::none,
+    nsGkAtoms::none,
     roles::NOTHING,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // note
-    &nsGkAtoms::note_,
+    nsGkAtoms::note_,
     roles::NOTE,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // option
-    &nsGkAtoms::option,
+    nsGkAtoms::option,
     roles::OPTION,
     kUseMapRole,
     eNoValue,
     eSelectAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eARIASelectable,
     eARIACheckedMixed
   },
   { // paragraph
-    &nsGkAtoms::paragraph,
+    nsGkAtoms::paragraph,
     roles::PARAGRAPH,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
   },
   { // presentation
-    &nsGkAtoms::presentation,
+    nsGkAtoms::presentation,
     roles::NOTHING,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // progressbar
-    &nsGkAtoms::progressbar,
+    nsGkAtoms::progressbar,
     roles::PROGRESSBAR,
     kUseMapRole,
     eHasValueMinMax,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     states::READONLY,
     eIndeterminateIfNoValue
   },
   { // radio
-    &nsGkAtoms::radio,
+    nsGkAtoms::radio,
     roles::RADIOBUTTON,
     kUseMapRole,
     eNoValue,
     eSelectAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eARIACheckableBool
   },
   { // radiogroup
-    &nsGkAtoms::radiogroup,
+    nsGkAtoms::radiogroup,
     roles::RADIO_GROUP,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eARIAOrientation,
     eARIAReadonly
   },
   { // region
-    &nsGkAtoms::region,
+    nsGkAtoms::region,
     roles::REGION,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // row
-    &nsGkAtoms::row,
+    nsGkAtoms::row,
     roles::ROW,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eTableRow,
     kNoReqStates,
     eARIASelectable
   },
   { // rowgroup
-    &nsGkAtoms::rowgroup,
+    nsGkAtoms::rowgroup,
     roles::GROUPING,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // rowheader
-    &nsGkAtoms::rowheader,
+    nsGkAtoms::rowheader,
     roles::ROWHEADER,
     kUseMapRole,
     eNoValue,
     eSortAction,
     eNoLiveAttr,
     eTableCell,
     kNoReqStates,
     eARIASelectableIfDefined,
     eARIAReadonlyOrEditableIfDefined
   },
   { // scrollbar
-    &nsGkAtoms::scrollbar,
+    nsGkAtoms::scrollbar,
     roles::SCROLLBAR,
     kUseMapRole,
     eHasValueMinMax,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     states::VERTICAL,
     eARIAOrientation,
     eARIAReadonly
   },
   { // search
-    &nsGkAtoms::search,
+    nsGkAtoms::search,
     roles::NOTHING,
     kUseNativeRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eLandmark,
     kNoReqStates
   },
   { // searchbox
-    &nsGkAtoms::searchbox,
+    nsGkAtoms::searchbox,
     roles::ENTRY,
     kUseMapRole,
     eNoValue,
     eActivateAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eARIAAutoComplete,
     eARIAMultiline,
     eARIAReadonlyOrEditable
   },
   { // separator
-    &nsGkAtoms::separator_,
+    nsGkAtoms::separator_,
     roles::SEPARATOR,
     kUseMapRole,
     eHasValueMinMaxIfFocusable,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     states::HORIZONTAL,
     eARIAOrientation
   },
   { // slider
-    &nsGkAtoms::slider,
+    nsGkAtoms::slider,
     roles::SLIDER,
     kUseMapRole,
     eHasValueMinMax,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     states::HORIZONTAL,
     eARIAOrientation,
     eARIAReadonly
   },
   { // spinbutton
-    &nsGkAtoms::spinbutton,
+    nsGkAtoms::spinbutton,
     roles::SPINBUTTON,
     kUseMapRole,
     eHasValueMinMax,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eARIAReadonly
   },
   { // status
-    &nsGkAtoms::status,
+    nsGkAtoms::status,
     roles::STATUSBAR,
     kUseMapRole,
     eNoValue,
     eNoAction,
     ePoliteLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // switch
-    &nsGkAtoms::svgSwitch,
+    nsGkAtoms::svgSwitch,
     roles::SWITCH,
     kUseMapRole,
     eNoValue,
     eCheckUncheckAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eARIACheckableBool,
     eARIAReadonly
   },
   { // tab
-    &nsGkAtoms::tab,
+    nsGkAtoms::tab,
     roles::PAGETAB,
     kUseMapRole,
     eNoValue,
     eSwitchAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eARIASelectable
   },
   { // table
-    &nsGkAtoms::table,
+    nsGkAtoms::table,
     roles::TABLE,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eTable,
     kNoReqStates,
     eARIASelectable
   },
   { // tablist
-    &nsGkAtoms::tablist,
+    nsGkAtoms::tablist,
     roles::PAGETABLIST,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eSelect,
     states::HORIZONTAL,
     eARIAOrientation,
     eARIAMultiSelectable
   },
   { // tabpanel
-    &nsGkAtoms::tabpanel,
+    nsGkAtoms::tabpanel,
     roles::PROPERTYPAGE,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // term
-    &nsGkAtoms::term,
+    nsGkAtoms::term,
     roles::TERM,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     states::READONLY
   },
   { // textbox
-    &nsGkAtoms::textbox,
+    nsGkAtoms::textbox,
     roles::ENTRY,
     kUseMapRole,
     eNoValue,
     eActivateAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eARIAAutoComplete,
     eARIAMultiline,
     eARIAReadonlyOrEditable
   },
   { // timer
-    &nsGkAtoms::timer,
+    nsGkAtoms::timer,
     roles::NOTHING,
     kUseNativeRole,
     eNoValue,
     eNoAction,
     eOffLiveAttr,
     kNoReqStates
   },
   { // toolbar
-    &nsGkAtoms::toolbar,
+    nsGkAtoms::toolbar,
     roles::TOOLBAR,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     states::HORIZONTAL,
     eARIAOrientation
   },
   { // tooltip
-    &nsGkAtoms::tooltip,
+    nsGkAtoms::tooltip,
     roles::TOOLTIP,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates
   },
   { // tree
-    &nsGkAtoms::tree,
+    nsGkAtoms::tree,
     roles::OUTLINE,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eSelect,
     states::VERTICAL,
     eARIAReadonly,
     eARIAMultiSelectable,
     eFocusableUntilDisabled,
     eARIAOrientation
   },
   { // treegrid
-    &nsGkAtoms::treegrid,
+    nsGkAtoms::treegrid,
     roles::TREE_TABLE,
     kUseMapRole,
     eNoValue,
     eNoAction,
     eNoLiveAttr,
     eSelect | eTable,
     kNoReqStates,
     eARIAReadonlyOrEditable,
     eARIAMultiSelectable,
     eFocusableUntilDisabled,
     eARIAOrientation
   },
   { // treeitem
-    &nsGkAtoms::treeitem,
+    nsGkAtoms::treeitem,
     roles::OUTLINEITEM,
     kUseMapRole,
     eNoValue,
     eActivateAction, // XXX: should expose second 'expand/collapse' action based
                      // on states
     eNoLiveAttr,
     kGenericAccType,
     kNoReqStates,
     eARIASelectable,
     eARIACheckedMixed
   }
 };
 
 static const nsRoleMapEntry sLandmarkRoleMap = {
-  &nsGkAtoms::_empty,
+  nsGkAtoms::_empty,
   roles::NOTHING,
   kUseNativeRole,
   eNoValue,
   eNoAction,
   eNoLiveAttr,
   kGenericAccType,
   kNoReqStates
 };
 
 nsRoleMapEntry aria::gEmptyRoleMap = {
-  &nsGkAtoms::_empty,
+  nsGkAtoms::_empty,
   roles::NOTHING,
   kUseMapRole,
   eNoValue,
   eNoAction,
   eNoLiveAttr,
   kGenericAccType,
   kNoReqStates
 };
@@ -1284,58 +1284,58 @@ static const EStateRule sWAIUnivStateMap
 
 /**
  * ARIA attribute map for attribute characteristics.
  * @note ARIA attributes that don't have any flags are not included here.
  */
 
 struct AttrCharacteristics
 {
-  nsStaticAtom** attributeName;
+  const nsStaticAtom* const attributeName;
   const uint8_t characteristics;
 };
 
 static const AttrCharacteristics gWAIUnivAttrMap[] = {
-  {&nsGkAtoms::aria_activedescendant,  ATTR_BYPASSOBJ                               },
-  {&nsGkAtoms::aria_atomic,   ATTR_BYPASSOBJ_IF_FALSE | ATTR_VALTOKEN | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_busy,                               ATTR_VALTOKEN | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_checked,           ATTR_BYPASSOBJ | ATTR_VALTOKEN               }, /* exposes checkable obj attr */
-  {&nsGkAtoms::aria_controls,          ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_describedby,       ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_details,           ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_disabled,          ATTR_BYPASSOBJ | ATTR_VALTOKEN | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_dropeffect,                         ATTR_VALTOKEN | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_errormessage,      ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_expanded,          ATTR_BYPASSOBJ | ATTR_VALTOKEN               },
-  {&nsGkAtoms::aria_flowto,            ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_grabbed,                            ATTR_VALTOKEN | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_haspopup,          ATTR_BYPASSOBJ_IF_FALSE | ATTR_VALTOKEN | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_hidden,            ATTR_BYPASSOBJ | ATTR_VALTOKEN | ATTR_GLOBAL }, /* handled special way */
-  {&nsGkAtoms::aria_invalid,           ATTR_BYPASSOBJ | ATTR_VALTOKEN | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_label,             ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_labelledby,        ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_level,             ATTR_BYPASSOBJ                               }, /* handled via groupPosition */
-  {&nsGkAtoms::aria_live,                               ATTR_VALTOKEN | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_modal,             ATTR_BYPASSOBJ | ATTR_VALTOKEN | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_multiline,         ATTR_BYPASSOBJ | ATTR_VALTOKEN               },
-  {&nsGkAtoms::aria_multiselectable,   ATTR_BYPASSOBJ | ATTR_VALTOKEN               },
-  {&nsGkAtoms::aria_owns,              ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_orientation,                        ATTR_VALTOKEN               },
-  {&nsGkAtoms::aria_posinset,          ATTR_BYPASSOBJ                               }, /* handled via groupPosition */
-  {&nsGkAtoms::aria_pressed,           ATTR_BYPASSOBJ | ATTR_VALTOKEN               },
-  {&nsGkAtoms::aria_readonly,          ATTR_BYPASSOBJ | ATTR_VALTOKEN               },
-  {&nsGkAtoms::aria_relevant,          ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
-  {&nsGkAtoms::aria_required,          ATTR_BYPASSOBJ | ATTR_VALTOKEN               },
-  {&nsGkAtoms::aria_selected,          ATTR_BYPASSOBJ | ATTR_VALTOKEN               },
-  {&nsGkAtoms::aria_setsize,           ATTR_BYPASSOBJ                               }, /* handled via groupPosition */
-  {&nsGkAtoms::aria_sort,                               ATTR_VALTOKEN               },
-  {&nsGkAtoms::aria_valuenow,          ATTR_BYPASSOBJ                               },
-  {&nsGkAtoms::aria_valuemin,          ATTR_BYPASSOBJ                               },
-  {&nsGkAtoms::aria_valuemax,          ATTR_BYPASSOBJ                               },
-  {&nsGkAtoms::aria_valuetext,         ATTR_BYPASSOBJ                               }
+  {nsGkAtoms::aria_activedescendant,  ATTR_BYPASSOBJ                               },
+  {nsGkAtoms::aria_atomic,   ATTR_BYPASSOBJ_IF_FALSE | ATTR_VALTOKEN | ATTR_GLOBAL },
+  {nsGkAtoms::aria_busy,                               ATTR_VALTOKEN | ATTR_GLOBAL },
+  {nsGkAtoms::aria_checked,           ATTR_BYPASSOBJ | ATTR_VALTOKEN               }, /* exposes checkable obj attr */
+  {nsGkAtoms::aria_controls,          ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
+  {nsGkAtoms::aria_describedby,       ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
+  {nsGkAtoms::aria_details,           ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
+  {nsGkAtoms::aria_disabled,          ATTR_BYPASSOBJ | ATTR_VALTOKEN | ATTR_GLOBAL },
+  {nsGkAtoms::aria_dropeffect,                         ATTR_VALTOKEN | ATTR_GLOBAL },
+  {nsGkAtoms::aria_errormessage,      ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
+  {nsGkAtoms::aria_expanded,          ATTR_BYPASSOBJ | ATTR_VALTOKEN               },
+  {nsGkAtoms::aria_flowto,            ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
+  {nsGkAtoms::aria_grabbed,                            ATTR_VALTOKEN | ATTR_GLOBAL },
+  {nsGkAtoms::aria_haspopup,          ATTR_BYPASSOBJ_IF_FALSE | ATTR_VALTOKEN | ATTR_GLOBAL },
+  {nsGkAtoms::aria_hidden,            ATTR_BYPASSOBJ | ATTR_VALTOKEN | ATTR_GLOBAL }, /* handled special way */
+  {nsGkAtoms::aria_invalid,           ATTR_BYPASSOBJ | ATTR_VALTOKEN | ATTR_GLOBAL },
+  {nsGkAtoms::aria_label,             ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
+  {nsGkAtoms::aria_labelledby,        ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
+  {nsGkAtoms::aria_level,             ATTR_BYPASSOBJ                               }, /* handled via groupPosition */
+  {nsGkAtoms::aria_live,                               ATTR_VALTOKEN | ATTR_GLOBAL },
+  {nsGkAtoms::aria_modal,             ATTR_BYPASSOBJ | ATTR_VALTOKEN | ATTR_GLOBAL },
+  {nsGkAtoms::aria_multiline,         ATTR_BYPASSOBJ | ATTR_VALTOKEN               },
+  {nsGkAtoms::aria_multiselectable,   ATTR_BYPASSOBJ | ATTR_VALTOKEN               },
+  {nsGkAtoms::aria_owns,              ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
+  {nsGkAtoms::aria_orientation,                        ATTR_VALTOKEN               },
+  {nsGkAtoms::aria_posinset,          ATTR_BYPASSOBJ                               }, /* handled via groupPosition */
+  {nsGkAtoms::aria_pressed,           ATTR_BYPASSOBJ | ATTR_VALTOKEN               },
+  {nsGkAtoms::aria_readonly,          ATTR_BYPASSOBJ | ATTR_VALTOKEN               },
+  {nsGkAtoms::aria_relevant,          ATTR_BYPASSOBJ                 | ATTR_GLOBAL },
+  {nsGkAtoms::aria_required,          ATTR_BYPASSOBJ | ATTR_VALTOKEN               },
+  {nsGkAtoms::aria_selected,          ATTR_BYPASSOBJ | ATTR_VALTOKEN               },
+  {nsGkAtoms::aria_setsize,           ATTR_BYPASSOBJ                               }, /* handled via groupPosition */
+  {nsGkAtoms::aria_sort,                               ATTR_VALTOKEN               },
+  {nsGkAtoms::aria_valuenow,          ATTR_BYPASSOBJ                               },
+  {nsGkAtoms::aria_valuemin,          ATTR_BYPASSOBJ                               },
+  {nsGkAtoms::aria_valuemax,          ATTR_BYPASSOBJ                               },
+  {nsGkAtoms::aria_valuetext,         ATTR_BYPASSOBJ                               }
 };
 
 namespace {
 
 struct RoleComparator
 {
   const nsDependentSubstring& mRole;
   explicit RoleComparator(const nsDependentSubstring& aRole) : mRole(aRole) {}
@@ -1418,17 +1418,17 @@ aria::UniversalStatesFor(mozilla::dom::E
 
   return state;
 }
 
 uint8_t
 aria::AttrCharacteristicsFor(nsAtom* aAtom)
 {
   for (uint32_t i = 0; i < ArrayLength(gWAIUnivAttrMap); i++)
-    if (*gWAIUnivAttrMap[i].attributeName == aAtom)
+    if (gWAIUnivAttrMap[i].attributeName == aAtom)
       return gWAIUnivAttrMap[i].characteristics;
 
   return 0;
 }
 
 bool
 aria::HasDefinedARIAHidden(nsIContent* aContent)
 {
--- a/accessible/base/ARIAMap.h
+++ b/accessible/base/ARIAMap.h
@@ -137,32 +137,32 @@ const uint8_t ATTR_GLOBAL = 0x1 << 3;
  * For each ARIA role, this maps the nsIAccessible information.
  */
 struct nsRoleMapEntry
 {
   /**
    * Return true if matches to the given ARIA role.
    */
   bool Is(nsAtom* aARIARole) const
-    { return *roleAtom == aARIARole; }
+    { return roleAtom == aARIARole; }
 
   /**
    * Return true if ARIA role has the given accessible type.
    */
   bool IsOfType(mozilla::a11y::AccGenericType aType) const
     { return accTypes & aType; }
 
   /**
    * Return ARIA role.
    */
   const nsDependentAtomString ARIARoleString() const
-    { return nsDependentAtomString(*roleAtom); }
+    { return nsDependentAtomString(roleAtom); }
 
   // ARIA role: string representation such as "button"
-  nsStaticAtom** roleAtom;
+  nsStaticAtom* const roleAtom;
 
   // Role mapping rule: maps to enum Role
   mozilla::a11y::role role;
 
   // Role rule: whether to use mapped role or native semantics
   bool roleRule;
 
   // Value mapping rule: how to compute accessible value
--- a/accessible/base/ARIAStateMap.cpp
+++ b/accessible/base/ARIAStateMap.cpp
@@ -19,17 +19,17 @@ using namespace mozilla::a11y::aria;
  */
 struct EnumTypeData
 {
   // ARIA attribute name.
   nsStaticAtom* const mAttrName;
 
   // States if the attribute value is matched to the enum value. Used as
   // Element::AttrValuesArray, last item must be nullptr.
-  nsStaticAtom* const* const mValues[4];
+  nsStaticAtom* const mValues[4];
 
   // States applied if corresponding enum values are matched.
   const uint64_t mStates[3];
 
   // States to clear in case of match.
   const uint64_t mClearState;
 };
 
@@ -84,34 +84,34 @@ static void MapTokenType(dom::Element* a
 bool
 aria::MapToState(EStateRule aRule, dom::Element* aElement, uint64_t* aState)
 {
   switch (aRule) {
     case eARIAAutoComplete:
     {
       static const EnumTypeData data = {
         nsGkAtoms::aria_autocomplete,
-        { &nsGkAtoms::inlinevalue,
-          &nsGkAtoms::list_,
-          &nsGkAtoms::both, nullptr },
+        { nsGkAtoms::inlinevalue,
+          nsGkAtoms::list_,
+          nsGkAtoms::both, nullptr },
         { states::SUPPORTS_AUTOCOMPLETION,
           states::HASPOPUP | states::SUPPORTS_AUTOCOMPLETION,
           states::HASPOPUP | states::SUPPORTS_AUTOCOMPLETION }, 0
       };
 
       MapEnumType(aElement, aState, data);
       return true;
     }
 
     case eARIABusy:
     {
       static const EnumTypeData data = {
         nsGkAtoms::aria_busy,
-        { &nsGkAtoms::_true,
-          &nsGkAtoms::error, nullptr },
+        { nsGkAtoms::_true,
+          nsGkAtoms::error, nullptr },
         { states::BUSY,
           states::INVALID }, 0
       };
 
       MapEnumType(aElement, aState, data);
       return true;
     }
 
@@ -224,18 +224,18 @@ aria::MapToState(EStateRule aRule, dom::
       MapTokenType(aElement, aState, data);
       return true;
     }
 
     case eARIAOrientation:
     {
       static const EnumTypeData data = {
         nsGkAtoms::aria_orientation,
-        { &nsGkAtoms::horizontal,
-          &nsGkAtoms::vertical, nullptr },
+        { nsGkAtoms::horizontal,
+          nsGkAtoms::vertical, nullptr },
         { states::HORIZONTAL,
           states::VERTICAL },
         states::HORIZONTAL | states::VERTICAL
       };
 
       MapEnumType(aElement, aState, data);
       return true;
     }
--- a/accessible/base/TextAttrs.cpp
+++ b/accessible/base/TextAttrs.cpp
@@ -298,17 +298,17 @@ TextAttrsMgr::InvalidTextAttr::
 bool
 TextAttrsMgr::InvalidTextAttr::
   GetValue(nsIContent* aElm, uint32_t* aValue)
 {
   nsIContent* elm = aElm;
   do {
     if (nsAccUtils::HasDefinedARIAToken(elm, nsGkAtoms::aria_invalid)) {
       static Element::AttrValuesArray tokens[] =
-        { &nsGkAtoms::_false, &nsGkAtoms::grammar, &nsGkAtoms::spelling,
+        { nsGkAtoms::_false, nsGkAtoms::grammar, nsGkAtoms::spelling,
           nullptr };
 
       int32_t idx = elm->AsElement()->FindAttrValueIn(kNameSpaceID_None,
                                                       nsGkAtoms::aria_invalid,
                                                       tokens, eCaseMatters);
       switch (idx) {
         case 0:
           *aValue = eFalse;
--- a/accessible/base/XULMap.h
+++ b/accessible/base/XULMap.h
@@ -85,17 +85,17 @@ XULMAP(
     return CreateMenupopupAccessible(aElement, aContext);
   }
 )
 
 XULMAP(
   panel,
   [](Element* aElement, Accessible* aContext) -> Accessible* {
     static const Element::AttrValuesArray sIgnoreTypeVals[] =
-      { &nsGkAtoms::autocomplete_richlistbox, &nsGkAtoms::autocomplete, nullptr };
+      { nsGkAtoms::autocomplete_richlistbox, nsGkAtoms::autocomplete, nullptr };
 
     if (aElement->FindAttrValueIn(kNameSpaceID_None, nsGkAtoms::type,
                                   sIgnoreTypeVals, eIgnoreCase) >= 0) {
       return nullptr;
     }
 
     if (aElement->AttrValueIs(kNameSpaceID_None, nsGkAtoms::noautofocus,
                               nsGkAtoms::_true, eCaseMatters)) {
--- a/accessible/base/nsAccUtils.cpp
+++ b/accessible/base/nsAccUtils.cpp
@@ -203,30 +203,29 @@ nsAccUtils::HasDefinedARIAToken(nsIConte
                            eCaseMatters) ||
       element->AttrValueIs(kNameSpaceID_None, aAtom, nsGkAtoms::_undefined,
                            eCaseMatters)) {
         return false;
   }
   return true;
 }
 
-nsAtom*
+nsStaticAtom*
 nsAccUtils::GetARIAToken(dom::Element* aElement, nsAtom* aAttr)
 {
   if (!HasDefinedARIAToken(aElement, aAttr))
     return nsGkAtoms::_empty;
 
   static Element::AttrValuesArray tokens[] =
-    { &nsGkAtoms::_false, &nsGkAtoms::_true,
-      &nsGkAtoms::mixed, nullptr};
+    { nsGkAtoms::_false, nsGkAtoms::_true, nsGkAtoms::mixed, nullptr};
 
   int32_t idx = aElement->FindAttrValueIn(kNameSpaceID_None,
                                           aAttr, tokens, eCaseMatters);
   if (idx >= 0)
-    return *(tokens[idx]);
+    return tokens[idx];
 
   return nullptr;
 }
 
 Accessible*
 nsAccUtils::GetSelectableContainer(Accessible* aAccessible, uint64_t aState)
 {
   if (!aAccessible)
--- a/accessible/base/nsAccUtils.h
+++ b/accessible/base/nsAccUtils.h
@@ -96,17 +96,18 @@ public:
    *
    * Return true if the ARIA property is defined, otherwise false
    */
   static bool HasDefinedARIAToken(nsIContent *aContent, nsAtom *aAtom);
 
   /**
    * Return atomic value of ARIA attribute of boolean or NMTOKEN type.
    */
-  static nsAtom* GetARIAToken(mozilla::dom::Element* aElement, nsAtom* aAttr);
+  static nsStaticAtom* GetARIAToken(mozilla::dom::Element* aElement,
+                                    nsAtom* aAttr);
 
   /**
    * Return document accessible for the given DOM node.
    */
   static DocAccessible* GetDocAccessibleFor(nsINode* aNode)
   {
     nsIPresShell *presShell = nsCoreUtils::GetPresShellFor(aNode);
     return GetAccService()->GetDocAccessible(presShell);
--- a/accessible/base/nsAccessibilityService.cpp
+++ b/accessible/base/nsAccessibilityService.cpp
@@ -285,36 +285,36 @@ New_HTMLTableCellAccessible(Element* aEl
  * Cached value of the PREF_ACCESSIBILITY_FORCE_DISABLED preference.
  */
 static int32_t sPlatformDisabledState = 0;
 
 ////////////////////////////////////////////////////////////////////////////////
 // Markup maps array.
 
 #define Attr(name, value) \
-  { &nsGkAtoms::name, &nsGkAtoms::value }
+  { nsGkAtoms::name, nsGkAtoms::value }
 
 #define AttrFromDOM(name, DOMAttrName) \
-  { &nsGkAtoms::name, nullptr, &nsGkAtoms::DOMAttrName }
+  { nsGkAtoms::name, nullptr, nsGkAtoms::DOMAttrName }
 
 #define AttrFromDOMIf(name, DOMAttrName, DOMAttrValue) \
-  { &nsGkAtoms::name, nullptr,  &nsGkAtoms::DOMAttrName, &nsGkAtoms::DOMAttrValue }
+  { nsGkAtoms::name, nullptr,  nsGkAtoms::DOMAttrName, nsGkAtoms::DOMAttrValue }
 
 #define MARKUPMAP(atom, new_func, r, ... ) \
-  { &nsGkAtoms::atom, new_func, static_cast<a11y::role>(r), { __VA_ARGS__ } },
+  { nsGkAtoms::atom, new_func, static_cast<a11y::role>(r), { __VA_ARGS__ } },
 
 static const HTMLMarkupMapInfo sHTMLMarkupMapList[] = {
   #include "MarkupMap.h"
 };
 
 #undef MARKUPMAP
 
 #ifdef MOZ_XUL
 #define XULMAP(atom, ...) \
-  { &nsGkAtoms::atom, __VA_ARGS__ },
+  { nsGkAtoms::atom, __VA_ARGS__ },
 
 #define XULMAP_TYPE(atom, new_type) \
 XULMAP( \
   atom, \
   [](Element* aElement, Accessible* aContext) -> Accessible* { \
     return new new_type(aElement, aContext->Document()); \
   } \
 )
@@ -1352,21 +1352,21 @@ nsAccessibilityService::Init()
   nsCOMPtr<nsIEventListenerService> eventListenerService =
     do_GetService("@mozilla.org/eventlistenerservice;1");
   if (!eventListenerService)
     return false;
 
   eventListenerService->AddListenerChangeListener(this);
 
   for (uint32_t i = 0; i < ArrayLength(sHTMLMarkupMapList); i++)
-    mHTMLMarkupMap.Put(*sHTMLMarkupMapList[i].tag, &sHTMLMarkupMapList[i]);
+    mHTMLMarkupMap.Put(sHTMLMarkupMapList[i].tag, &sHTMLMarkupMapList[i]);
 
 #ifdef MOZ_XUL
   for (uint32_t i = 0; i < ArrayLength(sXULMarkupMapList); i++)
-    mXULMarkupMap.Put(*sXULMarkupMapList[i].tag, &sXULMarkupMapList[i]);
+    mXULMarkupMap.Put(sXULMarkupMapList[i].tag, &sXULMarkupMapList[i]);
 #endif
 
 #ifdef A11Y_LOG
   logging::CheckEnv();
 #endif
 
   gAccessibilityService = this;
   NS_ADDREF(gAccessibilityService); // will release in Shutdown()
@@ -1618,37 +1618,37 @@ nsAccessibilityService::MarkupAttributes
     const MarkupAttrInfo* info = markupMap->attrs + i;
     if (!info->name)
       break;
 
     if (info->DOMAttrName) {
       if (info->DOMAttrValue) {
         if (aContent->IsElement() &&
             aContent->AsElement()->AttrValueIs(kNameSpaceID_None,
-                                               *info->DOMAttrName,
-                                               *info->DOMAttrValue,
+                                               info->DOMAttrName,
+                                               info->DOMAttrValue,
                                                eCaseMatters)) {
-          nsAccUtils::SetAccAttr(aAttributes, *info->name, *info->DOMAttrValue);
+          nsAccUtils::SetAccAttr(aAttributes, info->name, info->DOMAttrValue);
         }
         continue;
       }
 
       nsAutoString value;
 
       if (aContent->IsElement()) {
-        aContent->AsElement()->GetAttr(kNameSpaceID_None, *info->DOMAttrName, value);
+        aContent->AsElement()->GetAttr(kNameSpaceID_None, info->DOMAttrName, value);
       }
 
       if (!value.IsEmpty())
-        nsAccUtils::SetAccAttr(aAttributes, *info->name, value);
+        nsAccUtils::SetAccAttr(aAttributes, info->name, value);
 
       continue;
     }
 
-    nsAccUtils::SetAccAttr(aAttributes, *info->name, *info->value);
+    nsAccUtils::SetAccAttr(aAttributes, info->name, info->value);
   }
 }
 
 Accessible*
 nsAccessibilityService::AddNativeRootAccessible(void* aAtkAccessible)
 {
 #ifdef MOZ_ACCESSIBILITY_ATK
   ApplicationAccessible* applicationAcc = ApplicationAcc();
--- a/accessible/base/nsAccessibilityService.h
+++ b/accessible/base/nsAccessibilityService.h
@@ -48,34 +48,35 @@ SelectionManager* SelectionMgr();
 /**
  * Returns the application accessible.
  */
 ApplicationAccessible* ApplicationAcc();
 xpcAccessibleApplication* XPCApplicationAcc();
 
 typedef Accessible* (New_Accessible)(Element* aElement, Accessible* aContext);
 
+// These fields are not `nsStaticAtom* const` because MSVC doesn't like it.
 struct MarkupAttrInfo {
-  nsStaticAtom** name;
-  nsStaticAtom** value;
+  nsStaticAtom* name;
+  nsStaticAtom* value;
 
-  nsStaticAtom** DOMAttrName;
-  nsStaticAtom** DOMAttrValue;
+  nsStaticAtom* DOMAttrName;
+  nsStaticAtom* DOMAttrValue;
 };
 
 struct HTMLMarkupMapInfo {
-  nsStaticAtom** tag;
+  const nsStaticAtom* const tag;
   New_Accessible* new_func;
   a11y::role role;
   MarkupAttrInfo attrs[4];
 };
 
 #ifdef MOZ_XUL
 struct XULMarkupMapInfo {
-  nsStaticAtom** tag;
+  const nsStaticAtom* const tag;
   New_Accessible* new_func;
 };
 #endif
 
 /**
  * PREF_ACCESSIBILITY_FORCE_DISABLED preference change callback.
  */
 void PrefChanged(const char* aPref, void* aClosure);
--- a/accessible/generic/Accessible.cpp
+++ b/accessible/generic/Accessible.cpp
@@ -1544,18 +1544,19 @@ Accessible::ARIATransformRole(role aRole
 
   return aRole;
 }
 
 nsAtom*
 Accessible::LandmarkRole() const
 {
   const nsRoleMapEntry* roleMapEntry = ARIARoleMap();
-  return roleMapEntry && roleMapEntry->IsOfType(eLandmark) ?
-    *(roleMapEntry->roleAtom) : nullptr;
+  return roleMapEntry && roleMapEntry->IsOfType(eLandmark)
+       ? roleMapEntry->roleAtom
+       : nullptr;
 }
 
 role
 Accessible::NativeRole() const
 {
   return roles::NOTHING;
 }
 
--- a/accessible/generic/DocAccessible.cpp
+++ b/accessible/generic/DocAccessible.cpp
@@ -50,27 +50,27 @@
 #include "mozilla/dom/MutationEventBinding.h"
 
 using namespace mozilla;
 using namespace mozilla::a11y;
 
 ////////////////////////////////////////////////////////////////////////////////
 // Static member initialization
 
-static nsStaticAtom** kRelationAttrs[] =
+static nsStaticAtom* const kRelationAttrs[] =
 {
-  &nsGkAtoms::aria_labelledby,
-  &nsGkAtoms::aria_describedby,
-  &nsGkAtoms::aria_details,
-  &nsGkAtoms::aria_owns,
-  &nsGkAtoms::aria_controls,
-  &nsGkAtoms::aria_flowto,
-  &nsGkAtoms::aria_errormessage,
-  &nsGkAtoms::_for,
-  &nsGkAtoms::control
+  nsGkAtoms::aria_labelledby,
+  nsGkAtoms::aria_describedby,
+  nsGkAtoms::aria_details,
+  nsGkAtoms::aria_owns,
+  nsGkAtoms::aria_controls,
+  nsGkAtoms::aria_flowto,
+  nsGkAtoms::aria_errormessage,
+  nsGkAtoms::_for,
+  nsGkAtoms::control
 };
 
 static const uint32_t kRelationAttrsLen = ArrayLength(kRelationAttrs);
 
 ////////////////////////////////////////////////////////////////////////////////
 // Constructor/desctructor
 
 DocAccessible::
@@ -1578,17 +1578,17 @@ DocAccessible::ProcessLoad()
 void
 DocAccessible::AddDependentIDsFor(Accessible* aRelProvider, nsAtom* aRelAttr)
 {
   dom::Element* relProviderEl = aRelProvider->Elm();
   if (!relProviderEl)
     return;
 
   for (uint32_t idx = 0; idx < kRelationAttrsLen; idx++) {
-    nsAtom* relAttr = *kRelationAttrs[idx];
+    nsStaticAtom* relAttr = kRelationAttrs[idx];
     if (aRelAttr && aRelAttr != relAttr)
       continue;
 
     if (relAttr == nsGkAtoms::_for) {
       if (!relProviderEl->IsAnyOfHTMLElements(nsGkAtoms::label,
                                                nsGkAtoms::output))
         continue;
 
@@ -1650,18 +1650,18 @@ void
 DocAccessible::RemoveDependentIDsFor(Accessible* aRelProvider,
                                      nsAtom* aRelAttr)
 {
   dom::Element* relProviderElm = aRelProvider->Elm();
   if (!relProviderElm)
     return;
 
   for (uint32_t idx = 0; idx < kRelationAttrsLen; idx++) {
-    nsAtom* relAttr = *kRelationAttrs[idx];
-    if (aRelAttr && aRelAttr != *kRelationAttrs[idx])
+    nsStaticAtom* relAttr = kRelationAttrs[idx];
+    if (aRelAttr && aRelAttr != kRelationAttrs[idx])
       continue;
 
     IDRefsIterator iter(this, relProviderElm, relAttr);
     while (true) {
       const nsDependentSubstring id = iter.NextID();
       if (id.IsEmpty())
         break;
 
--- a/accessible/html/HTMLTableAccessible.cpp
+++ b/accessible/html/HTMLTableAccessible.cpp
@@ -302,18 +302,18 @@ HTMLTableHeaderCellAccessible::
 ////////////////////////////////////////////////////////////////////////////////
 // HTMLTableHeaderCellAccessible: Accessible implementation
 
 role
 HTMLTableHeaderCellAccessible::NativeRole() const
 {
   // Check value of @scope attribute.
   static Element::AttrValuesArray scopeValues[] =
-    { &nsGkAtoms::col, &nsGkAtoms::colgroup,
-      &nsGkAtoms::row, &nsGkAtoms::rowgroup, nullptr };
+    { nsGkAtoms::col, nsGkAtoms::colgroup,
+      nsGkAtoms::row, nsGkAtoms::rowgroup, nullptr };
   int32_t valueIdx =
     mContent->AsElement()->FindAttrValueIn(kNameSpaceID_None, nsGkAtoms::scope,
                                            scopeValues, eCaseMatters);
 
   switch (valueIdx) {
     case 0:
     case 1:
       return roles::COLUMNHEADER;
--- a/accessible/ipc/ProxyAccessibleShared.h
+++ b/accessible/ipc/ProxyAccessibleShared.h
@@ -57,17 +57,17 @@ nsTArray<ProxyAccessible*> RelationByTyp
  */
 void Relations(nsTArray<RelationType>* aTypes,
     nsTArray<nsTArray<ProxyAccessible*>>* aTargetSets) const;
 
 bool IsSearchbox() const;
 
 nsAtom* LandmarkRole() const;
 
-nsAtom* ARIARoleAtom() const;
+nsStaticAtom* ARIARoleAtom() const;
 
 int32_t GetLevelInternal();
 void ScrollTo(uint32_t aScrollType);
 void ScrollToPoint(uint32_t aScrollType, int32_t aX, int32_t aY);
 
 int32_t CaretLineNumber();
 int32_t CaretOffset();
 void SetCaretOffset(int32_t aOffset);
--- a/accessible/ipc/other/DocAccessibleChild.cpp
+++ b/accessible/ipc/other/DocAccessibleChild.cpp
@@ -288,17 +288,17 @@ mozilla::ipc::IPCResult
 DocAccessibleChild::RecvARIARoleAtom(const uint64_t& aID, nsString* aRole)
 {
   Accessible* acc = IdToAccessible(aID);
   if (!acc) {
     return IPC_OK();
   }
 
   if (const nsRoleMapEntry* roleMap = acc->ARIARoleMap()) {
-    if (nsAtom* roleAtom = *(roleMap->roleAtom)) {
+    if (nsStaticAtom* roleAtom = roleMap->roleAtom) {
       roleAtom->ToString(*aRole);
     }
   }
 
   return IPC_OK();
 }
 
 mozilla::ipc::IPCResult
--- a/accessible/ipc/other/ProxyAccessible.cpp
+++ b/accessible/ipc/other/ProxyAccessible.cpp
@@ -122,17 +122,17 @@ ProxyAccessible::IsSearchbox() const
 nsAtom*
 ProxyAccessible::LandmarkRole() const
 {
   nsString landmark;
   Unused << mDoc->SendLandmarkRole(mID, &landmark);
   return NS_GetStaticAtom(landmark);
 }
 
-nsAtom*
+nsStaticAtom*
 ProxyAccessible::ARIARoleAtom() const
 {
   nsString role;
   Unused << mDoc->SendARIARoleAtom(mID, &role);
   return NS_GetStaticAtom(role);
 }
 
 int32_t
--- a/accessible/mac/mozAccessible.mm
+++ b/accessible/mac/mozAccessible.mm
@@ -765,20 +765,20 @@ ConvertToNSArray(nsTArray<ProxyAccessibl
   // macOS groups the specific landmark types of DPub ARIA into two broad
   // categories with corresponding subroles: Navigation and region/container.
   if (mRole == roles::NAVIGATION)
     return @"AXLandmarkNavigation";
   if (mRole == roles::LANDMARK)
     return @"AXLandmarkRegion";
 
   // Now, deal with widget roles
-  nsAtom* roleAtom = nullptr;
+  nsStaticAtom* roleAtom = nullptr;
   if (accWrap && accWrap->HasARIARole()) {
     const nsRoleMapEntry* roleMap = accWrap->ARIARoleMap();
-    roleAtom = *roleMap->roleAtom;
+    roleAtom = roleMap->roleAtom;
   }
   if (proxy)
     roleAtom = proxy->ARIARoleAtom();
 
   if (roleAtom) {
     if (roleAtom == nsGkAtoms::alert)
       return @"AXApplicationAlert";
     if (roleAtom == nsGkAtoms::alertdialog)
--- a/accessible/xul/XULMenuAccessible.cpp
+++ b/accessible/xul/XULMenuAccessible.cpp
@@ -53,17 +53,17 @@ XULMenuitemAccessible::NativeState() con
     if (mContent->AsElement()->HasAttr(kNameSpaceID_None, nsGkAtoms::open))
       state |= states::EXPANDED;
     else
       state |= states::COLLAPSED;
   }
 
   // Checkable/checked?
   static Element::AttrValuesArray strings[] =
-    { &nsGkAtoms::radio, &nsGkAtoms::checkbox, nullptr };
+    { nsGkAtoms::radio, nsGkAtoms::checkbox, nullptr };
 
   if (mContent->AsElement()->FindAttrValueIn(kNameSpaceID_None, nsGkAtoms::type,
                                              strings, eCaseMatters) >= 0) {
 
     // Checkable?
     state |= states::CHECKABLE;
 
     // Checked?
--- a/browser/app/winlauncher/LauncherProcessWin.cpp
+++ b/browser/app/winlauncher/LauncherProcessWin.cpp
@@ -161,66 +161,78 @@ MaybeBreakForBrowserDebugging()
   DWORD pauseLenMs = wcstoul(pauseLenS, nullptr, 10) * 1000;
   printf_stderr("\n\nBROWSERBROWSERBROWSERBROWSER\n  debug me @ %lu\n\n",
                 ::GetCurrentProcessId());
   ::Sleep(pauseLenMs);
 }
 
 #if defined(MOZ_LAUNCHER_PROCESS)
 
-static mozilla::Maybe<bool>
+static bool
 IsSameBinaryAsParentProcess()
 {
   mozilla::Maybe<DWORD> parentPid = mozilla::nt::GetParentProcessId();
   if (!parentPid) {
-    return mozilla::Nothing();
+    // If NtQueryInformationProcess failed (in GetParentProcessId()),
+    // we should not behave as the launcher process because it will also
+    // likely to fail in child processes.
+    MOZ_CRASH("NtQueryInformationProcess failed");
   }
 
   nsAutoHandle parentProcess(::OpenProcess(PROCESS_QUERY_LIMITED_INFORMATION,
                                            FALSE, parentPid.value()));
   if (!parentProcess.get()) {
-    return mozilla::Nothing();
+    // If OpenProcess failed, the parent process may not be present,
+    // may be already terminated, etc. So we will have to behave as the
+    // launcher proces in this case.
+    return false;
   }
 
   WCHAR parentExe[MAX_PATH + 1] = {};
   DWORD parentExeLen = mozilla::ArrayLength(parentExe);
   if (!::QueryFullProcessImageNameW(parentProcess.get(), 0, parentExe,
                                     &parentExeLen)) {
-    return mozilla::Nothing();
+    // If QueryFullProcessImageNameW failed, we should not behave as the
+    // launcher process for the same reason as NtQueryInformationProcess.
+    MOZ_CRASH("QueryFullProcessImageNameW failed");
   }
 
   WCHAR ourExe[MAX_PATH + 1] = {};
   DWORD ourExeOk = ::GetModuleFileNameW(nullptr, ourExe,
                                         mozilla::ArrayLength(ourExe));
   if (!ourExeOk || ourExeOk == mozilla::ArrayLength(ourExe)) {
-    return mozilla::Nothing();
+    // If GetModuleFileNameW failed, we should not behave as the launcher
+    // process for the same reason as NtQueryInformationProcess.
+    MOZ_CRASH("GetModuleFileNameW failed");
   }
 
-  return mozilla::DoPathsPointToIdenticalFile(parentExe, ourExe);
+  mozilla::Maybe<bool> isSame =
+    mozilla::DoPathsPointToIdenticalFile(parentExe, ourExe);
+  if (!isSame) {
+    // If DoPathsPointToIdenticalFile failed, we should not behave as the
+    // launcher process for the same reason as NtQueryInformationProcess.
+    MOZ_CRASH("DoPathsPointToIdenticalFile failed");
+  }
+  return isSame.value();
 }
 
 #endif // defined(MOZ_LAUNCHER_PROCESS)
 
 namespace mozilla {
 
 bool
 RunAsLauncherProcess(int& argc, wchar_t** argv)
 {
   // NB: We run all tests in this function instead of returning early in order
   // to ensure that all side effects take place, such as clearing environment
   // variables.
   bool result = false;
 
 #if defined(MOZ_LAUNCHER_PROCESS)
-  Maybe<bool> isChildOfFirefox = IsSameBinaryAsParentProcess();
-  if (isChildOfFirefox) {
-    result |= !isChildOfFirefox.value();
-  } else {
-    result = true;
-  }
+  result = !IsSameBinaryAsParentProcess();
 #endif // defined(MOZ_LAUNCHER_PROCESS)
 
   if (mozilla::EnvHasValue("MOZ_LAUNCHER_PROCESS")) {
     mozilla::SaveToEnv("MOZ_LAUNCHER_PROCESS=");
     result = true;
   }
 
   result |= CheckArg(argc, argv, L"launcher",
--- a/browser/base/content/test/general/browser_e10s_about_page_triggeringprincipal.js
+++ b/browser/base/content/test/general/browser_e10s_about_page_triggeringprincipal.js
@@ -9,16 +9,19 @@ const kAboutPagesRegistered = Promise.al
     Ci.nsIAboutModule.URI_MUST_LOAD_IN_CHILD | Ci.nsIAboutModule.ALLOW_SCRIPT),
   BrowserTestUtils.registerAboutPage(
     registerCleanupFunction, "test-about-principal-parent", kParentPage,
     Ci.nsIAboutModule.ALLOW_SCRIPT),
 ]);
 
 add_task(async function test_principal_click() {
   await kAboutPagesRegistered;
+  await SpecialPowers.pushPrefEnv({
+    "set": [["csp.skip_about_page_has_csp_assert", true]],
+  });
   await BrowserTestUtils.withNewTab("about:test-about-principal-parent", async function(browser) {
     let loadPromise = BrowserTestUtils.browserLoaded(browser, false, "about:test-about-principal-child");
     let myLink = browser.contentDocument.getElementById("aboutchildprincipal");
     myLink.click();
     await loadPromise;
 
     await ContentTask.spawn(gBrowser.selectedBrowser, {}, async function() {
       let channel = content.docShell.currentDocumentChannel;
@@ -39,17 +42,17 @@ add_task(async function test_principal_c
          "sanity check - load of TYPE_DOCUMENT must have a null loadingPrincipal");
     });
   });
 });
 
 add_task(async function test_principal_ctrl_click() {
   await kAboutPagesRegistered;
   await SpecialPowers.pushPrefEnv({
-    "set": [["security.sandbox.content.level", 1]],
+    "set": [["security.sandbox.content.level", 1], ["csp.skip_about_page_has_csp_assert", true]],
   });
 
   await BrowserTestUtils.withNewTab("about:test-about-principal-parent", async function(browser) {
     let loadPromise = BrowserTestUtils.waitForNewTab(gBrowser, "about:test-about-principal-child");
     // simulate ctrl+click
     BrowserTestUtils.synthesizeMouseAtCenter("#aboutchildprincipal",
                                              { ctrlKey: true, metaKey: true },
                                              gBrowser.selectedBrowser);
@@ -76,17 +79,17 @@ add_task(async function test_principal_c
     });
     BrowserTestUtils.removeTab(tab);
   });
 });
 
 add_task(async function test_principal_right_click_open_link_in_new_tab() {
   await kAboutPagesRegistered;
   await SpecialPowers.pushPrefEnv({
-    "set": [["security.sandbox.content.level", 1]],
+    "set": [["security.sandbox.content.level", 1], ["csp.skip_about_page_has_csp_assert", true]],
   });
 
   await BrowserTestUtils.withNewTab("about:test-about-principal-parent", async function(browser) {
     let loadPromise = BrowserTestUtils.waitForNewTab(gBrowser, "about:test-about-principal-child");
 
     // simulate right-click open link in tab
     BrowserTestUtils.waitForEvent(document, "popupshown", false, event => {
       // These are operations that must be executed synchronously with the event.
--- a/browser/components/sessionstore/test/browser_parentProcessRestoreHash.js
+++ b/browser/components/sessionstore/test/browser_parentProcessRestoreHash.js
@@ -49,16 +49,18 @@ let TestAboutPage = {
 };
 
 
 /**
  * Test that switching from a remote to a parent process browser
  * correctly clears the userTypedValue
  */
 add_task(async function() {
+  await SpecialPowers.pushPrefEnv({set: [["csp.skip_about_page_has_csp_assert", true]]});
+
   TestAboutPage.register();
   let tab = await BrowserTestUtils.openNewForegroundTab(gBrowser, "http://example.com/", true, true);
   ok(tab.linkedBrowser.isRemoteBrowser, "Browser should be remote");
 
   let resolveLocationChangePromise;
   let locationChangePromise = new Promise(r => resolveLocationChangePromise = r);
   let wpl = {
     onStateChange(listener, request, state, status) {
--- a/browser/components/shell/nsWindowsShellService.cpp
+++ b/browser/components/shell/nsWindowsShellService.cpp
@@ -4,21 +4,19 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "nsWindowsShellService.h"
 
 #include "BinaryPath.h"
 #include "city.h"
 #include "imgIContainer.h"
 #include "imgIRequest.h"
-#include "mozilla/gfx/2D.h"
 #include "mozilla/RefPtr.h"
 #include "nsIContent.h"
 #include "nsIImageLoadingContent.h"
-#include "nsIOutputStream.h"
 #include "nsIPrefService.h"
 #include "nsIPrefLocalizedString.h"
 #include "nsIServiceManager.h"
 #include "nsIStringBundle.h"
 #include "nsNetUtil.h"
 #include "nsServiceManagerUtils.h"
 #include "nsShellService.h"
 #include "nsIProcess.h"
@@ -41,16 +39,17 @@
 #undef _WIN32_WINNT
 #endif
 #define _WIN32_WINNT 0x0600
 #define INITGUID
 #undef NTDDI_VERSION
 #define NTDDI_VERSION NTDDI_WIN8
 // Needed for access to IApplicationActivationManager
 #include <shlobj.h>
+#include "WinUtils.h"
 
 #include <mbstring.h>
 #include <shlwapi.h>
 
 #include <lm.h>
 #undef ACCESS_READ
 
 #ifndef MAX_BUF
@@ -62,17 +61,17 @@
 
 #define REG_FAILED(val) \
   (val != ERROR_SUCCESS)
 
 #define APP_REG_NAME_BASE L"Firefox-"
 
 using mozilla::IsWin8OrLater;
 using namespace mozilla;
-using namespace mozilla::gfx;
+using namespace mozilla::widget;
 
 NS_IMPL_ISUPPORTS(nsWindowsShellService, nsIShellService)
 
 static nsresult
 OpenKeyForReading(HKEY aKeyRoot, const nsAString& aKeyName, HKEY* aKey)
 {
   const nsString &flatName = PromiseFlatString(aKeyName);
 
@@ -480,105 +479,16 @@ nsWindowsShellService::SetDefaultBrowser
     // Reset the number of times the dialog should be shown
     // before it is silenced.
     (void) prefs->SetIntPref(PREF_DEFAULTBROWSERCHECKCOUNT, 0);
   }
 
   return rv;
 }
 
-static nsresult
-WriteBitmap(nsIFile* aFile, imgIContainer* aImage)
-{
-  nsresult rv;
-
-  RefPtr<SourceSurface> surface =
-    aImage->GetFrame(imgIContainer::FRAME_FIRST,
-                     imgIContainer::FLAG_SYNC_DECODE);
-  NS_ENSURE_TRUE(surface, NS_ERROR_FAILURE);
-
-  // For either of the following formats we want to set the biBitCount member
-  // of the BITMAPINFOHEADER struct to 32, below. For that value the bitmap
-  // format defines that the A8/X8 WORDs in the bitmap byte stream be ignored
-  // for the BI_RGB value we use for the biCompression member.
-  MOZ_ASSERT(surface->GetFormat() == SurfaceFormat::B8G8R8A8 ||
-             surface->GetFormat() == SurfaceFormat::B8G8R8X8);
-
-  RefPtr<DataSourceSurface> dataSurface = surface->GetDataSurface();
-  NS_ENSURE_TRUE(dataSurface, NS_ERROR_FAILURE);
-
-  int32_t width = dataSurface->GetSize().width;
-  int32_t height = dataSurface->GetSize().height;
-  int32_t bytesPerPixel = 4 * sizeof(uint8_t);
-  uint32_t bytesPerRow = bytesPerPixel * width;
-
-  // initialize these bitmap structs which we will later
-  // serialize directly to the head of the bitmap file
-  BITMAPINFOHEADER bmi;
-  bmi.biSize = sizeof(BITMAPINFOHEADER);
-  bmi.biWidth = width;
-  bmi.biHeight = height;
-  bmi.biPlanes = 1;
-  bmi.biBitCount = (WORD)bytesPerPixel*8;
-  bmi.biCompression = BI_RGB;
-  bmi.biSizeImage = bytesPerRow * height;
-  bmi.biXPelsPerMeter = 0;
-  bmi.biYPelsPerMeter = 0;
-  bmi.biClrUsed = 0;
-  bmi.biClrImportant = 0;
-
-  BITMAPFILEHEADER bf;
-  bf.bfType = 0x4D42; // 'BM'
-  bf.bfReserved1 = 0;
-  bf.bfReserved2 = 0;
-  bf.bfOffBits = sizeof(BITMAPFILEHEADER) + sizeof(BITMAPINFOHEADER);
-  bf.bfSize = bf.bfOffBits + bmi.biSizeImage;
-
-  // get a file output stream
-  nsCOMPtr<nsIOutputStream> stream;
-  rv = NS_NewLocalFileOutputStream(getter_AddRefs(stream), aFile);
-  NS_ENSURE_SUCCESS(rv, rv);
-
-  DataSourceSurface::MappedSurface map;
-  if (!dataSurface->Map(DataSourceSurface::MapType::READ, &map)) {
-    return NS_ERROR_FAILURE;
-  }
-
-  // write the bitmap headers and rgb pixel data to the file
-  rv = NS_ERROR_FAILURE;
-  if (stream) {
-    uint32_t written;
-    stream->Write((const char*)&bf, sizeof(BITMAPFILEHEADER), &written);
-    if (written == sizeof(BITMAPFILEHEADER)) {
-      stream->Write((const char*)&bmi, sizeof(BITMAPINFOHEADER), &written);
-      if (written == sizeof(BITMAPINFOHEADER)) {
-        // write out the image data backwards because the desktop won't
-        // show bitmaps with negative heights for top-to-bottom
-        uint32_t i = map.mStride * height;
-        do {
-          i -= map.mStride;
-          stream->Write(((const char*)map.mData) + i, bytesPerRow, &written);
-          if (written == bytesPerRow) {
-            rv = NS_OK;
-          } else {
-            rv = NS_ERROR_FAILURE;
-            break;
-          }
-        } while (i != 0);
-      }
-    }
-
-    stream->Close();
-  }
-
-  dataSurface->Unmap();
-
-  return rv;
-}
-
 NS_IMETHODIMP
 nsWindowsShellService::SetDesktopBackground(dom::Element* aElement,
                                             int32_t aPosition,
                                             const nsACString& aImageName)
 {
   if (!aElement || !aElement->IsHTMLElement(nsGkAtoms::img)) {
     // XXX write background loading stuff!
     return NS_ERROR_NOT_AVAILABLE;
@@ -628,17 +538,17 @@ nsWindowsShellService::SetDesktopBackgro
   rv = file->Append(fileLeafName);
   NS_ENSURE_SUCCESS(rv, rv);
 
   nsAutoString path;
   rv = file->GetPath(path);
   NS_ENSURE_SUCCESS(rv, rv);
 
   // write the bitmap to a file in the profile directory
-  rv = WriteBitmap(file, container);
+  rv = WinUtils::WriteBitmap(file, container);
 
   // if the file was written successfully, set it as the system wallpaper
   if (NS_SUCCEEDED(rv)) {
     nsCOMPtr<nsIWindowsRegKey> regKey =
       do_CreateInstance("@mozilla.org/windows-registry-key;1", &rv);
     NS_ENSURE_SUCCESS(rv, rv);
 
     rv = regKey->Create(nsIWindowsRegKey::ROOT_KEY_CURRENT_USER,
--- a/build/autoconf/arch.m4
+++ b/build/autoconf/arch.m4
@@ -211,17 +211,17 @@ if test "$CPU_ARCH" = "arm"; then
   AC_MSG_RESULT("$result")
   if test "$result" = "yes"; then
       AC_DEFINE(HAVE_ARM_SIMD)
       HAVE_ARM_SIMD=1
   fi
 
   AC_MSG_CHECKING(ARM version support in compiler)
   dnl Determine the target ARM architecture (5 for ARMv5, v5T, v5E, etc.; 6 for ARMv6, v6K, etc.)
-  ARM_ARCH=`${CC-cc} ${CFLAGS} -dM -E - < /dev/null | sed -n 's/.*__ARM_ARCH_\([[0-9]][[0-9]]*\).*/\1/p'`
+  ARM_ARCH=`${CC-cc} ${CFLAGS} -dM -E - < /dev/null | sed -n 's/.*__ARM_ARCH_\([[0-9]][[0-9]]*\).*/\1/p' | head -n 1`
   AC_MSG_RESULT("$ARM_ARCH")
 
   AC_MSG_CHECKING(for ARM NEON support in compiler)
   # We try to link so that this also fails when
   # building with LTO.
   AC_TRY_LINK([],
                  [asm(".fpu neon\n vadd.i8 d0, d0, d0");],
                  result="yes", result="no")
--- a/build/autoconf/compiler-opts.m4
+++ b/build/autoconf/compiler-opts.m4
@@ -1,47 +1,14 @@
 dnl This Source Code Form is subject to the terms of the Mozilla Public
 dnl License, v. 2.0. If a copy of the MPL was not distributed with this
 dnl file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 dnl Add compiler specific options
 
-AC_DEFUN([MOZ_DEFAULT_COMPILER],
-[
-dnl Default to MSVC for win32 and gcc-4.2 for darwin
-dnl ==============================================================
-if test -z "$CROSS_COMPILE"; then
-case "$target" in
-*-mingw*)
-    if test -z "$CPP"; then CPP="$CC -E -nologo"; fi
-    if test -z "$CXXCPP"; then CXXCPP="$CXX -TP -E -nologo"; ac_cv_prog_CXXCPP="$CXXCPP"; fi
-    if test -z "$AS"; then
-        case "${target_cpu}" in
-        i*86)
-            AS=ml;
-            ;;
-        x86_64)
-            AS=ml64;
-            ;;
-        aarch64)
-            AS=armasm64;
-            ;;
-        esac
-    fi
-    if test -z "$MIDL"; then MIDL=midl; fi
-
-    # need override this flag since we don't use $(LDFLAGS) for this.
-    if test -z "$HOST_LDFLAGS" ; then
-        HOST_LDFLAGS=" "
-    fi
-    ;;
-esac
-fi
-])
-
 dnl ============================================================================
 dnl C++ rtti
 dnl We don't use it in the code, but it can be usefull for debugging, so give
 dnl the user the option of enabling it.
 dnl ============================================================================
 AC_DEFUN([MOZ_RTTI],
 [
 MOZ_ARG_ENABLE_BOOL(cpp-rtti,
--- a/build/autoconf/toolchain.m4
+++ b/build/autoconf/toolchain.m4
@@ -9,30 +9,23 @@ dnl However, theses checks are not neces
 dnl the corresponding variables already, so just skip those tests
 dnl entirely.
 define([AC_PROG_CPP],[])
 define([AC_PROG_CXXCPP],[])
 define([AC_HEADER_STDC], [])
 
 AC_DEFUN([MOZ_TOOL_VARIABLES],
 [
-GNU_AS=
-
 GNU_CC=
 GNU_CXX=
 if test "$CC_TYPE" = "gcc"; then
     GNU_CC=1
     GNU_CXX=1
 fi
 
-if test "`echo | $AS -o conftest.out -v 2>&1 | grep -c GNU`" != "0"; then
-    GNU_AS=1
-fi
-rm -f conftest.out
-
 CLANG_CC=
 CLANG_CXX=
 CLANG_CL=
 if test "$CC_TYPE" = "clang"; then
     GNU_CC=1
     GNU_CXX=1
     CLANG_CC=1
     CLANG_CXX=1
--- a/build/moz.configure/old.configure
+++ b/build/moz.configure/old.configure
@@ -164,17 +164,16 @@ def old_configure_options(*options):
 
     return depends(prepare_configure, extra_old_configure_args, all_options,
                    *options)
 
 
 @old_configure_options(
     '--cache-file',
     '--datadir',
-    '--enable-accessibility',
     '--enable-content-sandbox',
     '--enable-cookies',
     '--enable-cpp-rtti',
     '--enable-crashreporter',
     '--enable-dbus',
     '--enable-debug-js-modules',
     '--enable-directshow',
     '--enable-dtrace',
--- a/build/moz.configure/toolchain.configure
+++ b/build/moz.configure/toolchain.configure
@@ -792,16 +792,43 @@ def default_cxx_compilers(c_compiler, ot
             return (os.path.join(dir, file.replace('clang', 'clang++')),)
 
         return (c_compiler.compiler,)
 
     return default_cxx_compilers
 
 
 @template
+def provided_program(env_var):
+    '''Template handling cases where a program can be specified either as a
+    path or as a path with applicable arguments.
+    '''
+
+    @depends_if(env_var)
+    @imports(_from='itertools', _import='takewhile')
+    @imports(_from='mozbuild.shellutil', _import='split', _as='shell_split')
+    def provided(cmd):
+        # Assume the first dash-prefixed item (and any subsequent items) are
+        # command-line options, the item before the dash-prefixed item is
+        # the program we're looking for, and anything before that is a wrapper
+        # of some kind (e.g. sccache).
+        cmd = shell_split(cmd[0])
+
+        without_flags = list(takewhile(lambda x: not x.startswith('-'), cmd))
+
+        return namespace(
+            wrapper=without_flags[:-1],
+            program=without_flags[-1],
+            flags=cmd[len(without_flags):],
+        )
+
+    return provided
+
+
+@template
 def compiler(language, host_or_target, c_compiler=None, other_compiler=None,
              other_c_compiler=None):
     '''Template handling the generic base checks for the compiler for the
     given `language` on the given platform (`host_or_target`).
     `host_or_target` is either `host` or `target` (the @depends functions
     from init.configure.
     When the language is 'C++', `c_compiler` is the result of the `compiler`
     template for the language 'C' for the same `host_or_target`.
@@ -836,41 +863,24 @@ def compiler(language, host_or_target, c
     }[language]()
 
     what = 'the %s %s compiler' % (host_or_target_str, language)
 
     option(env=var, nargs=1, help='Path to %s' % what)
 
     # Handle the compiler given by the user through one of the CC/CXX/HOST_CC/
     # HOST_CXX variables.
-    @depends_if(var)
-    @imports(_from='itertools', _import='takewhile')
-    @imports(_from='mozbuild.shellutil', _import='split', _as='shell_split')
-    def provided_compiler(cmd):
-        # Historically, the compiler variables have contained more than the
-        # path to the compiler itself. So for backwards compatibility, try to
-        # find what is what in there, assuming the first dash-prefixed item is
-        # a compiler option, the item before that is the compiler, and anything
-        # before that is a compiler wrapper.
-        cmd = shell_split(cmd[0])
-
-        without_flags = list(takewhile(lambda x: not x.startswith('-'), cmd))
-
-        return namespace(
-            wrapper=without_flags[:-1],
-            compiler=without_flags[-1],
-            flags=cmd[len(without_flags):],
-        )
+    provided_compiler = provided_program(var)
 
     # Normally, we'd use `var` instead of `_var`, but the interaction with
     # old-configure complicates things, and for now, we a) can't take the plain
     # result from check_prog as CC/CXX/HOST_CC/HOST_CXX and b) have to let
     # old-configure AC_SUBST it (because it's autoconf doing it, not us)
     compiler = check_prog('_%s' % var, what=what, progs=default_compilers,
-                          input=provided_compiler.compiler,
+                          input=provided_compiler.program,
                           paths=toolchain_search_path)
 
     @depends(compiler, provided_compiler, compiler_wrapper, host_or_target)
     @checking('whether %s can be used' % what, lambda x: bool(x))
     @imports(_from='mozbuild.shellutil', _import='quote')
     def valid_compiler(compiler, provided_compiler, compiler_wrapper,
                        host_or_target):
         wrapper = list(compiler_wrapper or ())
@@ -1803,16 +1813,119 @@ def select_linker(linker, c_compiler, de
     return result
 
 
 set_config('LD_IS_BFD', depends(select_linker.KIND)
            (lambda x: x == 'bfd' or None))
 add_old_configure_assignment('LINKER_LDFLAGS', select_linker.LINKER_FLAG)
 
 
+# Assembler detection
+# ==============================================================
+
+js_option(env='AS', nargs=1, help='Path to the assembler')
+
+@depends(target, c_compiler)
+def as_info(target, c_compiler):
+    if c_compiler.type in ('msvc', 'clang-cl'):
+        ml = {
+            'x86': 'ml',
+            'x86_64': 'ml64',
+            'aarch64': 'armasm64.exe',
+        }.get(target.cpu)
+        return namespace(
+            type='masm',
+            names=(ml, )
+        )
+    # When building with anything but MSVC, we just use the C compiler as the assembler.
+    return namespace(
+        type='gcc',
+        names=(c_compiler.compiler, )
+    )
+
+# One would expect the assembler to be specified merely as a program.  But in
+# cases where the assembler is passed down into js/, it can be specified in
+# the same way as CC: a program + a list of argument flags.  We might as well
+# permit the same behavior in general, even though it seems somewhat unusual.
+# So we have to do the same sort of dance as we did above with
+# `provided_compiler`.
+provided_assembler = provided_program('AS')
+assembler = check_prog('_AS', input=provided_assembler.program,
+                       what='the assembler', progs=as_info.names)
+
+@depends(as_info, assembler, provided_assembler, c_compiler)
+def as_with_flags(as_info, assembler, provided_assembler, c_compiler):
+    if provided_assembler:
+        return provided_assembler.wrapper + \
+            [provided_assembler.program] + \
+            provided_assembler.flags
+
+    if as_info.type == 'masm':
+        return assembler
+
+    assert as_info.type == 'gcc'
+
+    # Need to add compiler wrappers and flags as appropriate.
+    return c_compiler.wrapper + [assembler] + c_compiler.flags
+
+
+add_old_configure_assignment('AS', as_with_flags)
+
+
+@depends(assembler, c_compiler, extra_toolchain_flags)
+@imports('subprocess')
+@imports(_from='os', _import='devnull')
+def gnu_as(assembler, c_compiler, toolchain_flags):
+    # clang uses a compatible GNU assembler.
+    if c_compiler.type == 'clang':
+        return True
+
+    if c_compiler.type == 'gcc':
+        cmd = [assembler] + c_compiler.flags
+        if toolchain_flags:
+            cmd += toolchain_flags
+        cmd += ['-Wa,--version', '-c', '-o', devnull, '-x', 'assembler', '-']
+        # We don't actually have to provide any input on stdin, `Popen.communicate` will
+        # close the stdin pipe.
+        # clang will error if it uses its integrated assembler for this target,
+        # so handle failures gracefully.
+        if 'GNU' in check_cmd_output(*cmd, stdin=subprocess.PIPE, onerror=lambda: '').decode('utf-8'):
+            return True
+
+
+set_config('GNU_AS', gnu_as)
+add_old_configure_assignment('GNU_AS', gnu_as)
+
+
+@depends(as_info, target)
+def as_dash_c_flag(as_info, target):
+    # armasm64 doesn't understand -c.
+    if as_info.type == 'masm' and target.cpu == 'aarch64':
+        return ''
+    else:
+        return '-c'
+
+
+set_config('AS_DASH_C_FLAG', as_dash_c_flag)
+
+
+@depends(as_info, target)
+def as_outoption(as_info, target):
+    # The uses of ASOUTOPTION depend on the spacing for -o/-Fo.
+    if as_info.type == 'masm' and target.cpu != 'aarch64':
+        return '-Fo'
+
+    return '-o '
+
+
+set_config('ASOUTOPTION', as_outoption)
+
+# clang plugin handling
+# ==============================================================
+
 js_option('--enable-clang-plugin', env='ENABLE_CLANG_PLUGIN',
           help="Enable building with the mozilla clang plugin")
 
 add_old_configure_assignment('ENABLE_CLANG_PLUGIN',
                              depends_if('--enable-clang-plugin')(lambda _: True))
 
 js_option('--enable-mozsearch-plugin', env='ENABLE_MOZSEARCH_PLUGIN',
           help="Enable building with the mozsearch indexer plugin")
--- a/config/rules.mk
+++ b/config/rules.mk
@@ -371,22 +371,16 @@ IFLAGS2 = -m 755
 endif
 
 ifeq (_WINNT,$(GNU_CC)_$(OS_ARCH))
 OUTOPTION = -Fo# eol
 else
 OUTOPTION = -o # eol
 endif # WINNT && !GNU_CC
 
-ifneq (,$(filter ml%,$(AS)))
-ASOUTOPTION = -Fo# eol
-else
-ASOUTOPTION = -o # eol
-endif
-
 ifeq (,$(CROSS_COMPILE))
 HOST_OUTOPTION = $(OUTOPTION)
 else
 # Windows-to-Windows cross compiles should always use MSVC-style options for
 # host compiles.
 ifeq (WINNT_WINNT,$(HOST_OS_ARCH)_$(OS_ARCH))
 ifneq (,$(filter-out msvc clang-cl,$(HOST_CC_TYPE)))
 $(error MSVC-style compilers should be used for host compilations!)
--- a/dom/base/Element.cpp
+++ b/dom/base/Element.cpp
@@ -2223,17 +2223,17 @@ Element::GetAttributeChangeHint(const ns
 bool
 Element::FindAttributeDependence(const nsAtom* aAttribute,
                                  const MappedAttributeEntry* const aMaps[],
                                  uint32_t aMapCount)
 {
   for (uint32_t mapindex = 0; mapindex < aMapCount; ++mapindex) {
     for (const MappedAttributeEntry* map = aMaps[mapindex];
          map->attribute; ++map) {
-      if (aAttribute == *map->attribute) {
+      if (aAttribute == map->attribute) {
         return true;
       }
     }
   }
 
   return false;
 }
 
@@ -2952,17 +2952,17 @@ Element::FindAttrValueIn(int32_t aNameSp
 {
   NS_ASSERTION(aName, "Must have attr name");
   NS_ASSERTION(aNameSpaceID != kNameSpaceID_Unknown, "Must have namespace");
   NS_ASSERTION(aValues, "Null value array");
 
   const nsAttrValue* val = mAttrs.GetAttr(aName, aNameSpaceID);
   if (val) {
     for (int32_t i = 0; aValues[i]; ++i) {
-      if (val->Equals(*aValues[i], aCaseSensitive)) {
+      if (val->Equals(aValues[i], aCaseSensitive)) {
         return i;
       }
     }
     return ATTR_VALUE_NO_MATCH;
   }
   return ATTR_MISSING;
 }
 
@@ -3464,40 +3464,40 @@ static void
 nsDOMTokenListPropertyDestructor(void *aObject, nsAtom *aProperty,
                                  void *aPropertyValue, void *aData)
 {
   nsDOMTokenList* list =
     static_cast<nsDOMTokenList*>(aPropertyValue);
   NS_RELEASE(list);
 }
 
-static nsStaticAtom** sPropertiesToTraverseAndUnlink[] =
+static nsStaticAtom* const sPropertiesToTraverseAndUnlink[] =
   {
-    &nsGkAtoms::sandbox,
-    &nsGkAtoms::sizes,
-    &nsGkAtoms::dirAutoSetBy,
+    nsGkAtoms::sandbox,
+    nsGkAtoms::sizes,
+    nsGkAtoms::dirAutoSetBy,
     nullptr
   };
 
 // static
-nsStaticAtom***
+nsStaticAtom* const*
 Element::HTMLSVGPropertiesToTraverseAndUnlink()
 {
   return sPropertiesToTraverseAndUnlink;
 }
 
 nsDOMTokenList*
 Element::GetTokenList(nsAtom* aAtom,
                       const DOMTokenListSupportedTokenArray aSupportedTokens)
 {
 #ifdef DEBUG
-  nsStaticAtom*** props = HTMLSVGPropertiesToTraverseAndUnlink();
+  const nsStaticAtom* const* props = HTMLSVGPropertiesToTraverseAndUnlink();
   bool found = false;
   for (uint32_t i = 0; props[i]; ++i) {
-    if (*props[i] == aAtom) {
+    if (props[i] == aAtom) {
       found = true;
       break;
     }
   }
   MOZ_ASSERT(found, "Trying to use an unknown tokenlist!");
 #endif
 
   nsDOMTokenList* list = nullptr;
--- a/dom/base/Element.h
+++ b/dom/base/Element.h
@@ -829,17 +829,17 @@ public:
    *                     be kNameSpaceID_Unknown.
    * @param aName The name atom of the attribute.  Must not be null.
    * @param aValues a nullptr-terminated array of pointers to atom values to test
    *                against.
    * @param aCaseSensitive Whether to do a case-sensitive compare on the values.
    * @return ATTR_MISSING, ATTR_VALUE_NO_MATCH or the non-negative index
    * indicating the first value of aValues that matched
    */
-  typedef nsStaticAtom* const* const AttrValuesArray;
+  typedef nsStaticAtom* const AttrValuesArray;
   int32_t FindAttrValueIn(int32_t aNameSpaceID,
                                   nsAtom* aName,
                                   AttrValuesArray* aValues,
                                   nsCaseTreatment aCaseSensitive) const;
 
   /**
    * Set attribute values. All attribute values are assumed to have a
    * canonical string representation that can be used for these
@@ -979,34 +979,34 @@ public:
    * describing the element.
    */
   void Describe(nsAString& aOutDescription) const;
 
   /*
    * Attribute Mapping Helpers
    */
   struct MappedAttributeEntry {
-    nsStaticAtom** attribute;
+    const nsStaticAtom* const attribute;
   };
 
   /**
    * A common method where you can just pass in a list of maps to check
    * for attribute dependence. Most implementations of
    * IsAttributeMapped should use this function as a default
    * handler.
    */
   template<size_t N>
   static bool
   FindAttributeDependence(const nsAtom* aAttribute,
                           const MappedAttributeEntry* const (&aMaps)[N])
   {
     return FindAttributeDependence(aAttribute, aMaps, N);
   }
 
-  static nsStaticAtom*** HTMLSVGPropertiesToTraverseAndUnlink();
+  static nsStaticAtom* const* HTMLSVGPropertiesToTraverseAndUnlink();
 
 private:
   void DescribeAttribute(uint32_t index, nsAString& aOutDescription) const;
 
   static bool
   FindAttributeDependence(const nsAtom* aAttribute,
                           const MappedAttributeEntry* const aMaps[],
                           uint32_t aMapCount);
--- a/dom/base/FragmentOrElement.cpp
+++ b/dom/base/FragmentOrElement.cpp
@@ -1478,19 +1478,20 @@ NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(Fr
 
   if (tmp->HasProperties()) {
     if (tmp->IsElement()) {
       Element* elem = tmp->AsElement();
       elem->UnlinkIntersectionObservers();
     }
 
     if (tmp->IsHTMLElement() || tmp->IsSVGElement()) {
-      nsStaticAtom*** props = Element::HTMLSVGPropertiesToTraverseAndUnlink();
+      nsStaticAtom* const* props =
+        Element::HTMLSVGPropertiesToTraverseAndUnlink();
       for (uint32_t i = 0; props[i]; ++i) {
-        tmp->DeleteProperty(*props[i]);
+        tmp->DeleteProperty(props[i]);
       }
       if (tmp->MayHaveAnimations()) {
         nsAtom** effectProps = EffectSet::GetEffectSetPropertyAtoms();
         for (uint32_t i = 0; effectProps[i]; ++i) {
           tmp->DeleteProperty(effectProps[i]);
         }
       }
     }
@@ -2034,20 +2035,21 @@ NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN_
       if (observers) {
         for (auto iter = observers->Iter(); !iter.Done(); iter.Next()) {
           DOMIntersectionObserver* observer = iter.Key();
           cb.NoteXPCOMChild(observer);
         }
       }
     }
     if (tmp->IsHTMLElement() || tmp->IsSVGElement()) {
-      nsStaticAtom*** props = Element::HTMLSVGPropertiesToTraverseAndUnlink();
+      nsStaticAtom* const* props =
+        Element::HTMLSVGPropertiesToTraverseAndUnlink();
       for (uint32_t i = 0; props[i]; ++i) {
         nsISupports* property =
-          static_cast<nsISupports*>(tmp->GetProperty(*props[i]));
+          static_cast<nsISupports*>(tmp->GetProperty(props[i]));
         cb.NoteXPCOMChild(property);
       }
       if (tmp->MayHaveAnimations()) {
         nsAtom** effectProps = EffectSet::GetEffectSetPropertyAtoms();
         for (uint32_t i = 0; effectProps[i]; ++i) {
           EffectSet* effectSet =
             static_cast<EffectSet*>(tmp->GetProperty(effectProps[i]));
           if (effectSet) {
--- a/dom/base/nsContentUtils.cpp
+++ b/dom/base/nsContentUtils.cpp
@@ -4640,17 +4640,17 @@ nsContentUtils::UnregisterShutdownObserv
 }
 
 /* static */
 bool
 nsContentUtils::HasNonEmptyAttr(const nsIContent* aContent,
                                 int32_t aNameSpaceID,
                                 nsAtom* aName)
 {
-  static Element::AttrValuesArray strings[] = {&nsGkAtoms::_empty, nullptr};
+  static Element::AttrValuesArray strings[] = {nsGkAtoms::_empty, nullptr};
   return aContent->IsElement() &&
     aContent->AsElement()->FindAttrValueIn(aNameSpaceID, aName, strings, eCaseMatters)
       == Element::ATTR_VALUE_NO_MATCH;
 }
 
 /* static */
 bool
 nsContentUtils::HasMutationListeners(nsINode* aNode,
--- a/dom/base/nsDocument.cpp
+++ b/dom/base/nsDocument.cpp
@@ -5303,68 +5303,50 @@ nsIDocument::DispatchContentLoadedEvents
 // attached, but ultimately that whitelist should disappear.
 // Please note that any about: page should not use inline JS or inline CSS,
 // and instead should load JS and CSS from an external file (*.js, *.css)
 // which allows us to apply a strong CSP omitting 'unsafe-inline'. Ideally,
 // the CSP allows precisely the resources that need to be loaded; but it
 // should at least be as strong as:
 // <meta http-equiv="Content-Security-Policy" content="default-src chrome:"/>
 static void
-AssertContentPrivilegedAboutPageHasCSP(nsIURI* aDocumentURI, nsIPrincipal* aPrincipal)
-{
-  // Curently we can't serialize the CSP, hence we only assert if
-  // running in the content process.
-  if (!XRE_IsContentProcess()) {
-    return;
-  }
-
+AssertAboutPageHasCSP(nsIURI* aDocumentURI, nsIPrincipal* aPrincipal)
+{
   // Check if we are loading an about: URI at all
   bool isAboutURI =
     (NS_SUCCEEDED(aDocumentURI->SchemeIs("about", &isAboutURI)) && isAboutURI);
 
-  if (!isAboutURI) {
-    return;
-  }
-
-  // Check if we are loading a content-privileged about: URI
-  nsCOMPtr<nsIAboutModule> aboutModule;
-  nsresult rv = NS_GetAboutModule(aDocumentURI, getter_AddRefs(aboutModule));
-  NS_ENSURE_SUCCESS_VOID(rv);
-
-  uint32_t aboutModuleFlags = 0;
-  rv = aboutModule->GetURIFlags(aDocumentURI, &aboutModuleFlags);
-  NS_ENSURE_SUCCESS_VOID(rv);
-
-  if (!(aboutModuleFlags & nsIAboutModule::URI_SAFE_FOR_UNTRUSTED_CONTENT)) {
+  if (!isAboutURI || Preferences::GetBool("csp.skip_about_page_has_csp_assert")) {
     return;
   }
 
   // Potentially init the legacy whitelist of about URIs without a CSP.
   static StaticAutoPtr<nsTArray<nsCString>> sLegacyAboutPagesWithNoCSP;
   if (!sLegacyAboutPagesWithNoCSP ||
-      Preferences::GetBool("csp.overrule_content_privileged_about_uris_without_csp_whitelist")) {
+      Preferences::GetBool("csp.overrule_about_uris_without_csp_whitelist")) {
     sLegacyAboutPagesWithNoCSP = new nsTArray<nsCString>();
     nsAutoCString legacyAboutPages;
-    Preferences::GetCString("csp.content_privileged_about_uris_without_csp",
+    Preferences::GetCString("csp.about_uris_without_csp",
       legacyAboutPages);
     for (const nsACString& hostString : legacyAboutPages.Split(',')) {
       // please note that for the actual whitelist we only store the path of
       // about: URI. Let's reassemble the full about URI here so we don't
       // have to remove query arguments later.
       nsCString aboutURI;
       aboutURI.AppendLiteral("about:");
       aboutURI.Append(hostString);
       sLegacyAboutPagesWithNoCSP->AppendElement(aboutURI);
     }
     ClearOnShutdown(&sLegacyAboutPagesWithNoCSP);
   }
 
   // Check if the about URI is whitelisted
   nsAutoCString aboutSpec;
   aDocumentURI->GetSpec(aboutSpec);
+  ToLowerCase(aboutSpec);
   for (auto& legacyPageEntry : *sLegacyAboutPagesWithNoCSP) {
     // please note that we perform a substring match here on purpose,
     // so we don't have to deal and parse out all the query arguments
     // the various about pages rely on.
     if (aboutSpec.Find(legacyPageEntry) == 0) {
       return;
     }
   }
@@ -5374,32 +5356,32 @@ AssertContentPrivilegedAboutPageHasCSP(n
   nsAutoString parsedPolicyStr;
   if (csp) {
     uint32_t policyCount = 0;
      csp->GetPolicyCount(&policyCount);
      if (policyCount > 0) {
        csp->GetPolicyString(0, parsedPolicyStr);
      }
   }
-  if (Preferences::GetBool("csp.overrule_content_privileged_about_uris_without_csp_whitelist")) {
+  if (Preferences::GetBool("csp.overrule_about_uris_without_csp_whitelist")) {
     NS_ASSERTION(parsedPolicyStr.Find("default-src") >= 0, "about: page must have a CSP");
     return;
   }
   MOZ_ASSERT(parsedPolicyStr.Find("default-src") >= 0,
     "about: page must contain a CSP including default-src");
 }
 #endif
 
 void
 nsDocument::EndLoad()
 {
 #if defined(DEBUG) && !defined(ANDROID)
   // only assert if nothing stopped the load on purpose
   if (!mParserAborted) {
-    AssertContentPrivilegedAboutPageHasCSP(mDocumentURI, NodePrincipal());
+    AssertAboutPageHasCSP(mDocumentURI, NodePrincipal());
   }
 #endif
 
   // EndLoad may have been called without a matching call to BeginLoad, in the
   // case of a failed parse (for example, due to timeout). In such a case, we
   // still want to execute part of this code to do appropriate cleanup, but we
   // gate part of it because it is intended to match 1-for-1 with calls to
   // BeginLoad. We have an explicit flag bit for this purpose, since it's
--- a/dom/base/nsJSUtils.cpp
+++ b/dom/base/nsJSUtils.cpp
@@ -471,91 +471,92 @@ nsJSUtils::ExecutionContext::ExtractRetu
   return NS_OK;
 }
 
 nsresult
 nsJSUtils::CompileModule(JSContext* aCx,
                        JS::SourceBufferHolder& aSrcBuf,
                        JS::Handle<JSObject*> aEvaluationGlobal,
                        JS::CompileOptions &aCompileOptions,
-                       JS::MutableHandle<JSScript*> aScript)
+                       JS::MutableHandle<JSObject*> aModule)
 {
   AUTO_PROFILER_LABEL("nsJSUtils::CompileModule", JS);
 
   MOZ_ASSERT(aCx == nsContentUtils::GetCurrentJSContext());
   MOZ_ASSERT(aSrcBuf.get());
   MOZ_ASSERT(JS_IsGlobalObject(aEvaluationGlobal));
   MOZ_ASSERT(JS::CurrentGlobalOrNull(aCx) == aEvaluationGlobal);
   MOZ_ASSERT(NS_IsMainThread());
   MOZ_ASSERT(CycleCollectedJSContext::Get() &&
              CycleCollectedJSContext::Get()->MicroTaskLevel());
 
   NS_ENSURE_TRUE(xpc::Scriptability::Get(aEvaluationGlobal).Allowed(), NS_OK);
 
-  if (!JS::CompileModule(aCx, aCompileOptions, aSrcBuf, aScript)) {
+  if (!JS::CompileModule(aCx, aCompileOptions, aSrcBuf, aModule)) {
     return NS_ERROR_FAILURE;
   }
 
   return NS_OK;
 }
 
 nsresult
 nsJSUtils::InitModuleSourceElement(JSContext* aCx,
-                                   JS::Handle<JSScript*> aScript,
+                                   JS::Handle<JSObject*> aModule,
                                    nsIScriptElement* aElement)
 {
   JS::Rooted<JS::Value> value(aCx);
   nsresult rv = nsContentUtils::WrapNative(aCx, aElement, &value,
                                            /* aAllowWrapping = */ true);
   if (NS_FAILED(rv)) {
     return rv;
   }
 
   MOZ_ASSERT(value.isObject());
   JS::Rooted<JSObject*> object(aCx, &value.toObject());
 
-  if (!JS::InitScriptSourceElement(aCx, aScript, object, nullptr)) {
+  JS::Rooted<JSScript*> script(aCx, JS::GetModuleScript(aModule));
+  if (!JS::InitScriptSourceElement(aCx, script, object, nullptr)) {
     return NS_ERROR_FAILURE;
   }
 
   return NS_OK;
 }
 
 nsresult
-nsJSUtils::ModuleInstantiate(JSContext* aCx, JS::Handle<JSScript*> aScript)
+nsJSUtils::ModuleInstantiate(JSContext* aCx, JS::Handle<JSObject*> aModule)
 {
   AUTO_PROFILER_LABEL("nsJSUtils::ModuleInstantiate", JS);
 
   MOZ_ASSERT(aCx == nsContentUtils::GetCurrentJSContext());
   MOZ_ASSERT(NS_IsMainThread());
   MOZ_ASSERT(CycleCollectedJSContext::Get() &&
              CycleCollectedJSContext::Get()->MicroTaskLevel());
 
-  NS_ENSURE_TRUE(xpc::Scriptability::Get(aScript).Allowed(), NS_OK);
+  NS_ENSURE_TRUE(xpc::Scriptability::Get(aModule).Allowed(), NS_OK);
 
-  if (!JS::ModuleInstantiate(aCx, aScript)) {
+  if (!JS::ModuleInstantiate(aCx, aModule)) {
     return NS_ERROR_FAILURE;
   }
 
   return NS_OK;
 }
 
 nsresult
-nsJSUtils::ModuleEvaluate(JSContext* aCx, JS::Handle<JSScript*> aScript)
+nsJSUtils::ModuleEvaluate(JSContext* aCx, JS::Handle<JSObject*> aModule)
 {
   AUTO_PROFILER_LABEL("nsJSUtils::ModuleEvaluate", JS);
 
   MOZ_ASSERT(aCx == nsContentUtils::GetCurrentJSContext());
   MOZ_ASSERT(NS_IsMainThread());
   MOZ_ASSERT(CycleCollectedJSContext::Get() &&
              CycleCollectedJSContext::Get()->MicroTaskLevel());
 
-  NS_ENSURE_TRUE(xpc::Scriptability::Get(aScript).Allowed(), NS_OK);
+  NS_ENSURE_TRUE(xpc::Scriptability::Get(aModule).Allowed(), NS_OK);
 
-  if (!JS::ModuleEvaluate(aCx, aScript)) {
+  if (!JS::ModuleEvaluate(aCx, aModule)) {
     return NS_ERROR_FAILURE;
   }
 
   return NS_OK;
 }
 
 static bool
 AddScopeChainItem(JSContext* aCx,
--- a/dom/base/nsJSUtils.h
+++ b/dom/base/nsJSUtils.h
@@ -184,27 +184,27 @@ public:
                                  const uint8_t* aBuf, size_t aLength,
                                  JS::MutableHandle<JSScript*> aScript);
   };
 
   static nsresult CompileModule(JSContext* aCx,
                                 JS::SourceBufferHolder& aSrcBuf,
                                 JS::Handle<JSObject*> aEvaluationGlobal,
                                 JS::CompileOptions &aCompileOptions,
-                                JS::MutableHandle<JSScript*> aScript);
+                                JS::MutableHandle<JSObject*> aModule);
 
   static nsresult InitModuleSourceElement(JSContext* aCx,
-                                          JS::Handle<JSScript*> aScript,
+                                          JS::Handle<JSObject*> aModule,
                                           nsIScriptElement* aElement);
 
   static nsresult ModuleInstantiate(JSContext* aCx,
-                                    JS::Handle<JSScript*> aScript);
+                                    JS::Handle<JSObject*> aModule);
 
   static nsresult ModuleEvaluate(JSContext* aCx,
-                                 JS::Handle<JSScript*> aScript);
+                                 JS::Handle<JSObject*> aModule);
 
   // Returns false if an exception got thrown on aCx.  Passing a null
   // aElement is allowed; that wil produce an empty aScopeChain.
   static bool GetScopeChainForElement(JSContext* aCx,
                                       mozilla::dom::Element* aElement,
                                       JS::AutoObjectVector& aScopeChain);
 
   // Returns a scope chain suitable for XBL execution.
--- a/dom/events/EventStateManager.cpp
+++ b/dom/events/EventStateManager.cpp
@@ -3007,17 +3007,17 @@ EventStateManager::DecideGestureEvent(Wi
 #ifdef XP_MACOSX
 static bool
 NodeAllowsClickThrough(nsINode* aNode)
 {
   while (aNode) {
     if (aNode->IsXULElement()) {
       mozilla::dom::Element* element = aNode->AsElement();
       static Element::AttrValuesArray strings[] =
-        {&nsGkAtoms::always, &nsGkAtoms::never, nullptr};
+        {nsGkAtoms::always, nsGkAtoms::never, nullptr};
       switch (element->FindAttrValueIn(kNameSpaceID_None, nsGkAtoms::clickthrough,
                                        strings, eCaseMatters)) {
         case 0:
           return true;
         case 1:
           return false;
       }
     }
--- a/dom/html/HTMLBRElement.cpp
+++ b/dom/html/HTMLBRElement.cpp
@@ -62,17 +62,17 @@ HTMLBRElement::MapAttributesIntoRule(con
   }
   nsGenericHTMLElement::MapCommonAttributesInto(aAttributes, aDecls);
 }
 
 NS_IMETHODIMP_(bool)
 HTMLBRElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::clear },
+    { nsGkAtoms::clear },
     { nullptr }
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sCommonAttributeMap,
   };
 
--- a/dom/html/HTMLBodyElement.cpp
+++ b/dom/html/HTMLBodyElement.cpp
@@ -227,26 +227,26 @@ HTMLBodyElement::GetAttributeMappingFunc
 {
   return &MapAttributesIntoRule;
 }
 
 NS_IMETHODIMP_(bool)
 HTMLBodyElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::link },
-    { &nsGkAtoms::vlink },
-    { &nsGkAtoms::alink },
-    { &nsGkAtoms::text },
-    { &nsGkAtoms::marginwidth },
-    { &nsGkAtoms::marginheight },
-    { &nsGkAtoms::topmargin },
-    { &nsGkAtoms::rightmargin },
-    { &nsGkAtoms::bottommargin },
-    { &nsGkAtoms::leftmargin },
+    { nsGkAtoms::link },
+    { nsGkAtoms::vlink },
+    { nsGkAtoms::alink },
+    { nsGkAtoms::text },
+    { nsGkAtoms::marginwidth },
+    { nsGkAtoms::marginheight },
+    { nsGkAtoms::topmargin },
+    { nsGkAtoms::rightmargin },
+    { nsGkAtoms::bottommargin },
+    { nsGkAtoms::leftmargin },
     { nullptr },
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sCommonAttributeMap,
     sBackgroundAttributeMap,
   };
--- a/dom/html/HTMLFontElement.cpp
+++ b/dom/html/HTMLFontElement.cpp
@@ -92,19 +92,19 @@ HTMLFontElement::MapAttributesIntoRule(c
 
   nsGenericHTMLElement::MapCommonAttributesInto(aAttributes, aDecls);
 }
 
 NS_IMETHODIMP_(bool)
 HTMLFontElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::face },
-    { &nsGkAtoms::size },
-    { &nsGkAtoms::color },
+    { nsGkAtoms::face },
+    { nsGkAtoms::size },
+    { nsGkAtoms::color },
     { nullptr }
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sCommonAttributeMap,
   };
 
--- a/dom/html/HTMLHRElement.cpp
+++ b/dom/html/HTMLHRElement.cpp
@@ -168,21 +168,21 @@ HTMLHRElement::MapAttributesIntoRule(con
   nsGenericHTMLElement::MapWidthAttributeInto(aAttributes, aDecls);
   nsGenericHTMLElement::MapCommonAttributesInto(aAttributes, aDecls);
 }
 
 NS_IMETHODIMP_(bool)
 HTMLHRElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::align },
-    { &nsGkAtoms::width },
-    { &nsGkAtoms::size },
-    { &nsGkAtoms::color },
-    { &nsGkAtoms::noshade },
+    { nsGkAtoms::align },
+    { nsGkAtoms::width },
+    { nsGkAtoms::size },
+    { nsGkAtoms::color },
+    { nsGkAtoms::noshade },
     { nullptr },
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sCommonAttributeMap,
   };
 
--- a/dom/html/HTMLIFrameElement.cpp
+++ b/dom/html/HTMLIFrameElement.cpp
@@ -126,19 +126,19 @@ HTMLIFrameElement::MapAttributesIntoRule
   nsGenericHTMLElement::MapImageAlignAttributeInto(aAttributes, aDecls);
   nsGenericHTMLElement::MapCommonAttributesInto(aAttributes, aDecls);
 }
 
 NS_IMETHODIMP_(bool)
 HTMLIFrameElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::width },
-    { &nsGkAtoms::height },
-    { &nsGkAtoms::frameborder },
+    { nsGkAtoms::width },
+    { nsGkAtoms::height },
+    { nsGkAtoms::frameborder },
     { nullptr },
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sImageAlignAttributeMap,
     sCommonAttributeMap,
   };
--- a/dom/html/HTMLInputElement.cpp
+++ b/dom/html/HTMLInputElement.cpp
@@ -5647,17 +5647,17 @@ HTMLInputElement::GetAttributeChangeHint
   }
   return retval;
 }
 
 NS_IMETHODIMP_(bool)
 HTMLInputElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::align },
+    { nsGkAtoms::align },
     { nullptr },
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sCommonAttributeMap,
     sImageMarginSizeAttributeMap,
     sImageBorderAttributeMap,
--- a/dom/html/HTMLLIElement.cpp
+++ b/dom/html/HTMLLIElement.cpp
@@ -78,17 +78,17 @@ HTMLLIElement::MapAttributesIntoRule(con
 
   nsGenericHTMLElement::MapCommonAttributesInto(aAttributes, aDecls);
 }
 
 NS_IMETHODIMP_(bool)
 HTMLLIElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::type },
+    { nsGkAtoms::type },
     { nullptr },
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sCommonAttributeMap,
   };
 
--- a/dom/html/HTMLLinkElement.cpp
+++ b/dom/html/HTMLLinkElement.cpp
@@ -236,17 +236,17 @@ HTMLLinkElement::CreateAndDispatchEvent(
 
   // In the unlikely case that both rev is specified *and* rel=stylesheet,
   // this code will cause the event to fire, on the principle that maybe the
   // page really does want to specify that its author is a stylesheet. Since
   // this should never actually happen and the performance hit is minimal,
   // doing the "right" thing costs virtually nothing here, even if it doesn't
   // make much sense.
   static Element::AttrValuesArray strings[] =
-    {&nsGkAtoms::_empty, &nsGkAtoms::stylesheet, nullptr};
+    {nsGkAtoms::_empty, nsGkAtoms::stylesheet, nullptr};
 
   if (!nsContentUtils::HasNonEmptyAttr(this, kNameSpaceID_None,
                                        nsGkAtoms::rev) &&
       FindAttrValueIn(kNameSpaceID_None, nsGkAtoms::rel,
                       strings, eIgnoreCase) != ATTR_VALUE_NO_MATCH)
     return;
 
   RefPtr<AsyncEventDispatcher> asyncDispatcher =
--- a/dom/html/HTMLPreElement.cpp
+++ b/dom/html/HTMLPreElement.cpp
@@ -57,17 +57,17 @@ HTMLPreElement::MapAttributesIntoRule(co
 NS_IMETHODIMP_(bool)
 HTMLPreElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   if (!mNodeInfo->Equals(nsGkAtoms::pre)) {
     return nsGenericHTMLElement::IsAttributeMapped(aAttribute);
   }
 
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::wrap },
+    { nsGkAtoms::wrap },
     { nullptr },
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sCommonAttributeMap,
   };
 
--- a/dom/html/HTMLSharedElement.cpp
+++ b/dom/html/HTMLSharedElement.cpp
@@ -117,18 +117,18 @@ DirectoryMapAttributesIntoRule(const nsM
   nsGenericHTMLElement::MapCommonAttributesInto(aAttributes, aDecls);
 }
 
 NS_IMETHODIMP_(bool)
 HTMLSharedElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   if (mNodeInfo->Equals(nsGkAtoms::dir)) {
     static const MappedAttributeEntry attributes[] = {
-      { &nsGkAtoms::type },
-      // { &nsGkAtoms::compact }, // XXX
+      { nsGkAtoms::type },
+      // { nsGkAtoms::compact }, // XXX
       { nullptr}
     };
 
     static const MappedAttributeEntry* const map[] = {
       attributes,
       sCommonAttributeMap,
     };
 
--- a/dom/html/HTMLSharedListElement.cpp
+++ b/dom/html/HTMLSharedListElement.cpp
@@ -95,17 +95,17 @@ HTMLSharedListElement::MapAttributesInto
 }
 
 NS_IMETHODIMP_(bool)
 HTMLSharedListElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   if (mNodeInfo->Equals(nsGkAtoms::ol) ||
       mNodeInfo->Equals(nsGkAtoms::ul)) {
     static const MappedAttributeEntry attributes[] = {
-      { &nsGkAtoms::type },
+      { nsGkAtoms::type },
       { nullptr }
     };
 
     static const MappedAttributeEntry* const map[] = {
       attributes,
       sCommonAttributeMap,
     };
 
--- a/dom/html/HTMLTableCaptionElement.cpp
+++ b/dom/html/HTMLTableCaptionElement.cpp
@@ -63,17 +63,17 @@ HTMLTableCaptionElement::MapAttributesIn
 
   nsGenericHTMLElement::MapCommonAttributesInto(aAttributes, aDecls);
 }
 
 NS_IMETHODIMP_(bool)
 HTMLTableCaptionElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::align },
+    { nsGkAtoms::align },
     { nullptr }
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sCommonAttributeMap,
   };
 
--- a/dom/html/HTMLTableCellElement.cpp
+++ b/dom/html/HTMLTableCellElement.cpp
@@ -232,29 +232,29 @@ HTMLTableCellElement::MapAttributesIntoR
   nsGenericHTMLElement::MapBackgroundAttributesInto(aAttributes, aDecls);
   nsGenericHTMLElement::MapCommonAttributesInto(aAttributes, aDecls);
 }
 
 NS_IMETHODIMP_(bool)
 HTMLTableCellElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::align },
-    { &nsGkAtoms::valign },
-    { &nsGkAtoms::nowrap },
+    { nsGkAtoms::align },
+    { nsGkAtoms::valign },
+    { nsGkAtoms::nowrap },
 #if 0
     // XXXldb If these are implemented, they might need to move to
     // GetAttributeChangeHint (depending on how, and preferably not).
-    { &nsGkAtoms::abbr },
-    { &nsGkAtoms::axis },
-    { &nsGkAtoms::headers },
-    { &nsGkAtoms::scope },
+    { nsGkAtoms::abbr },
+    { nsGkAtoms::axis },
+    { nsGkAtoms::headers },
+    { nsGkAtoms::scope },
 #endif
-    { &nsGkAtoms::width },
-    { &nsGkAtoms::height },
+    { nsGkAtoms::width },
+    { nsGkAtoms::height },
     { nullptr }
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sCommonAttributeMap,
     sBackgroundAttributeMap,
   };
--- a/dom/html/HTMLTableColElement.cpp
+++ b/dom/html/HTMLTableColElement.cpp
@@ -86,20 +86,20 @@ HTMLTableColElement::MapAttributesIntoRu
   nsGenericHTMLElement::MapVAlignAttributeInto(aAttributes, aDecls);
   nsGenericHTMLElement::MapCommonAttributesInto(aAttributes, aDecls);
 }
 
 NS_IMETHODIMP_(bool)
 HTMLTableColElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::width },
-    { &nsGkAtoms::align },
-    { &nsGkAtoms::valign },
-    { &nsGkAtoms::span },
+    { nsGkAtoms::width },
+    { nsGkAtoms::align },
+    { nsGkAtoms::valign },
+    { nsGkAtoms::span },
     { nullptr }
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sCommonAttributeMap,
   };
 
--- a/dom/html/HTMLTableElement.cpp
+++ b/dom/html/HTMLTableElement.cpp
@@ -1011,27 +1011,27 @@ HTMLTableElement::MapAttributesIntoRule(
   nsGenericHTMLElement::MapBackgroundAttributesInto(aAttributes, aDecls);
   nsGenericHTMLElement::MapCommonAttributesInto(aAttributes, aDecls);
 }
 
 NS_IMETHODIMP_(bool)
 HTMLTableElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::cellpadding },
-    { &nsGkAtoms::cellspacing },
-    { &nsGkAtoms::border },
-    { &nsGkAtoms::width },
-    { &nsGkAtoms::height },
-    { &nsGkAtoms::hspace },
-    { &nsGkAtoms::vspace },
+    { nsGkAtoms::cellpadding },
+    { nsGkAtoms::cellspacing },
+    { nsGkAtoms::border },
+    { nsGkAtoms::width },
+    { nsGkAtoms::height },
+    { nsGkAtoms::hspace },
+    { nsGkAtoms::vspace },
 
-    { &nsGkAtoms::bordercolor },
+    { nsGkAtoms::bordercolor },
 
-    { &nsGkAtoms::align },
+    { nsGkAtoms::align },
     { nullptr }
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sCommonAttributeMap,
     sBackgroundAttributeMap,
   };
--- a/dom/html/HTMLTableRowElement.cpp
+++ b/dom/html/HTMLTableRowElement.cpp
@@ -268,19 +268,19 @@ HTMLTableRowElement::MapAttributesIntoRu
   nsGenericHTMLElement::MapBackgroundAttributesInto(aAttributes, aDecls);
   nsGenericHTMLElement::MapCommonAttributesInto(aAttributes, aDecls);
 }
 
 NS_IMETHODIMP_(bool)
 HTMLTableRowElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::align },
-    { &nsGkAtoms::valign },
-    { &nsGkAtoms::height },
+    { nsGkAtoms::align },
+    { nsGkAtoms::valign },
+    { nsGkAtoms::height },
     { nullptr }
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sCommonAttributeMap,
     sBackgroundAttributeMap,
   };
--- a/dom/html/HTMLTableSectionElement.cpp
+++ b/dom/html/HTMLTableSectionElement.cpp
@@ -176,19 +176,19 @@ HTMLTableSectionElement::MapAttributesIn
   nsGenericHTMLElement::MapBackgroundAttributesInto(aAttributes, aDecls);
   nsGenericHTMLElement::MapCommonAttributesInto(aAttributes, aDecls);
 }
 
 NS_IMETHODIMP_(bool)
 HTMLTableSectionElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::align },
-    { &nsGkAtoms::valign },
-    { &nsGkAtoms::height },
+    { nsGkAtoms::align },
+    { nsGkAtoms::valign },
+    { nsGkAtoms::height },
     { nullptr }
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sCommonAttributeMap,
     sBackgroundAttributeMap,
   };
--- a/dom/html/HTMLTextAreaElement.cpp
+++ b/dom/html/HTMLTextAreaElement.cpp
@@ -456,17 +456,17 @@ HTMLTextAreaElement::GetAttributeChangeH
   }
   return retval;
 }
 
 NS_IMETHODIMP_(bool)
 HTMLTextAreaElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::wrap },
+    { nsGkAtoms::wrap },
     { nullptr }
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sDivAlignAttributeMap,
     sCommonAttributeMap,
   };
--- a/dom/html/HTMLVideoElement.cpp
+++ b/dom/html/HTMLVideoElement.cpp
@@ -106,18 +106,18 @@ HTMLVideoElement::MapAttributesIntoRule(
   nsGenericHTMLElement::MapImageSizeAttributesInto(aAttributes, aDecls);
   nsGenericHTMLElement::MapCommonAttributesInto(aAttributes, aDecls);
 }
 
 NS_IMETHODIMP_(bool)
 HTMLVideoElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   static const MappedAttributeEntry attributes[] = {
-    { &nsGkAtoms::width },
-    { &nsGkAtoms::height },
+    { nsGkAtoms::width },
+    { nsGkAtoms::height },
     { nullptr }
   };
 
   static const MappedAttributeEntry* const map[] = {
     attributes,
     sCommonAttributeMap
   };
 
--- a/dom/html/nsGenericHTMLElement.cpp
+++ b/dom/html/nsGenericHTMLElement.cpp
@@ -317,17 +317,17 @@ nsGenericHTMLElement::GetOffsetRect(CSSI
 bool
 nsGenericHTMLElement::Spellcheck()
 {
   // Has the state has been explicitly set?
   nsIContent* node;
   for (node = this; node; node = node->GetParent()) {
     if (node->IsHTMLElement()) {
       static Element::AttrValuesArray strings[] =
-        {&nsGkAtoms::_true, &nsGkAtoms::_false, nullptr};
+        {nsGkAtoms::_true, nsGkAtoms::_false, nullptr};
       switch (node->AsElement()->FindAttrValueIn(kNameSpaceID_None,
                                                  nsGkAtoms::spellcheck, strings,
                                                  eCaseMatters)) {
         case 0:                         // spellcheck = "true"
           return true;
         case 1:                         // spellcheck = "false"
           return false;
       }
@@ -1216,59 +1216,59 @@ nsGenericHTMLElement::MapCommonAttribute
     if (aAttributes->IndexOfAttr(nsGkAtoms::hidden) >= 0) {
       aDecls.SetKeywordValue(eCSSProperty_display, StyleDisplay::None);
     }
   }
 }
 
 /* static */ const nsGenericHTMLElement::MappedAttributeEntry
 nsGenericHTMLElement::sCommonAttributeMap[] = {
-  { &nsGkAtoms::contenteditable },
-  { &nsGkAtoms::lang },
-  { &nsGkAtoms::hidden },
+  { nsGkAtoms::contenteditable },
+  { nsGkAtoms::lang },
+  { nsGkAtoms::hidden },
   { nullptr }
 };
 
 /* static */ const Element::MappedAttributeEntry
 nsGenericHTMLElement::sImageMarginSizeAttributeMap[] = {
-  { &nsGkAtoms::width },
-  { &nsGkAtoms::height },
-  { &nsGkAtoms::hspace },
-  { &nsGkAtoms::vspace },
+  { nsGkAtoms::width },
+  { nsGkAtoms::height },
+  { nsGkAtoms::hspace },
+  { nsGkAtoms::vspace },
   { nullptr }
 };
 
 /* static */ const Element::MappedAttributeEntry
 nsGenericHTMLElement::sImageAlignAttributeMap[] = {
-  { &nsGkAtoms::align },
+  { nsGkAtoms::align },
   { nullptr }
 };
 
 /* static */ const Element::MappedAttributeEntry
 nsGenericHTMLElement::sDivAlignAttributeMap[] = {
-  { &nsGkAtoms::align },
+  { nsGkAtoms::align },
   { nullptr }
 };
 
 /* static */ const Element::MappedAttributeEntry
 nsGenericHTMLElement::sImageBorderAttributeMap[] = {
-  { &nsGkAtoms::border },
+  { nsGkAtoms::border },
   { nullptr }
 };
 
 /* static */ const Element::MappedAttributeEntry
 nsGenericHTMLElement::sBackgroundAttributeMap[] = {
-  { &nsGkAtoms::background },
-  { &nsGkAtoms::bgcolor },
+  { nsGkAtoms::background },
+  { nsGkAtoms::bgcolor },
   { nullptr }
 };
 
 /* static */ const Element::MappedAttributeEntry
 nsGenericHTMLElement::sBackgroundColorAttributeMap[] = {
-  { &nsGkAtoms::bgcolor },
+  { nsGkAtoms::bgcolor },
   { nullptr }
 };
 
 void
 nsGenericHTMLElement::MapImageAlignAttributeInto(const nsMappedAttributes* aAttributes,
                                                  MappedDeclarations& aDecls)
 {
   const nsAttrValue* value = aAttributes->GetAttr(nsGkAtoms::align);
--- a/dom/html/nsGenericHTMLElement.h
+++ b/dom/html/nsGenericHTMLElement.h
@@ -898,17 +898,17 @@ protected:
    * Returns eTrue if the element has a contentEditable attribute and its value
    * is "true" or an empty string. Returns eFalse if the element has a
    * contentEditable attribute and its value is "false". Otherwise returns
    * eInherit.
    */
   ContentEditableTristate GetContentEditableValue() const
   {
     static const Element::AttrValuesArray values[] =
-      { &nsGkAtoms::_false, &nsGkAtoms::_true, &nsGkAtoms::_empty, nullptr };
+      { nsGkAtoms::_false, nsGkAtoms::_true, nsGkAtoms::_empty, nullptr };
 
     if (!MayHaveContentEditableAttr())
       return eInherit;
 
     int32_t value = FindAttrValueIn(kNameSpaceID_None,
                                     nsGkAtoms::contenteditable, values,
                                     eIgnoreCase);
 
--- a/dom/html/nsTextEditorState.cpp
+++ b/dom/html/nsTextEditorState.cpp
@@ -229,17 +229,17 @@ nsITextControlElement::GetWrapPropertyEn
   // browsers treat it that way and there is no real reason to maintain physical
   // and virtual as separate entities if no one else does.  Only hard and off
   // do anything different.
   aWrapProp = eHTMLTextWrap_Soft; // the default
 
   nsAutoString wrap;
   if (aContent->IsHTMLElement()) {
     static Element::AttrValuesArray strings[] =
-      {&nsGkAtoms::HARD, &nsGkAtoms::OFF, nullptr};
+      {nsGkAtoms::HARD, nsGkAtoms::OFF, nullptr};
 
     switch (aContent->AsElement()->FindAttrValueIn(kNameSpaceID_None,
                                                    nsGkAtoms::wrap, strings,
                                                    eIgnoreCase)) {
       case 0: aWrapProp = eHTMLTextWrap_Hard; break;
       case 1: aWrapProp = eHTMLTextWrap_Off; break;
     }
 
--- a/dom/mathml/nsMathMLElement.cpp
+++ b/dom/mathml/nsMathMLElement.cpp
@@ -160,47 +160,47 @@ nsMathMLElement::ParseAttribute(int32_t 
 
   return nsMathMLElementBase::ParseAttribute(aNamespaceID, aAttribute,
                                              aValue,
                                              aMaybeScriptedPrincipal,
                                              aResult);
 }
 
 static Element::MappedAttributeEntry sMtableStyles[] = {
-  { &nsGkAtoms::width },
+  { nsGkAtoms::width },
   { nullptr }
 };
 
 static Element::MappedAttributeEntry sTokenStyles[] = {
-  { &nsGkAtoms::mathsize_ },
-  { &nsGkAtoms::fontsize_ },
-  { &nsGkAtoms::color },
-  { &nsGkAtoms::fontfamily_ },
-  { &nsGkAtoms::fontstyle_ },
-  { &nsGkAtoms::fontweight_ },
-  { &nsGkAtoms::mathvariant_},
+  { nsGkAtoms::mathsize_ },
+  { nsGkAtoms::fontsize_ },
+  { nsGkAtoms::color },
+  { nsGkAtoms::fontfamily_ },
+  { nsGkAtoms::fontstyle_ },
+  { nsGkAtoms::fontweight_ },
+  { nsGkAtoms::mathvariant_},
   { nullptr }
 };
 
 static Element::MappedAttributeEntry sEnvironmentStyles[] = {
-  { &nsGkAtoms::scriptlevel_ },
-  { &nsGkAtoms::scriptminsize_ },
-  { &nsGkAtoms::scriptsizemultiplier_ },
-  { &nsGkAtoms::background },
+  { nsGkAtoms::scriptlevel_ },
+  { nsGkAtoms::scriptminsize_ },
+  { nsGkAtoms::scriptsizemultiplier_ },
+  { nsGkAtoms::background },
   { nullptr }
 };
 
 static Element::MappedAttributeEntry sCommonPresStyles[] = {
-  { &nsGkAtoms::mathcolor_ },
-  { &nsGkAtoms::mathbackground_ },
+  { nsGkAtoms::mathcolor_ },
+  { nsGkAtoms::mathbackground_ },
   { nullptr }
 };
 
 static Element::MappedAttributeEntry sDirStyles[] = {
-  { &nsGkAtoms::dir },
+  { nsGkAtoms::dir },
   { nullptr }
 };
 
 bool
 nsMathMLElement::IsAttributeMapped(const nsAtom* aAttribute) const
 {
   MOZ_ASSERT(IsMathMLElement());
 
@@ -975,23 +975,23 @@ nsMathMLElement::IsLink(nsIURI** aURI) c
     //   xlink:type    - must be unset or set to "" or set to "simple"
     //   xlink:show    - must be unset or set to "", "new" or "replace"
     //   xlink:actuate - must be unset or set to "" or "onRequest"
     //
     // For any other values, we're either not a *clickable* XLink, or the end
     // result is poorly specified. Either way, we return false.
 
     static Element::AttrValuesArray sTypeVals[] =
-      { &nsGkAtoms::_empty, &nsGkAtoms::simple, nullptr };
+      { nsGkAtoms::_empty, nsGkAtoms::simple, nullptr };
 
     static Element::AttrValuesArray sShowVals[] =
-      { &nsGkAtoms::_empty, &nsGkAtoms::_new, &nsGkAtoms::replace, nullptr };
+      { nsGkAtoms::_empty, nsGkAtoms::_new, nsGkAtoms::replace, nullptr };
 
     static Element::AttrValuesArray sActuateVals[] =
-      { &nsGkAtoms::_empty, &nsGkAtoms::onRequest, nullptr };
+      { nsGkAtoms::_empty, nsGkAtoms::onRequest, nullptr };
 
     // Optimization: check for href first for early return
     href = mAttrs.GetAttr(nsGkAtoms::href, kNameSpaceID_XLink);
     if (href &&
         FindAttrValueIn(kNameSpaceID_XLink, nsGkAtoms::type,
                         sTypeVals, eCaseMatters) !=
         Element::ATTR_VALUE_NO_MATCH &&
         FindAttrValueIn(kNameSpaceID_XLink, nsGkAtoms::show,
@@ -1026,17 +1026,17 @@ nsMathMLElement::GetLinkTarget(nsAString
                                              kNameSpaceID_XLink);
   if (target) {
     target->ToString(aTarget);
   }
 
   if (aTarget.IsEmpty()) {
 
     static Element::AttrValuesArray sShowVals[] =
-      { &nsGkAtoms::_new, &nsGkAtoms::replace, nullptr };
+      { nsGkAtoms::_new, nsGkAtoms::replace, nullptr };
 
     switch (FindAttrValueIn(kNameSpaceID_XLink, nsGkAtoms::show,
                             sShowVals, eCaseMatters)) {
     case 0:
       aTarget.AssignLiteral("_blank");
       return;
     case 1:
       return;
--- a/dom/payments/PaymentRequest.cpp
+++ b/dom/payments/PaymentRequest.cpp
@@ -55,22 +55,21 @@ NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(
 NS_INTERFACE_MAP_END_INHERITING(DOMEventTargetHelper)
 
 NS_IMPL_ADDREF_INHERITED(PaymentRequest, DOMEventTargetHelper)
 NS_IMPL_RELEASE_INHERITED(PaymentRequest, DOMEventTargetHelper)
 
 bool
 PaymentRequest::PrefEnabled(JSContext* aCx, JSObject* aObj)
 {
-#ifdef NIGHTLY_BUILD
-  return XRE_IsContentProcess() &&
-         Preferences::GetBool("dom.payments.request.enabled");
-#else
-  return false;
-#endif
+  if (!XRE_IsContentProcess()) {
+    return false;
+  }
+
+  return StaticPrefs::dom_payments_request_enabled();
 }
 
 nsresult
 PaymentRequest::IsValidStandardizedPMI(const nsAString& aIdentifier,
                                        nsAString& aErrorMsg)
 {
   /*
    *   The syntax of a standardized payment method identifier is given by the
--- a/dom/script/ModuleScript.cpp
+++ b/dom/script/ModuleScript.cpp
@@ -16,109 +16,108 @@ namespace dom {
 NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(ModuleScript)
 NS_INTERFACE_MAP_END
 
 NS_IMPL_CYCLE_COLLECTION_CLASS(ModuleScript)
 
 NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(ModuleScript)
   NS_IMPL_CYCLE_COLLECTION_UNLINK(mLoader)
   NS_IMPL_CYCLE_COLLECTION_UNLINK(mBaseURL)
-  tmp->UnlinkScript();
+  tmp->UnlinkModuleRecord();
   tmp->mParseError.setUndefined();
   tmp->mErrorToRethrow.setUndefined();
 NS_IMPL_CYCLE_COLLECTION_UNLINK_END
 
 NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN(ModuleScript)
   NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mLoader)
 NS_IMPL_CYCLE_COLLECTION_TRAVERSE_END
 
 NS_IMPL_CYCLE_COLLECTION_TRACE_BEGIN(ModuleScript)
-  NS_IMPL_CYCLE_COLLECTION_TRACE_JS_MEMBER_CALLBACK(mScript)
+  NS_IMPL_CYCLE_COLLECTION_TRACE_JS_MEMBER_CALLBACK(mModuleRecord)
   NS_IMPL_CYCLE_COLLECTION_TRACE_JS_MEMBER_CALLBACK(mParseError)
   NS_IMPL_CYCLE_COLLECTION_TRACE_JS_MEMBER_CALLBACK(mErrorToRethrow)
 NS_IMPL_CYCLE_COLLECTION_TRACE_END
 
 NS_IMPL_CYCLE_COLLECTING_ADDREF(ModuleScript)
 NS_IMPL_CYCLE_COLLECTING_RELEASE(ModuleScript)
 
 ModuleScript::ModuleScript(ScriptLoader* aLoader, nsIURI* aBaseURL)
  : mLoader(aLoader),
    mBaseURL(aBaseURL),
    mSourceElementAssociated(false)
 {
   MOZ_ASSERT(mLoader);
   MOZ_ASSERT(mBaseURL);
-  MOZ_ASSERT(!mScript);
+  MOZ_ASSERT(!mModuleRecord);
   MOZ_ASSERT(!HasParseError());
   MOZ_ASSERT(!HasErrorToRethrow());
 }
 
 void
-ModuleScript::UnlinkScript()
+ModuleScript::UnlinkModuleRecord()
 {
   // Remove module's back reference to this object request if present.
-  if (mScript) {
-    MOZ_ASSERT(JS::GetTopLevelScriptPrivate(mScript) == this);
-    JS::SetTopLevelScriptPrivate(mScript, nullptr);
-    mScript = nullptr;
+  if (mModuleRecord) {
+    MOZ_ASSERT(JS::GetModuleHostDefinedField(mModuleRecord).toPrivate() ==
+               this);
+    JS::SetModuleHostDefinedField(mModuleRecord, JS::UndefinedValue());
+    mModuleRecord = nullptr;
   }
 }
 
 ModuleScript::~ModuleScript()
 {
   // The object may be destroyed without being unlinked first.
-  UnlinkScript();
+  UnlinkModuleRecord();
   DropJSObjects(this);
 }
 
 void
-ModuleScript::SetScript(JS::Handle<JSScript*> aScript)
+ModuleScript::SetModuleRecord(JS::Handle<JSObject*> aModuleRecord)
 {
-  MOZ_ASSERT(!mScript);
+  MOZ_ASSERT(!mModuleRecord);
   MOZ_ASSERT(!HasParseError());
   MOZ_ASSERT(!HasErrorToRethrow());
 
-  mScript = aScript;
+  mModuleRecord = aModuleRecord;
 
   // Make module's host defined field point to this module script object.
-  // This is cleared in the UnlinkScript().
-  MOZ_ASSERT(!JS::GetTopLevelScriptPrivate(mScript));
-  JS::SetTopLevelScriptPrivate(mScript, this);
-
+  // This is cleared in the UnlinkModuleRecord().
+  JS::SetModuleHostDefinedField(mModuleRecord, JS::PrivateValue(this));
   HoldJSObjects(this);
 }
 
 void
 ModuleScript::SetParseError(const JS::Value& aError)
 {
   MOZ_ASSERT(!aError.isUndefined());
   MOZ_ASSERT(!HasParseError());
   MOZ_ASSERT(!HasErrorToRethrow());
 
-  UnlinkScript();
+  UnlinkModuleRecord();
   mParseError = aError;
   HoldJSObjects(this);
 }
 
 void
 ModuleScript::SetErrorToRethrow(const JS::Value& aError)
 {
   MOZ_ASSERT(!aError.isUndefined());
   MOZ_ASSERT(!HasErrorToRethrow());
 
-  // This is only called after SetScript() or SetParseError() so we don't
+  // This is only called after SetModuleRecord() or SetParseError() so we don't
   // need to call HoldJSObjects() here.
-  MOZ_ASSERT(mScript || HasParseError());
+  MOZ_ASSERT(mModuleRecord || HasParseError());
 
   mErrorToRethrow = aError;
 }
 
 void
 ModuleScript::SetSourceElementAssociated()
 {
-  MOZ_ASSERT(mScript);
+  MOZ_ASSERT(mModuleRecord);
   MOZ_ASSERT(!mSourceElementAssociated);
 
   mSourceElementAssociated = true;
 }
 
 } // dom namespace
 } // mozilla namespace
--- a/dom/script/ModuleScript.h
+++ b/dom/script/ModuleScript.h
@@ -17,43 +17,43 @@ namespace mozilla {
 namespace dom {
 
 class ScriptLoader;
 
 class ModuleScript final : public nsISupports
 {
   RefPtr<ScriptLoader> mLoader;
   nsCOMPtr<nsIURI> mBaseURL;
-  JS::Heap<JSScript*> mScript;
+  JS::Heap<JSObject*> mModuleRecord;
   JS::Heap<JS::Value> mParseError;
   JS::Heap<JS::Value> mErrorToRethrow;
   bool mSourceElementAssociated;
 
   ~ModuleScript();
 
 public:
   NS_DECL_CYCLE_COLLECTING_ISUPPORTS
   NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(ModuleScript)
 
   ModuleScript(ScriptLoader* aLoader,
                nsIURI* aBaseURL);
 
-  void SetScript(JS::Handle<JSScript*> aScript);
+  void SetModuleRecord(JS::Handle<JSObject*> aModuleRecord);
   void SetParseError(const JS::Value& aError);
   void SetErrorToRethrow(const JS::Value& aError);
   void SetSourceElementAssociated();
 
   ScriptLoader* Loader() const { return mLoader; }
-  JSScript* Script() const { return mScript; }
+  JSObject* ModuleRecord() const { return mModuleRecord; }
   nsIURI* BaseURL() const { return mBaseURL; }
   JS::Value ParseError() const { return mParseError; }
   JS::Value ErrorToRethrow() const { return mErrorToRethrow; }
   bool HasParseError() const { return !mParseError.isUndefined(); }
   bool HasErrorToRethrow() const { return !mErrorToRethrow.isUndefined(); }
   bool SourceElementAssociated() const { return mSourceElementAssociated; }
 
-  void UnlinkScript();
+  void UnlinkModuleRecord();
 };
 
 } // dom namespace
 } // mozilla namespace
 
 #endif // mozilla_dom_ModuleScript_h
--- a/dom/script/ScriptLoader.cpp
+++ b/dom/script/ScriptLoader.cpp
@@ -476,60 +476,60 @@ ScriptLoader::CreateModuleScript(ModuleL
   AutoEntryScript aes(globalObject, "CompileModule", true);
 
   bool oldProcessingScriptTag = context->GetProcessingScriptTag();
   context->SetProcessingScriptTag(true);
 
   nsresult rv;
   {
     JSContext* cx = aes.cx();
-    JS::Rooted<JSScript*> script(cx);
+    JS::Rooted<JSObject*> module(cx);
 
     if (aRequest->mWasCompiledOMT) {
-      script = JS::FinishOffThreadModule(cx, aRequest->mOffThreadToken);
+      module = JS::FinishOffThreadModule(cx, aRequest->mOffThreadToken);
       aRequest->mOffThreadToken = nullptr;
-      rv = script ? NS_OK : NS_ERROR_FAILURE;
+      rv = module ? NS_OK : NS_ERROR_FAILURE;
     } else {
       JS::Rooted<JSObject*> global(cx, globalObject->GetGlobalJSObject());
 
       JS::CompileOptions options(cx);
       rv = FillCompileOptionsForRequest(aes, aRequest, global, &options);
 
       if (NS_SUCCEEDED(rv)) {
         auto srcBuf = GetScriptSource(cx, aRequest);
         if (srcBuf) {
-          rv = nsJSUtils::CompileModule(cx, *srcBuf, global, options, &script);
+          rv = nsJSUtils::CompileModule(cx, *srcBuf, global, options, &module);
         } else {
           rv = NS_ERROR_OUT_OF_MEMORY;
         }
       }
     }
 
-    MOZ_ASSERT(NS_SUCCEEDED(rv) == (script != nullptr));
+    MOZ_ASSERT(NS_SUCCEEDED(rv) == (module != nullptr));
 
     RefPtr<ModuleScript> moduleScript = new ModuleScript(this, aRequest->mBaseURL);
     aRequest->mModuleScript = moduleScript;
 
-    if (!script) {
+    if (!module) {
       LOG(("ScriptLoadRequest (%p):   compilation failed (%d)",
            aRequest, unsigned(rv)));
 
       MOZ_ASSERT(aes.HasException());
       JS::Rooted<JS::Value> error(cx);
       if (!aes.StealException(&error)) {
         aRequest->mModuleScript = nullptr;
         return NS_ERROR_FAILURE;
       }
 
       moduleScript->SetParseError(error);
       aRequest->ModuleErrored();
       return NS_OK;
     }
 
-    moduleScript->SetScript(script);
+    moduleScript->SetModuleRecord(module);
 
     // Validate requested modules and treat failure to resolve module specifiers
     // the same as a parse error.
     rv = ResolveRequestedModules(aRequest, nullptr);
     if (NS_FAILED(rv)) {
       aRequest->ModuleErrored();
       return NS_OK;
     }
@@ -612,24 +612,24 @@ ResolveModuleSpecifier(ModuleScript* aSc
 }
 
 static nsresult
 ResolveRequestedModules(ModuleLoadRequest* aRequest, nsCOMArray<nsIURI>* aUrlsOut)
 {
   ModuleScript* ms = aRequest->mModuleScript;
 
   AutoJSAPI jsapi;
-  if (!jsapi.Init(JS::GetScriptGlobal(ms->Script()))) {
+  if (!jsapi.Init(ms->ModuleRecord())) {
     return NS_ERROR_FAILURE;
   }
 
   JSContext* cx = jsapi.cx();
-  JS::Rooted<JSScript*> script(cx, ms->Script());
+  JS::Rooted<JSObject*> moduleRecord(cx, ms->ModuleRecord());
   JS::Rooted<JSObject*> requestedModules(cx);
-  requestedModules = JS::GetRequestedModules(cx, script);
+  requestedModules = JS::GetRequestedModules(cx, moduleRecord);
   MOZ_ASSERT(requestedModules);
 
   uint32_t length;
   if (!JS_GetArrayLength(cx, requestedModules, &length)) {
     return NS_ERROR_FAILURE;
   }
 
   JS::Rooted<JS::Value> element(cx);
@@ -753,29 +753,24 @@ ScriptLoader::StartFetchingModuleAndDepe
     childRequest->mReady.Reject(rv, __func__);
     return ready;
   }
 
   return ready;
 }
 
 // 8.1.3.8.1 HostResolveImportedModule(referencingModule, specifier)
-JSScript*
-HostResolveImportedModule(JSContext* aCx, JS::Handle<JSScript*> aScript,
+JSObject*
+HostResolveImportedModule(JSContext* aCx, JS::Handle<JSObject*> aModule,
                           JS::Handle<JSString*> aSpecifier)
 {
   // Let referencing module script be referencingModule.[[HostDefined]].
-  void* value = JS::GetTopLevelScriptPrivate(aScript);
-  if (!value) {
-    JS_ReportErrorASCII(aCx, "Module script not found");
-    return nullptr;
-  }
-
-  auto script = static_cast<ModuleScript*>(value);
-  MOZ_ASSERT(script->Script() == aScript);
+  JS::Value value = JS::GetModuleHostDefinedField(aModule);
+  auto script = static_cast<ModuleScript*>(value.toPrivate());
+  MOZ_ASSERT(script->ModuleRecord() == aModule);
 
   // Let url be the result of resolving a module specifier given referencing
   // module script and specifier.
   nsAutoJSString string;
   if (!string.init(aCx, aSpecifier)) {
     return nullptr;
   }
 
@@ -786,35 +781,35 @@ HostResolveImportedModule(JSContext* aCx
   MOZ_ASSERT(uri, "Failed to resolve previously-resolved module specifier");
 
   // Let resolved module script be moduleMap[url]. (This entry must exist for us
   // to have gotten to this point.)
   ModuleScript* ms = script->Loader()->GetFetchedModule(uri);
   MOZ_ASSERT(ms, "Resolved module not found in module map");
 
   MOZ_ASSERT(!ms->HasParseError());
-  MOZ_ASSERT(ms->Script());
-
-  return ms->Script();
+  MOZ_ASSERT(ms->ModuleRecord());
+
+  return ms->ModuleRecord();
 }
 
 bool
-HostPopulateImportMeta(JSContext* aCx, JS::Handle<JSScript*> aScript,
+HostPopulateImportMeta(JSContext* aCx, JS::Handle<JSObject*> aModule,
                        JS::Handle<JSObject*> aMetaObject)
 {
-  MOZ_DIAGNOSTIC_ASSERT(aScript);
-
-  void* value = JS::GetTopLevelScriptPrivate(aScript);
-  if (!value) {
+  MOZ_DIAGNOSTIC_ASSERT(aModule);
+
+  JS::Value value = JS::GetModuleHostDefinedField(aModule);
+  if (value.isUndefined()) {
     JS_ReportErrorASCII(aCx, "Module script not found");
     return false;
   }
 
-  auto script = static_cast<ModuleScript*>(value);
-  MOZ_DIAGNOSTIC_ASSERT(script->Script() == aScript);
+  auto script = static_cast<ModuleScript*>(value.toPrivate());
+  MOZ_DIAGNOSTIC_ASSERT(script->ModuleRecord() == aModule);
 
   nsAutoCString url;
   MOZ_DIAGNOSTIC_ASSERT(script->BaseURL());
   MOZ_ALWAYS_SUCCEEDS(script->BaseURL()->GetAsciiSpec(url));
 
   JS::Rooted<JSString*> urlString(aCx, JS_NewStringCopyZ(aCx, url.get()));
   if (!urlString) {
     JS_ReportOutOfMemory(aCx);
@@ -935,28 +930,28 @@ ScriptLoader::InstantiateModuleTree(Modu
 
   JS::Value parseError = FindFirstParseError(aRequest);
   if (!parseError.isUndefined()) {
     moduleScript->SetErrorToRethrow(parseError);
     LOG(("ScriptLoadRequest (%p):   found parse error", aRequest));
     return true;
   }
 
-  MOZ_ASSERT(moduleScript->Script());
+  MOZ_ASSERT(moduleScript->ModuleRecord());
 
   nsAutoMicroTask mt;
   AutoJSAPI jsapi;
-  if (NS_WARN_IF(!jsapi.Init(JS::GetScriptGlobal(moduleScript->Script())))) {
+  if (NS_WARN_IF(!jsapi.Init(moduleScript->ModuleRecord()))) {
     return false;
   }
 
   EnsureModuleResolveHook(jsapi.cx());
 
-  JS::Rooted<JSScript*> script(jsapi.cx(), moduleScript->Script());
-  bool ok = NS_SUCCEEDED(nsJSUtils::ModuleInstantiate(jsapi.cx(), script));
+  JS::Rooted<JSObject*> module(jsapi.cx(), moduleScript->ModuleRecord());
+  bool ok = NS_SUCCEEDED(nsJSUtils::ModuleInstantiate(jsapi.cx(), module));
 
   if (!ok) {
     LOG(("ScriptLoadRequest (%p): Instantiate failed", aRequest));
     MOZ_ASSERT(jsapi.HasException());
     JS::RootedValue exception(jsapi.cx());
     if (!jsapi.StealException(&exception)) {
       return false;
     }
@@ -982,24 +977,25 @@ ScriptLoader::AssociateSourceElementsFor
     return NS_OK;
   }
 
   for (ModuleLoadRequest* childRequest : aRequest->mImports) {
     nsresult rv = AssociateSourceElementsForModuleTree(aCx, childRequest);
     NS_ENSURE_SUCCESS(rv, rv);
   }
 
-  JS::Rooted<JSScript*> script(aCx, moduleScript->Script());
-  MOZ_ASSERT(script);
-
-  nsresult rv = nsJSUtils::InitModuleSourceElement(aCx, script, aRequest->Element());
+  JS::Rooted<JSObject*> module(aCx, moduleScript->ModuleRecord());
+  MOZ_ASSERT(module);
+
+  nsresult rv = nsJSUtils::InitModuleSourceElement(aCx, module, aRequest->Element());
   NS_ENSURE_SUCCESS(rv, rv);
   moduleScript->SetSourceElementAssociated();
 
   // The script is now ready to be exposed to the debugger.
+  JS::Rooted<JSScript*> script(aCx, JS::GetModuleScript(module));
   JS::ExposeScriptToDebugger(aCx, script);
 
   return NS_OK;
 }
 
 nsresult
 ScriptLoader::RestartLoad(ScriptLoadRequest* aRequest)
 {
@@ -2339,25 +2335,25 @@ ScriptLoader::EvaluateScript(ScriptLoadR
       ModuleScript* moduleScript = request->mModuleScript;
       if (moduleScript->HasErrorToRethrow()) {
         LOG(("ScriptLoadRequest (%p):   module has error to rethrow", aRequest));
         JS::Rooted<JS::Value> error(cx, moduleScript->ErrorToRethrow());
         JS_SetPendingException(cx, error);
         return NS_OK; // An error is reported by AutoEntryScript.
       }
 
-      JS::Rooted<JSScript*> script(cx, moduleScript->Script());
-      MOZ_ASSERT(script);
+      JS::Rooted<JSObject*> module(cx, moduleScript->ModuleRecord());
+      MOZ_ASSERT(module);
 
       if (!moduleScript->SourceElementAssociated()) {
         rv = AssociateSourceElementsForModuleTree(cx, request);
         NS_ENSURE_SUCCESS(rv, rv);
       }
 
-      rv = nsJSUtils::ModuleEvaluate(cx, script);
+      rv = nsJSUtils::ModuleEvaluate(cx, module);
       MOZ_ASSERT(NS_FAILED(rv) == aes.HasException());
       if (NS_FAILED(rv)) {
         LOG(("ScriptLoadRequest (%p):   evaluation failed", aRequest));
         rv = NS_OK; // An error is reported by AutoEntryScript.
       }
 
       aRequest->mCacheInfo = nullptr;
     } else {
--- a/dom/script/ScriptLoader.h
+++ b/dom/script/ScriptLoader.h
@@ -515,18 +515,18 @@ private:
                                                       nsresult aResult);
 
   bool IsFetchingModule(ModuleLoadRequest* aRequest) const;
 
   bool ModuleMapContainsURL(nsIURI* aURL) const;
   RefPtr<mozilla::GenericPromise> WaitForModuleFetch(nsIURI* aURL);
   ModuleScript* GetFetchedModule(nsIURI* aURL) const;
 
-  friend JSScript*
-  HostResolveImportedModule(JSContext* aCx, JS::Handle<JSScript*> aScript,
+  friend JSObject*
+  HostResolveImportedModule(JSContext* aCx, JS::Handle<JSObject*> aModule,
                           JS::Handle<JSString*> aSpecifier);
 
   // Returns wether we should save the bytecode of this script after the
   // execution of the script.
   static bool
   ShouldCacheBytecode(ScriptLoadRequest* aRequest);
 
   nsresult CreateModuleScript(ModuleLoadRequest* aRequest);
--- a/dom/security/test/general/test_assert_about_page_no_csp.html
+++ b/dom/security/test/general/test_assert_about_page_no_csp.html
@@ -9,33 +9,33 @@
 <iframe id="testframe"></iframe>
 <script class="testbody" type="text/javascript">
 
   SimpleTest.waitForExplicitFinish();
   SimpleTest.expectAssertions(0, 1);
 
   // Test Setup:
   // The test overrules the whitelist of about: pages that are allowed to load without a CSP
-  // and makes sure to hit the assertion within AssertContentPrivilegedAboutPageHasCSP().
-  // However, due to the caching mechanism within AssertContentPrivilegedAboutPageHasCSP this
+  // and makes sure to hit the assertion within AssertAboutPageHasCSP().
+  // However, due to the caching mechanism within AssertAboutPageHasCSP this
   // test loads a second dummy data: URI to reset the old cache and finally resets the pref
   // used for testing purposes.
 
-  let origWhiteList = SpecialPowers.getCharPref("csp.content_privileged_about_uris_without_csp");
+  let origWhiteList = SpecialPowers.getCharPref("csp.about_uris_without_csp");
 
-  SpecialPowers.setCharPref("csp.content_privileged_about_uris_without_csp", "");
-  SpecialPowers.setBoolPref("csp.overrule_content_privileged_about_uris_without_csp_whitelist", true);
+  SpecialPowers.setCharPref("csp.about_uris_without_csp", "");
+  SpecialPowers.setBoolPref("csp.overrule_about_uris_without_csp_whitelist", true);
 
   ok(true, "sanity: prefs flipped and test runs");
   let myFrame = document.getElementById("testframe");
   myFrame.src = "about:blank";
   // booom :-)
 
-  SpecialPowers.setCharPref("csp.content_privileged_about_uris_without_csp", origWhiteList);
+  SpecialPowers.setCharPref("csp.about_uris_without_csp", origWhiteList);
   myFrame.src = "data:text/html,<body>just a dumy data: URI</body>";
 
-  SpecialPowers.setBoolPref("csp.overrule_content_privileged_about_uris_without_csp_whitelist", false);
+  SpecialPowers.setBoolPref("csp.overrule_about_uris_without_csp_whitelist", false);
 
   SimpleTest.finish();
 </script>
 </pre>
 </body>
 </html>
--- a/dom/svg/SVGAElement.cpp
+++ b/dom/svg/SVGAElement.cpp
@@ -25,19 +25,19 @@ namespace dom {
 JSObject*
 SVGAElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGAElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::StringInfo SVGAElement::sStringInfo[3] =
 {
-  { &nsGkAtoms::href, kNameSpaceID_None, true },
-  { &nsGkAtoms::href, kNameSpaceID_XLink, true },
-  { &nsGkAtoms::target, kNameSpaceID_None, true }
+  { nsGkAtoms::href, kNameSpaceID_None, true },
+  { nsGkAtoms::href, kNameSpaceID_XLink, true },
+  { nsGkAtoms::target, kNameSpaceID_None, true }
 };
 
 // static
 const DOMTokenListSupportedToken SVGAElement::sSupportedRelValues[] = {
   "noreferrer",
   "noopener",
   nullptr
 };
@@ -344,23 +344,23 @@ SVGAElement::IsLink(nsIURI** aURI) const
   //   xlink:type    - must be unset or set to "" or set to "simple"
   //   xlink:show    - must be unset or set to "", "new" or "replace"
   //   xlink:actuate - must be unset or set to "" or "onRequest"
   //
   // For any other values, we're either not a *clickable* XLink, or the end
   // result is poorly specified. Either way, we return false.
 
   static Element::AttrValuesArray sTypeVals[] =
-    { &nsGkAtoms::_empty, &nsGkAtoms::simple, nullptr };
+    { nsGkAtoms::_empty, nsGkAtoms::simple, nullptr };
 
   static Element::AttrValuesArray sShowVals[] =
-    { &nsGkAtoms::_empty, &nsGkAtoms::_new, &nsGkAtoms::replace, nullptr };
+    { nsGkAtoms::_empty, nsGkAtoms::_new, nsGkAtoms::replace, nullptr };
 
   static Element::AttrValuesArray sActuateVals[] =
-    { &nsGkAtoms::_empty, &nsGkAtoms::onRequest, nullptr };
+    { nsGkAtoms::_empty, nsGkAtoms::onRequest, nullptr };
 
   // Optimization: check for href first for early return
   bool useBareHref = mStringAttributes[HREF].IsExplicitlySet();
 
   if ((useBareHref || mStringAttributes[XLINK_HREF].IsExplicitlySet()) &&
       FindAttrValueIn(kNameSpaceID_XLink, nsGkAtoms::type,
                       sTypeVals, eCaseMatters) !=
                       Element::ATTR_VALUE_NO_MATCH &&
@@ -386,17 +386,17 @@ SVGAElement::IsLink(nsIURI** aURI) const
 
 void
 SVGAElement::GetLinkTarget(nsAString& aTarget)
 {
   mStringAttributes[TARGET].GetAnimValue(aTarget, this);
   if (aTarget.IsEmpty()) {
 
     static Element::AttrValuesArray sShowVals[] =
-      { &nsGkAtoms::_new, &nsGkAtoms::replace, nullptr };
+      { nsGkAtoms::_new, nsGkAtoms::replace, nullptr };
 
     switch (FindAttrValueIn(kNameSpaceID_XLink, nsGkAtoms::show,
                             sShowVals, eCaseMatters)) {
     case 0:
       aTarget.AssignLiteral("_blank");
       return;
     case 1:
       return;
--- a/dom/svg/SVGAnimateMotionElement.h
+++ b/dom/svg/SVGAnimateMotionElement.h
@@ -34,17 +34,17 @@ public:
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // SVGAnimationElement
   virtual nsSMILAnimationFunction& AnimationFunction() override;
   virtual bool GetTargetAttributeName(int32_t *aNamespaceID,
                                       nsAtom **aLocalName) const override;
 
   // nsSVGElement
-  virtual nsAtom* GetPathDataAttrName() const override {
+  virtual nsStaticAtom* GetPathDataAttrName() const override {
     return nsGkAtoms::path;
   }
 
   // Utility method to let our <mpath> children tell us when they've changed,
   // so we can make sure our mAnimationFunction is marked as having changed.
   void MpathChanged() { mAnimationFunction.MpathChanged(); }
 };
 
--- a/dom/svg/SVGCircleElement.cpp
+++ b/dom/svg/SVGCircleElement.cpp
@@ -20,19 +20,19 @@ namespace dom {
 JSObject*
 SVGCircleElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGCircleElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::LengthInfo SVGCircleElement::sLengthInfo[3] =
 {
-  { &nsGkAtoms::cx, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::cy, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
-  { &nsGkAtoms::r, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::XY }
+  { nsGkAtoms::cx, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::cy, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::r, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::XY }
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
 SVGCircleElement::SVGCircleElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
   : SVGCircleElementBase(std::move(aNodeInfo))
 {
--- a/dom/svg/SVGClipPathElement.cpp
+++ b/dom/svg/SVGClipPathElement.cpp
@@ -21,17 +21,17 @@ using namespace SVGUnitTypes_Binding;
 JSObject*
 SVGClipPathElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGClipPathElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::EnumInfo SVGClipPathElement::sEnumInfo[1] =
 {
-  { &nsGkAtoms::clipPathUnits,
+  { nsGkAtoms::clipPathUnits,
     sSVGUnitTypesMap,
     SVG_UNIT_TYPE_USERSPACEONUSE
   }
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
--- a/dom/svg/SVGEllipseElement.cpp
+++ b/dom/svg/SVGEllipseElement.cpp
@@ -21,20 +21,20 @@ namespace dom {
 JSObject*
 SVGEllipseElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGEllipseElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::LengthInfo SVGEllipseElement::sLengthInfo[4] =
 {
-  { &nsGkAtoms::cx, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::cy, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
-  { &nsGkAtoms::rx, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::ry, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::cx, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::cy, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::rx, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::ry, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
 SVGEllipseElement::SVGEllipseElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
   : SVGEllipseElementBase(std::move(aNodeInfo))
 {
--- a/dom/svg/SVGFEBlendElement.cpp
+++ b/dom/svg/SVGFEBlendElement.cpp
@@ -17,48 +17,48 @@ namespace dom {
 
 JSObject*
 SVGFEBlendElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFEBlendElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGEnumMapping SVGFEBlendElement::sModeMap[] = {
-  {&nsGkAtoms::normal, SVG_FEBLEND_MODE_NORMAL},
-  {&nsGkAtoms::multiply, SVG_FEBLEND_MODE_MULTIPLY},
-  {&nsGkAtoms::screen, SVG_FEBLEND_MODE_SCREEN},
-  {&nsGkAtoms::darken, SVG_FEBLEND_MODE_DARKEN},
-  {&nsGkAtoms::lighten, SVG_FEBLEND_MODE_LIGHTEN},
-  {&nsGkAtoms::overlay, SVG_FEBLEND_MODE_OVERLAY},
-  {&nsGkAtoms::colorDodge, SVG_FEBLEND_MODE_COLOR_DODGE},
-  {&nsGkAtoms::colorBurn, SVG_FEBLEND_MODE_COLOR_BURN},
-  {&nsGkAtoms::hardLight, SVG_FEBLEND_MODE_HARD_LIGHT},
-  {&nsGkAtoms::softLight, SVG_FEBLEND_MODE_SOFT_LIGHT},
-  {&nsGkAtoms::difference, SVG_FEBLEND_MODE_DIFFERENCE},
-  {&nsGkAtoms::exclusion, SVG_FEBLEND_MODE_EXCLUSION},
-  {&nsGkAtoms::hue, SVG_FEBLEND_MODE_HUE},
-  {&nsGkAtoms::saturation, SVG_FEBLEND_MODE_SATURATION},
-  {&nsGkAtoms::color, SVG_FEBLEND_MODE_COLOR},
-  {&nsGkAtoms::luminosity, SVG_FEBLEND_MODE_LUMINOSITY},
+  {nsGkAtoms::normal, SVG_FEBLEND_MODE_NORMAL},
+  {nsGkAtoms::multiply, SVG_FEBLEND_MODE_MULTIPLY},
+  {nsGkAtoms::screen, SVG_FEBLEND_MODE_SCREEN},
+  {nsGkAtoms::darken, SVG_FEBLEND_MODE_DARKEN},
+  {nsGkAtoms::lighten, SVG_FEBLEND_MODE_LIGHTEN},
+  {nsGkAtoms::overlay, SVG_FEBLEND_MODE_OVERLAY},
+  {nsGkAtoms::colorDodge, SVG_FEBLEND_MODE_COLOR_DODGE},
+  {nsGkAtoms::colorBurn, SVG_FEBLEND_MODE_COLOR_BURN},
+  {nsGkAtoms::hardLight, SVG_FEBLEND_MODE_HARD_LIGHT},
+  {nsGkAtoms::softLight, SVG_FEBLEND_MODE_SOFT_LIGHT},
+  {nsGkAtoms::difference, SVG_FEBLEND_MODE_DIFFERENCE},
+  {nsGkAtoms::exclusion, SVG_FEBLEND_MODE_EXCLUSION},
+  {nsGkAtoms::hue, SVG_FEBLEND_MODE_HUE},
+  {nsGkAtoms::saturation, SVG_FEBLEND_MODE_SATURATION},
+  {nsGkAtoms::color, SVG_FEBLEND_MODE_COLOR},
+  {nsGkAtoms::luminosity, SVG_FEBLEND_MODE_LUMINOSITY},
   {nullptr, 0}
 };
 
 nsSVGElement::EnumInfo SVGFEBlendElement::sEnumInfo[1] =
 {
-  { &nsGkAtoms::mode,
+  { nsGkAtoms::mode,
     sModeMap,
     SVG_FEBLEND_MODE_NORMAL
   }
 };
 
 nsSVGElement::StringInfo SVGFEBlendElement::sStringInfo[3] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true },
-  { &nsGkAtoms::in, kNameSpaceID_None, true },
-  { &nsGkAtoms::in2, kNameSpaceID_None, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true },
+  { nsGkAtoms::in, kNameSpaceID_None, true },
+  { nsGkAtoms::in2, kNameSpaceID_None, true }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEBlendElement)
 
 //----------------------------------------------------------------------
--- a/dom/svg/SVGFEColorMatrixElement.cpp
+++ b/dom/svg/SVGFEColorMatrixElement.cpp
@@ -20,40 +20,40 @@ namespace dom {
 
 JSObject*
 SVGFEColorMatrixElement::WrapNode(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFEColorMatrixElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGEnumMapping SVGFEColorMatrixElement::sTypeMap[] = {
-  {&nsGkAtoms::matrix, SVG_FECOLORMATRIX_TYPE_MATRIX},
-  {&nsGkAtoms::saturate, SVG_FECOLORMATRIX_TYPE_SATURATE},
-  {&nsGkAtoms::hueRotate, SVG_FECOLORMATRIX_TYPE_HUE_ROTATE},
-  {&nsGkAtoms::luminanceToAlpha, SVG_FECOLORMATRIX_TYPE_LUMINANCE_TO_ALPHA},
+  {nsGkAtoms::matrix, SVG_FECOLORMATRIX_TYPE_MATRIX},
+  {nsGkAtoms::saturate, SVG_FECOLORMATRIX_TYPE_SATURATE},
+  {nsGkAtoms::hueRotate, SVG_FECOLORMATRIX_TYPE_HUE_ROTATE},
+  {nsGkAtoms::luminanceToAlpha, SVG_FECOLORMATRIX_TYPE_LUMINANCE_TO_ALPHA},
   {nullptr, 0}
 };
 
 nsSVGElement::EnumInfo SVGFEColorMatrixElement::sEnumInfo[1] =
 {
-  { &nsGkAtoms::type,
+  { nsGkAtoms::type,
     sTypeMap,
     SVG_FECOLORMATRIX_TYPE_MATRIX
   }
 };
 
 nsSVGElement::StringInfo SVGFEColorMatrixElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true },
-  { &nsGkAtoms::in, kNameSpaceID_None, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true },
+  { nsGkAtoms::in, kNameSpaceID_None, true }
 };
 
 nsSVGElement::NumberListInfo SVGFEColorMatrixElement::sNumberListInfo[1] =
 {
-  { &nsGkAtoms::values }
+  { nsGkAtoms::values }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEColorMatrixElement)
 
--- a/dom/svg/SVGFEComponentTransferElement.cpp
+++ b/dom/svg/SVGFEComponentTransferElement.cpp
@@ -20,18 +20,18 @@ namespace dom {
 JSObject*
 SVGFEComponentTransferElement::WrapNode(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFEComponentTransferElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::StringInfo SVGFEComponentTransferElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true },
-  { &nsGkAtoms::in, kNameSpaceID_None, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true },
+  { nsGkAtoms::in, kNameSpaceID_None, true }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEComponentTransferElement)
 
 already_AddRefed<SVGAnimatedString>
--- a/dom/svg/SVGFECompositeElement.cpp
+++ b/dom/svg/SVGFECompositeElement.cpp
@@ -17,45 +17,45 @@ namespace dom {
 JSObject*
 SVGFECompositeElement::WrapNode(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFECompositeElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::NumberInfo SVGFECompositeElement::sNumberInfo[4] =
 {
-  { &nsGkAtoms::k1, 0, false },
-  { &nsGkAtoms::k2, 0, false },
-  { &nsGkAtoms::k3, 0, false },
-  { &nsGkAtoms::k4, 0, false }
+  { nsGkAtoms::k1, 0, false },
+  { nsGkAtoms::k2, 0, false },
+  { nsGkAtoms::k3, 0, false },
+  { nsGkAtoms::k4, 0, false }
 };
 
 nsSVGEnumMapping SVGFECompositeElement::sOperatorMap[] = {
-  {&nsGkAtoms::over, SVG_FECOMPOSITE_OPERATOR_OVER},
-  {&nsGkAtoms::in, SVG_FECOMPOSITE_OPERATOR_IN},
-  {&nsGkAtoms::out, SVG_FECOMPOSITE_OPERATOR_OUT},
-  {&nsGkAtoms::atop, SVG_FECOMPOSITE_OPERATOR_ATOP},
-  {&nsGkAtoms::xor_, SVG_FECOMPOSITE_OPERATOR_XOR},
-  {&nsGkAtoms::arithmetic, SVG_FECOMPOSITE_OPERATOR_ARITHMETIC},
+  {nsGkAtoms::over, SVG_FECOMPOSITE_OPERATOR_OVER},
+  {nsGkAtoms::in, SVG_FECOMPOSITE_OPERATOR_IN},
+  {nsGkAtoms::out, SVG_FECOMPOSITE_OPERATOR_OUT},
+  {nsGkAtoms::atop, SVG_FECOMPOSITE_OPERATOR_ATOP},
+  {nsGkAtoms::xor_, SVG_FECOMPOSITE_OPERATOR_XOR},
+  {nsGkAtoms::arithmetic, SVG_FECOMPOSITE_OPERATOR_ARITHMETIC},
   {nullptr, 0}
 };
 
 nsSVGElement::EnumInfo SVGFECompositeElement::sEnumInfo[1] =
 {
-  { &nsGkAtoms::_operator,
+  { nsGkAtoms::_operator,
     sOperatorMap,
     SVG_FECOMPOSITE_OPERATOR_OVER
   }
 };
 
 nsSVGElement::StringInfo SVGFECompositeElement::sStringInfo[3] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true },
-  { &nsGkAtoms::in, kNameSpaceID_None, true },
-  { &nsGkAtoms::in2, kNameSpaceID_None, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true },
+  { nsGkAtoms::in, kNameSpaceID_None, true },
+  { nsGkAtoms::in2, kNameSpaceID_None, true }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFECompositeElement)
 
 already_AddRefed<SVGAnimatedString>
--- a/dom/svg/SVGFEConvolveMatrixElement.cpp
+++ b/dom/svg/SVGFEConvolveMatrixElement.cpp
@@ -22,65 +22,65 @@ namespace dom {
 JSObject*
 SVGFEConvolveMatrixElement::WrapNode(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFEConvolveMatrixElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::NumberInfo SVGFEConvolveMatrixElement::sNumberInfo[2] =
 {
-  { &nsGkAtoms::divisor, 1, false },
-  { &nsGkAtoms::bias, 0, false }
+  { nsGkAtoms::divisor, 1, false },
+  { nsGkAtoms::bias, 0, false }
 };
 
 nsSVGElement::NumberPairInfo SVGFEConvolveMatrixElement::sNumberPairInfo[1] =
 {
-  { &nsGkAtoms::kernelUnitLength, 0, 0 }
+  { nsGkAtoms::kernelUnitLength, 0, 0 }
 };
 
 nsSVGElement::IntegerInfo SVGFEConvolveMatrixElement::sIntegerInfo[2] =
 {
-  { &nsGkAtoms::targetX, 0 },
-  { &nsGkAtoms::targetY, 0 }
+  { nsGkAtoms::targetX, 0 },
+  { nsGkAtoms::targetY, 0 }
 };
 
 nsSVGElement::IntegerPairInfo SVGFEConvolveMatrixElement::sIntegerPairInfo[1] =
 {
-  { &nsGkAtoms::order, 3, 3 }
+  { nsGkAtoms::order, 3, 3 }
 };
 
 nsSVGElement::BooleanInfo SVGFEConvolveMatrixElement::sBooleanInfo[1] =
 {
-  { &nsGkAtoms::preserveAlpha, false }
+  { nsGkAtoms::preserveAlpha, false }
 };
 
 nsSVGEnumMapping SVGFEConvolveMatrixElement::sEdgeModeMap[] = {
-  {&nsGkAtoms::duplicate, SVG_EDGEMODE_DUPLICATE},
-  {&nsGkAtoms::wrap, SVG_EDGEMODE_WRAP},
-  {&nsGkAtoms::none, SVG_EDGEMODE_NONE},
+  {nsGkAtoms::duplicate, SVG_EDGEMODE_DUPLICATE},
+  {nsGkAtoms::wrap, SVG_EDGEMODE_WRAP},
+  {nsGkAtoms::none, SVG_EDGEMODE_NONE},
   {nullptr, 0}
 };
 
 nsSVGElement::EnumInfo SVGFEConvolveMatrixElement::sEnumInfo[1] =
 {
-  { &nsGkAtoms::edgeMode,
+  { nsGkAtoms::edgeMode,
     sEdgeModeMap,
     SVG_EDGEMODE_DUPLICATE
   }
 };
 
 nsSVGElement::StringInfo SVGFEConvolveMatrixElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true },
-  { &nsGkAtoms::in, kNameSpaceID_None, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true },
+  { nsGkAtoms::in, kNameSpaceID_None, true }
 };
 
 nsSVGElement::NumberListInfo SVGFEConvolveMatrixElement::sNumberListInfo[1] =
 {
-  { &nsGkAtoms::kernelMatrix }
+  { nsGkAtoms::kernelMatrix }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEConvolveMatrixElement)
 
 //----------------------------------------------------------------------
--- a/dom/svg/SVGFEDisplacementMapElement.cpp
+++ b/dom/svg/SVGFEDisplacementMapElement.cpp
@@ -19,44 +19,44 @@ namespace dom {
 JSObject*
 SVGFEDisplacementMapElement::WrapNode(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFEDisplacementMapElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::NumberInfo SVGFEDisplacementMapElement::sNumberInfo[1] =
 {
-  { &nsGkAtoms::scale, 0, false },
+  { nsGkAtoms::scale, 0, false },
 };
 
 nsSVGEnumMapping SVGFEDisplacementMapElement::sChannelMap[] = {
-  {&nsGkAtoms::R, SVG_CHANNEL_R},
-  {&nsGkAtoms::G, SVG_CHANNEL_G},
-  {&nsGkAtoms::B, SVG_CHANNEL_B},
-  {&nsGkAtoms::A, SVG_CHANNEL_A},
+  {nsGkAtoms::R, SVG_CHANNEL_R},
+  {nsGkAtoms::G, SVG_CHANNEL_G},
+  {nsGkAtoms::B, SVG_CHANNEL_B},
+  {nsGkAtoms::A, SVG_CHANNEL_A},
   {nullptr, 0}
 };
 
 nsSVGElement::EnumInfo SVGFEDisplacementMapElement::sEnumInfo[2] =
 {
-  { &nsGkAtoms::xChannelSelector,
+  { nsGkAtoms::xChannelSelector,
     sChannelMap,
     SVG_CHANNEL_A
   },
-  { &nsGkAtoms::yChannelSelector,
+  { nsGkAtoms::yChannelSelector,
     sChannelMap,
     SVG_CHANNEL_A
   }
 };
 
 nsSVGElement::StringInfo SVGFEDisplacementMapElement::sStringInfo[3] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true },
-  { &nsGkAtoms::in, kNameSpaceID_None, true },
-  { &nsGkAtoms::in2, kNameSpaceID_None, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true },
+  { nsGkAtoms::in, kNameSpaceID_None, true },
+  { nsGkAtoms::in2, kNameSpaceID_None, true }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEDisplacementMapElement)
 
 //----------------------------------------------------------------------
--- a/dom/svg/SVGFEDistantLightElement.cpp
+++ b/dom/svg/SVGFEDistantLightElement.cpp
@@ -18,18 +18,18 @@ namespace dom {
 JSObject*
 SVGFEDistantLightElement::WrapNode(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFEDistantLightElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::NumberInfo SVGFEDistantLightElement::sNumberInfo[2] =
 {
-  { &nsGkAtoms::azimuth,   0, false },
-  { &nsGkAtoms::elevation, 0, false }
+  { nsGkAtoms::azimuth,   0, false },
+  { nsGkAtoms::elevation, 0, false }
 };
 
 //----------------------------------------------------------------------
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEDistantLightElement)
 
--- a/dom/svg/SVGFEDropShadowElement.cpp
+++ b/dom/svg/SVGFEDropShadowElement.cpp
@@ -19,29 +19,29 @@ namespace dom {
 JSObject*
 SVGFEDropShadowElement::WrapNode(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFEDropShadowElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::NumberInfo SVGFEDropShadowElement::sNumberInfo[2] =
 {
-  { &nsGkAtoms::dx, 2, false },
-  { &nsGkAtoms::dy, 2, false }
+  { nsGkAtoms::dx, 2, false },
+  { nsGkAtoms::dy, 2, false }
 };
 
 nsSVGElement::NumberPairInfo SVGFEDropShadowElement::sNumberPairInfo[1] =
 {
-  { &nsGkAtoms::stdDeviation, 2, 2 }
+  { nsGkAtoms::stdDeviation, 2, 2 }
 };
 
 nsSVGElement::StringInfo SVGFEDropShadowElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true },
-  { &nsGkAtoms::in, kNameSpaceID_None, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true },
+  { nsGkAtoms::in, kNameSpaceID_None, true }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEDropShadowElement)
 
 //----------------------------------------------------------------------
--- a/dom/svg/SVGFEFloodElement.cpp
+++ b/dom/svg/SVGFEFloodElement.cpp
@@ -21,17 +21,17 @@ namespace dom {
 JSObject*
 SVGFEFloodElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFEFloodElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::StringInfo SVGFEFloodElement::sStringInfo[1] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEFloodElement)
 
 FilterPrimitiveDescription
--- a/dom/svg/SVGFEGaussianBlurElement.cpp
+++ b/dom/svg/SVGFEGaussianBlurElement.cpp
@@ -19,23 +19,23 @@ namespace dom {
 JSObject*
 SVGFEGaussianBlurElement::WrapNode(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFEGaussianBlurElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::NumberPairInfo SVGFEGaussianBlurElement::sNumberPairInfo[1] =
 {
-  { &nsGkAtoms::stdDeviation, 0, 0 }
+  { nsGkAtoms::stdDeviation, 0, 0 }
 };
 
 nsSVGElement::StringInfo SVGFEGaussianBlurElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true },
-  { &nsGkAtoms::in, kNameSpaceID_None, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true },
+  { nsGkAtoms::in, kNameSpaceID_None, true }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEGaussianBlurElement)
 
 //----------------------------------------------------------------------
--- a/dom/svg/SVGFEImageElement.cpp
+++ b/dom/svg/SVGFEImageElement.cpp
@@ -30,19 +30,19 @@ namespace dom {
 JSObject*
 SVGFEImageElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFEImageElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::StringInfo SVGFEImageElement::sStringInfo[3] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true },
-  { &nsGkAtoms::href, kNameSpaceID_None, true },
-  { &nsGkAtoms::href, kNameSpaceID_XLink, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true },
+  { nsGkAtoms::href, kNameSpaceID_None, true },
+  { nsGkAtoms::href, kNameSpaceID_XLink, true }
 };
 
 //----------------------------------------------------------------------
 // nsISupports methods
 
 NS_IMPL_ISUPPORTS_INHERITED(SVGFEImageElement, SVGFEImageElementBase,
                             imgINotificationObserver, nsIImageLoadingContent)
 
--- a/dom/svg/SVGFEMergeElement.cpp
+++ b/dom/svg/SVGFEMergeElement.cpp
@@ -18,17 +18,17 @@ namespace dom {
 JSObject*
 SVGFEMergeElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFEMergeElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::StringInfo SVGFEMergeElement::sStringInfo[1] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true }
 };
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEMergeElement)
 
 FilterPrimitiveDescription
 SVGFEMergeElement::GetPrimitiveDescription(nsSVGFilterInstance* aInstance,
                                            const IntRect& aFilterSubregion,
                                            const nsTArray<bool>& aInputsAreTainted,
--- a/dom/svg/SVGFEMergeNodeElement.cpp
+++ b/dom/svg/SVGFEMergeNodeElement.cpp
@@ -15,17 +15,17 @@ namespace dom {
 JSObject*
 SVGFEMergeNodeElement::WrapNode(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFEMergeNodeElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::StringInfo SVGFEMergeNodeElement::sStringInfo[1] =
 {
-  { &nsGkAtoms::in, kNameSpaceID_None, true }
+  { nsGkAtoms::in, kNameSpaceID_None, true }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEMergeNodeElement)
 
 //----------------------------------------------------------------------
--- a/dom/svg/SVGFEMorphologyElement.cpp
+++ b/dom/svg/SVGFEMorphologyElement.cpp
@@ -18,37 +18,37 @@ namespace dom {
 JSObject*
 SVGFEMorphologyElement::WrapNode(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFEMorphologyElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::NumberPairInfo SVGFEMorphologyElement::sNumberPairInfo[1] =
 {
-  { &nsGkAtoms::radius, 0, 0 }
+  { nsGkAtoms::radius, 0, 0 }
 };
 
 nsSVGEnumMapping SVGFEMorphologyElement::sOperatorMap[] = {
-  {&nsGkAtoms::erode, SVG_OPERATOR_ERODE},
-  {&nsGkAtoms::dilate, SVG_OPERATOR_DILATE},
+  {nsGkAtoms::erode, SVG_OPERATOR_ERODE},
+  {nsGkAtoms::dilate, SVG_OPERATOR_DILATE},
   {nullptr, 0}
 };
 
 nsSVGElement::EnumInfo SVGFEMorphologyElement::sEnumInfo[1] =
 {
-  { &nsGkAtoms::_operator,
+  { nsGkAtoms::_operator,
     sOperatorMap,
     SVG_OPERATOR_ERODE
   }
 };
 
 nsSVGElement::StringInfo SVGFEMorphologyElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true },
-  { &nsGkAtoms::in, kNameSpaceID_None, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true },
+  { nsGkAtoms::in, kNameSpaceID_None, true }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEMorphologyElement)
 
--- a/dom/svg/SVGFEOffsetElement.cpp
+++ b/dom/svg/SVGFEOffsetElement.cpp
@@ -18,24 +18,24 @@ namespace dom {
 JSObject*
 SVGFEOffsetElement::WrapNode(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFEOffsetElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::NumberInfo SVGFEOffsetElement::sNumberInfo[2] =
 {
-  { &nsGkAtoms::dx, 0, false },
-  { &nsGkAtoms::dy, 0, false }
+  { nsGkAtoms::dx, 0, false },
+  { nsGkAtoms::dy, 0, false }
 };
 
 nsSVGElement::StringInfo SVGFEOffsetElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true },
-  { &nsGkAtoms::in, kNameSpaceID_None, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true },
+  { nsGkAtoms::in, kNameSpaceID_None, true }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEOffsetElement)
 
--- a/dom/svg/SVGFEPointLightElement.cpp
+++ b/dom/svg/SVGFEPointLightElement.cpp
@@ -18,19 +18,19 @@ namespace dom {
 JSObject*
 SVGFEPointLightElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFEPointLightElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::NumberInfo SVGFEPointLightElement::sNumberInfo[3] =
 {
-  { &nsGkAtoms::x, 0, false },
-  { &nsGkAtoms::y, 0, false },
-  { &nsGkAtoms::z, 0, false }
+  { nsGkAtoms::x, 0, false },
+  { nsGkAtoms::y, 0, false },
+  { nsGkAtoms::z, 0, false }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEPointLightElement)
 
 //----------------------------------------------------------------------
--- a/dom/svg/SVGFESpotLightElement.cpp
+++ b/dom/svg/SVGFESpotLightElement.cpp
@@ -18,24 +18,24 @@ namespace dom {
 JSObject*
 SVGFESpotLightElement::WrapNode(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFESpotLightElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::NumberInfo SVGFESpotLightElement::sNumberInfo[8] =
 {
-  { &nsGkAtoms::x, 0, false },
-  { &nsGkAtoms::y, 0, false },
-  { &nsGkAtoms::z, 0, false },
-  { &nsGkAtoms::pointsAtX, 0, false },
-  { &nsGkAtoms::pointsAtY, 0, false },
-  { &nsGkAtoms::pointsAtZ, 0, false },
-  { &nsGkAtoms::specularExponent, 1, false },
-  { &nsGkAtoms::limitingConeAngle, 0, false }
+  { nsGkAtoms::x, 0, false },
+  { nsGkAtoms::y, 0, false },
+  { nsGkAtoms::z, 0, false },
+  { nsGkAtoms::pointsAtX, 0, false },
+  { nsGkAtoms::pointsAtY, 0, false },
+  { nsGkAtoms::pointsAtZ, 0, false },
+  { nsGkAtoms::specularExponent, 1, false },
+  { nsGkAtoms::limitingConeAngle, 0, false }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFESpotLightElement)
 
 //----------------------------------------------------------------------
--- a/dom/svg/SVGFETileElement.cpp
+++ b/dom/svg/SVGFETileElement.cpp
@@ -18,18 +18,18 @@ namespace dom {
 JSObject*
 SVGFETileElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFETileElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::StringInfo SVGFETileElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true },
-  { &nsGkAtoms::in, kNameSpaceID_None, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true },
+  { nsGkAtoms::in, kNameSpaceID_None, true }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFETileElement)
 
--- a/dom/svg/SVGFETurbulenceElement.cpp
+++ b/dom/svg/SVGFETurbulenceElement.cpp
@@ -25,60 +25,60 @@ static const int32_t MAX_OCTAVES = 10;
 JSObject*
 SVGFETurbulenceElement::WrapNode(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFETurbulenceElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::NumberInfo SVGFETurbulenceElement::sNumberInfo[1] =
 {
-  { &nsGkAtoms::seed, 0, false }
+  { nsGkAtoms::seed, 0, false }
 };
 
 nsSVGElement::NumberPairInfo SVGFETurbulenceElement::sNumberPairInfo[1] =
 {
-  { &nsGkAtoms::baseFrequency, 0, 0 }
+  { nsGkAtoms::baseFrequency, 0, 0 }
 };
 
 nsSVGElement::IntegerInfo SVGFETurbulenceElement::sIntegerInfo[1] =
 {
-  { &nsGkAtoms::numOctaves, 1 }
+  { nsGkAtoms::numOctaves, 1 }
 };
 
 nsSVGEnumMapping SVGFETurbulenceElement::sTypeMap[] = {
-  {&nsGkAtoms::fractalNoise,
+  {nsGkAtoms::fractalNoise,
    SVG_TURBULENCE_TYPE_FRACTALNOISE},
-  {&nsGkAtoms::turbulence,
+  {nsGkAtoms::turbulence,
    SVG_TURBULENCE_TYPE_TURBULENCE},
   {nullptr, 0}
 };
 
 nsSVGEnumMapping SVGFETurbulenceElement::sStitchTilesMap[] = {
-  {&nsGkAtoms::stitch,
+  {nsGkAtoms::stitch,
    SVG_STITCHTYPE_STITCH},
-  {&nsGkAtoms::noStitch,
+  {nsGkAtoms::noStitch,
    SVG_STITCHTYPE_NOSTITCH},
   {nullptr, 0}
 };
 
 nsSVGElement::EnumInfo SVGFETurbulenceElement::sEnumInfo[2] =
 {
-  { &nsGkAtoms::type,
+  { nsGkAtoms::type,
     sTypeMap,
     SVG_TURBULENCE_TYPE_TURBULENCE
   },
-  { &nsGkAtoms::stitchTiles,
+  { nsGkAtoms::stitchTiles,
     sStitchTilesMap,
     SVG_STITCHTYPE_NOSTITCH
   }
 };
 
 nsSVGElement::StringInfo SVGFETurbulenceElement::sStringInfo[1] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true }
 };
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFETurbulenceElement)
 
 //----------------------------------------------------------------------
--- a/dom/svg/SVGFilterElement.cpp
+++ b/dom/svg/SVGFilterElement.cpp
@@ -26,38 +26,38 @@ using namespace SVGUnitTypes_Binding;
 JSObject*
 SVGFilterElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGFilterElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::LengthInfo SVGFilterElement::sLengthInfo[4] =
 {
-  { &nsGkAtoms::x, -10, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
-  { &nsGkAtoms::y, -10, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
-  { &nsGkAtoms::width, 120, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
-  { &nsGkAtoms::height, 120, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
+  { nsGkAtoms::x, -10, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
+  { nsGkAtoms::y, -10, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
+  { nsGkAtoms::width, 120, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
+  { nsGkAtoms::height, 120, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
 };
 
 nsSVGElement::EnumInfo SVGFilterElement::sEnumInfo[2] =
 {
-  { &nsGkAtoms::filterUnits,
+  { nsGkAtoms::filterUnits,
     sSVGUnitTypesMap,
     SVG_UNIT_TYPE_OBJECTBOUNDINGBOX
   },
-  { &nsGkAtoms::primitiveUnits,
+  { nsGkAtoms::primitiveUnits,
     sSVGUnitTypesMap,
     SVG_UNIT_TYPE_USERSPACEONUSE
   }
 };
 
 nsSVGElement::StringInfo SVGFilterElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::href, kNameSpaceID_None, true },
-  { &nsGkAtoms::href, kNameSpaceID_XLink, true }
+  { nsGkAtoms::href, kNameSpaceID_None, true },
+  { nsGkAtoms::href, kNameSpaceID_XLink, true }
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
 SVGFilterElement::SVGFilterElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
   : SVGFilterElementBase(std::move(aNodeInfo))
 {
--- a/dom/svg/SVGForeignObjectElement.cpp
+++ b/dom/svg/SVGForeignObjectElement.cpp
@@ -20,20 +20,20 @@ namespace dom {
 JSObject*
 SVGForeignObjectElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGForeignObjectElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::LengthInfo SVGForeignObjectElement::sLengthInfo[4] =
 {
-  { &nsGkAtoms::x, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::y, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
-  { &nsGkAtoms::width, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::height, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::x, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::y, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::width, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::height, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
 SVGForeignObjectElement::SVGForeignObjectElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
   : SVGGraphicsElement(std::move(aNodeInfo))
 {
--- a/dom/svg/SVGGeometryElement.cpp
+++ b/dom/svg/SVGGeometryElement.cpp
@@ -15,17 +15,17 @@
 #include "nsSVGLength2.h"
 #include "SVGContentUtils.h"
 
 using namespace mozilla;
 using namespace mozilla::gfx;
 using namespace mozilla::dom;
 
 nsSVGElement::NumberInfo SVGGeometryElement::sNumberInfo =
-{ &nsGkAtoms::pathLength, 0, false };
+{ nsGkAtoms::pathLength, 0, false };
 
 //----------------------------------------------------------------------
 // Implementation
 
 SVGGeometryElement::SVGGeometryElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
   : SVGGeometryElementBase(std::move(aNodeInfo))
 {
 }
@@ -65,17 +65,17 @@ SVGGeometryElement::AttributeDefinesGeom
 {
   if (aName == nsGkAtoms::pathLength) {
     return true;
   }
 
   // Check for nsSVGLength2 attribute
   LengthAttributesInfo info = GetLengthInfo();
   for (uint32_t i = 0; i < info.mLengthCount; i++) {
-    if (aName == *info.mLengthInfo[i].mName) {
+    if (aName == info.mLengthInfo[i].mName) {
       return true;
     }
   }
 
   return false;
 }
 
 bool
--- a/dom/svg/SVGGradientElement.cpp
+++ b/dom/svg/SVGGradientElement.cpp
@@ -24,38 +24,38 @@ namespace mozilla {
 namespace dom {
 
 using namespace SVGGradientElement_Binding;
 using namespace SVGUnitTypes_Binding;
 
 //--------------------- Gradients------------------------
 
 nsSVGEnumMapping SVGGradientElement::sSpreadMethodMap[] = {
-  {&nsGkAtoms::pad, SVG_SPREADMETHOD_PAD},
-  {&nsGkAtoms::reflect, SVG_SPREADMETHOD_REFLECT},
-  {&nsGkAtoms::repeat, SVG_SPREADMETHOD_REPEAT},
+  {nsGkAtoms::pad, SVG_SPREADMETHOD_PAD},
+  {nsGkAtoms::reflect, SVG_SPREADMETHOD_REFLECT},
+  {nsGkAtoms::repeat, SVG_SPREADMETHOD_REPEAT},
   {nullptr, 0}
 };
 
 nsSVGElement::EnumInfo SVGGradientElement::sEnumInfo[2] =
 {
-  { &nsGkAtoms::gradientUnits,
+  { nsGkAtoms::gradientUnits,
     sSVGUnitTypesMap,
     SVG_UNIT_TYPE_OBJECTBOUNDINGBOX
   },
-  { &nsGkAtoms::spreadMethod,
+  { nsGkAtoms::spreadMethod,
     sSpreadMethodMap,
     SVG_SPREADMETHOD_PAD
   }
 };
 
 nsSVGElement::StringInfo SVGGradientElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::href, kNameSpaceID_None, true },
-  { &nsGkAtoms::href, kNameSpaceID_XLink, true }
+  { nsGkAtoms::href, kNameSpaceID_None, true },
+  { nsGkAtoms::href, kNameSpaceID_XLink, true }
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
 SVGGradientElement::SVGGradientElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
   : SVGGradientElementBase(std::move(aNodeInfo))
 {
@@ -127,20 +127,20 @@ SVGGradientElement::IsAttributeMapped(co
 JSObject*
 SVGLinearGradientElement::WrapNode(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGLinearGradientElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::LengthInfo SVGLinearGradientElement::sLengthInfo[4] =
 {
-  { &nsGkAtoms::x1, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
-  { &nsGkAtoms::y1, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
-  { &nsGkAtoms::x2, 100, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
-  { &nsGkAtoms::y2, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
+  { nsGkAtoms::x1, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
+  { nsGkAtoms::y1, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
+  { nsGkAtoms::x2, 100, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
+  { nsGkAtoms::y2, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
 SVGLinearGradientElement::SVGLinearGradientElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
   : SVGLinearGradientElementBase(std::move(aNodeInfo))
 {
@@ -201,22 +201,22 @@ SVGLinearGradientElement::GetLengthInfo(
 JSObject*
 SVGRadialGradientElement::WrapNode(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGRadialGradientElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::LengthInfo SVGRadialGradientElement::sLengthInfo[6] =
 {
-  { &nsGkAtoms::cx, 50, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
-  { &nsGkAtoms::cy, 50, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
-  { &nsGkAtoms::r, 50, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::XY },
-  { &nsGkAtoms::fx, 50, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
-  { &nsGkAtoms::fy, 50, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
-  { &nsGkAtoms::fr, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::XY },
+  { nsGkAtoms::cx, 50, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
+  { nsGkAtoms::cy, 50, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
+  { nsGkAtoms::r, 50, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::XY },
+  { nsGkAtoms::fx, 50, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
+  { nsGkAtoms::fy, 50, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
+  { nsGkAtoms::fr, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::XY },
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
 SVGRadialGradientElement::SVGRadialGradientElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
   : SVGRadialGradientElementBase(std::move(aNodeInfo))
 {
--- a/dom/svg/SVGGradientElement.h
+++ b/dom/svg/SVGGradientElement.h
@@ -45,17 +45,17 @@ protected:
 public:
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override = 0;
 
   // nsIContent
   NS_IMETHOD_(bool) IsAttributeMapped(const nsAtom* aAttribute) const override;
 
   virtual nsSVGAnimatedTransformList*
     GetAnimatedTransformList(uint32_t aFlags = 0) override;
-  virtual nsAtom* GetTransformListAttrName() const override {
+  virtual nsStaticAtom* GetTransformListAttrName() const override {
     return nsGkAtoms::gradientTransform;
   }
 
   // WebIDL
   already_AddRefed<SVGAnimatedEnumeration> GradientUnits();
   already_AddRefed<SVGAnimatedTransformList> GradientTransform();
   already_AddRefed<SVGAnimatedEnumeration> SpreadMethod();
   already_AddRefed<SVGAnimatedString> Href();
--- a/dom/svg/SVGImageElement.cpp
+++ b/dom/svg/SVGImageElement.cpp
@@ -28,26 +28,26 @@ namespace dom {
 JSObject*
 SVGImageElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGImageElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::LengthInfo SVGImageElement::sLengthInfo[4] =
 {
-  { &nsGkAtoms::x, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::y, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
-  { &nsGkAtoms::width, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::height, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::x, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::y, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::width, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::height, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
 };
 
 nsSVGElement::StringInfo SVGImageElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::href, kNameSpaceID_None, true },
-  { &nsGkAtoms::href, kNameSpaceID_XLink, true }
+  { nsGkAtoms::href, kNameSpaceID_None, true },
+  { nsGkAtoms::href, kNameSpaceID_XLink, true }
 };
 
 //----------------------------------------------------------------------
 // nsISupports methods
 
 NS_IMPL_ISUPPORTS_INHERITED(SVGImageElement, SVGImageElementBase,
                             imgINotificationObserver,
                             nsIImageLoadingContent)
--- a/dom/svg/SVGLength.cpp
+++ b/dom/svg/SVGLength.cpp
@@ -181,37 +181,37 @@ SVGLength::GetUserUnitsPerPercent(const 
     }
   }
   return std::numeric_limits<float>::quiet_NaN();
 }
 
 // Helpers:
 
 // These items must be at the same index as the SVGLength constants!
-static nsStaticAtom** const unitMap[] =
+static const nsStaticAtom* const unitMap[] =
 {
   nullptr, /* SVG_LENGTHTYPE_UNKNOWN */
   nullptr, /* SVG_LENGTHTYPE_NUMBER */
-  &nsGkAtoms::percentage,
-  &nsGkAtoms::em,
-  &nsGkAtoms::ex,
-  &nsGkAtoms::px,
-  &nsGkAtoms::cm,
-  &nsGkAtoms::mm,
-  &nsGkAtoms::in,
-  &nsGkAtoms::pt,
-  &nsGkAtoms::pc
+  nsGkAtoms::percentage,
+  nsGkAtoms::em,
+  nsGkAtoms::ex,
+  nsGkAtoms::px,
+  nsGkAtoms::cm,
+  nsGkAtoms::mm,
+  nsGkAtoms::in,
+  nsGkAtoms::pt,
+  nsGkAtoms::pc
 };
 
 static void
 GetUnitString(nsAString& unit, uint16_t unitType)
 {
   if (SVGLength::IsValidUnitType(unitType)) {
     if (unitMap[unitType]) {
-      (*unitMap[unitType])->ToString(unit);
+      unitMap[unitType]->ToString(unit);
     }
     return;
   }
   MOZ_ASSERT_UNREACHABLE("Unknown unit type! Someone's using an SVGLength "
                          "with an invalid unit?");
 }
 
 static uint16_t
@@ -219,17 +219,17 @@ GetUnitTypeForString(const nsAString& un
 {
   if (unitStr.IsEmpty())
     return SVGLength_Binding::SVG_LENGTHTYPE_NUMBER;
 
   nsAtom* unitAtom = NS_GetStaticAtom(unitStr);
 
   if (unitAtom) {
     for (uint32_t i = 1 ; i < ArrayLength(unitMap) ; i++) {
-      if (unitMap[i] && *unitMap[i] == unitAtom) {
+      if (unitMap[i] == unitAtom) {
         return i;
       }
     }
   }
   return SVGLength_Binding::SVG_LENGTHTYPE_UNKNOWN;
 }
 
 } // namespace mozilla
--- a/dom/svg/SVGLineElement.cpp
+++ b/dom/svg/SVGLineElement.cpp
@@ -19,20 +19,20 @@ namespace dom {
 JSObject*
 SVGLineElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGLineElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::LengthInfo SVGLineElement::sLengthInfo[4] =
 {
-  { &nsGkAtoms::x1, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::y1, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
-  { &nsGkAtoms::x2, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::y2, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::x1, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::y1, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::x2, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::y2, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
 SVGLineElement::SVGLineElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
   : SVGLineElementBase(std::move(aNodeInfo))
 {
--- a/dom/svg/SVGMPathElement.cpp
+++ b/dom/svg/SVGMPathElement.cpp
@@ -22,18 +22,18 @@ namespace dom {
 JSObject*
 SVGMPathElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGMPathElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::StringInfo SVGMPathElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::href, kNameSpaceID_None, false },
-  { &nsGkAtoms::href, kNameSpaceID_XLink, false }
+  { nsGkAtoms::href, kNameSpaceID_None, false },
+  { nsGkAtoms::href, kNameSpaceID_XLink, false }
 };
 
 // Cycle collection magic -- based on SVGUseElement
 NS_IMPL_CYCLE_COLLECTION_CLASS(SVGMPathElement)
 
 NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN_INHERITED(SVGMPathElement,
                                                 SVGMPathElementBase)
   tmp->UnlinkHrefTarget(false);
--- a/dom/svg/SVGMarkerElement.cpp
+++ b/dom/svg/SVGMarkerElement.cpp
@@ -31,39 +31,39 @@ using namespace SVGAngle_Binding;
 JSObject*
 SVGMarkerElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGMarkerElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::LengthInfo SVGMarkerElement::sLengthInfo[4] =
 {
-  { &nsGkAtoms::refX, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::refY, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
-  { &nsGkAtoms::markerWidth, 3, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::markerHeight, 3, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::refX, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::refY, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::markerWidth, 3, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::markerHeight, 3, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
 };
 
 nsSVGEnumMapping SVGMarkerElement::sUnitsMap[] = {
-  {&nsGkAtoms::strokeWidth, SVG_MARKERUNITS_STROKEWIDTH},
-  {&nsGkAtoms::userSpaceOnUse, SVG_MARKERUNITS_USERSPACEONUSE},
+  {nsGkAtoms::strokeWidth, SVG_MARKERUNITS_STROKEWIDTH},
+  {nsGkAtoms::userSpaceOnUse, SVG_MARKERUNITS_USERSPACEONUSE},
   {nullptr, 0}
 };
 
 nsSVGElement::EnumInfo SVGMarkerElement::sEnumInfo[1] =
 {
-  { &nsGkAtoms::markerUnits,
+  { nsGkAtoms::markerUnits,
     sUnitsMap,
     SVG_MARKERUNITS_STROKEWIDTH
   }
 };
 
 nsSVGElement::AngleInfo SVGMarkerElement::sAngleInfo[1] =
 {
-  { &nsGkAtoms::orient, 0, SVG_ANGLETYPE_UNSPECIFIED }
+  { nsGkAtoms::orient, 0, SVG_ANGLETYPE_UNSPECIFIED }
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
 nsresult
 nsSVGOrientType::SetBaseValue(uint16_t aValue,
                               nsSVGElement *aSVGElement)
--- a/dom/svg/SVGMaskElement.cpp
+++ b/dom/svg/SVGMaskElement.cpp
@@ -25,29 +25,29 @@ SVGMaskElement::WrapNode(JSContext *aCx,
 {
   return SVGMaskElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 //--------------------- Masks ------------------------
 
 nsSVGElement::LengthInfo SVGMaskElement::sLengthInfo[4] =
 {
-  { &nsGkAtoms::x, -10, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
-  { &nsGkAtoms::y, -10, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
-  { &nsGkAtoms::width, 120, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
-  { &nsGkAtoms::height, 120, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
+  { nsGkAtoms::x, -10, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
+  { nsGkAtoms::y, -10, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
+  { nsGkAtoms::width, 120, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
+  { nsGkAtoms::height, 120, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
 };
 
 nsSVGElement::EnumInfo SVGMaskElement::sEnumInfo[2] =
 {
-  { &nsGkAtoms::maskUnits,
+  { nsGkAtoms::maskUnits,
     sSVGUnitTypesMap,
     SVG_UNIT_TYPE_OBJECTBOUNDINGBOX
   },
-  { &nsGkAtoms::maskContentUnits,
+  { nsGkAtoms::maskContentUnits,
     sSVGUnitTypesMap,
     SVG_UNIT_TYPE_USERSPACEONUSE
   }
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
--- a/dom/svg/SVGPathElement.h
+++ b/dom/svg/SVGPathElement.h
@@ -58,17 +58,17 @@ public:
 
   // nsIContent interface
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   virtual SVGAnimatedPathSegList* GetAnimPathSegList() override {
     return &mD;
   }
 
-  virtual nsAtom* GetPathDataAttrName() const override {
+  virtual nsStaticAtom* GetPathDataAttrName() const override {
     return nsGkAtoms::d;
   }
 
   // WebIDL
   uint32_t GetPathSegAtLength(float distance);
   already_AddRefed<DOMSVGPathSegClosePath> CreateSVGPathSegClosePath();
   already_AddRefed<DOMSVGPathSegMovetoAbs> CreateSVGPathSegMovetoAbs(float x, float y);
   already_AddRefed<DOMSVGPathSegMovetoRel> CreateSVGPathSegMovetoRel(float x, float y);
--- a/dom/svg/SVGPatternElement.cpp
+++ b/dom/svg/SVGPatternElement.cpp
@@ -26,38 +26,38 @@ SVGPatternElement::WrapNode(JSContext *a
 {
   return SVGPatternElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 //--------------------- Patterns ------------------------
 
 nsSVGElement::LengthInfo SVGPatternElement::sLengthInfo[4] =
 {
-  { &nsGkAtoms::x, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
-  { &nsGkAtoms::y, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
-  { &nsGkAtoms::width, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
-  { &nsGkAtoms::height, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
+  { nsGkAtoms::x, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
+  { nsGkAtoms::y, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
+  { nsGkAtoms::width, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
+  { nsGkAtoms::height, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
 };
 
 nsSVGElement::EnumInfo SVGPatternElement::sEnumInfo[2] =
 {
-  { &nsGkAtoms::patternUnits,
+  { nsGkAtoms::patternUnits,
     sSVGUnitTypesMap,
     SVG_UNIT_TYPE_OBJECTBOUNDINGBOX
   },
-  { &nsGkAtoms::patternContentUnits,
+  { nsGkAtoms::patternContentUnits,
     sSVGUnitTypesMap,
     SVG_UNIT_TYPE_USERSPACEONUSE
   }
 };
 
 nsSVGElement::StringInfo SVGPatternElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::href, kNameSpaceID_None, true },
-  { &nsGkAtoms::href, kNameSpaceID_XLink, true }
+  { nsGkAtoms::href, kNameSpaceID_None, true },
+  { nsGkAtoms::href, kNameSpaceID_XLink, true }
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
 SVGPatternElement::SVGPatternElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
   : SVGPatternElementBase(std::move(aNodeInfo))
 {
--- a/dom/svg/SVGPatternElement.h
+++ b/dom/svg/SVGPatternElement.h
@@ -45,17 +45,17 @@ public:
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // nsSVGSVGElement methods:
   virtual bool HasValidDimensions() const override;
 
   virtual mozilla::nsSVGAnimatedTransformList*
     GetAnimatedTransformList(uint32_t aFlags = 0) override;
-  virtual nsAtom* GetTransformListAttrName() const override {
+  virtual nsStaticAtom* GetTransformListAttrName() const override {
     return nsGkAtoms::patternTransform;
   }
 
   // WebIDL
   already_AddRefed<SVGAnimatedRect> ViewBox();
   already_AddRefed<DOMSVGAnimatedPreserveAspectRatio> PreserveAspectRatio();
   already_AddRefed<SVGAnimatedEnumeration> PatternUnits();
   already_AddRefed<SVGAnimatedEnumeration> PatternContentUnits();
--- a/dom/svg/SVGPolyElement.h
+++ b/dom/svg/SVGPolyElement.h
@@ -31,17 +31,17 @@ public:
   NS_INLINE_DECL_REFCOUNTING_INHERITED(SVGPolyElement, SVGPolyElementBase)
 
   // nsIContent interface
   NS_IMETHOD_(bool) IsAttributeMapped(const nsAtom* name) const override;
 
   virtual SVGAnimatedPointList* GetAnimatedPointList() override {
     return &mPoints;
   }
-  virtual nsAtom* GetPointListAttrName() const override {
+  virtual nsStaticAtom* GetPointListAttrName() const override {
     return nsGkAtoms::points;
   }
 
   // nsSVGElement methods:
   virtual bool HasValidDimensions() const override;
 
   // SVGGeometryElement methods:
   virtual bool AttributeDefinesGeometry(const nsAtom *aName) override;
--- a/dom/svg/SVGRectElement.cpp
+++ b/dom/svg/SVGRectElement.cpp
@@ -26,22 +26,22 @@ class SVGAnimatedLength;
 JSObject*
 SVGRectElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGRectElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::LengthInfo SVGRectElement::sLengthInfo[6] =
 {
-  { &nsGkAtoms::x, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::y, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
-  { &nsGkAtoms::width, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::height, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
-  { &nsGkAtoms::rx, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::ry, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y }
+  { nsGkAtoms::x, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::y, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::width, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::height, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::rx, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::ry, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y }
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
 SVGRectElement::SVGRectElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
   : SVGRectElementBase(std::move(aNodeInfo))
 {
--- a/dom/svg/SVGSVGElement.cpp
+++ b/dom/svg/SVGSVGElement.cpp
@@ -31,24 +31,24 @@ using namespace mozilla::gfx;
 
 namespace mozilla {
 namespace dom {
 
 using namespace SVGPreserveAspectRatio_Binding;
 using namespace SVGSVGElement_Binding;
 
 nsSVGEnumMapping SVGSVGElement::sZoomAndPanMap[] = {
-  {&nsGkAtoms::disable, SVG_ZOOMANDPAN_DISABLE},
-  {&nsGkAtoms::magnify, SVG_ZOOMANDPAN_MAGNIFY},
+  {nsGkAtoms::disable, SVG_ZOOMANDPAN_DISABLE},
+  {nsGkAtoms::magnify, SVG_ZOOMANDPAN_MAGNIFY},
   {nullptr, 0}
 };
 
 nsSVGElement::EnumInfo SVGSVGElement::sEnumInfo[1] =
 {
-  { &nsGkAtoms::zoomAndPan,
+  { nsGkAtoms::zoomAndPan,
     sZoomAndPanMap,
     SVG_ZOOMANDPAN_MAGNIFY
   }
 };
 
 NS_IMPL_CYCLE_COLLECTION_INHERITED(DOMSVGTranslatePoint, nsISVGPoint,
                                    mElement)
 
--- a/dom/svg/SVGScriptElement.cpp
+++ b/dom/svg/SVGScriptElement.cpp
@@ -19,18 +19,18 @@ namespace dom {
 JSObject*
 SVGScriptElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGScriptElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::StringInfo SVGScriptElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::href, kNameSpaceID_None, false },
-  { &nsGkAtoms::href, kNameSpaceID_XLink, false }
+  { nsGkAtoms::href, kNameSpaceID_None, false },
+  { nsGkAtoms::href, kNameSpaceID_XLink, false }
 };
 
 //----------------------------------------------------------------------
 // nsISupports methods
 
 NS_IMPL_ISUPPORTS_INHERITED(SVGScriptElement, SVGScriptElementBase,
                             nsIScriptLoaderObserver,
                             nsIScriptElement, nsIMutationObserver)
--- a/dom/svg/SVGStopElement.cpp
+++ b/dom/svg/SVGStopElement.cpp
@@ -14,17 +14,17 @@ namespace dom {
 
 JSObject*
 SVGStopElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGStopElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::NumberInfo SVGStopElement::sNumberInfo =
-{ &nsGkAtoms::offset, 0, true };
+{ nsGkAtoms::offset, 0, true };
 
 //----------------------------------------------------------------------
 // Implementation
 
 SVGStopElement::SVGStopElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
   : SVGStopElementBase(std::move(aNodeInfo))
 {
 }
--- a/dom/svg/SVGTests.cpp
+++ b/dom/svg/SVGTests.cpp
@@ -10,21 +10,21 @@
 #include "mozilla/dom/SVGSwitchElement.h"
 #include "nsCharSeparatedTokenizer.h"
 #include "nsStyleUtil.h"
 #include "mozilla/Preferences.h"
 
 namespace mozilla {
 namespace dom {
 
-nsStaticAtom** SVGTests::sStringListNames[3] =
+nsStaticAtom* const SVGTests::sStringListNames[3] =
 {
-  &nsGkAtoms::requiredFeatures,
-  &nsGkAtoms::requiredExtensions,
-  &nsGkAtoms::systemLanguage,
+  nsGkAtoms::requiredFeatures,
+  nsGkAtoms::requiredExtensions,
+  nsGkAtoms::systemLanguage,
 };
 
 SVGTests::SVGTests()
 {
   mStringListAttributes[LANGUAGE].SetIsCommaSeparated(true);
 }
 
 already_AddRefed<DOMSVGStringList>
@@ -54,17 +54,17 @@ SVGTests::HasExtension(const nsAString& 
   return nsSVGFeatures::HasExtension(aExtension,
                                      AsSVGElement()->IsInChromeDocument());
 }
 
 bool
 SVGTests::IsConditionalProcessingAttribute(const nsAtom* aAttribute) const
 {
   for (uint32_t i = 0; i < ArrayLength(sStringListNames); i++) {
-    if (aAttribute == *sStringListNames[i]) {
+    if (aAttribute == sStringListNames[i]) {
       return true;
     }
   }
   return false;
 }
 
 int32_t
 SVGTests::GetBestLanguagePreferenceRank(const nsAString& aAcceptLangs) const
@@ -175,44 +175,44 @@ SVGTests::PassesConditionalProcessingTes
 }
 
 bool
 SVGTests::ParseConditionalProcessingAttribute(nsAtom* aAttribute,
                                               const nsAString& aValue,
                                               nsAttrValue& aResult)
 {
   for (uint32_t i = 0; i < ArrayLength(sStringListNames); i++) {
-    if (aAttribute == *sStringListNames[i]) {
+    if (aAttribute == sStringListNames[i]) {
       nsresult rv = mStringListAttributes[i].SetValue(aValue);
       if (NS_FAILED(rv)) {
         mStringListAttributes[i].Clear();
       }
       MaybeInvalidate();
       return true;
     }
   }
   return false;
 }
 
 void
 SVGTests::UnsetAttr(const nsAtom* aAttribute)
 {
   for (uint32_t i = 0; i < ArrayLength(sStringListNames); i++) {
-    if (aAttribute == *sStringListNames[i]) {
+    if (aAttribute == sStringListNames[i]) {
       mStringListAttributes[i].Clear();
       MaybeInvalidate();
       return;
     }
   }
 }
 
-nsAtom*
+nsStaticAtom*
 SVGTests::GetAttrName(uint8_t aAttrEnum) const
 {
-  return *sStringListNames[aAttrEnum];
+  return sStringListNames[aAttrEnum];
 }
 
 void
 SVGTests::GetAttrValue(uint8_t aAttrEnum, nsAttrValue& aValue) const
 {
   MOZ_ASSERT(aAttrEnum < ArrayLength(sStringListNames),
              "aAttrEnum out of range");
   aValue.SetTo(mStringListAttributes[aAttrEnum], nullptr);
--- a/dom/svg/SVGTests.h
+++ b/dom/svg/SVGTests.h
@@ -80,17 +80,17 @@ public:
          const nsAString& aValue,
          nsAttrValue& aResult);
 
   /**
    * Unsets a conditional processing attribute.
    */
   void UnsetAttr(const nsAtom* aAttribute);
 
-  nsAtom* GetAttrName(uint8_t aAttrEnum) const;
+  nsStaticAtom* GetAttrName(uint8_t aAttrEnum) const;
   void GetAttrValue(uint8_t aAttrEnum, nsAttrValue &aValue) const;
 
   void MaybeInvalidate();
 
   // WebIDL
   already_AddRefed<DOMSVGStringList> RequiredFeatures();
   already_AddRefed<DOMSVGStringList> RequiredExtensions();
   already_AddRefed<DOMSVGStringList> SystemLanguage();
@@ -104,17 +104,17 @@ public:
   }
 
 protected:
   virtual ~SVGTests() {}
 
 private:
   enum { FEATURES, EXTENSIONS, LANGUAGE };
   SVGStringList mStringListAttributes[3];
-  static nsStaticAtom** sStringListNames[3];
+  static nsStaticAtom* const sStringListNames[3];
 };
 
 NS_DEFINE_STATIC_IID_ACCESSOR(SVGTests, MOZILLA_DOMSVGTESTS_IID)
 
 } // namespace dom
 } // namespace mozilla
 
 #endif // mozilla_dom_SVGTests_h
--- a/dom/svg/SVGTextContentElement.cpp
+++ b/dom/svg/SVGTextContentElement.cpp
@@ -17,29 +17,29 @@
 #include "SVGTextFrame.h"
 
 namespace mozilla {
 namespace dom {
 
 using namespace SVGTextContentElement_Binding;
 
 nsSVGEnumMapping SVGTextContentElement::sLengthAdjustMap[] = {
-  { &nsGkAtoms::spacing, LENGTHADJUST_SPACING },
-  { &nsGkAtoms::spacingAndGlyphs, LENGTHADJUST_SPACINGANDGLYPHS },
+  { nsGkAtoms::spacing, LENGTHADJUST_SPACING },
+  { nsGkAtoms::spacingAndGlyphs, LENGTHADJUST_SPACINGANDGLYPHS },
   { nullptr, 0 }
 };
 
 nsSVGElement::EnumInfo SVGTextContentElement::sEnumInfo[1] =
 {
-  { &nsGkAtoms::lengthAdjust, sLengthAdjustMap, LENGTHADJUST_SPACING }
+  { nsGkAtoms::lengthAdjust, sLengthAdjustMap, LENGTHADJUST_SPACING }
 };
 
 nsSVGElement::LengthInfo SVGTextContentElement::sLengthInfo[1] =
 {
-  { &nsGkAtoms::textLength, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::XY }
+  { nsGkAtoms::textLength, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::XY }
 };
 
 SVGTextFrame*
 SVGTextContentElement::GetSVGTextFrame()
 {
   nsIFrame* frame = GetPrimaryFrame(FlushType::Layout);
   nsIFrame* textFrame =
     nsLayoutUtils::GetClosestFrameOfType(frame, LayoutFrameType::SVGText);
--- a/dom/svg/SVGTextPathElement.cpp
+++ b/dom/svg/SVGTextPathElement.cpp
@@ -26,65 +26,65 @@ JSObject*
 SVGTextPathElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGTextPathElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGElement::LengthInfo SVGTextPathElement::sLengthInfo[2] =
 {
   // from SVGTextContentElement:
-  { &nsGkAtoms::textLength, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::XY },
+  { nsGkAtoms::textLength, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::XY },
   // from SVGTextPathElement:
-  { &nsGkAtoms::startOffset, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X }
+  { nsGkAtoms::startOffset, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X }
 };
 
 nsSVGEnumMapping SVGTextPathElement::sMethodMap[] = {
-  {&nsGkAtoms::align, TEXTPATH_METHODTYPE_ALIGN},
-  {&nsGkAtoms::stretch, TEXTPATH_METHODTYPE_STRETCH},
+  {nsGkAtoms::align, TEXTPATH_METHODTYPE_ALIGN},
+  {nsGkAtoms::stretch, TEXTPATH_METHODTYPE_STRETCH},
   {nullptr, 0}
 };
 
 nsSVGEnumMapping SVGTextPathElement::sSpacingMap[] = {
-  {&nsGkAtoms::_auto, TEXTPATH_SPACINGTYPE_AUTO},
-  {&nsGkAtoms::exact, TEXTPATH_SPACINGTYPE_EXACT},
+  {nsGkAtoms::_auto, TEXTPATH_SPACINGTYPE_AUTO},
+  {nsGkAtoms::exact, TEXTPATH_SPACINGTYPE_EXACT},
   {nullptr, 0}
 };
 
 nsSVGEnumMapping SVGTextPathElement::sSideMap[] = {
-  {&nsGkAtoms::left, TEXTPATH_SIDETYPE_LEFT},
-  {&nsGkAtoms::right, TEXTPATH_SIDETYPE_RIGHT},
+  {nsGkAtoms::left, TEXTPATH_SIDETYPE_LEFT},
+  {nsGkAtoms::right, TEXTPATH_SIDETYPE_RIGHT},
   {nullptr, 0}
 };
 
 nsSVGElement::EnumInfo SVGTextPathElement::sEnumInfo[4] =
 {
   // from SVGTextContentElement:
-  { &nsGkAtoms::lengthAdjust,
+  { nsGkAtoms::lengthAdjust,
     sLengthAdjustMap,
     LENGTHADJUST_SPACING
   },
   // from SVGTextPathElement:
-  { &nsGkAtoms::method,
+  { nsGkAtoms::method,
     sMethodMap,
     TEXTPATH_METHODTYPE_ALIGN
   },
-  { &nsGkAtoms::spacing,
+  { nsGkAtoms::spacing,
     sSpacingMap,
     TEXTPATH_SPACINGTYPE_EXACT
   },
-  { &nsGkAtoms::side_,
+  { nsGkAtoms::side_,
     sSideMap,
     TEXTPATH_SIDETYPE_LEFT
   }
 };
 
 nsSVGElement::StringInfo SVGTextPathElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::href, kNameSpaceID_None, true },
-  { &nsGkAtoms::href, kNameSpaceID_XLink, true }
+  { nsGkAtoms::href, kNameSpaceID_None, true },
+  { nsGkAtoms::href, kNameSpaceID_XLink, true }
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
 SVGTextPathElement::SVGTextPathElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
   : SVGTextPathElementBase(std::move(aNodeInfo))
 {
--- a/dom/svg/SVGTextPathElement.h
+++ b/dom/svg/SVGTextPathElement.h
@@ -43,17 +43,17 @@ public:
   NS_IMETHOD_(bool) IsAttributeMapped(const nsAtom* aAttribute) const override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   SVGAnimatedPathSegList* GetAnimPathSegList() override {
     return &mPath;
   }
 
-  nsAtom* GetPathDataAttrName() const override {
+  nsStaticAtom* GetPathDataAttrName() const override {
     return nsGkAtoms::path;
   }
 
   // WebIDL
   already_AddRefed<SVGAnimatedLength> StartOffset();
   already_AddRefed<SVGAnimatedEnumeration> Method();
   already_AddRefed<SVGAnimatedEnumeration> Spacing();
   already_AddRefed<SVGAnimatedEnumeration> Side();
--- a/dom/svg/SVGTextPositioningElement.cpp
+++ b/dom/svg/SVGTextPositioningElement.cpp
@@ -12,33 +12,33 @@
 #include "DOMSVGAnimatedNumberList.h"
 #include "SVGContentUtils.h"
 
 namespace mozilla {
 namespace dom {
 
 nsSVGElement::LengthListInfo SVGTextPositioningElement::sLengthListInfo[4] =
 {
-  { &nsGkAtoms::x,  SVGContentUtils::X, false },
-  { &nsGkAtoms::y,  SVGContentUtils::Y, false },
-  { &nsGkAtoms::dx, SVGContentUtils::X, true },
-  { &nsGkAtoms::dy, SVGContentUtils::Y, true }
+  { nsGkAtoms::x,  SVGContentUtils::X, false },
+  { nsGkAtoms::y,  SVGContentUtils::Y, false },
+  { nsGkAtoms::dx, SVGContentUtils::X, true },
+  { nsGkAtoms::dy, SVGContentUtils::Y, true }
 };
 
 nsSVGElement::LengthListAttributesInfo
 SVGTextPositioningElement::GetLengthListInfo()
 {
   return LengthListAttributesInfo(mLengthListAttributes, sLengthListInfo,
                                   ArrayLength(sLengthListInfo));
 }
 
 
 nsSVGElement::NumberListInfo SVGTextPositioningElement::sNumberListInfo[1] =
 {
-  { &nsGkAtoms::rotate }
+  { nsGkAtoms::rotate }
 };
 
 nsSVGElement::NumberListAttributesInfo
 SVGTextPositioningElement::GetNumberListInfo()
 {
   return NumberListAttributesInfo(mNumberListAttributes, sNumberListInfo,
                                   ArrayLength(sNumberListInfo));
 }
--- a/dom/svg/SVGTransformableElement.h
+++ b/dom/svg/SVGTransformableElement.h
@@ -58,17 +58,17 @@ public:
   virtual gfxMatrix PrependLocalTransformsTo(
     const gfxMatrix &aMatrix,
     SVGTransformTypes aWhich = eAllTransforms) const override;
   virtual const gfx::Matrix* GetAnimateMotionTransform() const override;
   virtual void SetAnimateMotionTransform(const gfx::Matrix* aMatrix) override;
 
   virtual nsSVGAnimatedTransformList*
     GetAnimatedTransformList(uint32_t aFlags = 0) override;
-  virtual nsAtom* GetTransformListAttrName() const override {
+  virtual nsStaticAtom* GetTransformListAttrName() const override {
     return nsGkAtoms::transform;
   }
 
   virtual bool IsTransformable() override { return true; }
 
 protected:
   /**
    * Helper for overrides of PrependLocalTransformsTo.  If both arguments are
--- a/dom/svg/SVGUseElement.cpp
+++ b/dom/svg/SVGUseElement.cpp
@@ -33,26 +33,26 @@ SVGUseElement::WrapNode(JSContext *aCx, 
   return SVGUseElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 ////////////////////////////////////////////////////////////////////////
 // implementation
 
 nsSVGElement::LengthInfo SVGUseElement::sLengthInfo[4] =
 {
-  { &nsGkAtoms::x, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::y, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
-  { &nsGkAtoms::width, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::height, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::x, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::y, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::width, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::height, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
 };
 
 nsSVGElement::StringInfo SVGUseElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::href, kNameSpaceID_None, true },
-  { &nsGkAtoms::href, kNameSpaceID_XLink, true }
+  { nsGkAtoms::href, kNameSpaceID_None, true },
+  { nsGkAtoms::href, kNameSpaceID_XLink, true }
 };
 
 //----------------------------------------------------------------------
 // nsISupports methods
 
 NS_IMPL_CYCLE_COLLECTION_CLASS(SVGUseElement)
 
 NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN_INHERITED(SVGUseElement,
@@ -372,17 +372,17 @@ SVGUseElement::SyncWidthOrHeight(nsAtom*
                "The clue is in the function name");
   NS_ASSERTION(OurWidthAndHeightAreUsed(), "Don't call this");
 
   if (!OurWidthAndHeightAreUsed()) {
     return;
   }
 
   auto* target = nsSVGElement::FromNode(GetClonedChild(*this));
-  uint32_t index = *sLengthInfo[ATTR_WIDTH].mName == aName ? ATTR_WIDTH : ATTR_HEIGHT;
+  uint32_t index = sLengthInfo[ATTR_WIDTH].mName == aName ? ATTR_WIDTH : ATTR_HEIGHT;
 
   if (mLengthAttributes[index].IsExplicitlySet()) {
     target->SetLength(aName, mLengthAttributes[index]);
     return;
   }
   if (target->IsSVGElement(nsGkAtoms::svg)) {
     // Our width/height attribute is now no longer explicitly set, so we
     // need to revert the clone's width/height to the width/height of the
--- a/dom/svg/SVGViewElement.cpp
+++ b/dom/svg/SVGViewElement.cpp
@@ -16,24 +16,24 @@ using namespace SVGViewElement_Binding;
 
 JSObject*
 SVGViewElement::WrapNode(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
 {
   return SVGViewElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 nsSVGEnumMapping SVGViewElement::sZoomAndPanMap[] = {
-  {&nsGkAtoms::disable, SVG_ZOOMANDPAN_DISABLE},
-  {&nsGkAtoms::magnify, SVG_ZOOMANDPAN_MAGNIFY},
+  {nsGkAtoms::disable, SVG_ZOOMANDPAN_DISABLE},
+  {nsGkAtoms::magnify, SVG_ZOOMANDPAN_MAGNIFY},
   {nullptr, 0}
 };
 
 nsSVGElement::EnumInfo SVGViewElement::sEnumInfo[1] =
 {
-  { &nsGkAtoms::zoomAndPan,
+  { nsGkAtoms::zoomAndPan,
     sZoomAndPanMap,
     SVG_ZOOMANDPAN_MAGNIFY
   }
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
--- a/dom/svg/SVGViewportElement.cpp
+++ b/dom/svg/SVGViewportElement.cpp
@@ -35,20 +35,20 @@
 
 using namespace mozilla::gfx;
 
 namespace mozilla {
 namespace dom {
 
 nsSVGElement::LengthInfo SVGViewportElement::sLengthInfo[4] =
 {
-  { &nsGkAtoms::x, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
-  { &nsGkAtoms::y, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
-  { &nsGkAtoms::width, 100, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
-  { &nsGkAtoms::height, 100, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
+  { nsGkAtoms::x, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::X },
+  { nsGkAtoms::y, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER, SVGContentUtils::Y },
+  { nsGkAtoms::width, 100, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
+  { nsGkAtoms::height, 100, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
 SVGViewportElement::SVGViewportElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
   : SVGGraphicsElement(std::move(aNodeInfo)),
     mViewportWidth(0),
--- a/dom/svg/nsSVGAngle.cpp
+++ b/dom/svg/nsSVGAngle.cpp
@@ -17,23 +17,23 @@
 #include "SVGAnimatedAngle.h"
 #include "SVGOrientSMILType.h"
 
 using namespace mozilla;
 using namespace mozilla::dom;
 using namespace mozilla::dom::SVGAngle_Binding;
 using namespace mozilla::dom::SVGMarkerElement_Binding;
 
-static nsStaticAtom** const unitMap[] =
+static const nsStaticAtom* const unitMap[] =
 {
   nullptr, /* SVG_ANGLETYPE_UNKNOWN */
   nullptr, /* SVG_ANGLETYPE_UNSPECIFIED */
-  &nsGkAtoms::deg,
-  &nsGkAtoms::rad,
-  &nsGkAtoms::grad
+  nsGkAtoms::deg,
+  nsGkAtoms::rad,
+  nsGkAtoms::grad
 };
 
 static nsSVGAttrTearoffTable<nsSVGAngle, SVGAnimatedAngle>
   sSVGAnimatedAngleTearoffTable;
 static nsSVGAttrTearoffTable<nsSVGAngle, SVGAngle>
   sBaseSVGAngleTearoffTable;
 static nsSVGAttrTearoffTable<nsSVGAngle, SVGAngle>
   sAnimSVGAngleTearoffTable;
@@ -50,17 +50,17 @@ IsValidUnitType(uint16_t unit)
   return false;
 }
 
 static void
 GetUnitString(nsAString& unit, uint16_t unitType)
 {
   if (IsValidUnitType(unitType)) {
     if (unitMap[unitType]) {
-      (*unitMap[unitType])->ToString(unit);
+      unitMap[unitType]->ToString(unit);
     }
     return;
   }
 
   MOZ_ASSERT_UNREACHABLE("Unknown unit type");
 }
 
 static uint16_t
@@ -68,17 +68,17 @@ GetUnitTypeForString(const nsAString& un
 {
   if (unitStr.IsEmpty())
     return SVG_ANGLETYPE_UNSPECIFIED;
 
   nsStaticAtom* unitAtom = NS_GetStaticAtom(unitStr);
 
   if (unitAtom) {
     for (uint32_t i = 0 ; i < ArrayLength(unitMap) ; i++) {
-      if (unitMap[i] && *unitMap[i] == unitAtom) {
+      if (unitMap[i] == unitAtom) {
         return i;
       }
     }
   }
 
   return SVG_ANGLETYPE_UNKNOWN;
 }
 
--- a/dom/svg/nsSVGElement.cpp
+++ b/dom/svg/nsSVGElement.cpp
@@ -79,18 +79,18 @@ NS_NewSVGElement(Element **aResult, alre
 
   it.forget(aResult);
   return rv;
 }
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(nsSVGElement)
 
 nsSVGEnumMapping nsSVGElement::sSVGUnitTypesMap[] = {
-  {&nsGkAtoms::userSpaceOnUse, SVG_UNIT_TYPE_USERSPACEONUSE},
-  {&nsGkAtoms::objectBoundingBox, SVG_UNIT_TYPE_OBJECTBOUNDINGBOX},
+  {nsGkAtoms::userSpaceOnUse, SVG_UNIT_TYPE_USERSPACEONUSE},
+  {nsGkAtoms::objectBoundingBox, SVG_UNIT_TYPE_OBJECTBOUNDINGBOX},
   {nullptr, 0}
 };
 
 nsSVGElement::nsSVGElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
   : nsSVGElementBase(std::move(aNodeInfo))
 {
 }
 
@@ -317,34 +317,34 @@ nsSVGElement::ParseAttribute(int32_t aNa
   bool didSetResult = false;
 
   if (aNamespaceID == kNameSpaceID_None) {
     // Check for nsSVGLength2 attribute
     LengthAttributesInfo lengthInfo = GetLengthInfo();
 
     uint32_t i;
     for (i = 0; i < lengthInfo.mLengthCount; i++) {
-      if (aAttribute == *lengthInfo.mLengthInfo[i].mName) {
+      if (aAttribute == lengthInfo.mLengthInfo[i].mName) {
         rv = lengthInfo.mLengths[i].SetBaseValueString(aValue, this, false);
         if (NS_FAILED(rv)) {
           lengthInfo.Reset(i);
         } else {
           aResult.SetTo(lengthInfo.mLengths[i], &aValue);
           didSetResult = true;
         }
         foundMatch = true;
         break;
       }
     }
 
     if (!foundMatch) {
       // Check for SVGAnimatedLengthList attribute
       LengthListAttributesInfo lengthListInfo = GetLengthListInfo();
       for (i = 0; i < lengthListInfo.mLengthListCount; i++) {
-        if (aAttribute == *lengthListInfo.mLengthListInfo[i].mName) {
+        if (aAttribute == lengthListInfo.mLengthListInfo[i].mName) {
           rv = lengthListInfo.mLengthLists[i].SetBaseValueString(aValue);
           if (NS_FAILED(rv)) {
             lengthListInfo.Reset(i);
           } else {
             aResult.SetTo(lengthListInfo.mLengthLists[i].GetBaseValue(),
                           &aValue);
             didSetResult = true;
           }
@@ -353,17 +353,17 @@ nsSVGElement::ParseAttribute(int32_t aNa
         }
       }
     }
 
     if (!foundMatch) {
       // Check for SVGAnimatedNumberList attribute
       NumberListAttributesInfo numberListInfo = GetNumberListInfo();
       for (i = 0; i < numberListInfo.mNumberListCount; i++) {
-        if (aAttribute == *numberListInfo.mNumberListInfo[i].mName) {
+        if (aAttribute == numberListInfo.mNumberListInfo[i].mName) {
           rv = numberListInfo.mNumberLists[i].SetBaseValueString(aValue);
           if (NS_FAILED(rv)) {
             numberListInfo.Reset(i);
           } else {
             aResult.SetTo(numberListInfo.mNumberLists[i].GetBaseValue(),
                           &aValue);
             didSetResult = true;
           }
@@ -404,17 +404,17 @@ nsSVGElement::ParseAttribute(int32_t aNa
         }
       }
     }
 
     if (!foundMatch) {
       // Check for nsSVGNumber2 attribute
       NumberAttributesInfo numberInfo = GetNumberInfo();
       for (i = 0; i < numberInfo.mNumberCount; i++) {
-        if (aAttribute == *numberInfo.mNumberInfo[i].mName) {
+        if (aAttribute == numberInfo.mNumberInfo[i].mName) {
           rv = numberInfo.mNumbers[i].SetBaseValueString(aValue, this);
           if (NS_FAILED(rv)) {
             numberInfo.Reset(i);
           } else {
             aResult.SetTo(numberInfo.mNumbers[i].GetBaseValue(), &aValue);
             didSetResult = true;
           }
           foundMatch = true;
@@ -422,17 +422,17 @@ nsSVGElement::ParseAttribute(int32_t aNa
         }
       }
     }
 
     if (!foundMatch) {
       // Check for nsSVGNumberPair attribute
       NumberPairAttributesInfo numberPairInfo = GetNumberPairInfo();
       for (i = 0; i < numberPairInfo.mNumberPairCount; i++) {
-        if (aAttribute == *numberPairInfo.mNumberPairInfo[i].mName) {
+        if (aAttribute == numberPairInfo.mNumberPairInfo[i].mName) {
           rv = numberPairInfo.mNumberPairs[i].SetBaseValueString(aValue, this);
           if (NS_FAILED(rv)) {
             numberPairInfo.Reset(i);
           } else {
             aResult.SetTo(numberPairInfo.mNumberPairs[i], &aValue);
             didSetResult = true;
           }
           foundMatch = true;
@@ -440,17 +440,17 @@ nsSVGElement::ParseAttribute(int32_t aNa
         }
       }
     }
 
     if (!foundMatch) {
       // Check for nsSVGInteger attribute
       IntegerAttributesInfo integerInfo = GetIntegerInfo();
       for (i = 0; i < integerInfo.mIntegerCount; i++) {
-        if (aAttribute == *integerInfo.mIntegerInfo[i].mName) {
+        if (aAttribute == integerInfo.mIntegerInfo[i].mName) {
           rv = integerInfo.mIntegers[i].SetBaseValueString(aValue, this);
           if (NS_FAILED(rv)) {
             integerInfo.Reset(i);
           } else {
             aResult.SetTo(integerInfo.mIntegers[i].GetBaseValue(), &aValue);
             didSetResult = true;
           }
           foundMatch = true;
@@ -458,17 +458,17 @@ nsSVGElement::ParseAttribute(int32_t aNa
         }
       }
     }
 
     if (!foundMatch) {
       // Check for nsSVGIntegerPair attribute
       IntegerPairAttributesInfo integerPairInfo = GetIntegerPairInfo();
       for (i = 0; i < integerPairInfo.mIntegerPairCount; i++) {
-        if (aAttribute == *integerPairInfo.mIntegerPairInfo[i].mName) {
+        if (aAttribute == integerPairInfo.mIntegerPairInfo[i].mName) {
           rv =
             integerPairInfo.mIntegerPairs[i].SetBaseValueString(aValue, this);
           if (NS_FAILED(rv)) {
             integerPairInfo.Reset(i);
           } else {
             aResult.SetTo(integerPairInfo.mIntegerPairs[i], &aValue);
             didSetResult = true;
           }
@@ -477,17 +477,17 @@ nsSVGElement::ParseAttribute(int32_t aNa
         }
       }
     }
 
     if (!foundMatch) {
       // Check for nsSVGAngle attribute
       AngleAttributesInfo angleInfo = GetAngleInfo();
       for (i = 0; i < angleInfo.mAngleCount; i++) {
-        if (aAttribute == *angleInfo.mAngleInfo[i].mName) {
+        if (aAttribute == angleInfo.mAngleInfo[i].mName) {
           rv = angleInfo.mAngles[i].SetBaseValueString(aValue, this, false);
           if (NS_FAILED(rv)) {
             angleInfo.Reset(i);
           } else {
             aResult.SetTo(angleInfo.mAngles[i], &aValue);
             didSetResult = true;
           }
           foundMatch = true;
@@ -495,17 +495,17 @@ nsSVGElement::ParseAttribute(int32_t aNa
         }
       }
     }
 
     if (!foundMatch) {
       // Check for nsSVGBoolean attribute
       BooleanAttributesInfo booleanInfo = GetBooleanInfo();
       for (i = 0; i < booleanInfo.mBooleanCount; i++) {
-        if (aAttribute == *booleanInfo.mBooleanInfo[i].mName) {
+        if (aAttribute == booleanInfo.mBooleanInfo[i].mName) {
           nsAtom *valAtom = NS_GetStaticAtom(aValue);
           rv = valAtom ? booleanInfo.mBooleans[i].SetBaseValueAtom(valAtom, this) :
                  NS_ERROR_DOM_SYNTAX_ERR;
           if (NS_FAILED(rv)) {
             booleanInfo.Reset(i);
           } else {
             aResult.SetTo(valAtom);
             didSetResult = true;
@@ -515,17 +515,17 @@ nsSVGElement::ParseAttribute(int32_t aNa
         }
       }
     }
 
     if (!foundMatch) {
       // Check for nsSVGEnum attribute
       EnumAttributesInfo enumInfo = GetEnumInfo();
       for (i = 0; i < enumInfo.mEnumCount; i++) {
-        if (aAttribute == *enumInfo.mEnumInfo[i].mName) {
+        if (aAttribute == enumInfo.mEnumInfo[i].mName) {
           RefPtr<nsAtom> valAtom = NS_Atomize(aValue);
           rv = enumInfo.mEnums[i].SetBaseValueAtom(valAtom, this);
           if (NS_FAILED(rv)) {
             enumInfo.SetUnknownValue(i);
           } else {
             aResult.SetTo(valAtom);
             didSetResult = true;
           }
@@ -543,17 +543,17 @@ nsSVGElement::ParseAttribute(int32_t aNa
         foundMatch = true;
       }
     }
 
     if (!foundMatch) {
       // Check for StringList attribute
       StringListAttributesInfo stringListInfo = GetStringListInfo();
       for (i = 0; i < stringListInfo.mStringListCount; i++) {
-        if (aAttribute == *stringListInfo.mStringListInfo[i].mName) {
+        if (aAttribute == stringListInfo.mStringListInfo[i].mName) {
           rv = stringListInfo.mStringLists[i].SetValue(aValue);
           if (NS_FAILED(rv)) {
             stringListInfo.Reset(i);
           } else {
             aResult.SetTo(stringListInfo.mStringLists[i], &aValue);
             didSetResult = true;
           }
           foundMatch = true;
@@ -622,17 +622,17 @@ nsSVGElement::ParseAttribute(int32_t aNa
     }
   }
 
   if (!foundMatch) {
     // Check for nsSVGString attribute
     StringAttributesInfo stringInfo = GetStringInfo();
     for (uint32_t i = 0; i < stringInfo.mStringCount; i++) {
       if (aNamespaceID == stringInfo.mStringInfo[i].mNamespaceID &&
-          aAttribute == *stringInfo.mStringInfo[i].mName) {
+          aAttribute == stringInfo.mStringInfo[i].mName) {
         stringInfo.mStrings[i].SetBaseValue(aValue, this, false);
         foundMatch = true;
         break;
       }
     }
   }
 
   if (foundMatch) {
@@ -672,39 +672,39 @@ nsSVGElement::UnsetAttrInternal(int32_t 
       }
       return;
     }
 
     // Check if this is a length attribute going away
     LengthAttributesInfo lenInfo = GetLengthInfo();
 
     for (uint32_t i = 0; i < lenInfo.mLengthCount; i++) {
-      if (aName == *lenInfo.mLengthInfo[i].mName) {
+      if (aName == lenInfo.mLengthInfo[i].mName) {
         MaybeSerializeAttrBeforeRemoval(aName, aNotify);
         lenInfo.Reset(i);
         return;
       }
     }
 
     // Check if this is a length list attribute going away
     LengthListAttributesInfo lengthListInfo = GetLengthListInfo();
 
     for (uint32_t i = 0; i < lengthListInfo.mLengthListCount; i++) {
-      if (aName == *lengthListInfo.mLengthListInfo[i].mName) {
+      if (aName == lengthListInfo.mLengthListInfo[i].mName) {
         MaybeSerializeAttrBeforeRemoval(aName, aNotify);
         lengthListInfo.Reset(i);
         return;
       }
     }
 
     // Check if this is a number list attribute going away
     NumberListAttributesInfo numberListInfo = GetNumberListInfo();
 
     for (uint32_t i = 0; i < numberListInfo.mNumberListCount; i++) {
-      if (aName == *numberListInfo.mNumberListInfo[i].mName) {
+      if (aName == numberListInfo.mNumberListInfo[i].mName) {
         MaybeSerializeAttrBeforeRemoval(aName, aNotify);
         numberListInfo.Reset(i);
         return;
       }
     }
 
     // Check if this is a point list attribute going away
     if (GetPointListAttrName() == aName) {
@@ -725,80 +725,80 @@ nsSVGElement::UnsetAttrInternal(int32_t 
         return;
       }
     }
 
     // Check if this is a number attribute going away
     NumberAttributesInfo numInfo = GetNumberInfo();
 
     for (uint32_t i = 0; i < numInfo.mNumberCount; i++) {
-      if (aName == *numInfo.mNumberInfo[i].mName) {
+      if (aName == numInfo.mNumberInfo[i].mName) {
         numInfo.Reset(i);
         return;
       }
     }
 
     // Check if this is a number pair attribute going away
     NumberPairAttributesInfo numPairInfo = GetNumberPairInfo();
 
     for (uint32_t i = 0; i < numPairInfo.mNumberPairCount; i++) {
-      if (aName == *numPairInfo.mNumberPairInfo[i].mName) {
+      if (aName == numPairInfo.mNumberPairInfo[i].mName) {
         MaybeSerializeAttrBeforeRemoval(aName, aNotify);
         numPairInfo.Reset(i);
         return;
       }
     }
 
     // Check if this is an integer attribute going away
     IntegerAttributesInfo intInfo = GetIntegerInfo();
 
     for (uint32_t i = 0; i < intInfo.mIntegerCount; i++) {
-      if (aName == *intInfo.mIntegerInfo[i].mName) {
+      if (aName == intInfo.mIntegerInfo[i].mName) {
         intInfo.Reset(i);
         return;
       }
     }
 
     // Check if this is an integer pair attribute going away
     IntegerPairAttributesInfo intPairInfo = GetIntegerPairInfo();
 
     for (uint32_t i = 0; i < intPairInfo.mIntegerPairCount; i++) {
-      if (aName == *intPairInfo.mIntegerPairInfo[i].mName) {
+      if (aName == intPairInfo.mIntegerPairInfo[i].mName) {
         MaybeSerializeAttrBeforeRemoval(aName, aNotify);
         intPairInfo.Reset(i);
         return;
       }
     }
 
     // Check if this is an angle attribute going away
     AngleAttributesInfo angleInfo = GetAngleInfo();
 
     for (uint32_t i = 0; i < angleInfo.mAngleCount; i++) {
-      if (aName == *angleInfo.mAngleInfo[i].mName) {
+      if (aName == angleInfo.mAngleInfo[i].mName) {
         MaybeSerializeAttrBeforeRemoval(aName, aNotify);
         angleInfo.Reset(i);
         return;
       }
     }
 
     // Check if this is a boolean attribute going away
     BooleanAttributesInfo boolInfo = GetBooleanInfo();
 
     for (uint32_t i = 0; i < boolInfo.mBooleanCount; i++) {
-      if (aName == *boolInfo.mBooleanInfo[i].mName) {
+      if (aName == boolInfo.mBooleanInfo[i].mName) {
         boolInfo.Reset(i);
         return;
       }
     }
 
     // Check if this is an enum attribute going away
     EnumAttributesInfo enumInfo = GetEnumInfo();
 
     for (uint32_t i = 0; i < enumInfo.mEnumCount; i++) {
-      if (aName == *enumInfo.mEnumInfo[i].mName) {
+      if (aName == enumInfo.mEnumInfo[i].mName) {
         enumInfo.Reset(i);
         return;
       }
     }
 
     // Check if this is a nsViewBox attribute going away
     if (aName == nsGkAtoms::viewBox) {
       nsSVGViewBox* viewBox = GetViewBox();
@@ -837,17 +837,17 @@ nsSVGElement::UnsetAttrInternal(int32_t 
       tests->UnsetAttr(aName);
       return;
     }
 
     // Check if this is a string list attribute going away
     StringListAttributesInfo stringListInfo = GetStringListInfo();
 
     for (uint32_t i = 0; i < stringListInfo.mStringListCount; i++) {
-      if (aName == *stringListInfo.mStringListInfo[i].mName) {
+      if (aName == stringListInfo.mStringListInfo[i].mName) {
         MaybeSerializeAttrBeforeRemoval(aName, aNotify);
         stringListInfo.Reset(i);
         return;
       }
     }
 
     if (aName == nsGkAtoms::_class) {
       mClassAttribute.Init();
@@ -855,17 +855,17 @@ nsSVGElement::UnsetAttrInternal(int32_t 
     }
   }
 
   // Check if this is a string attribute going away
   StringAttributesInfo stringInfo = GetStringInfo();
 
   for (uint32_t i = 0; i < stringInfo.mStringCount; i++) {
     if (aNamespaceID == stringInfo.mStringInfo[i].mNamespaceID &&
-        aName == *stringInfo.mStringInfo[i].mName) {
+        aName == stringInfo.mStringInfo[i].mName) {
       stringInfo.Reset(i);
       return;
     }
   }
 }
 
 nsresult
 nsSVGElement::BeforeSetAttr(int32_t aNamespaceID, nsAtom* aName,
@@ -918,139 +918,139 @@ nsSVGElement::IsAttributeMapped(const ns
     return true;
   }
   return nsSVGElementBase::IsAttributeMapped(name);
 }
 
 // PresentationAttributes-FillStroke
 /* static */ const Element::MappedAttributeEntry
 nsSVGElement::sFillStrokeMap[] = {
-  { &nsGkAtoms::fill },
-  { &nsGkAtoms::fill_opacity },
-  { &nsGkAtoms::fill_rule },
-  { &nsGkAtoms::paint_order },
-  { &nsGkAtoms::stroke },
-  { &nsGkAtoms::stroke_dasharray },
-  { &nsGkAtoms::stroke_dashoffset },
-  { &nsGkAtoms::stroke_linecap },
-  { &nsGkAtoms::stroke_linejoin },
-  { &nsGkAtoms::stroke_miterlimit },
-  { &nsGkAtoms::stroke_opacity },
-  { &nsGkAtoms::stroke_width },
-  { &nsGkAtoms::vector_effect },
+  { nsGkAtoms::fill },
+  { nsGkAtoms::fill_opacity },
+  { nsGkAtoms::fill_rule },
+  { nsGkAtoms::paint_order },
+  { nsGkAtoms::stroke },
+  { nsGkAtoms::stroke_dasharray },
+  { nsGkAtoms::stroke_dashoffset },
+  { nsGkAtoms::stroke_linecap },
+  { nsGkAtoms::stroke_linejoin },
+  { nsGkAtoms::stroke_miterlimit },
+  { nsGkAtoms::stroke_opacity },
+  { nsGkAtoms::stroke_width },
+  { nsGkAtoms::vector_effect },
   { nullptr }
 };
 
 // PresentationAttributes-Graphics
 /* static */ const Element::MappedAttributeEntry
 nsSVGElement::sGraphicsMap[] = {
-  { &nsGkAtoms::clip_path },
-  { &nsGkAtoms::clip_rule },
-  { &nsGkAtoms::colorInterpolation },
-  { &nsGkAtoms::cursor },
-  { &nsGkAtoms::display },
-  { &nsGkAtoms::filter },
-  { &nsGkAtoms::image_rendering },
-  { &nsGkAtoms::mask },
-  { &nsGkAtoms::opacity },
-  { &nsGkAtoms::pointer_events },
-  { &nsGkAtoms::shape_rendering },
-  { &nsGkAtoms::text_rendering },
-  { &nsGkAtoms::visibility },
+  { nsGkAtoms::clip_path },
+  { nsGkAtoms::clip_rule },
+  { nsGkAtoms::colorInterpolation },
+  { nsGkAtoms::cursor },
+  { nsGkAtoms::display },
+  { nsGkAtoms::filter },
+  { nsGkAtoms::image_rendering },
+  { nsGkAtoms::mask },
+  { nsGkAtoms::opacity },
+  { nsGkAtoms::pointer_events },
+  { nsGkAtoms::shape_rendering },
+  { nsGkAtoms::text_rendering },
+  { nsGkAtoms::visibility },
   { nullptr }
 };
 
 // PresentationAttributes-TextContentElements
 /* static */ const Element::MappedAttributeEntry
 nsSVGElement::sTextContentElementsMap[] = {
   // Properties that we don't support are commented out.
-  // { &nsGkAtoms::alignment_baseline },
-  // { &nsGkAtoms::baseline_shift },
-  { &nsGkAtoms::direction },
-  { &nsGkAtoms::dominant_baseline },
-  { &nsGkAtoms::letter_spacing },
-  { &nsGkAtoms::text_anchor },
-  { &nsGkAtoms::text_decoration },
-  { &nsGkAtoms::unicode_bidi },
-  { &nsGkAtoms::word_spacing },
-  { &nsGkAtoms::writing_mode },
+  // { nsGkAtoms::alignment_baseline },
+  // { nsGkAtoms::baseline_shift },
+  { nsGkAtoms::direction },
+  { nsGkAtoms::dominant_baseline },
+  { nsGkAtoms::letter_spacing },
+  { nsGkAtoms::text_anchor },
+  { nsGkAtoms::text_decoration },
+  { nsGkAtoms::unicode_bidi },
+  { nsGkAtoms::word_spacing },
+  { nsGkAtoms::writing_mode },
   { nullptr }
 };
 
 // PresentationAttributes-FontSpecification
 /* static */ const Element::MappedAttributeEntry
 nsSVGElement::sFontSpecificationMap[] = {
-  { &nsGkAtoms::font_family },
-  { &nsGkAtoms::font_size },
-  { &nsGkAtoms::font_size_adjust },
-  { &nsGkAtoms::font_stretch },
-  { &nsGkAtoms::font_style },
-  { &nsGkAtoms::font_variant },
-  { &nsGkAtoms::fontWeight },
+  { nsGkAtoms::font_family },
+  { nsGkAtoms::font_size },
+  { nsGkAtoms::font_size_adjust },
+  { nsGkAtoms::font_stretch },
+  { nsGkAtoms::font_style },
+  { nsGkAtoms::font_variant },
+  { nsGkAtoms::fontWeight },
   { nullptr }
 };
 
 // PresentationAttributes-GradientStop
 /* static */ const Element::MappedAttributeEntry
 nsSVGElement::sGradientStopMap[] = {
-  { &nsGkAtoms::stop_color },
-  { &nsGkAtoms::stop_opacity },
+  { nsGkAtoms::stop_color },
+  { nsGkAtoms::stop_opacity },
   { nullptr }
 };
 
 // PresentationAttributes-Viewports
 /* static */ const Element::MappedAttributeEntry
 nsSVGElement::sViewportsMap[] = {
-  { &nsGkAtoms::overflow },
-  { &nsGkAtoms::clip },
+  { nsGkAtoms::overflow },
+  { nsGkAtoms::clip },
   { nullptr }
 };
 
 // PresentationAttributes-Makers
 /* static */ const Element::MappedAttributeEntry
 nsSVGElement::sMarkersMap[] = {
-  { &nsGkAtoms::marker_end },
-  { &nsGkAtoms::marker_mid },
-  { &nsGkAtoms::marker_start },
+  { nsGkAtoms::marker_end },
+  { nsGkAtoms::marker_mid },
+  { nsGkAtoms::marker_start },
   { nullptr }
 };
 
 // PresentationAttributes-Color
 /* static */ const Element::MappedAttributeEntry
 nsSVGElement::sColorMap[] = {
-  { &nsGkAtoms::color },
+  { nsGkAtoms::color },
   { nullptr }
 };
 
 // PresentationAttributes-Filters
 /* static */ const Element::MappedAttributeEntry
 nsSVGElement::sFiltersMap[] = {
-  { &nsGkAtoms::colorInterpolationFilters },
+  { nsGkAtoms::colorInterpolationFilters },
   { nullptr }
 };
 
 // PresentationAttributes-feFlood
 /* static */ const Element::MappedAttributeEntry
 nsSVGElement::sFEFloodMap[] = {
-  { &nsGkAtoms::flood_color },
-  { &nsGkAtoms::flood_opacity },
+  { nsGkAtoms::flood_color },
+  { nsGkAtoms::flood_opacity },
   { nullptr }
 };
 
 // PresentationAttributes-LightingEffects
 /* static */ const Element::MappedAttributeEntry
 nsSVGElement::sLightingEffectsMap[] = {
-  { &nsGkAtoms::lighting_color },
+  { nsGkAtoms::lighting_color },
   { nullptr }
 };
 
 // PresentationAttributes-mask
 /* static */ const Element::MappedAttributeEntry
 nsSVGElement::sMaskMap[] = {
-  { &nsGkAtoms::mask_type },
+  { nsGkAtoms::mask_type },
   { nullptr }
 };
 
 //----------------------------------------------------------------------
 // Element methods
 
 // forwarded to Element implementations
 
@@ -1507,70 +1507,70 @@ nsSVGElement::LengthAttributesInfo::Rese
 }
 
 void
 nsSVGElement::SetLength(nsAtom* aName, const nsSVGLength2 &aLength)
 {
   LengthAttributesInfo lengthInfo = GetLengthInfo();
 
   for (uint32_t i = 0; i < lengthInfo.mLengthCount; i++) {
-    if (aName == *lengthInfo.mLengthInfo[i].mName) {
+    if (aName == lengthInfo.mLengthInfo[i].mName) {
       lengthInfo.mLengths[i] = aLength;
       DidAnimateLength(i);
       return;
     }
   }
   MOZ_ASSERT(false, "no length found to set");
 }
 
 nsAttrValue
 nsSVGElement::WillChangeLength(uint8_t aAttrEnum)
 {
-  return WillChangeValue(*GetLengthInfo().mLengthInfo[aAttrEnum].mName);
+  return WillChangeValue(GetLengthInfo().mLengthInfo[aAttrEnum].mName);
 }
 
 void
 nsSVGElement::DidChangeLength(uint8_t aAttrEnum,
                               const nsAttrValue& aEmptyOrOldValue)
 {
   LengthAttributesInfo info = GetLengthInfo();
 
   NS_ASSERTION(info.mLengthCount > 0,
                "DidChangeLength on element with no length attribs");
   NS_ASSERTION(aAttrEnum < info.mLengthCount, "aAttrEnum out of range");
 
   nsAttrValue newValue;
   newValue.SetTo(info.mLengths[aAttrEnum], nullptr);
 
-  DidChangeValue(*info.mLengthInfo[aAttrEnum].mName, aEmptyOrOldValue,
+  DidChangeValue(info.mLengthInfo[aAttrEnum].mName, aEmptyOrOldValue,
                  newValue);
 }
 
 void
 nsSVGElement::DidAnimateLength(uint8_t aAttrEnum)
 {
   ClearAnyCachedPath();
 
   nsIFrame* frame = GetPrimaryFrame();
 
   if (frame) {
     LengthAttributesInfo info = GetLengthInfo();
     frame->AttributeChanged(kNameSpaceID_None,
-                            *info.mLengthInfo[aAttrEnum].mName,
+                            info.mLengthInfo[aAttrEnum].mName,
                             MutationEvent_Binding::SMIL);
   }
 }
 
 nsSVGLength2*
 nsSVGElement::GetAnimatedLength(const nsAtom *aAttrName)
 {
   LengthAttributesInfo lengthInfo = GetLengthInfo();
 
   for (uint32_t i = 0; i < lengthInfo.mLengthCount; i++) {
-    if (aAttrName == *lengthInfo.mLengthInfo[i].mName) {
+    if (aAttrName == lengthInfo.mLengthInfo[i].mName) {
       return &lengthInfo.mLengths[i];
     }
   }
   MOZ_ASSERT(false, "no matching length found");
   return nullptr;
 }
 
 void
@@ -1618,45 +1618,45 @@ nsSVGElement::LengthListAttributesInfo::
 {
   mLengthLists[aAttrEnum].ClearBaseValue(aAttrEnum);
   // caller notifies
 }
 
 nsAttrValue
 nsSVGElement::WillChangeLengthList(uint8_t aAttrEnum)
 {
-  return WillChangeValue(*GetLengthListInfo().mLengthListInfo[aAttrEnum].mName);
+  return WillChangeValue(GetLengthListInfo().mLengthListInfo[aAttrEnum].mName);
 }
 
 void
 nsSVGElement::DidChangeLengthList(uint8_t aAttrEnum,
                                   const nsAttrValue& aEmptyOrOldValue)
 {
   LengthListAttributesInfo info = GetLengthListInfo();
 
   NS_ASSERTION(info.mLengthListCount > 0,
                "DidChangeLengthList on element with no length list attribs");
   NS_ASSERTION(aAttrEnum < info.mLengthListCount, "aAttrEnum out of range");
 
   nsAttrValue newValue;
   newValue.SetTo(info.mLengthLists[aAttrEnum].GetBaseValue(), nullptr);
 
-  DidChangeValue(*info.mLengthListInfo[aAttrEnum].mName, aEmptyOrOldValue,
+  DidChangeValue(info.mLengthListInfo[aAttrEnum].mName, aEmptyOrOldValue,
                  newValue);
 }
 
 void
 nsSVGElement::DidAnimateLengthList(uint8_t aAttrEnum)
 {
   nsIFrame* frame = GetPrimaryFrame();
 
   if (frame) {
     LengthListAttributesInfo info = GetLengthListInfo();
     frame->AttributeChanged(kNameSpaceID_None,
-                            *info.mLengthListInfo[aAttrEnum].mName,
+                            info.mLengthListInfo[aAttrEnum].mName,
                             MutationEvent_Binding::SMIL);
   }
 }
 
 void
 nsSVGElement::GetAnimatedLengthListValues(SVGUserUnitList *aFirst, ...)
 {
   LengthListAttributesInfo info = GetLengthListInfo();
@@ -1703,48 +1703,48 @@ nsSVGElement::NumberListAttributesInfo::
   MOZ_ASSERT(aAttrEnum < mNumberListCount, "Bad attr enum");
   mNumberLists[aAttrEnum].ClearBaseValue(aAttrEnum);
   // caller notifies
 }
 
 nsAttrValue
 nsSVGElement::WillChangeNumberList(uint8_t aAttrEnum)
 {
-  return WillChangeValue(*GetNumberListInfo().mNumberListInfo[aAttrEnum].mName);
+  return WillChangeValue(GetNumberListInfo().mNumberListInfo[aAttrEnum].mName);
 }
 
 void
 nsSVGElement::DidChangeNumberList(uint8_t aAttrEnum,
                                   const nsAttrValue& aEmptyOrOldValue)
 {
   NumberListAttributesInfo info = GetNumberListInfo();
 
   MOZ_ASSERT(info.mNumberListCount > 0,
              "DidChangeNumberList on element with no number list attribs");
   MOZ_ASSERT(aAttrEnum < info.mNumberListCount,
              "aAttrEnum out of range");
 
   nsAttrValue newValue;
   newValue.SetTo(info.mNumberLists[aAttrEnum].GetBaseValue(), nullptr);
 
-  DidChangeValue(*info.mNumberListInfo[aAttrEnum].mName, aEmptyOrOldValue,
+  DidChangeValue(info.mNumberListInfo[aAttrEnum].mName, aEmptyOrOldValue,
                  newValue);
 }
 
 void
 nsSVGElement::DidAnimateNumberList(uint8_t aAttrEnum)
 {
   nsIFrame* frame = GetPrimaryFrame();
 
   if (frame) {
     NumberListAttributesInfo info = GetNumberListInfo();
     MOZ_ASSERT(aAttrEnum < info.mNumberListCount, "aAttrEnum out of range");
 
     frame->AttributeChanged(kNameSpaceID_None,
-                            *info.mNumberListInfo[aAttrEnum].mName,
+                            info.mNumberListInfo[aAttrEnum].mName,
                             MutationEvent_Binding::SMIL);
   }
 }
 
 SVGAnimatedNumberList*
 nsSVGElement::GetAnimatedNumberList(uint8_t aAttrEnum)
 {
   NumberListAttributesInfo info = GetNumberListInfo();
@@ -1755,17 +1755,17 @@ nsSVGElement::GetAnimatedNumberList(uint
   return nullptr;
 }
 
 SVGAnimatedNumberList*
 nsSVGElement::GetAnimatedNumberList(nsAtom *aAttrName)
 {
   NumberListAttributesInfo info = GetNumberListInfo();
   for (uint32_t i = 0; i < info.mNumberListCount; i++) {
-    if (aAttrName == *info.mNumberListInfo[i].mName) {
+    if (aAttrName == info.mNumberListInfo[i].mName) {
       return &info.mNumberLists[i];
     }
   }
   MOZ_ASSERT(false, "Bad caller");
   return nullptr;
 }
 
 nsAttrValue
@@ -1862,29 +1862,29 @@ nsSVGElement::DidChangeNumber(uint8_t aA
 
   NS_ASSERTION(info.mNumberCount > 0,
                "DidChangeNumber on element with no number attribs");
   NS_ASSERTION(aAttrEnum < info.mNumberCount, "aAttrEnum out of range");
 
   nsAttrValue attrValue;
   attrValue.SetTo(info.mNumbers[aAttrEnum].GetBaseValue(), nullptr);
 
-  SetParsedAttr(kNameSpaceID_None, *info.mNumberInfo[aAttrEnum].mName, nullptr,
+  SetParsedAttr(kNameSpaceID_None, info.mNumberInfo[aAttrEnum].mName, nullptr,
                 attrValue, true);
 }
 
 void
 nsSVGElement::DidAnimateNumber(uint8_t aAttrEnum)
 {
   nsIFrame* frame = GetPrimaryFrame();
 
   if (frame) {
     NumberAttributesInfo info = GetNumberInfo();
     frame->AttributeChanged(kNameSpaceID_None,
-                            *info.mNumberInfo[aAttrEnum].mName,
+                            info.mNumberInfo[aAttrEnum].mName,
                             MutationEvent_Binding::SMIL);
   }
 }
 
 void
 nsSVGElement::GetAnimatedNumberValues(float *aFirst, ...)
 {
   NumberAttributesInfo info = GetNumberInfo();
@@ -1917,45 +1917,45 @@ nsSVGElement::NumberPairAttributesInfo::
   mNumberPairs[aAttrEnum].Init(aAttrEnum,
                                mNumberPairInfo[aAttrEnum].mDefaultValue1,
                                mNumberPairInfo[aAttrEnum].mDefaultValue2);
 }
 
 nsAttrValue
 nsSVGElement::WillChangeNumberPair(uint8_t aAttrEnum)
 {
-  return WillChangeValue(*GetNumberPairInfo().mNumberPairInfo[aAttrEnum].mName);
+  return WillChangeValue(GetNumberPairInfo().mNumberPairInfo[aAttrEnum].mName);
 }
 
 void
 nsSVGElement::DidChangeNumberPair(uint8_t aAttrEnum,
                                   const nsAttrValue& aEmptyOrOldValue)
 {
   NumberPairAttributesInfo info = GetNumberPairInfo();
 
   NS_ASSERTION(info.mNumberPairCount > 0,
                "DidChangePairNumber on element with no number pair attribs");
   NS_ASSERTION(aAttrEnum < info.mNumberPairCount, "aAttrEnum out of range");
 
   nsAttrValue newValue;
   newValue.SetTo(info.mNumberPairs[aAttrEnum], nullptr);
 
-  DidChangeValue(*info.mNumberPairInfo[aAttrEnum].mName, aEmptyOrOldValue,
+  DidChangeValue(info.mNumberPairInfo[aAttrEnum].mName, aEmptyOrOldValue,
                  newValue);
 }
 
 void
 nsSVGElement::DidAnimateNumberPair(uint8_t aAttrEnum)
 {
   nsIFrame* frame = GetPrimaryFrame();
 
   if (frame) {
     NumberPairAttributesInfo info = GetNumberPairInfo();
     frame->AttributeChanged(kNameSpaceID_None,
-                            *info.mNumberPairInfo[aAttrEnum].mName,
+                            info.mNumberPairInfo[aAttrEnum].mName,
                             MutationEvent_Binding::SMIL);
   }
 }
 
 nsSVGElement::IntegerAttributesInfo
 nsSVGElement::GetIntegerInfo()
 {
   return IntegerAttributesInfo(nullptr, nullptr, 0);
@@ -1975,29 +1975,29 @@ nsSVGElement::DidChangeInteger(uint8_t a
 
   NS_ASSERTION(info.mIntegerCount > 0,
                "DidChangeInteger on element with no integer attribs");
   NS_ASSERTION(aAttrEnum < info.mIntegerCount, "aAttrEnum out of range");
 
   nsAttrValue attrValue;
   attrValue.SetTo(info.mIntegers[aAttrEnum].GetBaseValue(), nullptr);
 
-  SetParsedAttr(kNameSpaceID_None, *info.mIntegerInfo[aAttrEnum].mName, nullptr,
+  SetParsedAttr(kNameSpaceID_None, info.mIntegerInfo[aAttrEnum].mName, nullptr,
                 attrValue, true);
 }
 
 void
 nsSVGElement::DidAnimateInteger(uint8_t aAttrEnum)
 {
   nsIFrame* frame = GetPrimaryFrame();
 
   if (frame) {
     IntegerAttributesInfo info = GetIntegerInfo();
     frame->AttributeChanged(kNameSpaceID_None,
-                            *info.mIntegerInfo[aAttrEnum].mName,
+                            info.mIntegerInfo[aAttrEnum].mName,
                             MutationEvent_Binding::SMIL);
   }
 }
 
 void
 nsSVGElement::GetAnimatedIntegerValues(int32_t *aFirst, ...)
 {
   IntegerAttributesInfo info = GetIntegerInfo();
@@ -2031,45 +2031,45 @@ nsSVGElement::IntegerPairAttributesInfo:
                                 mIntegerPairInfo[aAttrEnum].mDefaultValue1,
                                 mIntegerPairInfo[aAttrEnum].mDefaultValue2);
 }
 
 nsAttrValue
 nsSVGElement::WillChangeIntegerPair(uint8_t aAttrEnum)
 {
   return WillChangeValue(
-    *GetIntegerPairInfo().mIntegerPairInfo[aAttrEnum].mName);
+    GetIntegerPairInfo().mIntegerPairInfo[aAttrEnum].mName);
 }
 
 void
 nsSVGElement::DidChangeIntegerPair(uint8_t aAttrEnum,
                                    const nsAttrValue& aEmptyOrOldValue)
 {
   IntegerPairAttributesInfo info = GetIntegerPairInfo();
 
   NS_ASSERTION(info.mIntegerPairCount > 0,
                "DidChangeIntegerPair on element with no integer pair attribs");
   NS_ASSERTION(aAttrEnum < info.mIntegerPairCount, "aAttrEnum out of range");
 
   nsAttrValue newValue;
   newValue.SetTo(info.mIntegerPairs[aAttrEnum], nullptr);
 
-  DidChangeValue(*info.mIntegerPairInfo[aAttrEnum].mName, aEmptyOrOldValue,
+  DidChangeValue(info.mIntegerPairInfo[aAttrEnum].mName, aEmptyOrOldValue,
                  newValue);
 }
 
 void
 nsSVGElement::DidAnimateIntegerPair(uint8_t aAttrEnum)
 {
   nsIFrame* frame = GetPrimaryFrame();
 
   if (frame) {
     IntegerPairAttributesInfo info = GetIntegerPairInfo();
     frame->AttributeChanged(kNameSpaceID_None,
-                            *info.mIntegerPairInfo[aAttrEnum].mName,
+                            info.mIntegerPairInfo[aAttrEnum].mName,
                             MutationEvent_Binding::SMIL);
   }
 }
 
 nsSVGElement::AngleAttributesInfo
 nsSVGElement::GetAngleInfo()
 {
   return AngleAttributesInfo(nullptr, nullptr, 0);
@@ -2081,44 +2081,44 @@ nsSVGElement::AngleAttributesInfo::Reset
   mAngles[aAttrEnum].Init(aAttrEnum,
                           mAngleInfo[aAttrEnum].mDefaultValue,
                           mAngleInfo[aAttrEnum].mDefaultUnitType);
 }
 
 nsAttrValue
 nsSVGElement::WillChangeAngle(uint8_t aAttrEnum)
 {
-  return WillChangeValue(*GetAngleInfo().mAngleInfo[aAttrEnum].mName);
+  return WillChangeValue(GetAngleInfo().mAngleInfo[aAttrEnum].mName);
 }
 
 void
 nsSVGElement::DidChangeAngle(uint8_t aAttrEnum,
                              const nsAttrValue& aEmptyOrOldValue)
 {
   AngleAttributesInfo info = GetAngleInfo();
 
   NS_ASSERTION(info.mAngleCount > 0,
                "DidChangeAngle on element with no angle attribs");
   NS_ASSERTION(aAttrEnum < info.mAngleCount, "aAttrEnum out of range");
 
   nsAttrValue newValue;
   newValue.SetTo(info.mAngles[aAttrEnum], nullptr);
 
-  DidChangeValue(*info.mAngleInfo[aAttrEnum].mName, aEmptyOrOldValue, newValue);
+  DidChangeValue(info.mAngleInfo[aAttrEnum].mName, aEmptyOrOldValue, newValue);
 }
 
 void
 nsSVGElement::DidAnimateAngle(uint8_t aAttrEnum)
 {
   nsIFrame* frame = GetPrimaryFrame();
 
   if (frame) {
     AngleAttributesInfo info = GetAngleInfo();
     frame->AttributeChanged(kNameSpaceID_None,
-                            *info.mAngleInfo[aAttrEnum].mName,
+                            info.mAngleInfo[aAttrEnum].mName,
                             MutationEvent_Binding::SMIL);
   }
 }
 
 nsSVGElement::BooleanAttributesInfo
 nsSVGElement::GetBooleanInfo()
 {
   return BooleanAttributesInfo(nullptr, nullptr, 0);
@@ -2136,29 +2136,29 @@ nsSVGElement::DidChangeBoolean(uint8_t a
 {
   BooleanAttributesInfo info = GetBooleanInfo();
 
   NS_ASSERTION(info.mBooleanCount > 0,
                "DidChangeBoolean on element with no boolean attribs");
   NS_ASSERTION(aAttrEnum < info.mBooleanCount, "aAttrEnum out of range");
 
   nsAttrValue attrValue(info.mBooleans[aAttrEnum].GetBaseValueAtom());
-  SetParsedAttr(kNameSpaceID_None, *info.mBooleanInfo[aAttrEnum].mName, nullptr,
+  SetParsedAttr(kNameSpaceID_None, info.mBooleanInfo[aAttrEnum].mName, nullptr,
                 attrValue, true);
 }
 
 void
 nsSVGElement::DidAnimateBoolean(uint8_t aAttrEnum)
 {
   nsIFrame* frame = GetPrimaryFrame();
 
   if (frame) {
     BooleanAttributesInfo info = GetBooleanInfo();
     frame->AttributeChanged(kNameSpaceID_None,
-                            *info.mBooleanInfo[aAttrEnum].mName,
+                            info.mBooleanInfo[aAttrEnum].mName,
                             MutationEvent_Binding::SMIL);
   }
 }
 
 nsSVGElement::EnumAttributesInfo
 nsSVGElement::GetEnumInfo()
 {
   return EnumAttributesInfo(nullptr, nullptr, 0);
@@ -2183,29 +2183,29 @@ nsSVGElement::DidChangeEnum(uint8_t aAtt
 {
   EnumAttributesInfo info = GetEnumInfo();
 
   NS_ASSERTION(info.mEnumCount > 0,
                "DidChangeEnum on element with no enum attribs");
   NS_ASSERTION(aAttrEnum < info.mEnumCount, "aAttrEnum out of range");
 
   nsAttrValue attrValue(info.mEnums[aAttrEnum].GetBaseValueAtom(this));
-  SetParsedAttr(kNameSpaceID_None, *info.mEnumInfo[aAttrEnum].mName, nullptr,
+  SetParsedAttr(kNameSpaceID_None, info.mEnumInfo[aAttrEnum].mName, nullptr,
                 attrValue, true);
 }
 
 void
 nsSVGElement::DidAnimateEnum(uint8_t aAttrEnum)
 {
   nsIFrame* frame = GetPrimaryFrame();
 
   if (frame) {
     EnumAttributesInfo info = GetEnumInfo();
     frame->AttributeChanged(kNameSpaceID_None,
-                            *info.mEnumInfo[aAttrEnum].mName,
+                            info.mEnumInfo[aAttrEnum].mName,
                             MutationEvent_Binding::SMIL);
   }
 }
 
 nsSVGViewBox *
 nsSVGElement::GetViewBox()
 {
   return nullptr;
@@ -2348,87 +2348,87 @@ nsSVGElement::GetStringBaseValue(uint8_t
   nsSVGElement::StringAttributesInfo info = const_cast<nsSVGElement*>(this)->GetStringInfo();
 
   NS_ASSERTION(info.mStringCount > 0,
                "GetBaseValue on element with no string attribs");
 
   NS_ASSERTION(aAttrEnum < info.mStringCount, "aAttrEnum out of range");
 
   GetAttr(info.mStringInfo[aAttrEnum].mNamespaceID,
-          *info.mStringInfo[aAttrEnum].mName, aResult);
+          info.mStringInfo[aAttrEnum].mName, aResult);
 }
 
 void
 nsSVGElement::SetStringBaseValue(uint8_t aAttrEnum, const nsAString& aValue)
 {
   nsSVGElement::StringAttributesInfo info = GetStringInfo();
 
   NS_ASSERTION(info.mStringCount > 0,
                "SetBaseValue on element with no string attribs");
 
   NS_ASSERTION(aAttrEnum < info.mStringCount, "aAttrEnum out of range");
 
   SetAttr(info.mStringInfo[aAttrEnum].mNamespaceID,
-          *info.mStringInfo[aAttrEnum].mName, aValue, true);
+          info.mStringInfo[aAttrEnum].mName, aValue, true);
 }
 
 void
 nsSVGElement::DidAnimateString(uint8_t aAttrEnum)
 {
   nsIFrame* frame = GetPrimaryFrame();
 
   if (frame) {
     StringAttributesInfo info = GetStringInfo();
     frame->AttributeChanged(info.mStringInfo[aAttrEnum].mNamespaceID,
-                            *info.mStringInfo[aAttrEnum].mName,
+                            info.mStringInfo[aAttrEnum].mName,
                             MutationEvent_Binding::SMIL);
   }
 }
 
 nsSVGElement::StringListAttributesInfo
 nsSVGElement::GetStringListInfo()
 {
   return StringListAttributesInfo(nullptr, nullptr, 0);
 }
 
 nsAttrValue
 nsSVGElement::WillChangeStringList(bool aIsConditionalProcessingAttribute,
                                    uint8_t aAttrEnum)
 {
-  nsAtom* name;
+  nsStaticAtom* name;
   if (aIsConditionalProcessingAttribute) {
     nsCOMPtr<SVGTests> tests(do_QueryInterface(this));
     name = tests->GetAttrName(aAttrEnum);
   } else {
-    name = *GetStringListInfo().mStringListInfo[aAttrEnum].mName;
+    name = GetStringListInfo().mStringListInfo[aAttrEnum].mName;
   }
   return WillChangeValue(name);
 }
 
 void
 nsSVGElement::DidChangeStringList(bool aIsConditionalProcessingAttribute,
                                   uint8_t aAttrEnum,
                                   const nsAttrValue& aEmptyOrOldValue)
 {
-  nsAtom* name;
+  nsStaticAtom* name;
   nsAttrValue newValue;
   nsCOMPtr<SVGTests> tests;
 
   if (aIsConditionalProcessingAttribute) {
     tests = do_QueryObject(this);
     name = tests->GetAttrName(aAttrEnum);
     tests->GetAttrValue(aAttrEnum, newValue);
   } else {
     StringListAttributesInfo info = GetStringListInfo();
 
     NS_ASSERTION(info.mStringListCount > 0,
                  "DidChangeStringList on element with no string list attribs");
     NS_ASSERTION(aAttrEnum < info.mStringListCount, "aAttrEnum out of range");
 
-    name = *info.mStringListInfo[aAttrEnum].mName;
+    name = info.mStringListInfo[aAttrEnum].mName;
     newValue.SetTo(info.mStringLists[aAttrEnum], nullptr);
   }
 
   DidChangeValue(name, aEmptyOrOldValue, newValue);
 
   if (aIsConditionalProcessingAttribute) {
     tests->MaybeInvalidate();
   }
@@ -2491,86 +2491,86 @@ nsSVGElement::GetAnimatedAttr(int32_t aN
     // Motion (fake 'attribute' for animateMotion)
     if (aName == nsGkAtoms::mozAnimateMotionDummyAttr) {
       return MakeUnique<SVGMotionSMILAttr>(this);
     }
 
     // Lengths:
     LengthAttributesInfo info = GetLengthInfo();
     for (uint32_t i = 0; i < info.mLengthCount; i++) {
-      if (aName == *info.mLengthInfo[i].mName) {
+      if (aName == info.mLengthInfo[i].mName) {
         return info.mLengths[i].ToSMILAttr(this);
       }
     }
 
     // Numbers:
     {
       NumberAttributesInfo info = GetNumberInfo();
       for (uint32_t i = 0; i < info.mNumberCount; i++) {
-        if (aName == *info.mNumberInfo[i].mName) {
+        if (aName == info.mNumberInfo[i].mName) {
           return info.mNumbers[i].ToSMILAttr(this);
         }
       }
     }
 
     // Number Pairs:
     {
       NumberPairAttributesInfo info = GetNumberPairInfo();
       for (uint32_t i = 0; i < info.mNumberPairCount; i++) {
-        if (aName == *info.mNumberPairInfo[i].mName) {
+        if (aName == info.mNumberPairInfo[i].mName) {
           return info.mNumberPairs[i].ToSMILAttr(this);
         }
       }
     }
 
     // Integers:
     {
       IntegerAttributesInfo info = GetIntegerInfo();
       for (uint32_t i = 0; i < info.mIntegerCount; i++) {
-        if (aName == *info.mIntegerInfo[i].mName) {
+        if (aName == info.mIntegerInfo[i].mName) {
           return info.mIntegers[i].ToSMILAttr(this);
         }
       }
     }
 
     // Integer Pairs:
     {
       IntegerPairAttributesInfo info = GetIntegerPairInfo();
       for (uint32_t i = 0; i < info.mIntegerPairCount; i++) {
-        if (aName == *info.mIntegerPairInfo[i].mName) {
+        if (aName == info.mIntegerPairInfo[i].mName) {
           return info.mIntegerPairs[i].ToSMILAttr(this);
         }
       }
     }
 
     // Enumerations:
     {
       EnumAttributesInfo info = GetEnumInfo();
       for (uint32_t i = 0; i < info.mEnumCount; i++) {
-        if (aName == *info.mEnumInfo[i].mName) {
+        if (aName == info.mEnumInfo[i].mName) {
           return info.mEnums[i].ToSMILAttr(this);
         }
       }
     }
 
     // Booleans:
     {
       BooleanAttributesInfo info = GetBooleanInfo();
       for (uint32_t i = 0; i < info.mBooleanCount; i++) {
-        if (aName == *info.mBooleanInfo[i].mName) {
+        if (aName == info.mBooleanInfo[i].mName) {
           return info.mBooleans[i].ToSMILAttr(this);
         }
       }
     }
 
     // Angles:
     {
       AngleAttributesInfo info = GetAngleInfo();
       for (uint32_t i = 0; i < info.mAngleCount; i++) {
-        if (aName == *info.mAngleInfo[i].mName) {
+        if (aName == info.mAngleInfo[i].mName) {
           return info.mAngles[i].ToSMILAttr(this);
         }
       }
     }
 
     // viewBox:
     if (aName == nsGkAtoms::viewBox) {
       nsSVGViewBox *viewBox = GetViewBox();
@@ -2584,28 +2584,28 @@ nsSVGElement::GetAnimatedAttr(int32_t aN
       return preserveAspectRatio ?
         preserveAspectRatio->ToSMILAttr(this) : nullptr;
     }
 
     // NumberLists:
     {
       NumberListAttributesInfo info = GetNumberListInfo();
       for (uint32_t i = 0; i < info.mNumberListCount; i++) {
-        if (aName == *info.mNumberListInfo[i].mName) {
+        if (aName == info.mNumberListInfo[i].mName) {
           MOZ_ASSERT(i <= UCHAR_MAX, "Too many attributes");
           return info.mNumberLists[i].ToSMILAttr(this, uint8_t(i));
         }
       }
     }
 
     // LengthLists:
     {
       LengthListAttributesInfo info = GetLengthListInfo();
       for (uint32_t i = 0; i < info.mLengthListCount; i++) {
-        if (aName == *info.mLengthListInfo[i].mName) {
+        if (aName == info.mLengthListInfo[i].mName) {
           MOZ_ASSERT(i <= UCHAR_MAX, "Too many attributes");
           return info.mLengthLists[i].ToSMILAttr(this,
                                                  uint8_t(i),
                                                  info.mLengthListInfo[i].mAxis,
                                                  info.mLengthListInfo[i].mCouldZeroPadList);
         }
       }
     }
@@ -2635,17 +2635,17 @@ nsSVGElement::GetAnimatedAttr(int32_t aN
     }
   }
 
   // Strings
   {
     StringAttributesInfo info = GetStringInfo();
     for (uint32_t i = 0; i < info.mStringCount; i++) {
       if (aNamespaceID == info.mStringInfo[i].mNamespaceID &&
-          aName == *info.mStringInfo[i].mName) {
+          aName == info.mStringInfo[i].mName) {
         return info.mStrings[i].ToSMILAttr(this);
       }
     }
   }
 
   return nullptr;
 }
 
--- a/dom/svg/nsSVGElement.h
+++ b/dom/svg/nsSVGElement.h
@@ -281,23 +281,23 @@ public:
   void AnimationNeedsResample();
   void FlushAnimations();
 
   virtual void RecompileScriptEventListeners() override;
 
   void GetStringBaseValue(uint8_t aAttrEnum, nsAString& aResult) const;
   void SetStringBaseValue(uint8_t aAttrEnum, const nsAString& aValue);
 
-  virtual nsAtom* GetPointListAttrName() const {
+  virtual nsStaticAtom* GetPointListAttrName() const {
     return nullptr;
   }
-  virtual nsAtom* GetPathDataAttrName() const {
+  virtual nsStaticAtom* GetPathDataAttrName() const {
     return nullptr;
   }
-  virtual nsAtom* GetTransformListAttrName() const {
+  virtual nsStaticAtom* GetTransformListAttrName() const {
     return nullptr;
   }
   const nsAttrValue* GetAnimatedClassName() const
   {
     if (!mClassAttribute.IsAnimated()) {
       return nullptr;
     }
     return mClassAnimAttr;
@@ -339,266 +339,267 @@ protected:
                                 nsAttrValue& aResult) override;
   static nsresult ReportAttributeParseFailure(nsIDocument* aDocument,
                                               nsAtom* aAttribute,
                                               const nsAString& aValue);
 
   nsAttrValue WillChangeValue(nsAtom* aName);
   // aNewValue is set to the old value. This value may be invalid if
   // !StoresOwnData.
-  void DidChangeValue(nsAtom* aName, const nsAttrValue& aEmptyOrOldValue,
+  void DidChangeValue(nsAtom* aName,
+                      const nsAttrValue& aEmptyOrOldValue,
                       nsAttrValue& aNewValue);
   void MaybeSerializeAttrBeforeRemoval(nsAtom* aName, bool aNotify);
 
   static nsAtom* GetEventNameForAttr(nsAtom* aAttr);
 
   struct LengthInfo {
-    nsStaticAtom** mName;
-    float     mDefaultValue;
-    uint8_t   mDefaultUnitType;
-    uint8_t   mCtxType;
+    nsStaticAtom* const mName;
+    const float mDefaultValue;
+    const uint8_t mDefaultUnitType;
+    const uint8_t mCtxType;
   };
 
   struct LengthAttributesInfo {
-    nsSVGLength2* mLengths;
-    LengthInfo*   mLengthInfo;
-    uint32_t      mLengthCount;
+    nsSVGLength2* const mLengths;
+    const LengthInfo* const mLengthInfo;
+    const uint32_t mLengthCount;
 
     LengthAttributesInfo(nsSVGLength2 *aLengths,
                          LengthInfo *aLengthInfo,
                          uint32_t aLengthCount) :
       mLengths(aLengths), mLengthInfo(aLengthInfo), mLengthCount(aLengthCount)
       {}
 
     void Reset(uint8_t aAttrEnum);
   };
 
   struct NumberInfo {
-    nsStaticAtom** mName;
-    float     mDefaultValue;
-    bool mPercentagesAllowed;
+    nsStaticAtom* const mName;
+    const float mDefaultValue;
+    const bool mPercentagesAllowed;
   };
 
   struct NumberAttributesInfo {
-    nsSVGNumber2* mNumbers;
-    NumberInfo*   mNumberInfo;
-    uint32_t      mNumberCount;
+    nsSVGNumber2* const mNumbers;
+    const NumberInfo* const mNumberInfo;
+    const uint32_t mNumberCount;
 
     NumberAttributesInfo(nsSVGNumber2 *aNumbers,
                          NumberInfo *aNumberInfo,
                          uint32_t aNumberCount) :
       mNumbers(aNumbers), mNumberInfo(aNumberInfo), mNumberCount(aNumberCount)
       {}
 
     void Reset(uint8_t aAttrEnum);
   };
 
   struct NumberPairInfo {
-    nsStaticAtom** mName;
-    float     mDefaultValue1;
-    float     mDefaultValue2;
+    nsStaticAtom* const mName;
+    const float mDefaultValue1;
+    const float mDefaultValue2;
   };
 
   struct NumberPairAttributesInfo {
-    nsSVGNumberPair* mNumberPairs;
-    NumberPairInfo*  mNumberPairInfo;
-    uint32_t         mNumberPairCount;
+    nsSVGNumberPair* const mNumberPairs;
+    const NumberPairInfo* const mNumberPairInfo;
+    const uint32_t mNumberPairCount;
 
     NumberPairAttributesInfo(nsSVGNumberPair *aNumberPairs,
                              NumberPairInfo *aNumberPairInfo,
                              uint32_t aNumberPairCount) :
       mNumberPairs(aNumberPairs), mNumberPairInfo(aNumberPairInfo),
       mNumberPairCount(aNumberPairCount)
       {}
 
     void Reset(uint8_t aAttrEnum);
   };
 
   struct IntegerInfo {
-    nsStaticAtom** mName;
-    int32_t   mDefaultValue;
+    nsStaticAtom* const mName;
+    const int32_t mDefaultValue;
   };
 
   struct IntegerAttributesInfo {
-    nsSVGInteger* mIntegers;
-    IntegerInfo*  mIntegerInfo;
-    uint32_t      mIntegerCount;
+    nsSVGInteger* const mIntegers;
+    const IntegerInfo* const mIntegerInfo;
+    const uint32_t mIntegerCount;
 
     IntegerAttributesInfo(nsSVGInteger *aIntegers,
                           IntegerInfo *aIntegerInfo,
                           uint32_t aIntegerCount) :
       mIntegers(aIntegers), mIntegerInfo(aIntegerInfo), mIntegerCount(aIntegerCount)
       {}
 
     void Reset(uint8_t aAttrEnum);
   };
 
   struct IntegerPairInfo {
-    nsStaticAtom** mName;
-    int32_t   mDefaultValue1;
-    int32_t   mDefaultValue2;
+    nsStaticAtom* const mName;
+    const int32_t mDefaultValue1;
+    const int32_t mDefaultValue2;
   };
 
   struct IntegerPairAttributesInfo {
-    nsSVGIntegerPair* mIntegerPairs;
-    IntegerPairInfo*  mIntegerPairInfo;
-    uint32_t          mIntegerPairCount;
+    nsSVGIntegerPair* const mIntegerPairs;
+    const IntegerPairInfo* const mIntegerPairInfo;
+    const uint32_t mIntegerPairCount;
 
     IntegerPairAttributesInfo(nsSVGIntegerPair *aIntegerPairs,
                               IntegerPairInfo *aIntegerPairInfo,
                               uint32_t aIntegerPairCount) :
       mIntegerPairs(aIntegerPairs), mIntegerPairInfo(aIntegerPairInfo),
       mIntegerPairCount(aIntegerPairCount)
       {}
 
     void Reset(uint8_t aAttrEnum);
   };
 
   struct AngleInfo {
-    nsStaticAtom** mName;
-    float     mDefaultValue;
-    uint8_t   mDefaultUnitType;
+    nsStaticAtom* const mName;
+    const float mDefaultValue;
+    const uint8_t mDefaultUnitType;
   };
 
   struct AngleAttributesInfo {
-    nsSVGAngle* mAngles;
-    AngleInfo*  mAngleInfo;
-    uint32_t    mAngleCount;
+    nsSVGAngle* const mAngles;
+    const AngleInfo* const mAngleInfo;
+    const uint32_t mAngleCount;
 
     AngleAttributesInfo(nsSVGAngle *aAngles,
                         AngleInfo *aAngleInfo,
                         uint32_t aAngleCount) :
       mAngles(aAngles), mAngleInfo(aAngleInfo), mAngleCount(aAngleCount)
       {}
 
     void Reset(uint8_t aAttrEnum);
   };
 
   struct BooleanInfo {
-    nsStaticAtom** mName;
-    bool mDefaultValue;
+    nsStaticAtom* const mName;
+    const bool mDefaultValue;
   };
 
   struct BooleanAttributesInfo {
-    nsSVGBoolean* mBooleans;
-    BooleanInfo*  mBooleanInfo;
-    uint32_t      mBooleanCount;
+    nsSVGBoolean* const mBooleans;
+    const BooleanInfo* const mBooleanInfo;
+    const uint32_t mBooleanCount;
 
     BooleanAttributesInfo(nsSVGBoolean *aBooleans,
                           BooleanInfo *aBooleanInfo,
                           uint32_t aBooleanCount) :
       mBooleans(aBooleans), mBooleanInfo(aBooleanInfo), mBooleanCount(aBooleanCount)
       {}
 
     void Reset(uint8_t aAttrEnum);
   };
 
   friend class nsSVGEnum;
 
   struct EnumInfo {
-    nsStaticAtom**    mName;
-    nsSVGEnumMapping* mMapping;
-    uint16_t          mDefaultValue;
+    nsStaticAtom* const mName;
+    const nsSVGEnumMapping* const mMapping;
+    const uint16_t mDefaultValue;
   };
 
   struct EnumAttributesInfo {
-    nsSVGEnum* mEnums;
-    EnumInfo*  mEnumInfo;
-    uint32_t   mEnumCount;
+    nsSVGEnum* const mEnums;
+    const EnumInfo* const mEnumInfo;
+    const uint32_t mEnumCount;
 
     EnumAttributesInfo(nsSVGEnum *aEnums,
                        EnumInfo *aEnumInfo,
                        uint32_t aEnumCount) :
       mEnums(aEnums), mEnumInfo(aEnumInfo), mEnumCount(aEnumCount)
       {}
 
     void Reset(uint8_t aAttrEnum);
     void SetUnknownValue(uint8_t aAttrEnum);
   };
 
   struct NumberListInfo {
-    nsStaticAtom** mName;
+    nsStaticAtom* const mName;
   };
 
   struct NumberListAttributesInfo {
-    SVGAnimatedNumberList* mNumberLists;
-    NumberListInfo*        mNumberListInfo;
-    uint32_t               mNumberListCount;
+    SVGAnimatedNumberList* const mNumberLists;
+    const NumberListInfo* const mNumberListInfo;
+    const uint32_t mNumberListCount;
 
     NumberListAttributesInfo(SVGAnimatedNumberList *aNumberLists,
                              NumberListInfo *aNumberListInfo,
                              uint32_t aNumberListCount)
       : mNumberLists(aNumberLists)
       , mNumberListInfo(aNumberListInfo)
       , mNumberListCount(aNumberListCount)
     {}
 
     void Reset(uint8_t aAttrEnum);
   };
 
   struct LengthListInfo {
-    nsStaticAtom** mName;
-    uint8_t   mAxis;
+    nsStaticAtom* const mName;
+    const uint8_t mAxis;
     /**
      * Flag to indicate whether appending zeros to the end of the list would
      * change the rendering of the SVG for the attribute in question. For x and
      * y on the <text> element this is true, but for dx and dy on <text> this
      * is false. This flag is fed down to SVGLengthListSMILType so it can
      * determine if it can sensibly animate from-to lists of different lengths,
      * which is desirable in the case of dx and dy.
      */
-    bool mCouldZeroPadList;
+    const bool mCouldZeroPadList;
   };
 
   struct LengthListAttributesInfo {
-    SVGAnimatedLengthList* mLengthLists;
-    LengthListInfo*        mLengthListInfo;
-    uint32_t               mLengthListCount;
+    SVGAnimatedLengthList* const mLengthLists;
+    const LengthListInfo* const mLengthListInfo;
+    const uint32_t mLengthListCount;
 
     LengthListAttributesInfo(SVGAnimatedLengthList *aLengthLists,
                              LengthListInfo *aLengthListInfo,
                              uint32_t aLengthListCount)
       : mLengthLists(aLengthLists)
       , mLengthListInfo(aLengthListInfo)
       , mLengthListCount(aLengthListCount)
     {}
 
     void Reset(uint8_t aAttrEnum);
   };
 
   struct StringInfo {
-    nsStaticAtom** mName;
-    int32_t      mNamespaceID;
-    bool mIsAnimatable;
+    nsStaticAtom* const mName;
+    const int32_t mNamespaceID;
+    const bool mIsAnimatable;
   };
 
   struct StringAttributesInfo {
-    nsSVGString*  mStrings;
-    StringInfo*   mStringInfo;
-    uint32_t      mStringCount;
+    nsSVGString* const mStrings;
+    const StringInfo* const mStringInfo;
+    const uint32_t mStringCount;
 
     StringAttributesInfo(nsSVGString *aStrings,
                          StringInfo *aStringInfo,
                          uint32_t aStringCount) :
       mStrings(aStrings), mStringInfo(aStringInfo), mStringCount(aStringCount)
       {}
 
     void Reset(uint8_t aAttrEnum);
   };
 
   friend class mozilla::DOMSVGStringList;
 
   struct StringListInfo {
-    nsStaticAtom** mName;
+    nsStaticAtom* const mName;
   };
 
   struct StringListAttributesInfo {
-    SVGStringList*    mStringLists;
-    StringListInfo*   mStringListInfo;
-    uint32_t          mStringListCount;
+    SVGStringList* const mStringLists;
+    const StringListInfo* const mStringListInfo;
+    const uint32_t mStringListCount;
 
     StringListAttributesInfo(SVGStringList  *aStringLists,
                              StringListInfo *aStringListInfo,
                              uint32_t aStringListCount) :
       mStringLists(aStringLists), mStringListInfo(aStringListInfo),
       mStringListCount(aStringListCount)
       {}
 
--- a/dom/svg/nsSVGEnum.cpp
+++ b/dom/svg/nsSVGEnum.cpp
@@ -13,34 +13,34 @@
 #include "SMILEnumType.h"
 
 using namespace mozilla;
 using namespace mozilla::dom;
 
 static nsSVGAttrTearoffTable<nsSVGEnum, nsSVGEnum::DOMAnimatedEnum>
   sSVGAnimatedEnumTearoffTable;
 
-nsSVGEnumMapping *
+const nsSVGEnumMapping*
 nsSVGEnum::GetMapping(nsSVGElement *aSVGElement)
 {
   nsSVGElement::EnumAttributesInfo info = aSVGElement->GetEnumInfo();
 
   NS_ASSERTION(info.mEnumCount > 0 && mAttrEnum < info.mEnumCount,
                "mapping request for a non-attrib enum");
 
   return info.mEnumInfo[mAttrEnum].mMapping;
 }
 
 nsresult
 nsSVGEnum::SetBaseValueAtom(const nsAtom* aValue, nsSVGElement *aSVGElement)
 {
-  nsSVGEnumMapping *mapping = GetMapping(aSVGElement);
+  const nsSVGEnumMapping* mapping = GetMapping(aSVGElement);
 
   while (mapping && mapping->mKey) {
-    if (aValue == *(mapping->mKey)) {
+    if (aValue == mapping->mKey) {
       mIsBaseSet = true;
       if (mBaseVal != mapping->mVal) {
         mBaseVal = mapping->mVal;
         if (!mIsAnimated) {
           mAnimVal = mBaseVal;
         }
         else {
           aSVGElement->AnimationNeedsResample();
@@ -55,33 +55,33 @@ nsSVGEnum::SetBaseValueAtom(const nsAtom
   }
 
   return NS_ERROR_DOM_TYPE_ERR;
 }
 
 nsAtom*
 nsSVGEnum::GetBaseValueAtom(nsSVGElement *aSVGElement)
 {
-  nsSVGEnumMapping *mapping = GetMapping(aSVGElement);
+  const nsSVGEnumMapping* mapping = GetMapping(aSVGElement);
 
   while (mapping && mapping->mKey) {
     if (mBaseVal == mapping->mVal) {
-      return *mapping->mKey;
+      return mapping->mKey;
     }
     mapping++;
   }
   NS_ERROR("unknown enumeration value");
   return nsGkAtoms::_empty;
 }
 
 nsresult
 nsSVGEnum::SetBaseValue(uint16_t aValue,
                         nsSVGElement *aSVGElement)
 {
-  nsSVGEnumMapping *mapping = GetMapping(aSVGElement);
+  const nsSVGEnumMapping* mapping = GetMapping(aSVGElement);
 
   while (mapping && mapping->mKey) {
     if (mapping->mVal == aValue) {
       mIsBaseSet = true;
       if (mBaseVal != uint8_t(aValue)) {
         mBaseVal = uint8_t(aValue);
         if (!mIsAnimated) {
           mAnimVal = mBaseVal;
@@ -136,20 +136,20 @@ nsSVGEnum::ToSMILAttr(nsSVGElement *aSVG
 nsresult
 nsSVGEnum::SMILEnum::ValueFromString(const nsAString& aStr,
                                      const dom::SVGAnimationElement* /*aSrcElement*/,
                                      nsSMILValue& aValue,
                                      bool& aPreventCachingOfSandwich) const
 {
   nsAtom *valAtom = NS_GetStaticAtom(aStr);
   if (valAtom) {
-    nsSVGEnumMapping *mapping = mVal->GetMapping(mSVGElement);
+    const nsSVGEnumMapping* mapping = mVal->GetMapping(mSVGElement);
 
     while (mapping && mapping->mKey) {
-      if (valAtom == *(mapping->mKey)) {
+      if (valAtom == mapping->mKey) {
         nsSMILValue val(SMILEnumType::Singleton());
         val.mU.mUint = mapping->mVal;
         aValue = val;
         aPreventCachingOfSandwich = false;
         return NS_OK;
       }
       mapping++;
     }
--- a/dom/svg/nsSVGEnum.h
+++ b/dom/svg/nsSVGEnum.h
@@ -22,18 +22,18 @@ namespace mozilla {
 namespace dom {
 class SVGAnimationElement;
 } // namespace dom
 } // namespace mozilla
 
 typedef uint8_t nsSVGEnumValue;
 
 struct nsSVGEnumMapping {
-  nsStaticAtom** mKey;
-  nsSVGEnumValue mVal;
+  nsStaticAtom* const mKey;
+  const nsSVGEnumValue mVal;
 };
 
 class nsSVGEnum
 {
 public:
   void Init(uint8_t aAttrEnum, uint16_t aValue) {
     mAnimVal = mBaseVal = uint8_t(aValue);
     mAttrEnum = aAttrEnum;
@@ -61,17 +61,17 @@ public:
 
 private:
   nsSVGEnumValue mAnimVal;
   nsSVGEnumValue mBaseVal;
   uint8_t mAttrEnum; // element specified tracking for attribute
   bool mIsAnimated;
   bool mIsBaseSet;
 
-  nsSVGEnumMapping *GetMapping(nsSVGElement *aSVGElement);
+  const nsSVGEnumMapping* GetMapping(nsSVGElement *aSVGElement);
 
 public:
   struct DOMAnimatedEnum final : public mozilla::dom::SVGAnimatedEnumeration
   {
     DOMAnimatedEnum(nsSVGEnum* aVal, nsSVGElement *aSVGElement)
       : mozilla::dom::SVGAnimatedEnumeration(aSVGElement)
       , mVal(aVal)
     {}
--- a/dom/svg/nsSVGFilters.cpp
+++ b/dom/svg/nsSVGFilters.cpp
@@ -48,20 +48,20 @@
 using namespace mozilla;
 using namespace mozilla::dom;
 using namespace mozilla::gfx;
 
 //--------------------Filter Element Base Class-----------------------
 
 nsSVGElement::LengthInfo nsSVGFE::sLengthInfo[4] =
 {
-  { &nsGkAtoms::x, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
-  { &nsGkAtoms::y, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
-  { &nsGkAtoms::width, 100, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
-  { &nsGkAtoms::height, 100, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y }
+  { nsGkAtoms::x, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
+  { nsGkAtoms::y, 0, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y },
+  { nsGkAtoms::width, 100, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::X },
+  { nsGkAtoms::height, 100, SVGLength_Binding::SVG_LENGTHTYPE_PERCENTAGE, SVGContentUtils::Y }
 };
 
 //----------------------------------------------------------------------
 // nsISupports methods
 
 NS_IMPL_ADDREF_INHERITED(nsSVGFE,nsSVGFEBase)
 NS_IMPL_RELEASE_INHERITED(nsSVGFE,nsSVGFEBase)
 
@@ -195,45 +195,45 @@ nsSVGFE::GetLengthInfo()
                               ArrayLength(sLengthInfo));
 }
 
 namespace mozilla {
 namespace dom {
 
 nsSVGElement::NumberListInfo SVGComponentTransferFunctionElement::sNumberListInfo[1] =
 {
-  { &nsGkAtoms::tableValues }
+  { nsGkAtoms::tableValues }
 };
 
 nsSVGElement::NumberInfo SVGComponentTransferFunctionElement::sNumberInfo[5] =
 {
-  { &nsGkAtoms::slope,     1, false },
-  { &nsGkAtoms::intercept, 0, false },
-  { &nsGkAtoms::amplitude, 1, false },
-  { &nsGkAtoms::exponent,  1, false },
-  { &nsGkAtoms::offset,    0, false }
+  { nsGkAtoms::slope,     1, false },
+  { nsGkAtoms::intercept, 0, false },
+  { nsGkAtoms::amplitude, 1, false },
+  { nsGkAtoms::exponent,  1, false },
+  { nsGkAtoms::offset,    0, false }
 };
 
 nsSVGEnumMapping SVGComponentTransferFunctionElement::sTypeMap[] = {
-  {&nsGkAtoms::identity,
+  {nsGkAtoms::identity,
    SVG_FECOMPONENTTRANSFER_TYPE_IDENTITY},
-  {&nsGkAtoms::table,
+  {nsGkAtoms::table,
    SVG_FECOMPONENTTRANSFER_TYPE_TABLE},
-  {&nsGkAtoms::discrete,
+  {nsGkAtoms::discrete,
    SVG_FECOMPONENTTRANSFER_TYPE_DISCRETE},
-  {&nsGkAtoms::linear,
+  {nsGkAtoms::linear,
    SVG_FECOMPONENTTRANSFER_TYPE_LINEAR},
-  {&nsGkAtoms::gamma,
+  {nsGkAtoms::gamma,
    SVG_FECOMPONENTTRANSFER_TYPE_GAMMA},
   {nullptr, 0}
 };
 
 nsSVGElement::EnumInfo SVGComponentTransferFunctionElement::sEnumInfo[1] =
 {
-  { &nsGkAtoms::type,
+  { nsGkAtoms::type,
     sTypeMap,
     SVG_FECOMPONENTTRANSFER_TYPE_IDENTITY
   }
 };
 
 //----------------------------------------------------------------------
 // nsISupports methods
 
@@ -436,31 +436,31 @@ NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEFun
 
 } // namespace dom
 } // namespace mozilla
 
 //--------------------------------------------------------------------
 //
 nsSVGElement::NumberInfo nsSVGFELightingElement::sNumberInfo[4] =
 {
-  { &nsGkAtoms::surfaceScale, 1, false },
-  { &nsGkAtoms::diffuseConstant, 1, false },
-  { &nsGkAtoms::specularConstant, 1, false },
-  { &nsGkAtoms::specularExponent, 1, false }
+  { nsGkAtoms::surfaceScale, 1, false },
+  { nsGkAtoms::diffuseConstant, 1, false },
+  { nsGkAtoms::specularConstant, 1, false },
+  { nsGkAtoms::specularExponent, 1, false }
 };
 
 nsSVGElement::NumberPairInfo nsSVGFELightingElement::sNumberPairInfo[1] =
 {
-  { &nsGkAtoms::kernelUnitLength, 0, 0 }
+  { nsGkAtoms::kernelUnitLength, 0, 0 }
 };
 
 nsSVGElement::StringInfo nsSVGFELightingElement::sStringInfo[2] =
 {
-  { &nsGkAtoms::result, kNameSpaceID_None, true },
-  { &nsGkAtoms::in, kNameSpaceID_None, true }
+  { nsGkAtoms::result, kNameSpaceID_None, true },
+  { nsGkAtoms::in, kNameSpaceID_None, true }
 };
 
 //----------------------------------------------------------------------
 // Implementation
 
 NS_IMETHODIMP_(bool)
 nsSVGFELightingElement::IsAttributeMapped(const nsAtom* name) const
 {
--- a/dom/svg/nsSVGLength2.cpp
+++ b/dom/svg/nsSVGLength2.cpp
@@ -17,29 +17,29 @@
 #include "nsSVGIntegrationUtils.h"
 #include "nsTextFormatter.h"
 #include "DOMSVGLength.h"
 #include "LayoutLogging.h"
 
 using namespace mozilla;
 using namespace mozilla::dom;
 
-static nsStaticAtom** const unitMap[] =
+static const nsStaticAtom* const unitMap[] =
 {
   nullptr, /* SVG_LENGTHTYPE_UNKNOWN */
   nullptr, /* SVG_LENGTHTYPE_NUMBER */
-  &nsGkAtoms::percentage,
-  &nsGkAtoms::em,
-  &nsGkAtoms::ex,
-  &nsGkAtoms::px,
-  &nsGkAtoms::cm,
-  &nsGkAtoms::mm,
-  &nsGkAtoms::in,
-  &nsGkAtoms::pt,
-  &nsGkAtoms::pc
+  nsGkAtoms::percentage,
+  nsGkAtoms::em,
+  nsGkAtoms::ex,
+  nsGkAtoms::px,
+  nsGkAtoms::cm,
+  nsGkAtoms::mm,
+  nsGkAtoms::in,
+  nsGkAtoms::pt,
+  nsGkAtoms::pc
 };
 
 static nsSVGAttrTearoffTable<nsSVGLength2, SVGAnimatedLength>
   sSVGAnimatedLengthTearoffTable;
 
 /* Helper functions */
 
 static bool
@@ -52,34 +52,34 @@ IsValidUnitType(uint16_t unit)
   return false;
 }
 
 static void
 GetUnitString(nsAString& unit, uint16_t unitType)
 {
   if (IsValidUnitType(unitType)) {
     if (unitMap[unitType]) {
-      (*unitMap[unitType])->ToString(unit);
+      unitMap[unitType]->ToString(unit);
     }
     return;
   }
 
   MOZ_ASSERT_UNREACHABLE("Unknown unit type");
 }
 
 static uint16_t
 GetUnitTypeForString(const nsAString& unitStr)
 {
   if (unitStr.IsEmpty())
     return SVGLength_Binding::SVG_LENGTHTYPE_NUMBER;
 
   nsAtom *unitAtom = NS_GetStaticAtom(unitStr);
   if (unitAtom) {
     for (uint32_t i = 0 ; i < ArrayLength(unitMap) ; i++) {
-      if (unitMap[i] && *unitMap[i] == unitAtom) {
+      if (unitMap[i] == unitAtom) {
         return i;
       }
     }
   }
 
   return SVGLength_Binding::SVG_LENGTHTYPE_UNKNOWN;
 }
 
--- a/dom/xbl/nsXBLPrototypeBinding.cpp
+++ b/dom/xbl/nsXBLPrototypeBinding.cpp
@@ -1542,26 +1542,26 @@ nsXBLPrototypeBinding::WriteNamespace(ns
 
   return NS_OK;
 }
 
 
 bool CheckTagNameWhiteList(int32_t aNameSpaceID, nsAtom *aTagName)
 {
   static Element::AttrValuesArray kValidXULTagNames[] =  {
-    &nsGkAtoms::box, &nsGkAtoms::browser,
-    &nsGkAtoms::button, &nsGkAtoms::hbox, &nsGkAtoms::image, &nsGkAtoms::menu,
-    &nsGkAtoms::menubar, &nsGkAtoms::menuitem, &nsGkAtoms::menupopup,
-    &nsGkAtoms::row, &nsGkAtoms::slider, &nsGkAtoms::spacer,
-    &nsGkAtoms::splitter, &nsGkAtoms::text, &nsGkAtoms::tree, nullptr};
+    nsGkAtoms::box, nsGkAtoms::browser,
+    nsGkAtoms::button, nsGkAtoms::hbox, nsGkAtoms::image, nsGkAtoms::menu,
+    nsGkAtoms::menubar, nsGkAtoms::menuitem, nsGkAtoms::menupopup,
+    nsGkAtoms::row, nsGkAtoms::slider, nsGkAtoms::spacer,
+    nsGkAtoms::splitter, nsGkAtoms::text, nsGkAtoms::tree, nullptr};
 
   uint32_t i;
   if (aNameSpaceID == kNameSpaceID_XUL) {
     for (i = 0; kValidXULTagNames[i]; ++i) {
-      if (aTagName == *(kValidXULTagNames[i])) {
+      if (aTagName == kValidXULTagNames[i]) {
         return true;
       }
     }
   }
   else if (aNameSpaceID == kNameSpaceID_SVG &&
            aTagName == nsGkAtoms::generic_) {
     return true;
   }
--- a/dom/xslt/xpath/txCoreFunctionCall.cpp
+++ b/dom/xslt/xpath/txCoreFunctionCall.cpp
@@ -16,56 +16,56 @@
 #include <math.h>
 #include "txStringUtils.h"
 #include "txXMLUtils.h"
 
 using namespace mozilla;
 
 struct txCoreFunctionDescriptor
 {
-    int8_t mMinParams;
-    int8_t mMaxParams;
-    Expr::ResultType mReturnType;
-    nsStaticAtom** mName;
+    const int8_t mMinParams;
+    const int8_t mMaxParams;
+    const Expr::ResultType mReturnType;
+    const nsStaticAtom* const mName;
 };
 
 // This must be ordered in the same order as txCoreFunctionCall::eType.
 // If you change one, change the other.
 static const txCoreFunctionDescriptor descriptTable[] =
 {
-    { 1, 1, Expr::NUMBER_RESULT,  &nsGkAtoms::count }, // COUNT
-    { 1, 1, Expr::NODESET_RESULT, &nsGkAtoms::id }, // ID
-    { 0, 0, Expr::NUMBER_RESULT,  &nsGkAtoms::last }, // LAST
-    { 0, 1, Expr::STRING_RESULT,  &nsGkAtoms::localName }, // LOCAL_NAME
-    { 0, 1, Expr::STRING_RESULT,  &nsGkAtoms::namespaceUri }, // NAMESPACE_URI
-    { 0, 1, Expr::STRING_RESULT,  &nsGkAtoms::name }, // NAME
-    { 0, 0, Expr::NUMBER_RESULT,  &nsGkAtoms::position }, // POSITION
+    { 1, 1, Expr::NUMBER_RESULT,  nsGkAtoms::count }, // COUNT
+    { 1, 1, Expr::NODESET_RESULT, nsGkAtoms::id }, // ID
+    { 0, 0, Expr::NUMBER_RESULT,  nsGkAtoms::last }, // LAST
+    { 0, 1, Expr::STRING_RESULT,  nsGkAtoms::localName }, // LOCAL_NAME
+    { 0, 1, Expr::STRING_RESULT,  nsGkAtoms::namespaceUri }, // NAMESPACE_URI
+    { 0, 1, Expr::STRING_RESULT,  nsGkAtoms::name }, // NAME
+    { 0, 0, Expr::NUMBER_RESULT,  nsGkAtoms::position }, // POSITION
 
-    { 2, -1, Expr::STRING_RESULT, &nsGkAtoms::concat }, // CONCAT
-    { 2, 2, Expr::BOOLEAN_RESULT, &nsGkAtoms::contains }, // CONTAINS
-    { 0, 1, Expr::STRING_RESULT,  &nsGkAtoms::normalizeSpace }, // NORMALIZE_SPACE
-    { 2, 2, Expr::BOOLEAN_RESULT, &nsGkAtoms::startsWith }, // STARTS_WITH
-    { 0, 1, Expr::STRING_RESULT,  &nsGkAtoms::string }, // STRING
-    { 0, 1, Expr::NUMBER_RESULT,  &nsGkAtoms::stringLength }, // STRING_LENGTH
-    { 2, 3, Expr::STRING_RESULT,  &nsGkAtoms::substring }, // SUBSTRING
-    { 2, 2, Expr::STRING_RESULT,  &nsGkAtoms::substringAfter }, // SUBSTRING_AFTER
-    { 2, 2, Expr::STRING_RESULT,  &nsGkAtoms::substringBefore }, // SUBSTRING_BEFORE
-    { 3, 3, Expr::STRING_RESULT,  &nsGkAtoms::translate }, // TRANSLATE
+    { 2, -1, Expr::STRING_RESULT, nsGkAtoms::concat }, // CONCAT
+    { 2, 2, Expr::BOOLEAN_RESULT, nsGkAtoms::contains }, // CONTAINS
+    { 0, 1, Expr::STRING_RESULT,  nsGkAtoms::normalizeSpace }, // NORMALIZE_SPACE
+    { 2, 2, Expr::BOOLEAN_RESULT, nsGkAtoms::startsWith }, // STARTS_WITH
+    { 0, 1, Expr::STRING_RESULT,  nsGkAtoms::string }, // STRING
+    { 0, 1, Expr::NUMBER_RESULT,  nsGkAtoms::stringLength }, // STRING_LENGTH
+    { 2, 3, Expr::STRING_RESULT,  nsGkAtoms::substring }, // SUBSTRING
+    { 2, 2, Expr::STRING_RESULT,  nsGkAtoms::substringAfter }, // SUBSTRING_AFTER
+    { 2, 2, Expr::STRING_RESULT,  nsGkAtoms::substringBefore }, // SUBSTRING_BEFORE
+    { 3, 3, Expr::STRING_RESULT,  nsGkAtoms::translate }, // TRANSLATE
 
-    { 0, 1, Expr::NUMBER_RESULT,  &nsGkAtoms::number }, // NUMBER
-    { 1, 1, Expr::NUMBER_RESULT,  &nsGkAtoms::round }, // ROUND
-    { 1, 1, Expr::NUMBER_RESULT,  &nsGkAtoms::floor }, // FLOOR
-    { 1, 1, Expr::NUMBER_RESULT,  &nsGkAtoms::ceiling }, // CEILING
-    { 1, 1, Expr::NUMBER_RESULT,  &nsGkAtoms::sum }, // SUM
+    { 0, 1, Expr::NUMBER_RESULT,  nsGkAtoms::number }, // NUMBER
+    { 1, 1, Expr::NUMBER_RESULT,  nsGkAtoms::round }, // ROUND
+    { 1, 1, Expr::NUMBER_RESULT,  nsGkAtoms::floor }, // FLOOR
+    { 1, 1, Expr::NUMBER_RESULT,  nsGkAtoms::ceiling }, // CEILING
+    { 1, 1, Expr::NUMBER_RESULT,  nsGkAtoms::sum }, // SUM
 
-    { 1, 1, Expr::BOOLEAN_RESULT, &nsGkAtoms::boolean }, // BOOLEAN
-    { 0, 0, Expr::BOOLEAN_RESULT, &nsGkAtoms::_false }, // _FALSE
-    { 1, 1, Expr::BOOLEAN_RESULT, &nsGkAtoms::lang }, // LANG
-    { 1, 1, Expr::BOOLEAN_RESULT, &nsGkAtoms::_not }, // _NOT
-    { 0, 0, Expr::BOOLEAN_RESULT, &nsGkAtoms::_true } // _TRUE
+    { 1, 1, Expr::BOOLEAN_RESULT, nsGkAtoms::boolean }, // BOOLEAN
+    { 0, 0, Expr::BOOLEAN_RESULT, nsGkAtoms::_false }, // _FALSE
+    { 1, 1, Expr::BOOLEAN_RESULT, nsGkAtoms::lang }, // LANG
+    { 1, 1, Expr::BOOLEAN_RESULT, nsGkAtoms::_not }, // _NOT
+    { 0, 0, Expr::BOOLEAN_RESULT, nsGkAtoms::_true } // _TRUE
 };
 
 
 /*
  * Evaluates this Expr based on the given context node and processor state
  * @param context the context node for evaluation of this Expr
  * @param ps the ContextState containing the stack information needed
  * for evaluation
@@ -718,25 +718,25 @@ txCoreFunctionCall::isSensitiveTo(Contex
 }
 
 // static
 bool
 txCoreFunctionCall::getTypeFromAtom(nsAtom* aName, eType& aType)
 {
     uint32_t i;
     for (i = 0; i < ArrayLength(descriptTable); ++i) {
-        if (aName == *descriptTable[i].mName) {
+        if (aName == descriptTable[i].mName) {
             aType = static_cast<eType>(i);
 
             return true;
         }
     }
 
     return false;
 }
 
 #ifdef TX_TO_STRING
 void
 txCoreFunctionCall::appendName(nsAString& aDest)
 {
-    aDest.Append((*descriptTable[mType].mName)->GetUTF16String());
+    aDest.Append(descriptTable[mType].mName->GetUTF16String());
 }
 #endif
--- a/dom/xul/XULDocument.cpp
+++ b/dom/xul/XULDocument.cpp
@@ -2437,17 +2437,17 @@ XULDocument::CachedChromeStreamListener:
 bool
 XULDocument::IsDocumentRightToLeft()
 {
     // setting the localedir attribute on the root element forces a
     // specific direction for the document.
     Element* element = GetRootElement();
     if (element) {
         static Element::AttrValuesArray strings[] =
-            {&nsGkAtoms::ltr, &nsGkAtoms::rtl, nullptr};
+            {nsGkAtoms::ltr, nsGkAtoms::rtl, nullptr};
         switch (element->FindAttrValueIn(kNameSpaceID_None, nsGkAtoms::localedir,
                                          strings, eCaseMatters)) {
             case 0: return false;
             case 1: return true;
             default: break; // otherwise, not a valid value, so fall through
         }
     }
 
--- a/gfx/layers/FrameMetrics.cpp
+++ b/gfx/layers/FrameMetrics.cpp
@@ -75,17 +75,16 @@ FrameMetrics::KeepLayoutViewportEnclosin
         aLayoutViewport.MoveByY(aVisualViewport.YMost() - aLayoutViewport.YMost());
      }
    }
 }
 
 
 void
 ScrollMetadata::SetUsesContainerScrolling(bool aValue) {
-  MOZ_ASSERT_IF(aValue, gfxPrefs::LayoutUseContainersForRootFrames());
   mUsesContainerScrolling = aValue;
 }
 
 static OverscrollBehavior
 ToOverscrollBehavior(StyleOverscrollBehavior aBehavior)
 {
   switch (aBehavior) {
   case StyleOverscrollBehavior::Auto:
--- a/gfx/layers/apz/src/APZInputBridge.cpp
+++ b/gfx/layers/apz/src/APZInputBridge.cpp
@@ -61,16 +61,25 @@ APZInputBridge::ReceiveInputEvent(
 
       WidgetMouseEvent& mouseEvent = *aEvent.AsMouseEvent();
 
       // Note, we call this before having transformed the reference point.
       if (mouseEvent.IsReal()) {
         UpdateWheelTransaction(mouseEvent.mRefPoint, mouseEvent.mMessage);
       }
 
+      // If zooming is enabled, mark the mouse event as "ignore root
+      // scroll frame". This ensures that the main-thread hit test the
+      // mouse event undergoes (in PositionedEventTargeting.cpp) uses
+      // the IGNORE_ROOT_SCROLL_FRAME flag, which is needed for correct
+      // hit testing in a zoomed-in or zoomed-out state.
+      if (gfxPrefs::APZAllowZooming()) {
+        mouseEvent.mIgnoreRootScrollFrame = true;
+      }
+
       if (WillHandleMouseEvent(mouseEvent)) {
 
         MouseInput input(mouseEvent);
         input.mOrigin = ScreenPoint(mouseEvent.mRefPoint.x, mouseEvent.mRefPoint.y);
 
         nsEventStatus status = ReceiveInputEvent(input, aOutTargetGuid, aOutInputBlockId);
 
         mouseEvent.mRefPoint.x = input.mOrigin.x;
--- a/gfx/layers/apz/test/mochitest/apz_test_utils.js
+++ b/gfx/layers/apz/test/mochitest/apz_test_utils.js
@@ -49,16 +49,25 @@ function convertBuckets(buckets) {
 
 function convertTestData(testData) {
   var result = {};
   result.paints = convertBuckets(testData.paints);
   result.repaintRequests = convertBuckets(testData.repaintRequests);
   return result;
 }
 
+function getLastNonemptyBucket(buckets) {
+  for (var i = buckets.length - 1; i >= 0; --i) {
+    if (buckets[i].scrollFrames.length > 0) {
+      return buckets[i];
+    }
+  }
+  return null;
+}
+
 // Given APZ test data for a single paint on the compositor side,
 // reconstruct the APZC tree structure from the 'parentScrollId'
 // entries that were logged. More specifically, the subset of the
 // APZC tree structure corresponding to the layer subtree for the
 // content process that triggered the paint, is reconstructed (as
 // the APZ test data only contains information abot this subtree).
 function buildApzcTree(paint) {
   // The APZC tree can potentially have multiple root nodes,
--- a/gfx/layers/apz/test/mochitest/helper_basic_doubletap_zoom.html
+++ b/gfx/layers/apz/test/mochitest/helper_basic_doubletap_zoom.html
@@ -1,13 +1,13 @@
 <!DOCTYPE HTML>
 <html>
 <head>
   <meta charset="utf-8">
-  <meta name="viewport" content="width=1050"/>
+  <meta name="viewport" content="width=2100"/>
   <title>Sanity check for double-tap zooming</title>
   <script type="application/javascript" src="apz_test_native_event_utils.js"></script>
   <script type="application/javascript" src="apz_test_utils.js"></script>
   <script type="application/javascript" src="/tests/SimpleTest/paint_listener.js"></script>
   <script type="application/javascript">
 function getResolution() {
   let resolution = { value: -1 }; // bogus value in case DWU fails us
   SpecialPowers.getDOMWindowUtils(window).getResolution(resolution);
--- a/gfx/layers/apz/test/mochitest/helper_bug1280013.html
+++ b/gfx/layers/apz/test/mochitest/helper_bug1280013.html
@@ -1,27 +1,32 @@
 <!DOCTYPE HTML>
 <html style="overflow:hidden">
 <head>
   <meta charset="utf-8">
   <!-- The viewport tag will result in APZ being in a "zoomed-in" state, assuming
-       the device width is less than 980px. -->
-  <meta name="viewport" content="width=980; initial-scale=1.0">
+       the device width is less than 2500px. -->
+  <meta name="viewport" content="width=2500; initial-scale=1.0">
   <title>Test for bug 1280013</title>
   <script type="application/javascript" src="apz_test_native_event_utils.js"></script>
   <script type="application/javascript" src="apz_test_utils.js"></script>
   <script type="application/javascript" src="/tests/SimpleTest/paint_listener.js"></script>
   <script type="application/javascript">
 function* test(testDriver) {
   ok(screen.height > 500, "Screen height must be at least 500 pixels for this test to work");
 
   // This listener will trigger the test to continue once APZ is done with
   // processing the scroll.
   SpecialPowers.Services.obs.addObserver(testDriver, "APZ:TransformEnd");
 
+  // Note on the synthesizeNativeTouchDrag() calls in this file: by using
+  // yield and *not* passing |testDriver| as the |aObserver| argument, these
+  // calls block until something else (in this case, the APZ:TransformEnd
+  // notification) resumes the test.
+
   // Scroll down to the iframe. Do it in two drags instead of one in case the
   // device screen is short
   yield synthesizeNativeTouchDrag(document.body, 10, 400, 0, -350);
   yield synthesizeNativeTouchDrag(document.body, 10, 400, 0, -350);
   // Now the top of the visible area should be at y=700 of the top-level page,
   // so if the screen is >= 500px tall, the entire iframe should be visible, at
   // least vertically.
 
@@ -42,28 +47,28 @@ function* test(testDriver) {
   SpecialPowers.Services.obs.removeObserver(testDriver, "APZ:TransformEnd", false);
 
   // Flush any pending paints
   yield flushApzRepaints(testDriver);
 
   // get the displayport for the subframe
   var utils = SpecialPowers.getDOMWindowUtils(window);
   var contentPaints = utils.getContentAPZTestData().paints;
-  var lastPaint = convertScrollFrameData(contentPaints[contentPaints.length - 1].scrollFrames);
+  var lastPaint = convertScrollFrameData(getLastNonemptyBucket(contentPaints).scrollFrames);
   var foundIt = 0;
   for (var scrollId in lastPaint) {
     if (('contentDescription' in lastPaint[scrollId]) &&
         (lastPaint[scrollId]['contentDescription'].includes('tall_html'))) {
-      var dp = getPropertyAsRect(lastPaint, scrollId, 'criticalDisplayport');
-      ok(dp.y <= 0, 'The critical displayport top should be less than or equal to zero to cover the visible part of the subframe; it is ' + dp.y);
-      ok(dp.y + dp.h >= subframe.clientHeight, 'The critical displayport bottom should be greater than the clientHeight; it is ' + (dp.y + dp.h));
+      var dp = getPropertyAsRect(lastPaint, scrollId, 'displayport');
+      ok(dp.y <= 0, 'The displayport top should be less than or equal to zero to cover the visible part of the subframe; it is ' + dp.y);
+      ok(dp.y + dp.h >= subframe.clientHeight, 'The displayport bottom should be greater than the clientHeight; it is ' + (dp.y + dp.h));
       foundIt++;
     }
   }
-  is(foundIt, 1, "Found exactly one critical displayport for the subframe we were interested in.");
+  is(foundIt, 1, "Found exactly one displayport for the subframe we were interested in.");
 }
 
 waitUntilApzStable()
 .then(runContinuation(test))
 .then(subtestDone);
 
   </script>
 </head>
--- a/gfx/layers/apz/test/mochitest/helper_zoomed_pan.html
+++ b/gfx/layers/apz/test/mochitest/helper_zoomed_pan.html
@@ -21,42 +21,46 @@
 </head>
 <body>
   <div id="content"></div>
   <script type="application/javascript">
     const RESOLUTION = 4;
     const OFFSET_SCREEN_PX = 50;
     const OFFSET_CSS_PX = OFFSET_SCREEN_PX / RESOLUTION;
 
-    function computeDelta(visual) {
+    // Measure scrollbar widths before zooming.
+    const verticalScrollbarWidth = window.innerWidth - document.scrollingElement.clientWidth;
+    const horizontalScrollbarWidth = window.innerHeight - document.scrollingElement.clientHeight;
+
+    function computeDelta(visual, scrollbarWidth) {
       // Compute the distance from the right/bottom edge of the visual
       // viewport to the same edge of the layout viewport and add the desired
       // offset to that.
-      const layout = visual * RESOLUTION;
+      const layout = (visual + scrollbarWidth) * RESOLUTION;
       return layout - visual + OFFSET_SCREEN_PX;
     }
 
     function* test(testDriver) {
       const target = document.getElementById("content");
       const cases = [
         {
           x: 0,
           y: 0,
-          dx: (width) => -computeDelta(width),
+          dx: (width) => -computeDelta(width, verticalScrollbarWidth),
           dy: (height) => 0,
           expected: {
             x: [OFFSET_CSS_PX, "x-offset was adjusted"],
             y: [0, "y-offset was not affected"],
           },
         },
         {
           x: OFFSET_SCREEN_PX,
           y: 0,
           dx: (width) => 0,
-          dy: (height) => -computeDelta(height),
+          dy: (height) => -computeDelta(height, horizontalScrollbarWidth),
           expected: {
             x: [OFFSET_CSS_PX, "x-offset was not affected"],
             y: [OFFSET_CSS_PX, "y-offset was adjusted"],
           },
         },
       ];
 
       for (let c of cases) {
--- a/gfx/layers/apz/test/mochitest/mochitest.ini
+++ b/gfx/layers/apz/test/mochitest/mochitest.ini
@@ -24,17 +24,17 @@
   skip-if = (verify && debug && (os == 'win'))
 [test_group_touchevents-2.html]
   skip-if = (verify && debug && (os == 'win'))
 [test_group_touchevents-3.html]
   skip-if = (verify && debug && (os == 'win'))
 [test_group_wheelevents.html]
   skip-if = (toolkit == 'android') # wheel events not supported on mobile
 [test_group_zoom.html]
-  skip-if = (toolkit != 'android') # only android supports zoom
+  skip-if = (os == 'win') || webrender # zooming is not supported yet on WebRender; see bug 1495580 for Windows
 [test_interrupted_reflow.html]
 [test_group_keyboard.html]
 [test_layerization.html]
   skip-if = (os == 'android') # wheel events not supported on mobile
 [test_scroll_inactive_bug1190112.html]
   skip-if = (os == 'android') # wheel events not supported on mobile
 [test_scroll_inactive_flattened_frame.html]
   skip-if = (os == 'android') # wheel events not supported on mobile
--- a/gfx/layers/apz/test/mochitest/test_group_zoom.html
+++ b/gfx/layers/apz/test/mochitest/test_group_zoom.html
@@ -21,16 +21,29 @@ var prefs = [
   ["apz.fling_min_velocity_threshold", "10000"],
   // The helper_bug1280013's div gets a displayport on scroll, but if the
   // test takes too long the displayport can expire before we read the value
   // out of the test. So we disable displayport expiry for these tests.
   ["apz.displayport_expiry_ms", 0],
   // Prevent the dynamic toolbar from interfering with main-thread scroll
   // offset values.
   ["browser.chrome.dynamictoolbar", false],
+  // Explicitly enable pinch-zooming, so this test can run on desktop
+  // even though zooming isn't enabled by default on desktop yet.
+  ["apz.allow_zooming", true],
+  // Pinch-zooming currently requires meta viewport support (this requirement
+  // will eventually be removed).
+  ["dom.meta-viewport.enabled", true],
+  // Pinch-zooming currently requires container scrolling (this requirement
+  // will eventually be removed).
+  ["layout.scroll.root-frame-containers", true],
+  // Retained displaylists don't work well with container scrolling, so
+  // they too need to be disabled for now.
+  ["layout.display-list.retain", false],
+  ["layout.display-list.retain.chrome", false],
 ];
 
 // Increase the tap timeouts so the double-tap is still detected in case of
 // random delays during testing.
 var doubletap_prefs = [
   ...prefs,
   ["ui.click_hold_context_menus.delay", 10000],
   ["apz.max_tap_time", 10000],
--- a/gfx/layers/apz/util/APZCCallbackHelper.cpp
+++ b/gfx/layers/apz/util/APZCCallbackHelper.cpp
@@ -671,22 +671,23 @@ PrepareForSetTargetAPZCNotification(nsIW
                                     nsIFrame* aRootFrame,
                                     const LayoutDeviceIntPoint& aRefPoint,
                                     nsTArray<ScrollableLayerGuid>* aTargets)
 {
   ScrollableLayerGuid guid(aGuid.mLayersId, 0, FrameMetrics::NULL_SCROLL_ID);
   nsPoint point =
     nsLayoutUtils::GetEventCoordinatesRelativeTo(aWidget, aRefPoint, aRootFrame);
   uint32_t flags = 0;
-#ifdef MOZ_WIDGET_ANDROID
-  // On Android, we need IGNORE_ROOT_SCROLL_FRAME for correct hit testing
-  // when zoomed out. On desktop, don't use it because it interferes with
-  // hit testing for some purposes such as scrollbar dragging.
-  flags = nsLayoutUtils::IGNORE_ROOT_SCROLL_FRAME;
-#endif
+  if (gfxPrefs::APZAllowZooming()) {
+    // If zooming is enabled, we need IGNORE_ROOT_SCROLL_FRAME for correct
+    // hit testing. Otherwise, don't use it because it interferes with
+    // hit testing for some purposes such as scrollbar dragging (this will
+    // need to be fixed before enabling zooming by default on desktop).
+    flags = nsLayoutUtils::IGNORE_ROOT_SCROLL_FRAME;
+  }
   nsIFrame* target =
     nsLayoutUtils::GetFrameForPoint(aRootFrame, point, flags);
   nsIScrollableFrame* scrollAncestor = target
     ? nsLayoutUtils::GetAsyncScrollableAncestorFrame(target)
     : aRootFrame->PresShell()->GetRootScrollFrameAsScrollable();
 
   // Assuming that if there's no scrollAncestor, there's already a displayPort.
   nsCOMPtr<dom::Element> dpElement = scrollAncestor
--- a/gfx/layers/wr/WebRenderLayerManager.cpp
+++ b/gfx/layers/wr/WebRenderLayerManager.cpp
@@ -208,30 +208,33 @@ WebRenderLayerManager::EndEmptyTransacti
     // by just sending an updated window overlay image instead of rebuilding
     // the entire WR display list.
     return false;
   }
 
   // Since we don't do repeat transactions right now, just set the time
   mAnimationReadyTime = TimeStamp::Now();
 
-  if (aFlags & EndTransactionFlags::END_NO_COMPOSITE && 
+  mLatestTransactionId = mTransactionIdAllocator->GetTransactionId(/*aThrottle*/ true);
+
+  if (aFlags & EndTransactionFlags::END_NO_COMPOSITE &&
       !mWebRenderCommandBuilder.NeedsEmptyTransaction() &&
       mPendingScrollUpdates.empty()) {
     MOZ_ASSERT(!mTarget);
     WrBridge()->SendSetFocusTarget(mFocusTarget);
+    // Revoke TransactionId to trigger next paint.
+    mTransactionIdAllocator->RevokeTransactionId(mLatestTransactionId);
     return true;
   }
 
   LayoutDeviceIntSize size = mWidget->GetClientSize();
   WrBridge()->BeginTransaction();
 
   mWebRenderCommandBuilder.EmptyTransaction();
 
-  mLatestTransactionId = mTransactionIdAllocator->GetTransactionId(/*aThrottle*/ true);
   TimeStamp refreshStart = mTransactionIdAllocator->GetTransactionStart();
 
   // Skip the synchronization for buffer since we also skip the painting during
   // device-reset status.
   if (!gfxPlatform::GetPlatform()->DidRenderingDeviceReset()) {
     if (WrBridge()->GetSyncObject() &&
         WrBridge()->GetSyncObject()->IsSyncObjectValid()) {
       WrBridge()->GetSyncObject()->Synchronize();
--- a/gfx/thebes/gfxFontFamilyList.h
+++ b/gfx/thebes/gfxFontFamilyList.h
@@ -52,17 +52,17 @@ enum QuotedName { eQuotedName, eUnquoted
 
 /**
  * font family name, an Atom for the name if not a generic and
  * a font type indicated named family or which generic family
  */
 
 struct FontFamilyName final {
     FontFamilyName()
-        : mType(eFamily_named)
+        : mType(eFamily_none)
     {}
 
     // named font family - e.g. Helvetica
     explicit FontFamilyName(nsAtom* aFamilyName,
                             QuotedName aQuoted = eUnquotedName) {
         mType = (aQuoted == eQuotedName) ? eFamily_named_quoted : eFamily_named;
         mName = aFamilyName;
     }
--- a/gfx/thebes/gfxPrefs.h
+++ b/gfx/thebes/gfxPrefs.h
@@ -696,17 +696,17 @@ private:
   DECL_GFX_PREF(Live, "layout.display-list.flatten-transform", LayoutFlattenTransform, bool, true);
 
   DECL_GFX_PREF(Once, "layout.frame_rate",                     LayoutFrameRate, int32_t, -1);
   DECL_GFX_PREF(Once, "layout.less-event-region-items",        LessEventRegionItems, bool, true);
   DECL_GFX_PREF(Live, "layout.min-active-layer-size",          LayoutMinActiveLayerSize, int, 64);
   DECL_GFX_PREF(Once, "layout.paint_rects_separately",         LayoutPaintRectsSeparately, bool, true);
 
   // This and code dependent on it should be removed once containerless scrolling looks stable.
-  DECL_GFX_PREF(Once, "layout.scroll.root-frame-containers",   LayoutUseContainersForRootFrames, bool, true);
+  DECL_GFX_PREF(Live, "layout.scroll.root-frame-containers",   LayoutUseContainersForRootFrames, bool, true);
   // This pref is to be set by test code only.
   DECL_GFX_PREF(Live, "layout.scrollbars.always-layerize-track", AlwaysLayerizeScrollbarTrackTestOnly, bool, false);
   DECL_GFX_PREF(Live, "layout.smaller-painted-layers",         LayoutSmallerPaintedLayers, bool, false);
 
   DECL_GFX_PREF(Once, "media.hardware-video-decoding.force-enabled",
                                                                HardwareVideoDecodingForceEnabled, bool, false);
 #ifdef XP_WIN
   DECL_GFX_PREF(Live, "media.wmf.dxva.d3d11.enabled", PDMWMFAllowD3D11, bool, true);
--- a/js/public/OffThreadScriptCompilation.h
+++ b/js/public/OffThreadScriptCompilation.h
@@ -70,17 +70,17 @@ FinishOffThreadScript(JSContext* cx, Off
 extern JS_PUBLIC_API(void)
 CancelOffThreadScript(JSContext* cx, OffThreadToken* token);
 
 extern JS_PUBLIC_API(bool)
 CompileOffThreadModule(JSContext* cx, const ReadOnlyCompileOptions& options,
                        SourceBufferHolder& srcBuf, OffThreadCompileCallback callback,
                        void* callbackData);
 
-extern JS_PUBLIC_API(JSScript*)
+extern JS_PUBLIC_API(JSObject*)
 FinishOffThreadModule(JSContext* cx, OffThreadToken* token);
 
 extern JS_PUBLIC_API(void)
 CancelOffThreadModule(JSContext* cx, OffThreadToken* token);
 
 extern JS_PUBLIC_API(bool)
 DecodeOffThreadScript(JSContext* cx, const ReadOnlyCompileOptions& options,
                       mozilla::Vector<uint8_t>& buffer /* TranscodeBuffer& */, size_t cursor,
--- a/js/public/Realm.h
+++ b/js/public/Realm.h
@@ -69,21 +69,16 @@ GetCompartmentForRealm(Realm* realm)
 }
 
 // Return an object's realm. All objects except cross-compartment wrappers are
 // created in a particular realm, which never changes. Returns null if obj is
 // a cross-compartment wrapper.
 extern JS_PUBLIC_API(Realm*)
 GetObjectRealmOrNull(JSObject* obj);
 
-// Return a script's realm. All scripts are created in a particular realm, which
-// never changes.
-extern JS_PUBLIC_API(Realm*)
-GetScriptRealm(JSScript* script);
-
 // Get the value of the "private data" internal field of the given Realm.
 // This field is initially null and is set using SetRealmPrivate.
 // It's a pointer to embeddding-specific data that SpiderMonkey never uses.
 extern JS_PUBLIC_API(void*)
 GetRealmPrivate(Realm* realm);
 
 // Set the "private data" internal field of the given Realm.
 extern JS_PUBLIC_API(void)
--- a/js/src/builtin/ModuleObject.cpp
+++ b/js/src/builtin/ModuleObject.cpp
@@ -1046,16 +1046,28 @@ ModuleObject::metaObject() const
 void
 ModuleObject::setMetaObject(JSObject* obj)
 {
     MOZ_ASSERT(obj);
     MOZ_ASSERT(!metaObject());
     setReservedSlot(MetaObjectSlot, ObjectValue(*obj));
 }
 
+Value
+ModuleObject::hostDefinedField() const
+{
+    return getReservedSlot(HostDefinedSlot);
+}
+
+void
+ModuleObject::setHostDefinedField(const JS::Value& value)
+{
+    setReservedSlot(HostDefinedSlot, value);
+}
+
 Scope*
 ModuleObject::enclosingScope() const
 {
     return script()->enclosingScope();
 }
 
 /* static */ void
 ModuleObject::trace(JSTracer* trc, JSObject* obj)
@@ -1238,16 +1250,18 @@ GlobalObject::initModuleProto(JSContext*
         JS_PSG("dfsIndex", ModuleObject_dfsIndexGetter, 0),
         JS_PSG("dfsAncestorIndex", ModuleObject_dfsAncestorIndexGetter, 0),
         JS_PS_END
     };
 
     static const JSFunctionSpec protoFunctions[] = {
         JS_SELF_HOSTED_FN("getExportedNames", "ModuleGetExportedNames", 1, 0),
         JS_SELF_HOSTED_FN("resolveExport", "ModuleResolveExport", 2, 0),
+        JS_SELF_HOSTED_FN("declarationInstantiation", "ModuleInstantiate", 0, 0),
+        JS_SELF_HOSTED_FN("evaluation", "ModuleEvaluate", 0, 0),
         JS_FS_END
     };
 
     RootedObject proto(cx, GlobalObject::createBlankPrototype<PlainObject>(cx, global));
     if (!proto) {
         return false;
     }
 
@@ -1754,35 +1768,34 @@ ArrayObject* ModuleBuilder::createArray(
     for (auto r = map.all(); !r.empty(); r.popFront()) {
         array->initDenseElement(i++, ObjectValue(*r.front().value()));
     }
 
     return array;
 }
 
 JSObject*
-js::GetOrCreateModuleMetaObject(JSContext* cx, HandleScript script)
+js::GetOrCreateModuleMetaObject(JSContext* cx, HandleObject moduleArg)
 {
-    MOZ_ASSERT(script->module());
-    RootedModuleObject module(cx, script->module());
+    HandleModuleObject module = moduleArg.as<ModuleObject>();
     if (JSObject* obj = module->metaObject()) {
         return obj;
     }
 
     RootedObject metaObject(cx, NewObjectWithGivenProto<PlainObject>(cx, nullptr));
     if (!metaObject) {
         return nullptr;
     }
 
     JS::ModuleMetadataHook func = cx->runtime()->moduleMetadataHook;
     if (!func) {
         JS_ReportErrorASCII(cx, "Module metadata hook not set");
         return nullptr;
     }
 
-    if (!func(cx, script, metaObject)) {
+    if (!func(cx, module, metaObject)) {
         return nullptr;
     }
 
     module->setMetaObject(metaObject);
 
     return metaObject;
 }
--- a/js/src/builtin/ModuleObject.h
+++ b/js/src/builtin/ModuleObject.h
@@ -255,16 +255,17 @@ class ModuleObject : public NativeObject
     enum ModuleSlot
     {
         ScriptSlot = 0,
         EnvironmentSlot,
         NamespaceSlot,
         StatusSlot,
         EvaluationErrorSlot,
         MetaObjectSlot,
+        HostDefinedSlot,
         RequestedModulesSlot,
         ImportEntriesSlot,
         LocalExportEntriesSlot,
         IndirectExportEntriesSlot,
         StarExportEntriesSlot,
         ImportBindingsSlot,
         FunctionDeclarationsSlot,
         DFSIndexSlot,
@@ -305,31 +306,34 @@ class ModuleObject : public NativeObject
     Scope* enclosingScope() const;
     ModuleEnvironmentObject& initialEnvironment() const;
     ModuleEnvironmentObject* environment() const;
     ModuleNamespaceObject* namespace_();
     ModuleStatus status() const;
     bool hadEvaluationError() const;
     Value evaluationError() const;
     JSObject* metaObject() const;
+    Value hostDefinedField() const;
     ArrayObject& requestedModules() const;
     ArrayObject& importEntries() const;
     ArrayObject& localExportEntries() const;
     ArrayObject& indirectExportEntries() const;
     ArrayObject& starExportEntries() const;
     IndirectBindingMap& importBindings();
 
     static bool Instantiate(JSContext* cx, HandleModuleObject self);
     static bool Evaluate(JSContext* cx, HandleModuleObject self);
 
     static ModuleNamespaceObject* GetOrCreateModuleNamespace(JSContext* cx,
                                                              HandleModuleObject self);
 
     void setMetaObject(JSObject* obj);
 
+    void setHostDefinedField(const JS::Value& value);
+
     // For BytecodeEmitter.
     bool noteFunctionDeclaration(JSContext* cx, HandleAtom name, HandleFunction fun);
 
     // For intrinsic_InstantiateModuleFunctionDeclarations.
     static bool instantiateFunctionDeclarations(JSContext* cx, HandleModuleObject self);
 
     // For intrinsic_ExecuteModule.
     static bool execute(JSContext* cx, HandleModuleObject self, MutableHandleValue rval);
@@ -410,17 +414,17 @@ class MOZ_STACK_CLASS ModuleBuilder
 
     template <typename T>
     ArrayObject* createArray(const JS::Rooted<GCVector<T>>& vector);
     template <typename K, typename V>
     ArrayObject* createArray(const JS::Rooted<GCHashMap<K, V>>& map);
 };
 
 JSObject*
-GetOrCreateModuleMetaObject(JSContext* cx, HandleScript script);
+GetOrCreateModuleMetaObject(JSContext* cx, HandleObject module);
 
 } // namespace js
 
 template<>
 inline bool
 JSObject::is<js::ModuleNamespaceObject>() const
 {
     return js::IsDerivedProxyObject(this, &js::ModuleNamespaceObject::proxyHandler);
--- a/js/src/builtin/SelfHostingDefines.h
+++ b/js/src/builtin/SelfHostingDefines.h
@@ -94,18 +94,18 @@
 #define REGEXP_GLOBAL_FLAG      0x02
 #define REGEXP_MULTILINE_FLAG   0x04
 #define REGEXP_STICKY_FLAG      0x08
 #define REGEXP_UNICODE_FLAG     0x10
 
 #define MODULE_OBJECT_ENVIRONMENT_SLOT        1
 #define MODULE_OBJECT_STATUS_SLOT             3
 #define MODULE_OBJECT_EVALUATION_ERROR_SLOT   4
-#define MODULE_OBJECT_DFS_INDEX_SLOT          13
-#define MODULE_OBJECT_DFS_ANCESTOR_INDEX_SLOT 14
+#define MODULE_OBJECT_DFS_INDEX_SLOT          14
+#define MODULE_OBJECT_DFS_ANCESTOR_INDEX_SLOT 15
 
 #define MODULE_STATUS_UNINSTANTIATED  0
 #define MODULE_STATUS_INSTANTIATING   1
 #define MODULE_STATUS_INSTANTIATED    2
 #define MODULE_STATUS_EVALUATING      3
 #define MODULE_STATUS_EVALUATED       4
 #define MODULE_STATUS_EVALUATED_ERROR 5
 
--- a/js/src/builtin/TestingFunctions.cpp
+++ b/js/src/builtin/TestingFunctions.cpp
@@ -4571,16 +4571,111 @@ SetRNGState(JSContext* cx, unsigned argc
 
     cx->realm()->getOrCreateRandomNumberGenerator().setState(seed0, seed1);
 
     args.rval().setUndefined();
     return true;
 }
 #endif
 
+static ModuleEnvironmentObject*
+GetModuleEnvironment(JSContext* cx, HandleModuleObject module)
+{
+    // Use the initial environment so that tests can check bindings exists
+    // before they have been instantiated.
+    RootedModuleEnvironmentObject env(cx, &module->initialEnvironment());
+    MOZ_ASSERT(env);
+    return env;
+}
+
+static bool
+GetModuleEnvironmentNames(JSContext* cx, unsigned argc, Value* vp)
+{
+    CallArgs args = CallArgsFromVp(argc, vp);
+    if (args.length() != 1) {
+        JS_ReportErrorASCII(cx, "Wrong number of arguments");
+        return false;
+    }
+
+    if (!args[0].isObject() || !args[0].toObject().is<ModuleObject>()) {
+        JS_ReportErrorASCII(cx, "First argument should be a ModuleObject");
+        return false;
+    }
+
+    RootedModuleObject module(cx, &args[0].toObject().as<ModuleObject>());
+    if (module->hadEvaluationError()) {
+        JS_ReportErrorASCII(cx, "Module environment unavailable");
+        return false;
+    }
+
+    RootedModuleEnvironmentObject env(cx, GetModuleEnvironment(cx, module));
+    Rooted<IdVector> ids(cx, IdVector(cx));
+    if (!JS_Enumerate(cx, env, &ids)) {
+        return false;
+    }
+
+    uint32_t length = ids.length();
+    RootedArrayObject array(cx, NewDenseFullyAllocatedArray(cx, length));
+    if (!array) {
+        return false;
+    }
+
+    array->setDenseInitializedLength(length);
+    for (uint32_t i = 0; i < length; i++) {
+        array->initDenseElement(i, StringValue(JSID_TO_STRING(ids[i])));
+    }
+
+    args.rval().setObject(*array);
+    return true;
+}
+
+static bool
+GetModuleEnvironmentValue(JSContext* cx, unsigned argc, Value* vp)
+{
+    CallArgs args = CallArgsFromVp(argc, vp);
+    if (args.length() != 2) {
+        JS_ReportErrorASCII(cx, "Wrong number of arguments");
+        return false;
+    }
+
+    if (!args[0].isObject() || !args[0].toObject().is<ModuleObject>()) {
+        JS_ReportErrorASCII(cx, "First argument should be a ModuleObject");
+        return false;
+    }
+
+    if (!args[1].isString()) {
+        JS_ReportErrorASCII(cx, "Second argument should be a string");
+        return false;
+    }
+
+    RootedModuleObject module(cx, &args[0].toObject().as<ModuleObject>());
+    if (module->hadEvaluationError()) {
+        JS_ReportErrorASCII(cx, "Module environment unavailable");
+        return false;
+    }
+
+    RootedModuleEnvironmentObject env(cx, GetModuleEnvironment(cx, module));
+    RootedString name(cx, args[1].toString());
+    RootedId id(cx);
+    if (!JS_StringToId(cx, name, &id)) {
+        return false;
+    }
+
+    if (!GetProperty(cx, env, env, id, args.rval())) {
+        return false;
+    }
+
+    if (args.rval().isMagic(JS_UNINITIALIZED_LEXICAL)) {
+        ReportRuntimeLexicalError(cx, JSMSG_UNINITIALIZED_LEXICAL, id);
+        return false;
+    }
+
+    return true;
+}
+
 #ifdef DEBUG
 static const char*
 AssertionTypeToString(irregexp::RegExpAssertion::AssertionType type)
 {
     switch (type) {
       case irregexp::RegExpAssertion::START_OF_LINE:
         return "START_OF_LINE";
       case irregexp::RegExpAssertion::START_OF_INPUT:
@@ -6163,16 +6258,24 @@ gc::ZealModeHelpText),
 "  the current global is used as the default one.\n"),
 
 #ifdef DEBUG
     JS_FN_HELP("setRNGState", SetRNGState, 2, 0,
 "setRNGState(seed0, seed1)",
 "  Set this compartment's RNG state.\n"),
 #endif
 
+    JS_FN_HELP("getModuleEnvironmentNames", GetModuleEnvironmentNames, 1, 0,
+"getModuleEnvironmentNames(module)",
+"  Get the list of a module environment's bound names for a specified module.\n"),
+
+    JS_FN_HELP("getModuleEnvironmentValue", GetModuleEnvironmentValue, 2, 0,
+"getModuleEnvironmentValue(module, name)",
+"  Get the value of a bound name in a module environment.\n"),
+
 #if defined(FUZZING) && defined(__AFL_COMPILER)
     JS_FN_HELP("aflloop", AflLoop, 1, 0,
 "aflloop(max_cnt)",
 "  Call the __AFL_LOOP() runtime function (see AFL docs)\n"),
 #endif
 
     JS_FN_HELP("monotonicNow", MonotonicNow, 0, 0,
 "monotonicNow()",
--- a/js/src/frontend/BinSource-auto.cpp
+++ b/js/src/frontend/BinSource-auto.cpp
@@ -8369,16 +8369,19 @@ BinASTParser<Tok>::parseListOfAssertedMa
 {
     uint32_t length;
     AutoList guard(*tokenizer_);
 
     const auto start = tokenizer_->offset();
     MOZ_TRY(tokenizer_->enterList(length, guard));
     (void) start;
     auto result = Ok();
+    if (length >= ARGNO_LIMIT) {
+        return raiseError("Too many function parameters");
+    }
     BINJS_TRY(positionalParams.get().resize(length));
     for (uint32_t i = 0; i < length; i++) {
         positionalParams.get()[i] = nullptr;
     }
 
     for (uint32_t i = 0; i < length; ++i) {
         MOZ_TRY(parseAssertedMaybePositionalParameterName(
             scopeKind, positionalParams));
--- a/js/src/frontend/BinSource.yaml
+++ b/js/src/frontend/BinSource.yaml
@@ -904,16 +904,19 @@ ListOfAssertedMaybePositionalParameterNa
     extra-params: |
         AssertedScopeKind scopeKind,
         MutableHandle<GCVector<JSAtom*>> positionalParams
     extra-args: |
         scopeKind, positionalParams
     init: |
         (void) start;
         auto result = Ok();
+        if (length >= ARGNO_LIMIT) {
+            return raiseError("Too many function parameters");
+        }
         BINJS_TRY(positionalParams.get().resize(length));
         for (uint32_t i = 0; i < length; i++) {
             positionalParams.get()[i] = nullptr;
         }
 
 ListOfAssertedDeclaredName:
     inherits: ListOfAssertedBoundName
 
--- a/js/src/frontend/BinTokenReaderTester.cpp
+++ b/js/src/frontend/BinTokenReaderTester.cpp
@@ -291,16 +291,20 @@ BinTokenReaderTester::enterTaggedTuple(B
 
         // else
         return raiseError("Invalid tag");
     } while(false);
 
     // Now fields.
     BINJS_MOZ_TRY_DECL(fieldNum, readInternalUint32());
 
+    if (fieldNum > FIELD_NUM_MAX) {
+        return raiseError("Too many fields");
+    }
+
     fields.clear();
     if (!fields.reserve(fieldNum)) {
         return raiseOOM();
     }
 
     for (uint32_t i = 0; i < fieldNum; ++i) {
         // This would probably be much faster with a HashTable, but we don't
         // really care about the speed of BinTokenReaderTester.
--- a/js/src/frontend/BinTokenReaderTester.h
+++ b/js/src/frontend/BinTokenReaderTester.h
@@ -59,16 +59,19 @@ class MOZ_STACK_CLASS BinTokenReaderTest
     // they are valid UTF-8. Future versions may replace this by slice into
     // the buffer.
     using Chars     = Vector<uint8_t, 32>;
 
     class AutoList;
     class AutoTuple;
     class AutoTaggedTuple;
 
+    // The maximum number of fields in single tagged tuple.
+    static const uint32_t FIELD_NUM_MAX = 32;
+
   public:
     /**
      * Construct a token reader.
      *
      * Does NOT copy the buffer.
      */
     BinTokenReaderTester(JSContext* cx, ErrorReporter* er, const uint8_t* start, const size_t length);
 
--- a/js/src/frontend/BytecodeCompiler.cpp
+++ b/js/src/frontend/BytecodeCompiler.cpp
@@ -47,17 +47,17 @@ class MOZ_STACK_CLASS BytecodeCompiler
     BytecodeCompiler(JSContext* cx,
                      LifoAlloc& alloc,
                      const ReadOnlyCompileOptions& options,
                      SourceBufferHolder& sourceBuffer,
                      HandleScope enclosingScope);
 
     JSScript* compileGlobalScript(ScopeKind scopeKind);
     JSScript* compileEvalScript(HandleObject environment, HandleScope enclosingScope);
-    JSScript* compileModule();
+    ModuleObject* compileModule();
     bool compileStandaloneFunction(MutableHandleFunction fun, GeneratorKind generatorKind,
                                    FunctionAsyncKind asyncKind,
                                    const Maybe<uint32_t>& parameterListEnd);
 
     ScriptSourceObject* sourceObjectPtr() const;
 
   private:
     JSScript* compileScript(HandleObject environment, SharedContext* sc);
@@ -406,17 +406,17 @@ BytecodeCompiler::compileGlobalScript(Sc
 JSScript*
 BytecodeCompiler::compileEvalScript(HandleObject environment, HandleScope enclosingScope)
 {
     EvalSharedContext evalsc(cx, environment, enclosingScope,
                              directives, options.extraWarningsOption);
     return compileScript(environment, &evalsc);
 }
 
-JSScript*
+ModuleObject*
 BytecodeCompiler::compileModule()
 {
     if (!createSourceAndParser(ParseGoal::Module)) {
         return nullptr;
     }
 
     Rooted<ModuleObject*> module(cx, ModuleObject::create(cx));
     if (!module) {
@@ -457,17 +457,17 @@ BytecodeCompiler::compileModule()
     module->setInitialEnvironment(env);
 
     // Enqueue an off-thread source compression task after finishing parsing.
     if (!scriptSource->tryCompressOffThread(cx)) {
         return nullptr;
     }
 
     MOZ_ASSERT_IF(!cx->helperThread(), !cx->isExceptionPending());
-    return script;
+    return module;
 }
 
 // Compile a standalone JS function, which might appear as the value of an
 // event handler attribute in an HTML <INPUT> tag, or in a Function()
 // constructor.
 bool
 BytecodeCompiler::compileStandaloneFunction(MutableHandleFunction fun,
                                             GeneratorKind generatorKind,
@@ -737,17 +737,17 @@ frontend::CompileEvalScript(JSContext* c
     if (!script) {
         return nullptr;
     }
     assertException.reset();
     return script;
 
 }
 
-JSScript*
+ModuleObject*
 frontend::CompileModule(JSContext* cx, const ReadOnlyCompileOptions& optionsInput,
                         SourceBufferHolder& srcBuf, LifoAlloc& alloc,
                         ScriptSourceObject** sourceObjectOut)
 {
     MOZ_ASSERT(srcBuf.get());
     MOZ_ASSERT_IF(sourceObjectOut, *sourceObjectOut == nullptr);
 
     AutoAssertReportedException assertException(cx);
@@ -755,50 +755,49 @@ frontend::CompileModule(JSContext* cx, c
     CompileOptions options(cx, optionsInput);
     options.maybeMakeStrictMode(true); // ES6 10.2.1 Module code is always strict mode code.
     options.setIsRunOnce(true);
     options.allowHTMLComments = false;
 
     RootedScope emptyGlobalScope(cx, &cx->global()->emptyGlobalScope());
     BytecodeCompiler compiler(cx, alloc, options, srcBuf, emptyGlobalScope);
     AutoInitializeSourceObject autoSSO(compiler, sourceObjectOut);
-    JSScript* script = compiler.compileModule();
-    if (!script) {
+    ModuleObject* module = compiler.compileModule();
+    if (!module) {
         return nullptr;
     }
 
     assertException.reset();
-    return script;
+    return module;
 }
 
-JSScript*
+ModuleObject*
 frontend::CompileModule(JSContext* cx, const JS::ReadOnlyCompileOptions& options,
                         SourceBufferHolder& srcBuf)
 {
     AutoAssertReportedException assertException(cx);
 
     if (!GlobalObject::ensureModulePrototypesCreated(cx, cx->global())) {
         return nullptr;
     }
 
     LifoAlloc& alloc = cx->tempLifoAlloc();
-    RootedScript script(cx, CompileModule(cx, options, srcBuf, alloc));
-    if (!script) {
+    RootedModuleObject module(cx, CompileModule(cx, options, srcBuf, alloc));
+    if (!module) {
         return nullptr;
     }
 
     // This happens in GlobalHelperThreadState::finishModuleParseTask() when a
     // module is compiled off thread.
-    RootedModuleObject module(cx, script->module());
     if (!ModuleObject::Freeze(cx, module)) {
         return nullptr;
     }
 
     assertException.reset();
-    return script;
+    return module;
 }
 
 // When leaving this scope, the given function should either:
 //   * be linked to a fully compiled script
 //   * remain linking to a lazy script
 class MOZ_STACK_CLASS AutoAssertFunctionDelazificationCompletion
 {
 #ifdef DEBUG
--- a/js/src/frontend/BytecodeCompiler.h
+++ b/js/src/frontend/BytecodeCompiler.h
@@ -16,16 +16,17 @@
 #include "vm/TraceLogging.h"
 
 class JSLinearString;
 
 namespace js {
 
 class LazyScript;
 class LifoAlloc;
+class ModuleObject;
 class ScriptSourceObject;
 
 namespace frontend {
 
 class ErrorReporter;
 class FunctionBox;
 class ParseNode;
 
@@ -50,21 +51,21 @@ CompileLazyBinASTFunction(JSContext* cx,
 
 JSScript*
 CompileEvalScript(JSContext* cx, LifoAlloc& alloc,
                   HandleObject scopeChain, HandleScope enclosingScope,
                   const JS::ReadOnlyCompileOptions& options,
                   JS::SourceBufferHolder& srcBuf,
                   ScriptSourceObject** sourceObjectOut = nullptr);
 
-JSScript*
+ModuleObject*
 CompileModule(JSContext* cx, const JS::ReadOnlyCompileOptions& options,
               JS::SourceBufferHolder& srcBuf);
 
-JSScript*
+ModuleObject*
 CompileModule(JSContext* cx, const JS::ReadOnlyCompileOptions& options,
               JS::SourceBufferHolder& srcBuf, LifoAlloc& alloc,
               ScriptSourceObject** sourceObjectOut = nullptr);
 
 MOZ_MUST_USE bool
 CompileLazyFunction(JSContext* cx, Handle<LazyScript*> lazy, const char16_t* chars, size_t length);
 
 //
--- a/js/src/jit-test/tests/basic/bug1470732.js
+++ b/js/src/jit-test/tests/basic/bug1470732.js
@@ -2,11 +2,11 @@ if (helperThreadCount() === 0)
     quit();
 
 var i = 0;
 while(i++ < 500) {
   evalInWorker(`
     assertFloat32(0x23456789 | 0, false);
   `);
   let m = parseModule("");
-  instantiateModule(m);
+  m.declarationInstantiation();
 }
 
--- a/js/src/jit-test/tests/debug/RematerializedFrame-retval.js
+++ b/js/src/jit-test/tests/debug/RematerializedFrame-retval.js
@@ -27,13 +27,13 @@ function testResumptionVal(resumptionVal
   } finally {  }
 }
 assertEq(testResumptionVal({ return: "not 42" }), "not 42");
 `;
 loadFile(lfLogBuffer);
 function loadFile(lfVarx) {
     try {
          let m = parseModule(lfVarx);
-         instantiateModule(m);
-         evaluateModule(m);
+         m.declarationInstantiation();
+         m.evaluation();
     } catch (lfVare) {}
 }
 
--- a/js/src/jit-test/tests/debug/Script-isModule-01.js
+++ b/js/src/jit-test/tests/debug/Script-isModule-01.js
@@ -3,11 +3,11 @@
 const g = newGlobal();
 const dbg = Debugger(g);
 let count = 0;
 dbg.onNewScript = function (script) {
     count += 1;
     assertEq(script.isModule, true);
 };
 const m = g.parseModule("");
-g.instantiateModule(m);
-g.evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
 assertEq(count, 1);
--- a/js/src/jit-test/tests/debug/Script-isModule-03.js
+++ b/js/src/jit-test/tests/debug/Script-isModule-03.js
@@ -8,11 +8,11 @@ dbg.onNewScript = function (script) {
     assertEq(script.isModule, true);
 
     dbg.onNewScript = function (script) {
         count += 1;
         assertEq(script.isModule, false);
     };
 };
 const m = g.parseModule("eval('')");
-g.instantiateModule(m);
-g.evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
 assertEq(count, 2);
--- a/js/src/jit-test/tests/debug/Script-isModule-04.js
+++ b/js/src/jit-test/tests/debug/Script-isModule-04.js
@@ -8,12 +8,12 @@ dbg.onNewScript = function (script) {
     assertEq(script.isModule, true);
 };
 dbg.onDebuggerStatement = function (frame) {
     const { script } = frame;
 
     assertEq(script.isModule, false);
 };
 const m = g.parseModule("(function(){ debugger; })()");
-g.instantiateModule(m);
-g.evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
 
 assertEq(count, 1);
--- a/js/src/jit-test/tests/debug/bug1304553.js
+++ b/js/src/jit-test/tests/debug/bug1304553.js
@@ -12,10 +12,10 @@ try {
     }
 } catch (e) {}
 let m = parseModule(`
                     actual = '';
                     for (var i = 0; i < 1; ++i)
                         f(i);
                     actual;
                     `);
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
--- a/js/src/jit-test/tests/for-of/bug-1341339.js
+++ b/js/src/jit-test/tests/for-of/bug-1341339.js
@@ -1,9 +1,9 @@
 let m = parseModule(`
 function* values() {}
 var iterator = values();
 for (var i=0; i < 10000; ++i) {
     for (var x of iterator) {}
 }
 `);
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
--- a/js/src/jit-test/tests/gc/bug-1282986.js
+++ b/js/src/jit-test/tests/gc/bug-1282986.js
@@ -6,12 +6,12 @@ evalInWorker(\`
         try { oomAfterAllocations(2); } catch(e) {}
     \`);
 `;
 loadFile("");
 loadFile(lfLogBuffer);
 function loadFile(lfVarx) {
     oomTest(function() {
         let m = parseModule(lfVarx);
-        instantiateModule(m);
-        evaluateModule(m);
+        m.declarationInstantiation();
+        m.evaluation();
     });
 }
--- a/js/src/jit-test/tests/ion/bug1269756.js
+++ b/js/src/jit-test/tests/ion/bug1269756.js
@@ -1,8 +1,8 @@
 if (!('oomTest' in this))
     quit();
 
 oomTest(function() {
     m = parseModule(`while (x && NaN) prototype; let x`);
-    instantiateModule(m);
-    evaluateModule(m);
+    m.declarationInstantiation();
+    m.evaluation();
 })
--- a/js/src/jit-test/tests/modules/ambiguous-star-export.js
+++ b/js/src/jit-test/tests/modules/ambiguous-star-export.js
@@ -2,43 +2,43 @@
 
 "use strict";
 
 load(libdir + "asserts.js");
 load(libdir + "dummyModuleResolveHook.js");
 
 function checkModuleEval(source) {
     let m = parseModule(source);
-    instantiateModule(m);
-    evaluateModule(m);
+    m.declarationInstantiation();
+    m.evaluation();
     return m;
 }
 
 function checkModuleSyntaxError(source) {
     let m = parseModule(source);
-    assertThrowsInstanceOf(() => instantiateModule(m), SyntaxError);
+    assertThrowsInstanceOf(() => m.declarationInstantiation(), SyntaxError);
 }
 
 let a = moduleRepo['a'] = parseModule("export var a = 1; export var b = 2;");
 let b = moduleRepo['b'] = parseModule("export var b = 3; export var c = 4;");
 let c = moduleRepo['c'] = parseModule("export * from 'a'; export * from 'b';");
-instantiateModule(c);
-evaluateModule(c);
+c.declarationInstantiation();
+c.evaluation();
 
 // Check importing/exporting non-ambiguous name works.
 let d = checkModuleEval("import { a } from 'c';");
 assertEq(getModuleEnvironmentValue(d, "a"), 1);
 checkModuleEval("export { a } from 'c';");
 
 // Check importing/exporting ambiguous name is a syntax error.
 checkModuleSyntaxError("import { b } from 'c';");
 checkModuleSyntaxError("export { b } from 'c';");
 
 // Check that namespace objects include only non-ambiguous names.
 let m = parseModule("import * as ns from 'c';");
-instantiateModule(m);
-evaluateModule(m);
-let ns = getModuleObject(c).namespace;
+m.declarationInstantiation();
+m.evaluation();
+let ns = c.namespace;
 let names = Object.keys(ns);
 assertEq(names.length, 2);
 assertEq('a' in ns, true);
 assertEq('b' in ns, false);
 assertEq('c' in ns, true);
--- a/js/src/jit-test/tests/modules/bad-namespace-created.js
+++ b/js/src/jit-test/tests/modules/bad-namespace-created.js
@@ -9,9 +9,9 @@ load(libdir + "dummyModuleResolveHook.js
 
 moduleRepo['A'] = parseModule('import "B"; export {x} from "C"');
 moduleRepo['B'] = parseModule('import * as a from "A"');
 moduleRepo['C'] = parseModule('export * from "D"; export * from "E"');
 moduleRepo['D'] = parseModule('export let x');
 moduleRepo['E'] = parseModule('export let x');
 
 let m = moduleRepo['A'];
-assertThrowsInstanceOf(() => instantiateModule(m), SyntaxError);
+assertThrowsInstanceOf(() => m.declarationInstantiation(), SyntaxError);
--- a/js/src/jit-test/tests/modules/bug-1233915.js
+++ b/js/src/jit-test/tests/modules/bug-1233915.js
@@ -2,10 +2,10 @@ g = newGlobal();
 g.parent = this;
 g.eval("(" + function() {
     Debugger(parent)
         .onExceptionUnwind = function(frame) {
         return frame.eval("");
     };
 } + ")()");
 m = parseModule(` s1 `);
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
--- a/js/src/jit-test/tests/modules/bug-1236875.js
+++ b/js/src/jit-test/tests/modules/bug-1236875.js
@@ -1,2 +1,2 @@
 let m = parseModule(`{ function x() {} }`);
-instantiateModule(m);
+m.declarationInstantiation();
--- a/js/src/jit-test/tests/modules/bug-1245518.js
+++ b/js/src/jit-test/tests/modules/bug-1245518.js
@@ -6,10 +6,10 @@ evalInFrame = function(global) {
     frame = dbg.getNewestFrame().older;
     frame.eval(code);
   }
 }(this);
 m = parseModule(`
   function g() { return this.hours = 0; }
   evalInFrame.call(0, 0, "g()")
 `);
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
--- a/js/src/jit-test/tests/modules/bug-1247934.js
+++ b/js/src/jit-test/tests/modules/bug-1247934.js
@@ -1,9 +1,9 @@
 let moduleRepo = {};
 setModuleResolveHook(function(module, specifier) {
         return moduleRepo[specifier];
 });
 setJitCompilerOption("ion.warmup.trigger", 50);
 s = "";
 for (i = 0; i < 1024; i++) s += "export let e" + i + "\n";
 moduleRepo['a'] = parseModule(s);
-instantiateModule(parseModule("import * as ns from 'a'"));
+parseModule("import * as ns from 'a'").declarationInstantiation();
--- a/js/src/jit-test/tests/modules/bug-1283448.js
+++ b/js/src/jit-test/tests/modules/bug-1283448.js
@@ -1,10 +1,10 @@
 // |jit-test| error: TypeError
 
 let moduleRepo = {};
 setModuleResolveHook(function(module, specifier) {
         return moduleRepo[specifier];
 });
 let a = moduleRepo['a'] = parseModule("var x = 1; export { x };");
 let b = moduleRepo['b'] = parseModule("import { x as y } from 'a';");
-getModuleObject(a).__proto__ = {15: 1337};
-instantiateModule(b);
+a.__proto__ = {15: 1337};
+b.declarationInstantiation();
--- a/js/src/jit-test/tests/modules/bug-1284486-2.js
+++ b/js/src/jit-test/tests/modules/bug-1284486-2.js
@@ -10,26 +10,26 @@
 load(libdir + "dummyModuleResolveHook.js");
 
 let b = moduleRepo['b'] = parseModule("export var b = 3; export var c = 4;");
 let c = moduleRepo['c'] = parseModule("export * from 'a'; export * from 'b';");
 
 let e1;
 let threw = false;
 try {
-    instantiateModule(c);
+    c.declarationInstantiation();
 } catch (exc) {
     threw = true;
     e1 = exc;
 }
 assertEq(threw, true);
 assertEq(typeof e1 === "undefined", false);
 
 threw = false;
 let e2;
 try {
-    instantiateModule(c);
+    c.declarationInstantiation();
 } catch (exc) {
     threw = true;
     e2 = exc;
 }
 assertEq(threw, true);
 assertEq(e1, e2);
--- a/js/src/jit-test/tests/modules/bug-1284486.js
+++ b/js/src/jit-test/tests/modules/bug-1284486.js
@@ -10,26 +10,26 @@
 load(libdir + "dummyModuleResolveHook.js");
 
 let b = moduleRepo['b'] = parseModule("export var b = 3; export var c = 4;");
 let c = moduleRepo['c'] = parseModule("export * from 'a'; export * from 'b';");
 
 let e1;
 let threw = false;
 try {
-    instantiateModule(c);
+    c.declarationInstantiation();
 } catch (exc) {
     threw = true;
     e1 = exc;
 }
 assertEq(threw, true);
 assertEq(typeof e1 === "undefined", false);
 
 let a = moduleRepo['a'] = parseModule("export var a = 1; export var b = 2;");
 let d = moduleRepo['d'] = parseModule("import { a } from 'c'; a;");
 
 threw = false;
 try {
-    instantiateModule(d);
+    d.declarationInstantiation();
 } catch (exc) {
     threw = true;
 }
 assertEq(threw, false);
--- a/js/src/jit-test/tests/modules/bug-1287410.js
+++ b/js/src/jit-test/tests/modules/bug-1287410.js
@@ -4,20 +4,20 @@ let moduleRepo = {};
 setModuleResolveHook(function(module, specifier) {
     if (specifier in moduleRepo)
         return moduleRepo[specifier];
     throw "Module '" + specifier + "' not found";
 });
 let a = moduleRepo['a'] = parseModule("export var a = 1; export var b = 2;");
 let b = moduleRepo['b'] = parseModule("export var b = 3; export var c = 4;");
 let c = moduleRepo['c'] = parseModule("export * from 'a'; export * from 'b';");
-instantiateModule(c);
+c.declarationInstantiation();
 
 // Module 'a' is replaced with another module that has not been instantiated.
 // This should not happen and would be a bug in the module loader.
 a = moduleRepo['a'] = parseModule("export var a = 1; export var b = 2;");
 
 let d = moduleRepo['d'] = parseModule("import { a } from 'c'; a;");
 
 // Attempting to instantiate 'd' throws an error because depdency 'a' of
 // instantiated module 'c' is not instantiated.
-instantiateModule(d);
-evaluateModule(d);
+d.declarationInstantiation();
+d.evaluation();
--- a/js/src/jit-test/tests/modules/bug-1372258.js
+++ b/js/src/jit-test/tests/modules/bug-1372258.js
@@ -19,10 +19,10 @@ let a = moduleRepo['a'] = parseModule("e
 
 let s = "";
 for (let i = 0; i < count; i++) {
     s += "import { a as i" + i + " } from 'a';\n";
     s += "assertEq(i" + i + ", 1);\n";
 }
 let b = moduleRepo['b'] = parseModule(s);
 
-instantiateModule(b);
-evaluateModule(b);
+b.declarationInstantiation();
+b.evaluation();
--- a/js/src/jit-test/tests/modules/bug-1402535.js
+++ b/js/src/jit-test/tests/modules/bug-1402535.js
@@ -1,7 +1,7 @@
 if (!('stackTest' in this))
    quit();
 
 stackTest(function() {
     let m = parseModule(``);
-    instantiateModule(m);
+    m.declarationInstantiation();
 });
--- a/js/src/jit-test/tests/modules/bug-1402649.js
+++ b/js/src/jit-test/tests/modules/bug-1402649.js
@@ -1,15 +1,15 @@
 if (!('oomTest' in this))
    quit();
 
 loadFile(`
 function parseAndEvaluate(source) {
     let m = parseModule(source);
-    instantiateModule(m);
+    m.declarationInstantiation();
 }
 parseAndEvaluate("async function a() { await 2 + 3; }")
 `);
 function loadFile(lfVarx) {
     oomTest(function() {
         eval(lfVarx);
     });
 }
--- a/js/src/jit-test/tests/modules/bug-1406452.js
+++ b/js/src/jit-test/tests/modules/bug-1406452.js
@@ -1,5 +1,5 @@
 // |jit-test| error: Error
 let m = parseModule(`for (var x of iterator) {}`);
-instantiateModule(m);
-try { evaluateModule(m); } catch (e) {}
+m.declarationInstantiation();
+try { m.evaluation(); } catch (e) {}
 getModuleEnvironmentValue(m, "r");
--- a/js/src/jit-test/tests/modules/bug-1420420-2.js
+++ b/js/src/jit-test/tests/modules/bug-1420420-2.js
@@ -9,10 +9,10 @@ moduleRepo["y1"] = parseModule(`export l
 moduleRepo["y2"] = parseModule(`export let y`);
 moduleRepo["bad"] = parseModule(`export* from "y1"; export* from "y2";`);
 
 moduleRepo["a"] = parseModule(`import* as ns from "good"; import {y} from "bad";`);
 
 let b = moduleRepo["b"] = parseModule(`import "a";`);
 let c = moduleRepo["c"] = parseModule(`import "a";`);
 
-assertThrowsInstanceOf(() => instantiateModule(b), SyntaxError);
-assertThrowsInstanceOf(() => instantiateModule(c), SyntaxError);
+assertThrowsInstanceOf(() => b.declarationInstantiation(), SyntaxError);
+assertThrowsInstanceOf(() => c.declarationInstantiation(), SyntaxError);
--- a/js/src/jit-test/tests/modules/bug-1420420-3.js
+++ b/js/src/jit-test/tests/modules/bug-1420420-3.js
@@ -1,8 +1,8 @@
 if (!('stackTest' in this))
    quit();
 
 let a = parseModule(`throw new Error`);
-instantiateModule(a);
+a.declarationInstantiation();
 stackTest(function() {
-    evaluateModule(a);
+    a.evaluation();
 });
--- a/js/src/jit-test/tests/modules/bug-1420420-4.js
+++ b/js/src/jit-test/tests/modules/bug-1420420-4.js
@@ -1,15 +1,15 @@
 load(libdir + "asserts.js");
 load(libdir + "dummyModuleResolveHook.js");
 
 moduleRepo["a"] = parseModule(`throw undefined`);
 
 let b = moduleRepo["b"] = parseModule(`import "a";`);
 let c = moduleRepo["c"] = parseModule(`import "a";`);
 
-instantiateModule(b);
-instantiateModule(c);
+b.declarationInstantiation();
+c.declarationInstantiation();
 
 let count = 0;
-try { evaluateModule(b) } catch (e) { count++; }
-try { evaluateModule(c) } catch (e) { count++; }
+try { b.evaluation() } catch (e) { count++; }
+try { c.evaluation() } catch (e) { count++; }
 assertEq(count, 2);
--- a/js/src/jit-test/tests/modules/bug-1420420.js
+++ b/js/src/jit-test/tests/modules/bug-1420420.js
@@ -9,10 +9,10 @@ moduleRepo["y1"] = parseModule(`export l
 moduleRepo["y2"] = parseModule(`export let y`);
 moduleRepo["bad"] = parseModule(`export* from "y1"; export* from "y2";`);
 
 moduleRepo["a"] = parseModule(`import {x} from "good"; import {y} from "bad";`);
 
 let b = moduleRepo["b"] = parseModule(`import "a";`);
 let c = moduleRepo["c"] = parseModule(`import "a";`);
 
-assertThrowsInstanceOf(() => instantiateModule(b), SyntaxError);
-assertThrowsInstanceOf(() => instantiateModule(c), SyntaxError);
+assertThrowsInstanceOf(() => b.declarationInstantiation(), SyntaxError);
+assertThrowsInstanceOf(() => c.declarationInstantiation(), SyntaxError);
--- a/js/src/jit-test/tests/modules/bug-1435327.js
+++ b/js/src/jit-test/tests/modules/bug-1435327.js
@@ -3,30 +3,30 @@ if (!('oomTest' in this))
 
 lfLogBuffer = `
   let moduleRepo = {};
   setModuleResolveHook(function(x, specifier) {
         return moduleRepo[specifier];
   });
   let c = moduleRepo['c'] = parseModule("");
   let d = moduleRepo['d'] = parseModule("import { a } from 'c'; a;");
-  instantiateModule(d);
+  d.declarationInstantiation();
 `;
 lfLogBuffer = lfLogBuffer.split('\n');
 var lfCodeBuffer = "";
 while (true) {
     var line = lfLogBuffer.shift();
     if (line == null) {
         break;
     } else {
         lfCodeBuffer += line + "\n";
     }
 }
 if (lfCodeBuffer) loadFile(lfCodeBuffer);
 function loadFile(lfVarx) {
     try {
         oomTest(function() {
             let m = parseModule(lfVarx);
-            instantiateModule(m);
-            evaluateModule(m);
+            m.declarationInstantiation();
+            m.evaluation();
         });
     } catch (lfVare) {}
 }
--- a/js/src/jit-test/tests/modules/bug-1443555.js
+++ b/js/src/jit-test/tests/modules/bug-1443555.js
@@ -27,10 +27,10 @@ function loopy() {
 
 let ASrc = `
 export default 1;
 `;
 
 moduleRepo['A'] = parseModule(ASrc);
 
 let m = parseModule(mainSrc);
-instantiateModule(m)
-evaluateModule(m);
+m.declarationInstantiation()
+m.evaluation();
--- a/js/src/jit-test/tests/modules/bug-1462286.js
+++ b/js/src/jit-test/tests/modules/bug-1462286.js
@@ -1,10 +1,10 @@
 load(libdir + "dummyModuleResolveHook.js");
 
 let a = moduleRepo['a'] = parseModule(`
   export var { ... get } = { x: "foo" };
 `);
 
 let m = parseModule("import { get } from 'a'; export { get };");
-instantiateModule(m);
-evaluateModule(m)
+m.declarationInstantiation();
+m.evaluation()
 assertEq(getModuleEnvironmentValue(m, "get").x, "foo");
--- a/js/src/jit-test/tests/modules/bug-1462326.js
+++ b/js/src/jit-test/tests/modules/bug-1462326.js
@@ -1,6 +1,6 @@
 // |jit-test| error: Error
 
 let m = parseModule(`
   import A from "A";
 `);
-instantiateModule(m);
+m.declarationInstantiation();
--- a/js/src/jit-test/tests/modules/bug-1463371.js
+++ b/js/src/jit-test/tests/modules/bug-1463371.js
@@ -2,9 +2,9 @@
 
 var g = newGlobal();
 g.eval(`
   setModuleResolveHook(function(module, specifier) { return module; });
 `);
 let m = parseModule(`
   import {} from './foo.js';
 `);
-instantiateModule(m);
+m.declarationInstantiation();
--- a/js/src/jit-test/tests/modules/bug-1463373.js
+++ b/js/src/jit-test/tests/modules/bug-1463373.js
@@ -1,11 +1,11 @@
 // |jit-test| error: InternalError
 
 let m = parseModule(`
   let c = parseModule(\`
     import "a";
   \`);
-  instantiateModule(c);
+  c.declarationInstantiation();
 `);
 setModuleResolveHook(function(module, specifier) { return m; });
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
--- a/js/src/jit-test/tests/modules/bug-1466487.js
+++ b/js/src/jit-test/tests/modules/bug-1466487.js
@@ -1,7 +1,7 @@
 if (helperThreadCount() === 0)
     quit();
 evalInWorker(`
     let m = parseModule("import.meta;");
-    instantiateModule(m);
-    evaluateModule(m);
+    m.declarationInstantiation();
+    m.evaluation();
 `);
--- a/js/src/jit-test/tests/modules/bug-1476921.js
+++ b/js/src/jit-test/tests/modules/bug-1476921.js
@@ -8,12 +8,12 @@ class UniqueError extends Error {}
 let a = moduleRepo['a'] = parseModule(`
     throw new UniqueError();
 `);
 
 let b = moduleRepo['b'] = parseModule(`
     import * as ns0 from "a";
 `);
 
-instantiateModule(a);
-assertThrowsInstanceOf(() => evaluateModule(a), UniqueError);
-instantiateModule(b);
-assertThrowsInstanceOf(() => evaluateModule(b), UniqueError);
+a.declarationInstantiation();
+assertThrowsInstanceOf(() => a.evaluation(), UniqueError);
+b.declarationInstantiation();
+assertThrowsInstanceOf(() => b.evaluation(), UniqueError);
--- a/js/src/jit-test/tests/modules/bug1210391.js
+++ b/js/src/jit-test/tests/modules/bug1210391.js
@@ -1,8 +1,8 @@
 load(libdir + "dummyModuleResolveHook.js");
 let a = moduleRepo['a'] = parseModule("export var a = 1; export var b = 2;");
 let b = moduleRepo['b'] = parseModule("export var b = 3; export var c = 4;");
 let c = moduleRepo['c'] = parseModule("export * from 'a'; export * from 'b';");
 let d = moduleRepo['d'] = parseModule("import { a } from 'c'; a;");
-instantiateModule(d);
-evaluateModule(d);
+d.declarationInstantiation();
+d.evaluation();
 
--- a/js/src/jit-test/tests/modules/bug1394492.js
+++ b/js/src/jit-test/tests/modules/bug1394492.js
@@ -1,6 +1,6 @@
-// |jit-test| error: TypeError
+// |jit-test| error: NaN
 let m = parseModule(`
   throw i => { return 5; }, m-1;
 `);
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
--- a/js/src/jit-test/tests/modules/bug1429031.js
+++ b/js/src/jit-test/tests/modules/bug1429031.js
@@ -8,13 +8,13 @@ assertEq = function(a, b) {}
 evaluate(`
 let a = moduleRepo['a'] = parseModule(
     'export var a = 1;'
 );
 let b = moduleRepo['b'] = parseModule(
     \`import * as ns from 'a';
      export var x = ns.a + ns.b;\`
 );
-instantiateModule(b);
+b.declarationInstantiation();
 let ns = getModuleEnvironmentValue(b, "ns");
 assertEq(ns.a, 1);
 while ( t.ArrayType() ) 1;
 `);
--- a/js/src/jit-test/tests/modules/bug1449153.js
+++ b/js/src/jit-test/tests/modules/bug1449153.js
@@ -21,16 +21,16 @@ setModuleResolveHook(function(module, sp
 
 moduleRepo["a"] = parseModule(`
     throw new MyError();
 `);
 
 let c = moduleRepo["c"] = parseModule(`
     import "a";
 `);
-instantiateModule(c);
-assertThrowsMyError(() => evaluateModule(c));
+c.declarationInstantiation();
+assertThrowsMyError(() => c.evaluation());
 
 let b = moduleRepo['b'] = parseModule(`
     import * as ns0 from 'a'
 `);
-instantiateModule(b);
-assertThrowsMyError(() => evaluateModule(b));
+b.declarationInstantiation();
+assertThrowsMyError(() => b.evaluation(b));
--- a/js/src/jit-test/tests/modules/bug1485698.js
+++ b/js/src/jit-test/tests/modules/bug1485698.js
@@ -1,9 +1,9 @@
 let m = parseModule(`
   function f(x,y,z) {
     delete arguments[2];
     import.meta[2]
   }
   f(1,2,3)
 `);
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
--- a/js/src/jit-test/tests/modules/debugger-frames.js
+++ b/js/src/jit-test/tests/modules/debugger-frames.js
@@ -67,23 +67,23 @@ f = g2.eval(
     // Set up a module to import from.
     a = moduleRepo['a'] = parseModule(
     \`
         export var a = 1;
         export let b = 2;
         export const c = 3;
         export function f(x) { return x + 1; }
     \`);
-    instantiateModule(a);
-    evaluateModule(a);
+    a.declarationInstantiation();
+    a.evaluation();
 
     let m = parseModule(
     \`
         import { a, b, c } from 'a';
         var x = 4;
         let y = 5;
         const z = 6;
 
         debugger;
     \`);
-    instantiateModule(m);
-    evaluateModule(m);
+    m.declarationInstantiation();
+    m.evaluation();
 `);
--- a/js/src/jit-test/tests/modules/debugger-vars-function.js
+++ b/js/src/jit-test/tests/modules/debugger-vars-function.js
@@ -26,12 +26,12 @@ g.eval(
     \`
         var a = 1;
         let b = 2;
         export var c = 3;
         export let d = 4;
         let e = 5;
         function f() { debugger; return e; }
     \`);
-    instantiateModule(m);
-    evaluateModule(m);
+    m.declarationInstantiation();
+    m.evaluation();
 `);
 
--- a/js/src/jit-test/tests/modules/debugger-vars-toplevel.js
+++ b/js/src/jit-test/tests/modules/debugger-vars-toplevel.js
@@ -27,12 +27,12 @@ g.eval(
         var a = 1;
         let b = 2;
         export var c = 3;
         export let d = 4;
         let e = 5;
         function f() { return e; }
         debugger;
     \`);
-    instantiateModule(m);
-    evaluateModule(m);
+    m.declarationInstantiation();
+    m.evaluation();
 `);
 
--- a/js/src/jit-test/tests/modules/eval-module-oom.js
+++ b/js/src/jit-test/tests/modules/eval-module-oom.js
@@ -16,11 +16,11 @@ const sb =
  import { a as y } from "a";
  import * as ns from "a";
  ns.f(x, y);
 `;
 
 oomTest(() => {
     let a = moduleRepo['a'] = parseModule(sa);
     let b = moduleRepo['b'] = parseModule(sb);
-    instantiateModule(b);
-    assertEq(evaluateModule(b), 42);
+    b.declarationInstantiation();
+    assertEq(b.evaluation(), 42);
 });
--- a/js/src/jit-test/tests/modules/export-destructuring.js
+++ b/js/src/jit-test/tests/modules/export-destructuring.js
@@ -35,18 +35,18 @@ m = parseModule(`
     assertEq(a.i, 10);
     assertEq(a.j, 13);
     assertArrayEq(a.k, [14, 15, 16]);
     assertEq(a.l, 17);
     assertArrayEq(a.m, [18, 19]);
     assertArrayEq(a.n, [22]);
 `);
 
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
 
 moduleRepo['o'] = parseModule(`
     export const {} = {};
     export const {x: a=0} = {};
     export const {x: b=0} = {x: 1};
     export const {c, d, e} = {c: 2, d: 3, e: 4};
     export const {x: f} = {x: 5};
     export const {g} = {};
@@ -61,18 +61,18 @@ m = parseModule(`
     assertEq(o.c, 2);
     assertEq(o.d, 3);
     assertEq(o.e, 4);
     assertEq(o.f, 5);
     assertEq(o.g, undefined);
     assertEq(o.h, 6);
 `);
 
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
 
 moduleRepo['ao'] = parseModule(`
     export const [{x: a}, {x: b}] = [{x: 1}, {x: 2}];
     export const [{c}, {d}] = [{c: 3}, {d: 4}];
     export const [,, {e}, ...f] = [5, 6, {e: 7}, 8, 9];
 
     export const {x: [g, h, i]} = {x: [10, 11, 12]};
 
@@ -97,10 +97,10 @@ m = parseModule(`
     assertEq(ao.k, 16);
     assertEq(ao.l, 17);
     assertEq(ao.m, 18);
     assertEq(ao.n, 19);
     assertEq(ao.o, 20);
     assertEq(ao.p, 21);
 `);
 
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
--- a/js/src/jit-test/tests/modules/export-entries.js
+++ b/js/src/jit-test/tests/modules/export-entries.js
@@ -5,17 +5,17 @@ function testArrayContents(actual, expec
     for (var i = 0; i < actual.length; i++) {
         for (var property in expected[i]) {
             assertEq(actual[i][property], expected[i][property]);
         }
     }
 }
 
 function testLocalExportEntries(source, expected) {
-    var module = getModuleObject(parseModule(source));
+    var module = parseModule(source);
     testArrayContents(module.localExportEntries, expected);
 }
 
 testLocalExportEntries(
     'export var v;',
     [{exportName: 'v', moduleRequest: null, importName: null, localName: 'v'}]);
 
 testLocalExportEntries(
@@ -64,17 +64,17 @@ testLocalExportEntries(
 
 testLocalExportEntries(
     'export * from "mod";',
     []);
 
 // Test indirectExportEntries property
 
 function testIndirectExportEntries(source, expected) {
-    var module = getModuleObject(parseModule(source));
+    var module = parseModule(source);
     testArrayContents(module.indirectExportEntries, expected);
 }
 
 testIndirectExportEntries(
     'export default function f() {};',
     []);
 
 testIndirectExportEntries(
@@ -95,17 +95,17 @@ testIndirectExportEntries(
 
 testIndirectExportEntries(
     'import {v as x} from "mod"; export {x as y};',
     [{exportName: 'y', moduleRequest: 'mod', importName: 'v', localName: null}]);
 
 // Test starExportEntries property
 
 function testStarExportEntries(source, expected) {
-    var module = getModuleObject(parseModule(source));
+    var module = parseModule(source);
     testArrayContents(module.starExportEntries, expected);
 }
 
 testStarExportEntries(
     'export default function f() {};',
     []);
 
 testStarExportEntries(
--- a/js/src/jit-test/tests/modules/global-scope.js
+++ b/js/src/jit-test/tests/modules/global-scope.js
@@ -1,14 +1,14 @@
 // Test interaction with global object and global lexical scope.
 
 function evalModuleAndCheck(source, expected) {
     let m = parseModule(source);
-    instantiateModule(m);
-    evaluateModule(m);
+    m.declarationInstantiation();
+    m.evaluation();
     assertEq(getModuleEnvironmentValue(m, "r"), expected);
 }
 
 var x = 1;
 evalModuleAndCheck("export let r = x; x = 2;", 1);
 assertEq(x, 2);
 
 let y = 3;
@@ -17,18 +17,18 @@ assertEq(y, 4);
 
 if (helperThreadCount() == 0)
     quit();
 
 function offThreadEvalModuleAndCheck(source, expected) {
     offThreadCompileModule(source);
     let m = finishOffThreadModule();
     print("compiled");
-    instantiateModule(m);
-    evaluateModule(m);
+    m.declarationInstantiation();
+    m.evaluation();
     assertEq(getModuleEnvironmentValue(m, "r"), expected);
 }
 
 offThreadEvalModuleAndCheck("export let r = x; x = 5;", 2);
 assertEq(x, 5);
 
 offThreadEvalModuleAndCheck("export let r = y; y = 6;", 4);
 assertEq(y, 6);
--- a/js/src/jit-test/tests/modules/import-entries.js
+++ b/js/src/jit-test/tests/modules/import-entries.js
@@ -12,17 +12,17 @@ function findImportEntry(array, target)
     for (let i = 0; i < array.length; i++) {
         if (importEntryEq(array[i], target))
             return i;
     }
     return -1;
 }
 
 function testImportEntries(source, expected) {
-    var module = getModuleObject(parseModule(source));
+    var module = parseModule(source);
     var actual = module.importEntries.slice(0);
     assertEq(actual.length, expected.length);
     for (var i = 0; i < expected.length; i++) {
         let index = findImportEntry(actual, expected[i]);
         assertEq(index >= 0, true);
         actual.splice(index, 1);
     }
 }
--- a/js/src/jit-test/tests/modules/import-namespace.js
+++ b/js/src/jit-test/tests/modules/import-namespace.js
@@ -3,18 +3,18 @@
 "use strict";
 
 load(libdir + "asserts.js");
 load(libdir + "iteration.js");
 load(libdir + "dummyModuleResolveHook.js");
 
 function parseAndEvaluate(source) {
     let m = parseModule(source);
-    instantiateModule(m);
-    return evaluateModule(m);
+    m.declarationInstantiation();
+    return m.evaluation();
 }
 
 function testHasNames(names, expected) {
     assertEq(names.length, expected.length);
     expected.forEach(function(name) {
         assertEq(names.includes(name), true);
     });
 }
@@ -35,18 +35,18 @@ let a = moduleRepo['a'] = parseModule(
 );
 
 let b = moduleRepo['b'] = parseModule(
     `import * as ns from 'a';
      export { ns };
      export var x = ns.a + ns.b;`
 );
 
-instantiateModule(b);
-evaluateModule(b);
+b.declarationInstantiation();
+b.evaluation();
 testHasNames(getModuleEnvironmentNames(b), ["ns", "x"]);
 let ns = getModuleEnvironmentValue(b, "ns");
 testHasNames(Object.keys(ns), ["a", "b"]);
 assertEq(ns.a, 1);
 assertEq(ns.b, 2);
 assertEq(ns.c, undefined);
 assertEq(getModuleEnvironmentValue(b, "x"), 3);
 
@@ -84,23 +84,23 @@ testEqualArrays(Reflect.ownKeys(ns), ["a
 testEqualArrays(Object.getOwnPropertyNames(ns), ["a", "b"]);
 testEqualArrays(Object.getOwnPropertySymbols(ns), [Symbol.toStringTag]);
 
 // Test cyclic namespace import and access in module evaluation.
 let c = moduleRepo['c'] =
     parseModule("export let c = 1; import * as ns from 'd'; let d = ns.d;");
 let d = moduleRepo['d'] =
     parseModule("export let d = 2; import * as ns from 'c'; let c = ns.c;");
-instantiateModule(c);
-instantiateModule(d);
-assertThrowsInstanceOf(() => evaluateModule(c), ReferenceError);
+c.declarationInstantiation();
+d.declarationInstantiation();
+assertThrowsInstanceOf(() => c.evaluation(), ReferenceError);
 
 // Test cyclic namespace import.
 let e = moduleRepo['e'] =
     parseModule("export let e = 1; import * as ns from 'f'; export function f() { return ns.f }");
 let f = moduleRepo['f'] =
     parseModule("export let f = 2; import * as ns from 'e'; export function e() { return ns.e }");
-instantiateModule(e);
-instantiateModule(f);
-evaluateModule(e);
-evaluateModule(f);
-assertEq(getModuleObject(e).namespace.f(), 2);
-assertEq(getModuleObject(f).namespace.e(), 1);
+e.declarationInstantiation();
+f.declarationInstantiation();
+e.evaluation();
+f.evaluation();
+assertEq(e.namespace.f(), 2);
+assertEq(f.namespace.e(), 1);
--- a/js/src/jit-test/tests/modules/many-exports.js
+++ b/js/src/jit-test/tests/modules/many-exports.js
@@ -6,14 +6,14 @@ const count = 1024;
 
 let s = "";
 for (let i = 0; i < count; i++)
     s += "export let e" + i + " = " + (i * i) + ";\n";
 let a = moduleRepo['a'] = parseModule(s);
 
 let b = moduleRepo['b'] = parseModule("import * as ns from 'a'");
 
-instantiateModule(b);
-evaluateModule(b);
+b.declarationInstantiation();
+b.evaluation();
 
-let ns = getModuleObject(a).namespace;
+let ns = a.namespace;
 for (let i = 0; i < count; i++)
     assertEq(ns["e" + i], i * i);
--- a/js/src/jit-test/tests/modules/many-imports.js
+++ b/js/src/jit-test/tests/modules/many-imports.js
@@ -8,10 +8,10 @@ let a = moduleRepo['a'] = parseModule("e
 
 let s = "";
 for (let i = 0; i < count; i++) {
     s += "import { a as i" + i + " } from 'a';\n";
     s += "assertEq(i" + i + ", 1);\n";
 }
 let b = moduleRepo['b'] = parseModule(s);
 
-instantiateModule(b);
-evaluateModule(b);
+b.declarationInstantiation();
+b.evaluation();
--- a/js/src/jit-test/tests/modules/many-namespace-imports.js
+++ b/js/src/jit-test/tests/modules/many-namespace-imports.js
@@ -8,10 +8,10 @@ let a = moduleRepo['a'] = parseModule("e
 
 let s = "";
 for (let i = 0; i < count; i++) {
     s += "import * as ns" + i + " from 'a';\n";
     s += "assertEq(ns" + i + ".a, 1);\n";
 }
 let b = moduleRepo['b'] = parseModule(s);
 
-instantiateModule(b);
-evaluateModule(b);
+b.declarationInstantiation();
+b.evaluation();
--- a/js/src/jit-test/tests/modules/module-declaration-instantiation.js
+++ b/js/src/jit-test/tests/modules/module-declaration-instantiation.js
@@ -7,33 +7,33 @@ function testModuleEnvironment(module, e
     assertEq(actual.length, expected.length);
     for (var i = 0; i < actual.length; i++) {
         assertEq(actual[i], expected[i]);
     }
 }
 
 // Check the environment of an empty module.
 let m = parseModule("");
-instantiateModule(m);
+m.declarationInstantiation();
 testModuleEnvironment(m, []);
 
 let a = moduleRepo['a'] = parseModule("var x = 1; export { x };");
 let b = moduleRepo['b'] = parseModule("import { x as y } from 'a';");
 
-instantiateModule(a);
-instantiateModule(b);
+a.declarationInstantiation();
+b.declarationInstantiation();
 
 testModuleEnvironment(a, ['x']);
 testModuleEnvironment(b, ['y']);
 
 // Function bindings are initialized as well as instantiated.
 let c = parseModule(`function a(x) { return x; }
                      function b(x) { return x + 1; }
                      function c(x) { return x + 2; }
                      function d(x) { return x + 3; }`);
 const names = ['a', 'b', 'c', 'd'];
 testModuleEnvironment(c, names);
 names.forEach((n) => assertEq(typeof getModuleEnvironmentValue(c, n), "undefined"));
-instantiateModule(c);
+c.declarationInstantiation();
 for (let i = 0; i < names.length; i++) {
     let f = getModuleEnvironmentValue(c, names[i]);
     assertEq(f(21), 21 + i);
 }
--- a/js/src/jit-test/tests/modules/module-evaluation.js
+++ b/js/src/jit-test/tests/modules/module-evaluation.js
@@ -1,39 +1,39 @@
 // Exercise ModuleEvaluation() concrete method.
 
 load(libdir + "asserts.js");
 load(libdir + "dummyModuleResolveHook.js");
 
 function parseAndEvaluate(source) {
     let m = parseModule(source);
-    instantiateModule(m);
-    evaluateModule(m);
+    m.declarationInstantiation();
+    m.evaluation();
     return m;
 }
 
 // Check the evaluation of an empty module succeeds.
 parseAndEvaluate("");
 
 // Check evaluation returns evaluation result the first time, then undefined.
 let m = parseModule("1");
-instantiateModule(m);
-assertEq(evaluateModule(m), undefined);
-assertEq(typeof evaluateModule(m), "undefined");
+m.declarationInstantiation();
+assertEq(m.evaluation(), undefined);
+assertEq(typeof m.evaluation(), "undefined");
 
 // Check top level variables are initialized by evaluation.
 m = parseModule("export var x = 2 + 2;");
 assertEq(typeof getModuleEnvironmentValue(m, "x"), "undefined");
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
 assertEq(getModuleEnvironmentValue(m, "x"), 4);
 
 m = parseModule("export let x = 2 * 3;");
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
 assertEq(getModuleEnvironmentValue(m, "x"), 6);
 
 // Set up a module to import from.
 let a = moduleRepo['a'] =
 parseModule(`var x = 1;
              export { x };
              export default 2;
              export function f(x) { return x + 1; }`);
@@ -57,30 +57,30 @@ parseAndEvaluate("import a from 'a';");
 parseAndEvaluate("import { x } from 'a';");
 parseAndEvaluate("import * as ns from 'a';");
 parseAndEvaluate("export * from 'a'");
 parseAndEvaluate("export default class { constructor() {} };");
 parseAndEvaluate("export default class foo { constructor() {} };");
 
 // Test default import
 m = parseModule("import a from 'a'; export { a };")
-instantiateModule(m);
-evaluateModule(m)
+m.declarationInstantiation();
+m.evaluation()
 assertEq(getModuleEnvironmentValue(m, "a"), 2);
 
 // Test named import
 m = parseModule("import { x as y } from 'a'; export { y };")
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
 assertEq(getModuleEnvironmentValue(m, "y"), 1);
 
 // Call exported function
 m = parseModule("import { f } from 'a'; export let x = f(3);")
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
 assertEq(getModuleEnvironmentValue(m, "x"), 4);
 
 // Test importing an indirect export
 moduleRepo['b'] = parseModule("export { x as z } from 'a';");
 m = parseAndEvaluate("import { z } from 'b'; export { z }");
 assertEq(getModuleEnvironmentValue(m, "z"), 1);
 
 // Test cyclic dependencies
@@ -88,12 +88,12 @@ moduleRepo['c1'] = parseModule("export v
 moduleRepo['c2'] = parseModule("export var y = 2; export {x} from 'c1'");
 m = parseAndEvaluate(`import { x as x1, y as y1 } from 'c1';
                       import { x as x2, y as y2 } from 'c2';
                       export let z = [x1, y1, x2, y2]`),
 assertDeepEq(getModuleEnvironmentValue(m, "z"), [1, 2, 1, 2]);
 
 // Import access in functions
 m = parseModule("import { x } from 'a'; function f() { return x; }")
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
 let f = getModuleEnvironmentValue(m, "f");
 assertEq(f(), 1);
--- a/js/src/jit-test/tests/modules/module-this.js
+++ b/js/src/jit-test/tests/modules/module-this.js
@@ -1,15 +1,15 @@
 // Test 'this' is undefined in modules.
 
 function parseAndEvaluate(source) {
     let m = parseModule(source);
-    instantiateModule(m);
-    return evaluateModule(m);
+    m.declarationInstantiation();
+    return m.evaluation();
 }
 
 assertEq(typeof(parseAndEvaluate("this")), "undefined");
 
 let m = parseModule("export function getThis() { return this; }");
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
 let f = getModuleEnvironmentValue(m, "getThis");
 assertEq(typeof(f()), "undefined");
--- a/js/src/jit-test/tests/modules/off-thread-compile.js
+++ b/js/src/jit-test/tests/modules/off-thread-compile.js
@@ -4,13 +4,13 @@ if (helperThreadCount() == 0)
     quit();
 
 load(libdir + "asserts.js");
 load(libdir + "dummyModuleResolveHook.js");
 
 function offThreadParseAndEvaluate(source) {
     offThreadCompileModule(source);
     let m = finishOffThreadModule();
-    instantiateModule(m);
-    return evaluateModule(m);
+    m.declarationInstantiation();
+    return m.evaluation();
 }
 
 offThreadParseAndEvaluate("export let x = 2 * 3;");
--- a/js/src/jit-test/tests/modules/requested-modules.js
+++ b/js/src/jit-test/tests/modules/requested-modules.js
@@ -1,12 +1,12 @@
 // Test requestedModules property
 
 function testRequestedModules(source, expected) {
-    var module = getModuleObject(parseModule(source));
+    var module = parseModule(source);
     var actual = module.requestedModules;
     assertEq(actual.length, expected.length);
     for (var i = 0; i < actual.length; i++) {
         assertEq(actual[i].moduleSpecifier, expected[i]);
     }
 }
 
 testRequestedModules("", []);
--- a/js/src/jit-test/tests/parser/bug-1263355-16.js
+++ b/js/src/jit-test/tests/parser/bug-1263355-16.js
@@ -2,10 +2,10 @@
 
 let m = parseModule(`
 var i = 0;
 addThis();
 function addThis() {
   return statusmessages[i] = Number;
 }
 `);
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
--- a/js/src/jit-test/tests/parser/bug-1263355-23.js
+++ b/js/src/jit-test/tests/parser/bug-1263355-23.js
@@ -1,7 +1,7 @@
 let m = parseModule(`
   const root = newGlobal();
   minorgc();
   root.eval();
 `);
-instantiateModule(m);
-evaluateModule(m);
+m.declarationInstantiation();
+m.evaluation();
--- a/js/src/jit-test/tests/parser/bug-1263355-48.js
+++ b/js/src/jit-test/tests/parser/bug-1263355-48.js
@@ -1,16 +1,16 @@
 if (helperThreadCount() == 0)
   quit();
 
 function eval(source) {
     offThreadCompileModule(source);
     let m = finishOffThreadModule();
-    instantiateModule(m);
-    return evaluateModule(m);
+    m.declarationInstantiation();
+    return m.evaluation();
 }
 function runTestCase(testcase) {
     if (testcase() !== true) {}
 }
 eval(`
   function testcase() {
     function set () {}
   }
--- a/js/src/jit/BaselineCompiler.cpp
+++ b/js/src/jit/BaselineCompiler.cpp
@@ -5422,17 +5422,16 @@ BaselineCompiler::emit_JSOP_DERIVEDCONST
 }
 
 bool
 BaselineCompiler::emit_JSOP_IMPORTMETA()
 {
     RootedModuleObject module(cx, GetModuleObjectForScript(script));
     MOZ_ASSERT(module);
 
-    RootedScript moduleScript(cx, module->script());
-    JSObject* metaObject = GetOrCreateModuleMetaObject(cx, moduleScript);
+    JSObject* metaObject = GetOrCreateModuleMetaObject(cx, module);
     if (!metaObject) {
         return false;
     }
 
     frame.push(ObjectValue(*metaObject));
     return true;
 }
--- a/js/src/jsapi.cpp
+++ b/js/src/jsapi.cpp
@@ -1281,25 +1281,16 @@ JS::CurrentGlobalOrNull(JSContext* cx)
 JS_PUBLIC_API(JSObject*)
 JS::GetNonCCWObjectGlobal(JSObject* obj)
 {
     AssertHeapIsIdleOrIterating();
     MOZ_DIAGNOSTIC_ASSERT(!IsCrossCompartmentWrapper(obj));
     return &obj->nonCCWGlobal();
 }
 
-JS_PUBLIC_API(JSObject*)
-JS::GetScriptGlobal(JSScript* script)
-{
-    AssertHeapIsIdleOrIterating();
-    JSObject* global = script->realm()->maybeGlobal();
-    MOZ_ASSERT(global);
-    return global;
-}
-
 JS_PUBLIC_API(bool)
 JS::detail::ComputeThis(JSContext* cx, Value* vp, MutableHandleObject thisObject)
 {
     AssertHeapIsIdle();
     cx->check(vp[0], vp[1]);
 
     MutableHandleValue thisv = MutableHandleValue::fromMarkedLocation(&vp[1]);
     if (!BoxNonStrictThis(cx, thisv, thisv)) {
@@ -4145,71 +4136,63 @@ JS_PUBLIC_API(void)
 JS::SetModuleMetadataHook(JSRuntime* rt, JS::ModuleMetadataHook func)
 {
     AssertHeapIsIdle();
     rt->moduleMetadataHook = func;
 }
 
 JS_PUBLIC_API(bool)
 JS::CompileModule(JSContext* cx, const ReadOnlyCompileOptions& options,
-                  SourceBufferHolder& srcBuf, JS::MutableHandleScript script)
+                  SourceBufferHolder& srcBuf, JS::MutableHandleObject module)
 {
     MOZ_ASSERT(!cx->zone()->isAtomsZone());
     AssertHeapIsIdle();
     CHECK_THREAD(cx);
 
-    script.set(frontend::CompileModule(cx, options, srcBuf));
-    return !!script;
+    module.set(frontend::CompileModule(cx, options, srcBuf));
+    return !!module;
 }
 
 JS_PUBLIC_API(void)
-JS::SetTopLevelScriptPrivate(JSScript* script, void* value)
-{
-    MOZ_ASSERT(script);
-    script->setTopLevelPrivate(value);
-}
-
-JS_PUBLIC_API(void*)
-JS::GetTopLevelScriptPrivate(JSScript* script)
-{
-    MOZ_ASSERT(script);
-    return script->maybeTopLevelPrivate();
-}
-
-JS_PUBLIC_API(bool)
-JS::ModuleInstantiate(JSContext* cx, JS::HandleScript script)
-{
-    AssertHeapIsIdle();
-    CHECK_THREAD(cx);
-    cx->check(script);
-    RootedModuleObject module(cx, script->module());
-    MOZ_ASSERT(module);
-    return ModuleObject::Instantiate(cx, module);
-}
-
-JS_PUBLIC_API(bool)