From: David Edelsohn Date: Thu, 15 Aug 2002 14:51:00 +0000 (+0000) Subject: rs6000.c (output_mi_thunk): Return to function section on TARGET_ELF. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=b4d330e1630264a6ced3d637344ee1a708527799;p=gcc.git rs6000.c (output_mi_thunk): Return to function section on TARGET_ELF. * rs6000.c (output_mi_thunk): Return to function section on TARGET_ELF. * rs6000-c.c (rs6000_cpu_cpp_builtins): Define __PPC405__ if PPC405. From-SVN: r56348 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 71ae78dae20..ca3ebb23c75 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2002-08-15 David Edelsohn + + * rs6000.c (output_mi_thunk): Return to function section on + TARGET_ELF. + + * rs6000-c.c (rs6000_cpu_cpp_builtins): Define __PPC405__ if PPC405. + 2002-08-15 Ulrich Weigand * config/s390/s390.c (legitimize_address): Optimize loading diff --git a/gcc/config/rs6000/rs6000-c.c b/gcc/config/rs6000/rs6000-c.c index 14132ca68ad..6093996a132 100644 --- a/gcc/config/rs6000/rs6000-c.c +++ b/gcc/config/rs6000/rs6000-c.c @@ -97,6 +97,9 @@ rs6000_cpu_cpp_builtins (pfile) builtin_define ("__SPE__"); if (TARGET_SOFT_FLOAT) builtin_define ("_SOFT_FLOAT"); + /* Used by lwarx/stwcx. errata work-around. */ + if (rs6000_cpu == PROCESSOR_PPC405) + builtin_define ("__PPC405__"); if (BYTES_BIG_ENDIAN) { builtin_define ("__BIG_ENDIAN__"); @@ -127,5 +130,7 @@ rs6000_cpu_cpp_builtins (pfile) case ABI_DARWIN: builtin_define ("_CALL_DARWIN"); break; + default: + break; } } diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index 81df7c396bc..5b69dd58a19 100644 --- a/gcc/config/rs6000/rs6000.c +++ b/gcc/config/rs6000/rs6000.c @@ -11335,7 +11335,10 @@ output_mi_thunk (file, thunk_fndecl, delta, function) } assemble_name (file, fname); putc ('\n', file); - text_section (); + if (TARGET_ELF) + function_section (current_function_decl); + else + text_section(); if (TARGET_MINIMAL_TOC) asm_fprintf (file, (TARGET_32BIT) ? "\t{l|lwz} %s,%s(%s)\n" : "\tld %s,%s(%s)\n", r12,