Hi, Rewrite the declaration of toc_section from the source file rs6000.c to its header file for standardizing the code.
Bootstrap and regression were done on powerpc64le-linux-gnu (LE) with no regressions. Is it OK for trunk? Thanks, Bin Bin Lv gcc/ChangeLog 2020-03-03 Bin Bin Lv <s...@linux.ibm.com> * config/rs6000/rs6000.c (toc_section): Remove its declaration. * config/rs6000/rs6000.h (toc_section): Add its declaration. --- gcc/config/rs6000/rs6000.c | 1 - gcc/config/rs6000/rs6000.h | 1 + 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index 0faf44b..c0a6e86 100644 --- a/gcc/config/rs6000/rs6000.c +++ b/gcc/config/rs6000/rs6000.c @@ -181,7 +181,6 @@ static GTY(()) section *tls_private_data_section; static GTY(()) section *read_only_private_data_section; static GTY(()) section *sdata2_section; -extern GTY(()) section *toc_section; section *toc_section = 0; /* Describe the vector unit used for modes. */ diff --git a/gcc/config/rs6000/rs6000.h b/gcc/config/rs6000/rs6000.h index 3844bec..e77a84a 100644 --- a/gcc/config/rs6000/rs6000.h +++ b/gcc/config/rs6000/rs6000.h @@ -2494,6 +2494,7 @@ extern GTY(()) tree rs6000_builtin_types[RS6000_BTI_MAX]; extern GTY(()) tree rs6000_builtin_decls[RS6000_BUILTIN_COUNT]; extern GTY(()) tree builtin_mode_to_type[MAX_MACHINE_MODE][2]; extern GTY(()) tree altivec_builtin_mask_for_load; +extern union GTY(()) section *toc_section; #ifndef USED_FOR_TARGET /* A C structure for machine-specific, per-function data. -- 1.8.3.1