Bug 1789779 - Work around miscompilation on cross-LTO. r=emilio

Starting from
6c8adc5054,
Servo_NoteExplicitHints can end up inlined in its callers via
cross-language LTO, which didn't happen before. This yields a
miscompilation in the caller, causing crashes. Until the miscompilation
is fixed, avoid the inlining.

Differential Revision: https://phabricator.services.mozilla.com/D157423
This commit is contained in:
Mike Hommey 2022-09-15 20:55:30 +00:00
Родитель d8b071ca4d
Коммит 8ce6f0503e
1 изменённых файлов: 3 добавлений и 0 удалений

Просмотреть файл

@ -5721,6 +5721,9 @@ pub extern "C" fn Servo_CSSSupports(
}
#[no_mangle]
// Work around miscompilation when cross-LTO somehow inlines this function.
// (bug 1789779)
#[inline(never)]
pub unsafe extern "C" fn Servo_NoteExplicitHints(
element: &RawGeckoElement,
restyle_hint: RestyleHint,