зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1505608 - Try to ensure the bss section of the elfhack testcase stays large enough. r=froydnj
In bug 1470701, we added a dummy global variable so that it ends up in the bss section, making it large enough for two pointers. Unfortunately, in some cases, the symbol is eliminated by the linker because it is unused. So we try to ensure it stays there. Differential Revision: https://phabricator.services.mozilla.com/D11257 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
3a03e26be5
Коммит
29e5c3b9dd
|
@ -136,8 +136,12 @@ size_t dummy;
|
|||
void end_test() {
|
||||
static size_t count = 0;
|
||||
/* Only exit when both constructors have been called */
|
||||
if (++count == 2)
|
||||
if (++count == 2) {
|
||||
ret = 0;
|
||||
// Avoid the dummy variable being stripped out at link time because
|
||||
// it's unused.
|
||||
dummy = 1;
|
||||
}
|
||||
}
|
||||
|
||||
void test() {
|
||||
|
|
Загрузка…
Ссылка в новой задаче