From 1fb5aad1796596e6c875bfaf1eed71324a7d64df Mon Sep 17 00:00:00 2001 From: "B. Stack" Date: Wed, 25 May 2022 16:23:01 -0400 Subject: lw 100.0.2 dpkg rc1 --- ...reference-files-to-set-locked-prefs-with-.patch | 2 +- ...-Add-webrtc-configs-for-arm-and-ppc64-lin.patch | 60 +++--- ...-part-1-Work-around-a-GCC-issue-with-gene.patch | 235 --------------------- 3 files changed, 31 insertions(+), 266 deletions(-) delete mode 100644 librewolf/debian/patches/fixes/Bug-1756347-part-1-Work-around-a-GCC-issue-with-gene.patch (limited to 'librewolf/debian/patches/fixes') diff --git a/librewolf/debian/patches/fixes/Allow-.js-preference-files-to-set-locked-prefs-with-.patch b/librewolf/debian/patches/fixes/Allow-.js-preference-files-to-set-locked-prefs-with-.patch index c06839f..a474a5b 100644 --- a/librewolf/debian/patches/fixes/Allow-.js-preference-files-to-set-locked-prefs-with-.patch +++ b/librewolf/debian/patches/fixes/Allow-.js-preference-files-to-set-locked-prefs-with-.patch @@ -7,7 +7,7 @@ Subject: Allow .js preference files to set locked prefs with lockPref() 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/modules/libpref/parser/src/lib.rs b/modules/libpref/parser/src/lib.rs -index bce98c0..da33195 100644 +index bce98c0..da33195a 100644 --- a/modules/libpref/parser/src/lib.rs +++ b/modules/libpref/parser/src/lib.rs @@ -11,8 +11,9 @@ diff --git a/librewolf/debian/patches/fixes/Bug-1738845-Add-webrtc-configs-for-arm-and-ppc64-lin.patch b/librewolf/debian/patches/fixes/Bug-1738845-Add-webrtc-configs-for-arm-and-ppc64-lin.patch index 302d130..b700cce 100644 --- a/librewolf/debian/patches/fixes/Bug-1738845-Add-webrtc-configs-for-arm-and-ppc64-lin.patch +++ b/librewolf/debian/patches/fixes/Bug-1738845-Add-webrtc-configs-for-arm-and-ppc64-lin.patch @@ -121407,7 +121407,7 @@ index 0000000..bb14be3 \ No newline at end of file diff --git a/dom/media/webrtc/third_party_build/gn-configs/x64_True_arm_linux.mozconfig b/dom/media/webrtc/third_party_build/gn-configs/x64_True_arm_linux.mozconfig new file mode 100644 -index 0000000..0f162f5 +index 0000000..0f162f57 --- /dev/null +++ b/dom/media/webrtc/third_party_build/gn-configs/x64_True_arm_linux.mozconfig @@ -0,0 +1,4 @@ @@ -151627,7 +151627,7 @@ index 58f0062..b9556dc 100644 Library("audio_encoder_multiopus_gn") diff --git a/third_party/libwebrtc/api/audio_codecs/opus/audio_encoder_opus_config_gn/moz.build b/third_party/libwebrtc/api/audio_codecs/opus/audio_encoder_opus_config_gn/moz.build -index a8f5c61..8426e0f 100644 +index a8f5c61..8426e0f5 100644 --- a/third_party/libwebrtc/api/audio_codecs/opus/audio_encoder_opus_config_gn/moz.build +++ b/third_party/libwebrtc/api/audio_codecs/opus/audio_encoder_opus_config_gn/moz.build @@ -83,7 +83,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -152158,7 +152158,7 @@ index bb55b07..6c7ab10 100644 Library("callfactory_api_gn") diff --git a/third_party/libwebrtc/api/crypto/frame_decryptor_interface_gn/moz.build b/third_party/libwebrtc/api/crypto/frame_decryptor_interface_gn/moz.build -index fe4a347..9ca8a02 100644 +index fe4a347c..9ca8a02 100644 --- a/third_party/libwebrtc/api/crypto/frame_decryptor_interface_gn/moz.build +++ b/third_party/libwebrtc/api/crypto/frame_decryptor_interface_gn/moz.build @@ -74,7 +74,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -153304,7 +153304,7 @@ index 1a5b0bf..b00f466 100644 Library("network_state_predictor_api_gn") diff --git a/third_party/libwebrtc/api/numerics/numerics_gn/moz.build b/third_party/libwebrtc/api/numerics/numerics_gn/moz.build -index fa11b29..b5e327c 100644 +index fa11b290a..b5e327c 100644 --- a/third_party/libwebrtc/api/numerics/numerics_gn/moz.build +++ b/third_party/libwebrtc/api/numerics/numerics_gn/moz.build @@ -78,7 +78,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -153658,7 +153658,7 @@ index 01b92ce..de87a29 100644 Library("rtc_error_gn") diff --git a/third_party/libwebrtc/api/rtc_event_log/rtc_event_log_gn/moz.build b/third_party/libwebrtc/api/rtc_event_log/rtc_event_log_gn/moz.build -index 62dec01..c747f7b 100644 +index 62dec010..c747f7b 100644 --- a/third_party/libwebrtc/api/rtc_event_log/rtc_event_log_gn/moz.build +++ b/third_party/libwebrtc/api/rtc_event_log/rtc_event_log_gn/moz.build @@ -79,7 +79,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -154369,7 +154369,7 @@ index 691d7ed..02e2b71 100644 Library("task_queue_gn") diff --git a/third_party/libwebrtc/api/transport/bitrate_settings_gn/moz.build b/third_party/libwebrtc/api/transport/bitrate_settings_gn/moz.build -index 3513f9c..2e670ab 100644 +index 3513f9c2..2e670ab 100644 --- a/third_party/libwebrtc/api/transport/bitrate_settings_gn/moz.build +++ b/third_party/libwebrtc/api/transport/bitrate_settings_gn/moz.build @@ -74,7 +74,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -155263,7 +155263,7 @@ index 14b9742..9257173 100644 Library("data_size_gn") diff --git a/third_party/libwebrtc/api/units/frequency_gn/moz.build b/third_party/libwebrtc/api/units/frequency_gn/moz.build -index 79fcff4..5a54b58 100644 +index 79fcff48..5a54b58 100644 --- a/third_party/libwebrtc/api/units/frequency_gn/moz.build +++ b/third_party/libwebrtc/api/units/frequency_gn/moz.build @@ -78,7 +78,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -155533,7 +155533,7 @@ index 23aa0ba..83f104b 100644 Library("timestamp_gn") diff --git a/third_party/libwebrtc/api/video/builtin_video_bitrate_allocator_factory_gn/moz.build b/third_party/libwebrtc/api/video/builtin_video_bitrate_allocator_factory_gn/moz.build -index 0ecc793..c0cbd77 100644 +index 0ecc793..c0cbd775 100644 --- a/third_party/libwebrtc/api/video/builtin_video_bitrate_allocator_factory_gn/moz.build +++ b/third_party/libwebrtc/api/video/builtin_video_bitrate_allocator_factory_gn/moz.build @@ -79,7 +79,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -157051,7 +157051,7 @@ index 57a39cf..3528c34 100644 Library("video_stream_encoder_create_gn") diff --git a/third_party/libwebrtc/api/video/video_stream_encoder_gn/moz.build b/third_party/libwebrtc/api/video/video_stream_encoder_gn/moz.build -index e5e9a7c..7114a4a 100644 +index e5e9a7c0..7114a4a 100644 --- a/third_party/libwebrtc/api/video/video_stream_encoder_gn/moz.build +++ b/third_party/libwebrtc/api/video/video_stream_encoder_gn/moz.build @@ -74,7 +74,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -157405,7 +157405,7 @@ index bd29841..ee6547d 100644 Library("builtin_video_encoder_factory_gn") diff --git a/third_party/libwebrtc/api/video_codecs/rtc_software_fallback_wrappers_gn/moz.build b/third_party/libwebrtc/api/video_codecs/rtc_software_fallback_wrappers_gn/moz.build -index 90afc61..fe91abb 100644 +index 90afc61c..fe91abb 100644 --- a/third_party/libwebrtc/api/video_codecs/rtc_software_fallback_wrappers_gn/moz.build +++ b/third_party/libwebrtc/api/video_codecs/rtc_software_fallback_wrappers_gn/moz.build @@ -80,7 +80,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -158302,7 +158302,7 @@ index 8cb24f9..e7ede49 100644 Library("call_gn") diff --git a/third_party/libwebrtc/call/call_interfaces_gn/moz.build b/third_party/libwebrtc/call/call_interfaces_gn/moz.build -index 4f07c8b..f9aa9e3 100644 +index 4f07c8b7..f9aa9e3 100644 --- a/third_party/libwebrtc/call/call_interfaces_gn/moz.build +++ b/third_party/libwebrtc/call/call_interfaces_gn/moz.build @@ -84,7 +84,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -158662,7 +158662,7 @@ index 5c1f19a..89009b7 100644 Library("rtp_receiver_gn") diff --git a/third_party/libwebrtc/call/rtp_sender_gn/moz.build b/third_party/libwebrtc/call/rtp_sender_gn/moz.build -index 1d14b03..0ad5b6d 100644 +index 1d14b03..0ad5b6d1 100644 --- a/third_party/libwebrtc/call/rtp_sender_gn/moz.build +++ b/third_party/libwebrtc/call/rtp_sender_gn/moz.build @@ -81,7 +81,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -159019,7 +159019,7 @@ index 926361a..12f7e80 100644 Library("video_stream_api_gn") diff --git a/third_party/libwebrtc/common_audio/common_audio_c_arm_asm_gn/moz.build b/third_party/libwebrtc/common_audio/common_audio_c_arm_asm_gn/moz.build -index 7adcbbf..01a3edc 100644 +index 7adcbbf3..01a3edc 100644 --- a/third_party/libwebrtc/common_audio/common_audio_c_arm_asm_gn/moz.build +++ b/third_party/libwebrtc/common_audio/common_audio_c_arm_asm_gn/moz.build @@ -70,7 +70,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -159406,7 +159406,7 @@ index e499c12..5c5f4ba 100644 Library("common_audio_gn") diff --git a/third_party/libwebrtc/common_audio/common_audio_neon_c_gn/moz.build b/third_party/libwebrtc/common_audio/common_audio_neon_c_gn/moz.build -index 36ffd6a..3a73dc2 100644 +index 36ffd6ad..3a73dc20 100644 --- a/third_party/libwebrtc/common_audio/common_audio_neon_c_gn/moz.build +++ b/third_party/libwebrtc/common_audio/common_audio_neon_c_gn/moz.build @@ -73,14 +73,12 @@ if CONFIG["OS_TARGET"] == "Darwin": @@ -162143,7 +162143,7 @@ index b389938..4fd2f62 100644 Library("audio_network_adaptor_gn") diff --git a/third_party/libwebrtc/modules/audio_coding/default_neteq_factory_gn/moz.build b/third_party/libwebrtc/modules/audio_coding/default_neteq_factory_gn/moz.build -index df061c6..62c3c16 100644 +index df061c6..62c3c16d 100644 --- a/third_party/libwebrtc/modules/audio_coding/default_neteq_factory_gn/moz.build +++ b/third_party/libwebrtc/modules/audio_coding/default_neteq_factory_gn/moz.build @@ -78,7 +78,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -162323,7 +162323,7 @@ index e0f07f2..8cff22c 100644 Library("g711_c_gn") diff --git a/third_party/libwebrtc/modules/audio_coding/g711_gn/moz.build b/third_party/libwebrtc/modules/audio_coding/g711_gn/moz.build -index 3716ec4..d1088db 100644 +index 3716ec4..d1088dba 100644 --- a/third_party/libwebrtc/modules/audio_coding/g711_gn/moz.build +++ b/third_party/libwebrtc/modules/audio_coding/g711_gn/moz.build @@ -79,7 +79,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -162503,7 +162503,7 @@ index 8910ce7..d5a2030 100644 Library("g722_c_gn") diff --git a/third_party/libwebrtc/modules/audio_coding/g722_gn/moz.build b/third_party/libwebrtc/modules/audio_coding/g722_gn/moz.build -index 71d1053..31dda4e 100644 +index 71d1053..31dda4e6c 100644 --- a/third_party/libwebrtc/modules/audio_coding/g722_gn/moz.build +++ b/third_party/libwebrtc/modules/audio_coding/g722_gn/moz.build @@ -79,7 +79,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -163321,7 +163321,7 @@ index 67f8362..c607ac8 100644 Library("isac_gn") diff --git a/third_party/libwebrtc/modules/audio_coding/isac_neon_gn/moz.build b/third_party/libwebrtc/modules/audio_coding/isac_neon_gn/moz.build -index 3798420..a8ee826 100644 +index 3798420..a8ee826f 100644 --- a/third_party/libwebrtc/modules/audio_coding/isac_neon_gn/moz.build +++ b/third_party/libwebrtc/modules/audio_coding/isac_neon_gn/moz.build @@ -14,12 +14,7 @@ COMPILE_FLAGS["OS_INCLUDES"] = [] @@ -164491,7 +164491,7 @@ index 8e1e8c6..99fe511 100644 Library("audio_device_buffer_gn") diff --git a/third_party/libwebrtc/modules/audio_device/audio_device_default_gn/moz.build b/third_party/libwebrtc/modules/audio_device/audio_device_default_gn/moz.build -index a079f00..c949f26 100644 +index a079f00..c949f260 100644 --- a/third_party/libwebrtc/modules/audio_device/audio_device_default_gn/moz.build +++ b/third_party/libwebrtc/modules/audio_device/audio_device_default_gn/moz.build @@ -74,7 +74,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -165112,7 +165112,7 @@ index b1898d5..950331d 100644 Library("adaptive_fir_filter_erl_gn") diff --git a/third_party/libwebrtc/modules/audio_processing/aec3/adaptive_fir_filter_gn/moz.build b/third_party/libwebrtc/modules/audio_processing/aec3/adaptive_fir_filter_gn/moz.build -index 249c41b..793a944 100644 +index 249c41b..793a944d 100644 --- a/third_party/libwebrtc/modules/audio_processing/aec3/adaptive_fir_filter_gn/moz.build +++ b/third_party/libwebrtc/modules/audio_processing/aec3/adaptive_fir_filter_gn/moz.build @@ -74,7 +74,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -165637,7 +165637,7 @@ index 33c5ef2..03f2b1d 100644 Library("matched_filter_gn") diff --git a/third_party/libwebrtc/modules/audio_processing/aec3/render_buffer_gn/moz.build b/third_party/libwebrtc/modules/audio_processing/aec3/render_buffer_gn/moz.build -index a2685d2..7a83f11 100644 +index a2685d26..7a83f11 100644 --- a/third_party/libwebrtc/modules/audio_processing/aec3/render_buffer_gn/moz.build +++ b/third_party/libwebrtc/modules/audio_processing/aec3/render_buffer_gn/moz.build @@ -74,7 +74,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -171310,7 +171310,7 @@ index 60e216f..875ba0f 100644 Library("fft_gn") diff --git a/third_party/libwebrtc/modules/third_party/g711/g711_3p_gn/moz.build b/third_party/libwebrtc/modules/third_party/g711/g711_3p_gn/moz.build -index 4004c61..67610e7 100644 +index 4004c613..67610e7 100644 --- a/third_party/libwebrtc/modules/third_party/g711/g711_3p_gn/moz.build +++ b/third_party/libwebrtc/modules/third_party/g711/g711_3p_gn/moz.build @@ -74,7 +74,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -173291,7 +173291,7 @@ index 4b0b804..90c9ddb 100644 Library("webrtc_vp9_helpers_gn") diff --git a/third_party/libwebrtc/modules/video_processing/denoiser_filter_gn/moz.build b/third_party/libwebrtc/modules/video_processing/denoiser_filter_gn/moz.build -index 7407051..d31e40d 100644 +index 7407051e..d31e40d 100644 --- a/third_party/libwebrtc/modules/video_processing/denoiser_filter_gn/moz.build +++ b/third_party/libwebrtc/modules/video_processing/denoiser_filter_gn/moz.build @@ -70,7 +70,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -173598,7 +173598,7 @@ index 1131355..01086f1 100644 "/third_party/libwebrtc/modules/desktop_capture/desktop_capture_differ_sse2_gn", "/third_party/libwebrtc/modules/video_processing/video_processing_sse2_gn" diff --git a/third_party/libwebrtc/rtc_base/atomicops_gn/moz.build b/third_party/libwebrtc/rtc_base/atomicops_gn/moz.build -index e81ee45..970aa26 100644 +index e81ee452..970aa26 100644 --- a/third_party/libwebrtc/rtc_base/atomicops_gn/moz.build +++ b/third_party/libwebrtc/rtc_base/atomicops_gn/moz.build @@ -70,7 +70,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -173685,7 +173685,7 @@ index e81ee45..970aa26 100644 Library("atomicops_gn") diff --git a/third_party/libwebrtc/rtc_base/audio_format_to_string_gn/moz.build b/third_party/libwebrtc/rtc_base/audio_format_to_string_gn/moz.build -index 1562c0c..460d0d5 100644 +index 1562c0c1..460d0d5 100644 --- a/third_party/libwebrtc/rtc_base/audio_format_to_string_gn/moz.build +++ b/third_party/libwebrtc/rtc_base/audio_format_to_string_gn/moz.build @@ -78,7 +78,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -177429,7 +177429,7 @@ index 5f14995..81e19e5 100644 Library("rw_lock_wrapper_gn") diff --git a/third_party/libwebrtc/rtc_base/synchronization/sequence_checker_gn/moz.build b/third_party/libwebrtc/rtc_base/synchronization/sequence_checker_gn/moz.build -index 5ec0cff..40a1809 100644 +index 5ec0cff6..40a1809 100644 --- a/third_party/libwebrtc/rtc_base/synchronization/sequence_checker_gn/moz.build +++ b/third_party/libwebrtc/rtc_base/synchronization/sequence_checker_gn/moz.build @@ -78,7 +78,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -178905,7 +178905,7 @@ index a3c1b2d..fbbd5da 100644 Library("sigslot_gn") diff --git a/third_party/libwebrtc/rtc_base/thread_checker_gn/moz.build b/third_party/libwebrtc/rtc_base/thread_checker_gn/moz.build -index eb1c598..cbe6e31 100644 +index eb1c598..cbe6e316 100644 --- a/third_party/libwebrtc/rtc_base/thread_checker_gn/moz.build +++ b/third_party/libwebrtc/rtc_base/thread_checker_gn/moz.build @@ -74,7 +74,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -179346,7 +179346,7 @@ index 5d22a05..45e5410 100644 Library("unit_base_gn") diff --git a/third_party/libwebrtc/rtc_base/weak_ptr_gn/moz.build b/third_party/libwebrtc/rtc_base/weak_ptr_gn/moz.build -index a9a520b..b1e60d9 100644 +index a9a520b..b1e60d90 100644 --- a/third_party/libwebrtc/rtc_base/weak_ptr_gn/moz.build +++ b/third_party/libwebrtc/rtc_base/weak_ptr_gn/moz.build @@ -78,7 +78,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -180418,7 +180418,7 @@ index fa970ef..ecf69a0 100644 Library("flat_hash_map_gn") diff --git a/third_party/libwebrtc/third_party/abseil-cpp/absl/container/inlined_vector_gn/moz.build b/third_party/libwebrtc/third_party/abseil-cpp/absl/container/inlined_vector_gn/moz.build -index a75033f..7a353bc 100644 +index a75033fa..7a353bc 100644 --- a/third_party/libwebrtc/third_party/abseil-cpp/absl/container/inlined_vector_gn/moz.build +++ b/third_party/libwebrtc/third_party/abseil-cpp/absl/container/inlined_vector_gn/moz.build @@ -53,7 +53,6 @@ if CONFIG["OS_TARGET"] == "Linux": @@ -181105,7 +181105,7 @@ index 41cd799..c97aec9 100644 Library("span_gn") diff --git a/third_party/libwebrtc/third_party/abseil-cpp/absl/types/variant_gn/moz.build b/third_party/libwebrtc/third_party/abseil-cpp/absl/types/variant_gn/moz.build -index bb22317..879e032 100644 +index bb22317..879e032f 100644 --- a/third_party/libwebrtc/third_party/abseil-cpp/absl/types/variant_gn/moz.build +++ b/third_party/libwebrtc/third_party/abseil-cpp/absl/types/variant_gn/moz.build @@ -53,7 +53,6 @@ if CONFIG["OS_TARGET"] == "Linux": diff --git a/librewolf/debian/patches/fixes/Bug-1756347-part-1-Work-around-a-GCC-issue-with-gene.patch b/librewolf/debian/patches/fixes/Bug-1756347-part-1-Work-around-a-GCC-issue-with-gene.patch deleted file mode 100644 index 52daa27..0000000 --- a/librewolf/debian/patches/fixes/Bug-1756347-part-1-Work-around-a-GCC-issue-with-gene.patch +++ /dev/null @@ -1,235 +0,0 @@ -From: Jan de Mooij -Date: Mon, 28 Feb 2022 14:50:25 +0000 -Subject: Bug 1756347 part 1 - Work around a GCC issue with generated atomics. - r=lth - -Use MOZ_NEVER_INLINE for GCC x86-32. It seems to run out of byte registers when -inlining these functions. - -Differential Revision: https://phabricator.services.mozilla.com/D139703 ---- - js/src/jit/GenerateAtomicOperations.py | 52 +++++++++++++++----------- - 1 file changed, 30 insertions(+), 22 deletions(-) - -diff --git a/js/src/jit/GenerateAtomicOperations.py b/js/src/jit/GenerateAtomicOperations.py -index dbde8d8..08dd562 100644 ---- a/js/src/jit/GenerateAtomicOperations.py -+++ b/js/src/jit/GenerateAtomicOperations.py -@@ -10,6 +10,7 @@ import buildconfig - - is_64bit = "JS_64BIT" in buildconfig.defines - cpu_arch = buildconfig.substs["CPU_ARCH"] -+is_gcc = buildconfig.substs["CC_TYPE"] == "gcc" - - - def fmt_insn(s): -@@ -19,21 +20,21 @@ def fmt_insn(s): - def gen_seqcst(fun_name): - if cpu_arch in ("x86", "x86_64"): - return r""" -- inline void %(fun_name)s() { -+ INLINE_ATTR void %(fun_name)s() { - asm volatile ("mfence\n\t" ::: "memory"); - }""" % { - "fun_name": fun_name, - } - if cpu_arch == "aarch64": - return r""" -- inline void %(fun_name)s() { -+ INLINE_ATTR void %(fun_name)s() { - asm volatile ("dmb ish\n\t" ::: "memory"); - }""" % { - "fun_name": fun_name, - } - if cpu_arch == "arm": - return r""" -- inline void %(fun_name)s() { -+ INLINE_ATTR void %(fun_name)s() { - asm volatile ("dmb sy\n\t" ::: "memory"); - }""" % { - "fun_name": fun_name, -@@ -63,7 +64,7 @@ def gen_load(fun_name, cpp_type, size, barrier): - if barrier: - insns += fmt_insn("mfence") - return """ -- inline %(cpp_type)s %(fun_name)s(const %(cpp_type)s* arg) { -+ INLINE_ATTR %(cpp_type)s %(fun_name)s(const %(cpp_type)s* arg) { - %(cpp_type)s res; - asm volatile (%(insns)s - : [res] "=r" (res) -@@ -91,7 +92,7 @@ def gen_load(fun_name, cpp_type, size, barrier): - if barrier: - insns += fmt_insn("dmb ish") - return """ -- inline %(cpp_type)s %(fun_name)s(const %(cpp_type)s* arg) { -+ INLINE_ATTR %(cpp_type)s %(fun_name)s(const %(cpp_type)s* arg) { - %(cpp_type)s res; - asm volatile (%(insns)s - : [res] "=r" (res) -@@ -117,7 +118,7 @@ def gen_load(fun_name, cpp_type, size, barrier): - if barrier: - insns += fmt_insn("dmb sy") - return """ -- inline %(cpp_type)s %(fun_name)s(const %(cpp_type)s* arg) { -+ INLINE_ATTR %(cpp_type)s %(fun_name)s(const %(cpp_type)s* arg) { - %(cpp_type)s res; - asm volatile (%(insns)s - : [res] "=r" (res) -@@ -154,7 +155,7 @@ def gen_store(fun_name, cpp_type, size, barrier): - if barrier: - insns += fmt_insn("mfence") - return """ -- inline void %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { -+ INLINE_ATTR void %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { - asm volatile (%(insns)s - : - : [addr] "r" (addr), [val] "r"(val) -@@ -180,7 +181,7 @@ def gen_store(fun_name, cpp_type, size, barrier): - if barrier: - insns += fmt_insn("dmb ish") - return """ -- inline void %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { -+ INLINE_ATTR void %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { - asm volatile (%(insns)s - : - : [addr] "r" (addr), [val] "r"(val) -@@ -204,7 +205,7 @@ def gen_store(fun_name, cpp_type, size, barrier): - if barrier: - insns += fmt_insn("dmb sy") - return """ -- inline void %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { -+ INLINE_ATTR void %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { - asm volatile (%(insns)s - : - : [addr] "r" (addr), [val] "r"(val) -@@ -235,7 +236,7 @@ def gen_exchange(fun_name, cpp_type, size): - assert size == 64 - insns += fmt_insn("xchgq %[val], (%[addr])") - return """ -- inline %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { -+ INLINE_ATTR %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { - asm volatile (%(insns)s - : [val] "+r" (val) - : [addr] "r" (addr) -@@ -266,7 +267,7 @@ def gen_exchange(fun_name, cpp_type, size): - insns += fmt_insn("cbnz %w[scratch], 0b") - insns += fmt_insn("dmb ish") - return """ -- inline %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { -+ INLINE_ATTR %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { - %(cpp_type)s res; - uint32_t scratch; - asm volatile (%(insns)s -@@ -297,7 +298,7 @@ def gen_exchange(fun_name, cpp_type, size): - insns += fmt_insn("beq 0b") - insns += fmt_insn("dmb sy") - return """ -- inline %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { -+ INLINE_ATTR %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { - %(cpp_type)s res; - uint32_t scratch; - asm volatile (%(insns)s -@@ -321,7 +322,7 @@ def gen_cmpxchg(fun_name, cpp_type, size): - # Use a +A constraint to load `oldval` into EDX:EAX as input/output. - # `newval` is loaded into ECX:EBX. - return r""" -- inline %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, -+ INLINE_ATTR %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, - %(cpp_type)s oldval, - %(cpp_type)s newval) { - asm volatile ("lock; cmpxchg8b (%%[addr])\n\t" -@@ -337,7 +338,7 @@ def gen_cmpxchg(fun_name, cpp_type, size): - } - if cpu_arch == "arm" and size == 64: - return r""" -- inline %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, -+ INLINE_ATTR %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, - %(cpp_type)s oldval, - %(cpp_type)s newval) { - uint32_t oldval0 = oldval & 0xffff'ffff; -@@ -380,7 +381,7 @@ def gen_cmpxchg(fun_name, cpp_type, size): - assert size == 64 - insns += fmt_insn("lock; cmpxchgq %[newval], (%[addr])") - return """ -- inline %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, -+ INLINE_ATTR %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, - %(cpp_type)s oldval, - %(cpp_type)s newval) { - asm volatile (%(insns)s -@@ -425,7 +426,7 @@ def gen_cmpxchg(fun_name, cpp_type, size): - insns += fmt_insn("cbnz %w[scratch], 0b") - insns += fmt_insn("1: dmb ish") - return """ -- inline %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, -+ INLINE_ATTR %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, - %(cpp_type)s oldval, - %(cpp_type)s newval) { - %(cpp_type)s res, scratch; -@@ -466,7 +467,7 @@ def gen_cmpxchg(fun_name, cpp_type, size): - insns += fmt_insn("beq 0b") - insns += fmt_insn("1: dmb sy") - return """ -- inline %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, -+ INLINE_ATTR %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, - %(cpp_type)s oldval, - %(cpp_type)s newval) { - %(cpp_type)s res, scratch; -@@ -501,7 +502,7 @@ def gen_fetchop(fun_name, cpp_type, size, op): - assert size == 64 - insns += fmt_insn("lock; xaddq %[val], (%[addr])") - return """ -- inline %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { -+ INLINE_ATTR %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { - asm volatile (%(insns)s - : [val] "+&r" (val) - : [addr] "r" (addr) -@@ -539,7 +540,7 @@ def gen_fetchop(fun_name, cpp_type, size, op): - insns = insns.replace("OP", op) - insns += fmt_insn("jnz 0b") - return """ -- inline %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { -+ INLINE_ATTR %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { - %(cpp_type)s res, scratch; - asm volatile (%(insns)s - : [res] "=&a" (res), [scratch] "=&r" (scratch) -@@ -581,7 +582,7 @@ def gen_fetchop(fun_name, cpp_type, size, op): - insns += fmt_insn("cbnz %w[scratch2], 0b") - insns += fmt_insn("dmb ish") - return """ -- inline %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { -+ INLINE_ATTR %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { - %(cpp_type)s res; - uintptr_t scratch1, scratch2; - asm volatile (%(insns)s -@@ -621,7 +622,7 @@ def gen_fetchop(fun_name, cpp_type, size, op): - insns += fmt_insn("beq 0b") - insns += fmt_insn("dmb sy") - return """ -- inline %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { -+ INLINE_ATTR %(cpp_type)s %(fun_name)s(%(cpp_type)s* addr, %(cpp_type)s val) { - %(cpp_type)s res; - uintptr_t scratch1, scratch2; - asm volatile (%(insns)s -@@ -681,7 +682,7 @@ def gen_copy(fun_name, cpp_type, size, unroll, direction): - offset -= 1 - - return """ -- inline void %(fun_name)s(uint8_t* dst, const uint8_t* src) { -+ INLINE_ATTR void %(fun_name)s(uint8_t* dst, const uint8_t* src) { - %(cpp_type)s* dst_ = reinterpret_cast<%(cpp_type)s*>(dst); - const %(cpp_type)s* src_ = reinterpret_cast(src); - %(cpp_type)s scratch; -@@ -853,6 +854,13 @@ def generate_atomics_header(c_out): - "constexpr size_t JS_GENERATED_ATOMICS_WORDSIZE = " + str(wordsize) + ";\n" - ) - -+ # Work around a GCC issue on 32-bit x86 by adding MOZ_NEVER_INLINE. -+ # See bug 1756347. -+ if is_gcc and cpu_arch == "x86": -+ contents = contents.replace("INLINE_ATTR", "MOZ_NEVER_INLINE inline") -+ else: -+ contents = contents.replace("INLINE_ATTR", "inline") -+ - c_out.write( - HEADER_TEMPLATE - % { -- cgit