[MacPorts] #59706: libgcc7 @7.5.0 does not bild on PPC Mac OS X 10.5.8, Leopard, because of internal compiler error

MacPorts noreply at macports.org
Sat Nov 16 16:19:23 UTC 2019


#59706: libgcc7 @7.5.0 does not bild on PPC Mac OS X 10.5.8, Leopard, because of
internal compiler error
-----------------------+---------------------
 Reporter:  ballapete  |      Owner:  (none)
     Type:  defect     |     Status:  new
 Priority:  Normal     |  Milestone:
Component:  ports      |    Version:  2.6.2
 Keywords:  leopard    |       Port:  libgcc7
-----------------------+---------------------
 {{{
 /bin/sh ./libtool --tag=CC   --mode=compile
 /opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/build/./gcc/xgcc
 -B/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/build/./gcc/
 -B/opt/local/ppc-apple-darwin9/bin/ -B/opt/local/ppc-apple-darwin9/lib/
 -isystem /opt/local/ppc-apple-darwin9/include -isystem /opt/local/ppc-
 apple-darwin9/sys-include    -DHAVE_CONFIG_H -I.
 -I/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp
 -I/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp/config/bsd
 -I/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp/config/darwin
 -I/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp/config/posix
 -I/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp
 -I/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp/../include
 -Wall -Werror -Wc,-pthread -g -O2 -pipe -Os -MT target.lo -MD -MP -MF
 .deps/target.Tpo -c -o target.lo
 /opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp/target.c
 libtool: compile:
 /opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/build/./gcc/xgcc
 -B/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/build/./gcc/
 -B/opt/local/ppc-apple-darwin9/bin/ -B/opt/local/ppc-apple-darwin9/lib/
 -isystem /opt/local/ppc-apple-darwin9/include -isystem /opt/local/ppc-
 apple-darwin9/sys-include -DHAVE_CONFIG_H -I.
 -I/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp
 -I/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp/config/bsd
 -I/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp/config/darwin
 -I/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp/config/posix
 -I/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp
 -I/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp/../include
 -Wall -pthread -Werror -g -O2 -pipe -Os -MT target.lo -MD -MP -MF
 .deps/target.Tpo -c
 /opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp/target.c
 -fno-common -DPIC -o .libs/target.o
 /opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp/target.c:
 In function 'gomp_map_lookup':
 /opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/libgomp/target.c:151:1:
 internal compiler error: in maybe_record_trace_start, at dwarf2cfi.c:2330
  }
  ^
 libbacktrace could not find executable to open
 Please submit a full bug report,
 with preprocessed source if appropriate.
 See <https://trac.macports.org/newticket> for instructions.
 {standard input}:616:non-relocatable subtraction expression,
 "_register_lock" minus "L3$pb"
 {standard input}:616:symbol: "_register_lock" can't be undefined in a
 subtraction expression
 {standard input}:615:non-relocatable subtraction expression,
 "_register_lock" minus "L3$pb"
 {standard input}:615:symbol: "_register_lock" can't be undefined in a
 subtraction expression
 {standard input}:423:non-relocatable subtraction expression,
 "_register_lock" minus "L3$pb"
 {standard input}:423:symbol: "_register_lock" can't be undefined in a
 subtraction expression
 {standard input}:422:non-relocatable subtraction expression,
 "_register_lock" minus "L3$pb"
 {standard input}:422:symbol: "_register_lock" can't be undefined in a
 subtraction expression
 {standard input}:223:non-relocatable subtraction expression, "_devices"
 minus "L2$pb"
 {standard input}:223:symbol: "_devices" can't be undefined in a
 subtraction expression
 {standard input}:209:non-relocatable subtraction expression,
 "_num_devices" minus "L2$pb"
 {standard input}:209:symbol: "_num_devices" can't be undefined in a
 subtraction expression
 {standard input}:202:non-relocatable subtraction expression, "_devices"
 minus "L2$pb"
 {standard input}:202:symbol: "_devices" can't be undefined in a
 subtraction expression
 {standard input}:199:non-relocatable subtraction expression,
 "_num_devices" minus "L2$pb"
 {standard input}:199:symbol: "_num_devices" can't be undefined in a
 subtraction expression
 {standard input}:154:non-relocatable subtraction expression, "_devices"
 minus "L1$pb"
 {standard input}:154:symbol: "_devices" can't be undefined in a
 subtraction expression
 {standard input}:136:non-relocatable subtraction expression,
 "_num_devices" minus "L1$pb"
 {standard input}:136:symbol: "_num_devices" can't be undefined in a
 subtraction expression
 {standard input}:132:non-relocatable subtraction expression,
 "_num_devices_openmp" minus "L1$pb"
 {standard input}:132:symbol: "_num_devices_openmp" can't be undefined in a
 subtraction expression
 {standard input}:130:non-relocatable subtraction expression, "_devices"
 minus "L1$pb"
 {standard input}:130:symbol: "_devices" can't be undefined in a
 subtraction expression
 {standard input}:128:non-relocatable subtraction expression,
 "_num_devices_openmp" minus "L1$pb"
 {standard input}:128:symbol: "_num_devices_openmp" can't be undefined in a
 subtraction expression
 {standard input}:123:non-relocatable subtraction expression, "_devices"
 minus "L1$pb"
 {standard input}:123:symbol: "_devices" can't be undefined in a
 subtraction expression
 {standard input}:120:non-relocatable subtraction expression,
 "_num_devices" minus "L1$pb"
 {standard input}:120:symbol: "_num_devices" can't be undefined in a
 subtraction expression
 {standard input}:116:non-relocatable subtraction expression,
 "_num_devices" minus "L1$pb"
 {standard input}:116:symbol: "_num_devices" can't be undefined in a
 subtraction expression
 make[5]: *** [target.lo] Error 1
 make[5]: Leaving directory
 `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/build
 /ppc-apple-darwin9/libgomp'
 make[4]: *** [all-recursive] Error 1
 make[4]: Leaving directory
 `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/build
 /ppc-apple-darwin9/libgomp'
 make[3]: *** [all] Error 2
 make[3]: Leaving directory
 `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/build
 /ppc-apple-darwin9/libgomp'
 make[2]: *** [all-stage1-target-libgomp] Error 2
 make[2]: Leaving directory
 `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/build'
 make[1]: *** [stage1-bubble] Error 2
 make[1]: Leaving directory
 `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/build'
 make: *** [bootstrap-lean] Error 2
 make: Leaving directory
 `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/build'
 Command failed:  cd
 "/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/build"
 && /usr/bin/make -w bootstrap-lean
 }}}

 The function is:

 {{{
   134   static inline splay_tree_key
   135   gomp_map_lookup (splay_tree mem_map, splay_tree_key key)
   136   {
   137     if (key->host_start != key->host_end)
   138       return splay_tree_lookup (mem_map, key);
   139
   140     key->host_end++;
   141     splay_tree_key n = splay_tree_lookup (mem_map, key);
   142     key->host_end--;
   143     if (n)
   144       return n;
   145     key->host_start--;
   146     n = splay_tree_lookup (mem_map, key);
   147     key->host_start++;
   148     if (n)
   149       return n;
   150     return splay_tree_lookup (mem_map, key);
   151   }
 }}}

 The report about a missing executable seems faulty. `dwarf2cfi.c` was
 compiled into `dwarf2cfi.o` which was `ar`chived in `libbackend.a`. The
 source file can be found in
 `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/libgcc7/work/gcc-7.5.0/gcc`,
 or in `../gcc-7.5.0/gcc` relative to `build` directory. `dwarf2cfi.c` has
 around line #2330:

 {{{
  2272   /* If LABEL is the start of a trace, then initialize the state of
 that
  2273      trace from CUR_TRACE and CUR_ROW.  */
  2274
  2275   static void
  2276   maybe_record_trace_start (rtx_insn *start, rtx_insn *origin)
  2277   {
  2278     dw_trace_info *ti;
  2279     HOST_WIDE_INT args_size;
  2280
  2281     ti = get_trace_info (start);
  2282     gcc_assert (ti != NULL);
  2283
  2284     if (dump_file)
  2285       {
  2286         fprintf (dump_file, "   saw edge from trace %u to %u (via %s
 %d)\n",
  2287                  cur_trace->id, ti->id,
  2288                  (origin ? rtx_name[(int) GET_CODE (origin)] :
 "fallthru"),
  2289                  (origin ? INSN_UID (origin) : 0));
  2290       }
  2291
  2292     args_size = cur_trace->end_true_args_size;
  2293     if (ti->beg_row == NULL)
  2294       {
  2295         /* This is the first time we've encountered this trace.
 Propagate
  2296            state across the edge and push the trace onto the work
 list.  */
  2297         ti->beg_row = copy_cfi_row (cur_row);
  2298         ti->beg_true_args_size = args_size;
  2299
  2300         ti->cfa_store = cur_trace->cfa_store;
  2301         ti->cfa_temp = cur_trace->cfa_temp;
  2302         ti->regs_saved_in_regs = cur_trace->regs_saved_in_regs.copy
 ();
  2303
  2304         trace_work_list.safe_push (ti);
  2305
  2306         if (dump_file)
  2307           fprintf (dump_file, "\tpush trace %u to worklist\n",
 ti->id);
  2308       }
  2309     else
  2310       {
  2311
  2312         /* We ought to have the same state incoming to a given trace
 no
  2313            matter how we arrive at the trace.  Anything else means
 we've
  2314            got some kind of optimization error.  */
  2315   #if CHECKING_P
  2316         if (!cfi_row_equal_p (cur_row, ti->beg_row))
  2317           {
  2318             if (dump_file)
  2319               {
  2320                 fprintf (dump_file, "Inconsistent CFI state!\n");
  2321                 fprintf (dump_file, "SHOULD have:\n");
  2322                 dump_cfi_row (dump_file, ti->beg_row);
  2323                 fprintf (dump_file, "DO have:\n");
  2324                 dump_cfi_row (dump_file, cur_row);
  2325               }
  2326
  2327             gcc_unreachable ();
  2328           }
  2329   #endif
  2330
  2331         /* The args_size is allowed to conflict if it isn't actually
 used.  */
  2332         if (ti->beg_true_args_size != args_size)
  2333           ti->args_size_undefined = true;
  2334       }
  2335   }
 }}}

 The function `gcc_unreachable ()` is `#define`'d in
 `../gcc-7.5.0/gcc/system.h`:

 {{{
   747   /* Use gcc_unreachable() to mark unreachable locations (like an
   748      unreachable default case of a switch.  Do not use
 gcc_assert(0).  */
   749   #if (GCC_VERSION >= 4005) && !ENABLE_ASSERT_CHECKING
   750   #define gcc_unreachable() __builtin_unreachable ()
   751   #else
   752   #define gcc_unreachable() (fancy_abort (__FILE__, __LINE__,
 __FUNCTION__))
   753   #endif
 }}}

-- 
Ticket URL: <https://trac.macports.org/ticket/59706>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list