Skip to content

Commit 6514edc

Browse files
authored
Merge pull request #57 from rust-lang/fix/aarch64-builtins
Fix for double initialization of Aarch64 builtins
2 parents a306607 + 44b7998 commit 6514edc

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

gcc/config/aarch64/aarch64.cc

+8
Original file line numberDiff line numberDiff line change
@@ -15484,11 +15484,19 @@ aarch64_insn_cost (rtx_insn *insn, bool speed)
1548415484
static void
1548515485
aarch64_init_builtins ()
1548615486
{
15487+
// TODO: find a better fix than this to avoid the failure:
15488+
// SET_TYPE_VECTOR_SUBPARTS, in tree.h:4258
15489+
static bool builtins_initialized = false;
15490+
if (builtins_initialized)
15491+
return;
15492+
1548715493
aarch64_general_init_builtins ();
1548815494
aarch64_sve::init_builtins ();
1548915495
#ifdef SUBTARGET_INIT_BUILTINS
1549015496
SUBTARGET_INIT_BUILTINS;
1549115497
#endif
15498+
15499+
builtins_initialized = true;
1549215500
}
1549315501

1549415502
/* Implement TARGET_FOLD_BUILTIN. */

0 commit comments

Comments
 (0)