Bug 71009 - g++: ICE on modified gdb/valarith.c with -Ofast
Summary: g++: ICE on modified gdb/valarith.c with -Ofast
Status: RESOLVED INVALID
Alias: None
Product: gcc
Classification: Unclassified
Component: target (show other bugs)
Version: 7.0
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords: ice-on-valid-code
Depends on:
Blocks:
 
Reported: 2016-05-08 15:14 UTC by Eric Gallager
Modified: 2021-03-22 07:57 UTC (History)
5 users (show)

See Also:
Host: i386-apple-darwin9.8.0
Target: i386-apple-darwin9.8.0
Build: i386-apple-darwin9.8.0
Known to work:
Known to fail:
Last reconfirmed: 2017-12-30 00:00:00


Attachments
bzipped preprocessed source (147.80 KB, application/x-bzip2)
2016-05-08 15:19 UTC, Eric Gallager
Details
some compressed compiler output (202.84 KB, application/x-bzip2)
2016-08-09 16:55 UTC, Eric Gallager
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Gallager 2016-05-08 15:14:34 UTC
Full command line and output:

$ make CFLAGS="-g3 -Ofast -force_cpusubtype_ALL -gstrict-dwarf -gdwarf-2 -gfull -save-temps" V=1
this target, 'config.h' just makes its dep, 'stamp-h'
/usr/local/bin/g++ -g3 -Ofast -force_cpusubtype_ALL -gstrict-dwarf -gdwarf-2 -gfull -save-temps -arch i386 -DTARGET_I386 -I./macosx -I./macosx -DWITH_CFM=0 -DUSE_PTHREADS=1 -D_DARWIN_UNLIMITED_STREAMS -mmacosx-version-min=10.5  -I. -I. -I./config -DHAVE_CONFIG_H -DHAVE_SYS_TYPES_H -DLOCALEDIR="\"/usr/local/share/locale\""   -I./../include/opcode -I./../readline/.. -I./../zlib -I../bfd -I./../bfd -I./../include -I./../mmalloc -I../mmalloc -I../intl -I./../intl  -DMI_OUT=1 -I/sw/include/libxml2 -I/sw/include -D__MigTypeCheck=1 -D__DARWIN_UNIX03=1 -Wreturn-type -Wcomment -Wtrigraphs -Wparentheses -Wpointer-arith -Wchar-subscripts -Wno-unused -Wunused-value -Wunused-label -Wunused-result -Wunused-variable -Wunused-but-set-variable -Wunused-function -Wempty-body -Wmissing-declarations -Wignored-qualifiers -Wmissing-format-attribute -Waddress -Wattributes -Wswitch -Wclobbered -Wcoverage-mismatch -Wdiv-by-zero -Wdouble-promotion -Wfree-nonheap-object -Wsign-compare -Wtype-limits -Winvalid-memory-model -Winvalid-pch -Wmain -Wmissing-braces -Wmissing-include-dirs -Woverflow -Woverlength-strings -Wpragmas -Wreturn-local-addr -Wsequence-point -Wsizeof-pointer-memaccess -Wtrampolines -Wunknown-pragmas -Wnormalized=nfkc -Wlogical-op -Wfloat-conversion -Wmissing-field-initializers -Wno-deprecated-declarations -Wbool-compare -Wlogical-not-parentheses -Wsizeof-array-argument -Wswitch-bool -Wshift-count-negative -Wshift-count-overflow -Wshift-negative-value -Wshift-overflow=2 -Wmisleading-indentation -Wlto-type-mismatch -Wtautological-compare -Wduplicated-cond -Wwrite-strings -Wenum-compare -Wnonnull-compare -Wabi -Wabi-tag -Woverloaded-virtual -Wsign-promo -Wodr -Wsubobject-linkage -Wctor-dtor-privacy -Wterminate -Wc++11-compat -Wdelete-incomplete -Wdelete-non-virtual-dtor -Winherited-variadic-ctor -Winvalid-offsetof -Wliteral-suffix -Wnoexcept -Wnon-template-friend -Wnon-virtual-dtor -Wreorder -Wstrict-null-sentinel -Wmultiple-inheritance -Wvirtual-inheritance -Wpmf-conversions -Wtemplates -Wvirtual-move-assign -Wconversion-null -Weffc++ -Wsized-deallocation -Wplacement-new=2 -fpermissive -Wendif-labels -Wformat -Wformat-y2k -Wformat-security -Wnonnull -Wnonportable-cfstrings -Wno-unused-const-variable -std=gnu++03 -pedantic -Wno-long-long -Wcast-align -Wuninitialized -Winit-self -Wmissing-noreturn -Wvolatile-register-var -Wdisabled-optimization -Winline -Waggressive-loop-optimizations -Wvector-operation-performance -Wmaybe-uninitialized -Wstrict-overflow=1 -fno-strict-aliasing -Wnull-dereference -Wframe-address -Wframe-larger-than=262144 -Wlarger-than=262144 -Wsuggest-attribute=const -Warray-bounds  -Wall -Wextra -Wno-unused-parameter  -c -o valarith.o valarith.c
valarith.c: In function ‘value* value_binop(value*, value*, exp_opcode)’:
valarith.c:1408:1: internal compiler error: in gen_reg_rtx, at emit-rtl.c:1025
 }
 ^
libbacktrace could not find executable to open
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.
make: *** [valarith.o] Error 1

The file compiles fine with all the other optimization levels I've tested recently (-O3, -O2, -O1, -Os, -Og, -O0).

g++ version info:

$ /usr/local/bin/g++ -v
Using built-in specs.
COLLECT_GCC=/usr/local/bin/g++
COLLECT_LTO_WRAPPER=/usr/local/libexec/gcc/i386-apple-darwin9.8.0/7.0.0/lto-wrapper
Target: i386-apple-darwin9.8.0
Configured with: ../configure --disable-werror --enable-languages=c,c++,lto,objc,obj-c++ --enable-stage1-checking=release -C --with-system-libunwind --enable-secureplt --enable-frame-pointer --enable-version-specific-runtime-libs --enable-assert --enable-fat --enable-portable-binary --enable-browser-plugin --enable-gconf-peer --enable-libgcj-debug --enable-gc-debug --enable-interpreter --enable-aot-compile-rpm --enable-java-home --with-x --enable-collections --enable-gstreamer-peer --enable-xmlj --enable-qt-peer --enable-debug --enable-local-sockets --without-isl --enable-objc-gc --enable-maintainer-mode --enable-host-shared CC=/usr/local/bin/gcc CXX=/usr/local/bin/g++ AUTOCONF=/usr/local/bin/autoconf AUTOHEADER=/usr/local/bin/autoheader AUTOM4TE=/usr/local/bin/autom4te AUTORECONF=/usr/local/bin/autoreconf AUTOSCAN=/usr/local/bin/autoscan AUTOUPDATE=/usr/local/bin/autoupdate IFNAMES=/usr/local/bin/ifnames
Thread model: posix
gcc version 7.0.0 20160426 (experimental) (GCC)
Comment 1 Eric Gallager 2016-05-08 15:19:12 UTC
Created attachment 38442 [details]
bzipped preprocessed source
Comment 2 Marek Polacek 2016-05-19 14:41:43 UTC
Must be target-specific.
Comment 3 Eric Gallager 2016-06-09 14:55:17 UTC
Still happens with:

$ /usr/local/bin/g++ -v
Using built-in specs.
COLLECT_GCC=/usr/local/bin/g++
COLLECT_LTO_WRAPPER=/usr/local/libexec/gcc/i386-apple-darwin9.8.0/7.0.0/lto-wrapper
Target: i386-apple-darwin9.8.0
Configured with: ../configure --disable-werror --enable-languages=c,c++,lto,objc,obj-c++ --enable-stage1-checking=release -C --with-system-libunwind --enable-secureplt --enable-frame-pointer --enable-debug --without-isl --enable-objc-gc --enable-host-shared CC=/usr/local/bin/gcc CXX=/usr/local/bin/g++
Thread model: posix
gcc version 7.0.0 20160526 (experimental) (GCC) 


This time I attached gdb and got a backtrace:

(gdb) bt
#0  0x00ed6004 in internal_error ()
#1  0x00ed5040 in fancy_abort ()
#2  0x00719077 in gen_reg_rtx ()
#3  0x0048fc28 in gen_split_343 ()
#4  0x00569b62 in split_8 ()
#5  0x00720956 in try_split ()
#6  0x00a6a7be in split_insn ()
#7  0x00a6ec9a in split_all_insns ()
#8  0x00a6ecfb in (anonymous namespace)::pass_split_after_reload::execute ()
#9  0x00a3c567 in execute_one_pass ()
#10 0x00a3cb59 in execute_pass_list_1 ()
#11 0x00a3cb6c in execute_pass_list_1 ()
#12 0x00a3cb6c in execute_pass_list_1 ()
#13 0x00a3cbba in execute_pass_list ()
#14 0x0063b7d9 in cgraph_node::expand ()
#15 0x0063d244 in symbol_table::compile ()
#16 0x0063f74d in symbol_table::finalize_compilation_unit ()
#17 0x00b19b51 in compile_file ()
#18 0x0177f168 in toplev::main ()
#19 0x01780a24 in main ()

I'll have to rebuild gcc for debugging to get further info.
Comment 4 Martin Liška 2016-06-29 11:36:36 UTC
I also can't reproduce the ICE on x86_64-linux-gnu.
Comment 5 Eric Gallager 2016-07-08 03:41:32 UTC
I rebuilt with debugging info and got a better backtrace:

Breakpoint 1, internal_error (gmsgid=0x15ee807 "in %s, at %s:%d") at ../../gcc/diagnostic.c:1337
1337	  va_start (ap, gmsgid);
(gdb) bt
#0  internal_error (gmsgid=0x15ee807 "in %s, at %s:%d") at ../../gcc/diagnostic.c:1337
#1  0x01266866 in fancy_abort (file=0x157ccd5 "../../gcc/emit-rtl.c", line=1025, function=0x190cd98 "gen_reg_rtx") at ../../gcc/diagnostic.c:1405
#2  0x00945479 in gen_reg_rtx (mode=V2DImode) at ../../gcc/emit-rtl.c:1025
#3  0x00579f86 in gen_split_349 (curr_insn=0x325acf0, operands=0x1ff95c0) at ../../gcc/config/i386/sse.md:1129
#4  0x0076bb58 in split_8 (x1=0x3255ce4, insn=0x325acf0) at ../../gcc/config/i386/sse.md:1115
#5  0x00778c75 in split_insns (x1=0x3255ce4, insn=0x325acf0) at ../../gcc/config/i386/sse.md:13387
#6  0x0094b3e4 in try_split (pat=0x3255ce4, trial=0x325acf0, last=1) at ../../gcc/emit-rtl.c:3658
#7  0x00d4a502 in split_insn (insn=0x325acf0) at ../../gcc/recog.c:2887
#8  0x00d4a7c5 in split_all_insns () at ../../gcc/recog.c:2977
#9  0x00d4c34b in rest_of_handle_split_after_reload () at ../../gcc/recog.c:3913
#10 0x00d4c389 in (anonymous namespace)::pass_split_after_reload::execute (this=0x50d0e190) at ../../gcc/recog.c:3942
#11 0x00d12144 in execute_one_pass (pass=0x50d0e190) at ../../gcc/passes.c:2344
#12 0x00d12495 in execute_pass_list_1 (pass=0x50d0e190) at ../../gcc/passes.c:2428
#13 0x00d124c5 in execute_pass_list_1 (pass=0x50d0e0d0) at ../../gcc/passes.c:2429
#14 0x00d124c5 in execute_pass_list_1 (pass=0x50d0d590) at ../../gcc/passes.c:2429
#15 0x00d12515 in execute_pass_list (fn=0x2b35bb8, pass=0x50d0b190) at ../../gcc/passes.c:2439
#16 0x008539ee in cgraph_node::expand (this=0x2d4b424) at ../../gcc/cgraphunit.c:1983
#17 0x00853fff in expand_all_functions () at ../../gcc/cgraphunit.c:2119
#18 0x00854c8b in symbol_table::compile (this=0x50e0b000) at ../../gcc/cgraphunit.c:2475
#19 0x00854ed1 in symbol_table::finalize_compilation_unit (this=0x50e0b000) at ../../gcc/cgraphunit.c:2565
#20 0x00e246cd in compile_file () at ../../gcc/toplev.c:490
#21 0x00e26f70 in do_compile () at ../../gcc/toplev.c:1998
#22 0x00e27332 in toplev::main (this=0xbfff94de, argc=140, argv=0xbfff9510) at ../../gcc/toplev.c:2132
#23 0x0124f80f in main (argc=140, argv=0xbfff9510) at ../../gcc/main.c:39
Current language:  auto; currently c++
(gdb) bt full
#0  internal_error (gmsgid=0x15ee807 "in %s, at %s:%d") at ../../gcc/diagnostic.c:1337
	ap = 0x0
	richloc = {
  static MAX_RANGES = <optimized out>, 
  static MAX_FIXIT_HINTS = <optimized out>, 
  m_num_ranges = 0, 
  m_ranges = {{
      m_loc = 33527040, 
      m_show_caret_p = 204
    }, {
      m_loc = 0, 
      m_show_caret_p = false
    }, {
      m_loc = 0, 
      m_show_caret_p = true
    }}, 
  m_column_override = 0, 
  m_have_expanded_location = 104, 
  m_expanded_location = {
    file = 0xd47953 "??\020\017????U???\030?x?\001\002??u2?E\b\017?", 
    line = 18, 
    column = 1356874188, 
    data = 0x0, 
    sysp = false
  }, 
  m_num_fixit_hints = 18, 
  m_fixit_hints = {0x50e041cc, 0x0}
}
	__FUNCTION__ = "internal_error"
#1  0x01266866 in fancy_abort (file=0x157ccd5 "../../gcc/emit-rtl.c", line=1025, function=0x190cd98 "gen_reg_rtx") at ../../gcc/diagnostic.c:1405
No locals.
#2  0x00945479 in gen_reg_rtx (mode=V2DImode) at ../../gcc/emit-rtl.c:1025
	val = (rtx) 0xd479ef
	align = 128
	__FUNCTION__ = "gen_reg_rtx"
#3  0x00579f86 in gen_split_349 (curr_insn=0x325acf0, operands=0x1ff95c0) at ../../gcc/config/i386/sse.md:1129
	tmp = (rtx) 0x50e0e430
	_val = (rtx_insn *) 0x0
	__FUNCTION__ = "gen_split_349"
#4  0x0076bb58 in split_8 (x1=0x3255ce4, insn=0x325acf0) at ../../gcc/config/i386/sse.md:1115
	operands = (rtx * const) 0x1ff95c0
	x2 = (rtx) 0x3259dd0
	x3 = (rtx) 0x3259dc0
	x4 = (rtx) 0x32c22f0
	x5 = (rtx) 0x27c6018
	x6 = (rtx) 0x0
	x7 = (rtx) 0x3255ccc
	x8 = (rtx) 0x3254eb0
	x9 = (rtx) 0x32797e0
	x10 = (rtx) 0x0
#5  0x00778c75 in split_insns (x1=0x3255ce4, insn=0x325acf0) at ../../gcc/config/i386/sse.md:13387
	operands = (rtx * const) 0x1ff95c0
	x2 = (rtx) 0xbfff91d8
	x3 = (rtx) 0xbfff922b
	x4 = (rtx) 0x2d4b424
	x5 = (rtx) 0x3251a28
	x6 = (rtx) 0xbfff91c8
	x7 = (rtx) 0x27c0cdc
	x8 = (rtx) 0x325acf0
	x9 = (rtx) 0xc07a4e
	x10 = (rtx) 0xbfff91c8
	x11 = (rtx) 0x0
	x12 = (rtx) 0x3251a28
	x13 = (rtx) 0x95215c
	x14 = (rtx) 0xbfff91b8
	x15 = (rtx) 0x27c0cdc
	x16 = (rtx) 0x325ad14
	x17 = (rtx) 0x9521eb
#6  0x0094b3e4 in try_split (pat=0x3255ce4, trial=0x325acf0, last=1) at ../../gcc/emit-rtl.c:3658
	before = (rtx_insn *) 0x325aca8
	after = (rtx_insn *) 0x325ad14
	note = (rtx) 0x325aca8
	seq = (rtx_insn *) 0x0
	tem = (rtx_insn *) 0xbfff9248
	probability = -1
	insn_last = (rtx_insn *) 0x0
	insn = (rtx_insn *) 0x0
	njumps = 0
	call_insn = (rtx_insn *) 0x0
	__FUNCTION__ = "try_split"
#7  0x00d4a502 in split_insn (insn=0x325acf0) at ../../gcc/recog.c:2887
	first = (rtx_insn *) 0x325aca8
	last = (rtx_insn *) 0x3254eb0
	insn_set = (rtx) 0x3255ce4
	last_set = (rtx) 0x325acf0
	note = (rtx) 0x796dc3
#8  0x00d4a7c5 in split_all_insns () at ../../gcc/recog.c:2977
	set = (rtx) 0x3259dd0
	insn = (rtx_insn *) 0x325acf0
	next = (rtx_insn *) 0x325ad14
	finish = false
	blocks = (sbitmap) 0x3012620
	changed = true
	bb = (basic_block) 0x2dc79c0
#9  0x00d4c34b in rest_of_handle_split_after_reload () at ../../gcc/recog.c:3913
No locals.
#10 0x00d4c389 in (anonymous namespace)::pass_split_after_reload::execute (this=0x50d0e190) at ../../gcc/recog.c:3942
No locals.
#11 0x00d12144 in execute_one_pass (pass=0x50d0e190) at ../../gcc/passes.c:2344
	todo_after = 0
	gate_status = true
	__FUNCTION__ = "execute_one_pass"
#12 0x00d12495 in execute_pass_list_1 (pass=0x50d0e190) at ../../gcc/passes.c:2428
	__FUNCTION__ = "execute_pass_list_1"
#13 0x00d124c5 in execute_pass_list_1 (pass=0x50d0e0d0) at ../../gcc/passes.c:2429
	__FUNCTION__ = "execute_pass_list_1"
#14 0x00d124c5 in execute_pass_list_1 (pass=0x50d0d590) at ../../gcc/passes.c:2429
	__FUNCTION__ = "execute_pass_list_1"
#15 0x00d12515 in execute_pass_list (fn=0x2b35bb8, pass=0x50d0b190) at ../../gcc/passes.c:2439
	__FUNCTION__ = "execute_pass_list"
#16 0x008539ee in cgraph_node::expand (this=0x2d4b424) at ../../gcc/cgraphunit.c:1983
	saved_loc = 217398336
	__FUNCTION__ = "expand"
#17 0x00853fff in expand_all_functions () at ../../gcc/cgraphunit.c:2119
	node = (cgraph_node *) 0x2d4b424
	order = (cgraph_node **) 0x50dd81c0
	expanded_func_count = 9
	profiled_func_count = 0
	order_pos = 84
	new_order_pos = 20
	i = 11
	__FUNCTION__ = "expand_all_functions"
#18 0x00854c8b in symbol_table::compile (this=0x50e0b000) at ../../gcc/cgraphunit.c:2475
	node = (symtab_node *) 0x0
	__FUNCTION__ = "compile"
#19 0x00854ed1 in symbol_table::finalize_compilation_unit (this=0x50e0b000) at ../../gcc/cgraphunit.c:2565
	cnode = (cgraph_node *) 0x0
#20 0x00e246cd in compile_file () at ../../gcc/toplev.c:490
	pkg_version = 0xe26f68 "??\020?????\r??\fj\002蘳????\020??\fj\n???????\020\017?\005G\033?\001\017????\fP??????\020??\fj\n?h?????\020???U???\004?E\020?E??}\f"
	ident_str = 0xbfff94a8 "????2s?"
#21 0x00e26f70 in do_compile () at ../../gcc/toplev.c:1998
	i = 1
#22 0x00e27332 in toplev::main (this=0xbfff94de, argc=140, argv=0xbfff9510) at ../../gcc/toplev.c:2132
No locals.
#23 0x0124f80f in main (argc=140, argv=0xbfff9510) at ../../gcc/main.c:39
	toplev = {
  m_use_TV_TOTAL = true, 
  m_init_signals = true
}
(gdb) call debug_rtx((rtx)0xd479ef)
(??? bad code 50307
)


Let me know if there's any other debugging commands I should try.

Latest version info:
$ ./xg++ -v
Using built-in specs.
COLLECT_GCC=./xg++
Target: i386-apple-darwin9.8.0
Configured with: ../configure --enable-languages=c,objc,c++,obj-c++ CC=/usr/local/bin/gcc CXX=/usr/local/bin/g++ OBJC=/usr/local/bin/gcc OBJCXX=/usr/local/bin/g++
Thread model: posix
gcc version 7.0.0 20160627 (experimental) (GCC)
Comment 6 Eric Gallager 2016-07-11 17:55:21 UTC
I investigated more. What's happening at ../../gcc/emit-rtl.c:1025 is that the following assert is failing:

  gcc_assert (can_create_pseudo_p ());

This fails if and only if gen_reg_rtx is passed V2DImode as its mode parameter. I tried editing emit-rtl.c to make the assert conditional, like this:

  if (mode != V2DImode)
    gcc_assert (can_create_pseudo_p ());

...but that only resulted in a different error:

valarith.c: In function ‘value* value_binop(value*, value*, exp_opcode)’:
valarith.c:1408:1: error: insn does not satisfy its constraints:
(insn 3157 1585 3158 192 (set (reg:V2DI 1029)
        (vec_concat:V2DI (mem/c:DI (reg/f:SI 7 sp) [50 %sfp+-64 S8 A128])
            (const_int 0 [0]))) valarith.c:1180 3653 {vec_concatv2di}
     (nil))

Breakpoint 1, internal_error (gmsgid=0x15ee807 "in %s, at %s:%d") at ../../gcc/diagnostic.c:1337
1337	  va_start (ap, gmsgid);

Any ideas what's going on?
Comment 7 Eric Gallager 2016-08-09 16:55:04 UTC
Created attachment 39089 [details]
some compressed compiler output

Still happens with trunk from the end of July. I tried playing around with some of the developer options to generate some dumpfiles, but there's too many of them, and when I group them into folders, the archives are too big to upload even after compressing them, so I'm not really sure what to upload, besides the attached tempfiles.

Current version info:
$ /usr/local/bin/g++ -march=native -v
Using built-in specs.
COLLECT_GCC=/usr/local/bin/g++
COLLECT_LTO_WRAPPER=/usr/local/libexec/gcc/i386-apple-darwin9.8.0/7.0.0/lto-wrapper
Target: i386-apple-darwin9.8.0
Configured with: ../configure --disable-werror --enable-languages=c,c++,lto,objc,obj-c++ --enable-stage1-checking=release -C --with-system-libunwind --enable-secureplt --enable-frame-pointer --enable-debug --with-isl --enable-objc-gc --enable-host-shared CC=/usr/local/bin/gcc CXX=/usr/local/bin/g++
Thread model: posix
gcc version 7.0.0 20160730 (experimental) (GCC)
Comment 8 Eric Gallager 2016-09-17 20:17:55 UTC
I reduced the command line required to trigger the ICE. It depends on whether -fmath-errno is set or not. With:

$ /usr/local/bin/gcc -c -Ofast -I. -I../include -DHAVE_CONFIG_H -I../bfd -Imacosx -Iconfig -Wno-deprecated-declarations -fno-math-errno valarith.c

...it ICEs as it did previously, but with:

$ /usr/local/bin/gcc -c -Ofast -I. -I../include -DHAVE_CONFIG_H -I../bfd -Imacosx -Iconfig -Wno-deprecated-declarations -fmath-errno valarith.c

...it compiles successfully. That could explain why it wouldn't reproduce on x86_64-linux-gnu, as I believe the default for -fmath-errno is different between Darwin and GNU/Linux.
Comment 9 Ryan Schmidt 2017-12-26 03:05:17 UTC
I am also encountering this problem on i386-apple-darwin9.8.0 when compiling texlive-bin 20170604 with gcc 6.4.0, though in my case it's -Os not -Ofast:

libtool: compile:  /opt/local/bin/gcc-mp-6 -DHAVE_CONFIG_H -I. -I./LuaJIT-src/src -DLUAJIT_ENABLE_LUA52COMPAT -DLUAI_HASHLIMIT=6 -U_FORTIFY_SOURCE -isystem/opt/local/include -fomit-frame-pointer -march=i686 -msse -msse2 -mfpmath=sse -fno-stack-protector -Wall -pipe -Os -m32 -MT LuaJIT-src/src/lj_cconv.lo -MD -MP -MF LuaJIT-src/src/.deps/lj_cconv.Tpo -c LuaJIT-src/src/lj_cconv.c  -fno-common -DPIC -o LuaJIT-src/src/.libs/lj_cconv.o
LuaJIT-src/src/lj_cconv.c: In function 'lj_cconv_ct_ct':
LuaJIT-src/src/lj_cconv.c:368:1: internal compiler error: in gen_reg_rtx, at emit-rtl.c:1025
 }
 ^
libbacktrace could not find executable to open
Comment 10 Eric Gallager 2017-12-30 02:14:09 UTC
(In reply to Ryan Schmidt from comment #9)
> I am also encountering this problem on i386-apple-darwin9.8.0 when compiling
> texlive-bin 20170604 with gcc 6.4.0, though in my case it's -Os not -Ofast:
> 
> libtool: compile:  /opt/local/bin/gcc-mp-6 -DHAVE_CONFIG_H -I.
> -I./LuaJIT-src/src -DLUAJIT_ENABLE_LUA52COMPAT -DLUAI_HASHLIMIT=6
> -U_FORTIFY_SOURCE -isystem/opt/local/include -fomit-frame-pointer
> -march=i686 -msse -msse2 -mfpmath=sse -fno-stack-protector -Wall -pipe -Os
> -m32 -MT LuaJIT-src/src/lj_cconv.lo -MD -MP -MF
> LuaJIT-src/src/.deps/lj_cconv.Tpo -c LuaJIT-src/src/lj_cconv.c  -fno-common
> -DPIC -o LuaJIT-src/src/.libs/lj_cconv.o
> LuaJIT-src/src/lj_cconv.c: In function 'lj_cconv_ct_ct':
> LuaJIT-src/src/lj_cconv.c:368:1: internal compiler error: in gen_reg_rtx, at
> emit-rtl.c:1025
>  }
>  ^
> libbacktrace could not find executable to open

I'll take this as confirmation.
Comment 11 Eric Gallager 2018-10-20 01:20:05 UTC
(In reply to Ryan Schmidt from comment #9)
> I am also encountering this problem on i386-apple-darwin9.8.0 when compiling
> texlive-bin 20170604 with gcc 6.4.0, though in my case it's -Os not -Ofast:
> 
> libtool: compile:  /opt/local/bin/gcc-mp-6 -DHAVE_CONFIG_H -I.
> -I./LuaJIT-src/src -DLUAJIT_ENABLE_LUA52COMPAT -DLUAI_HASHLIMIT=6
> -U_FORTIFY_SOURCE -isystem/opt/local/include -fomit-frame-pointer
> -march=i686 -msse -msse2 -mfpmath=sse -fno-stack-protector -Wall -pipe -Os
> -m32 -MT LuaJIT-src/src/lj_cconv.lo -MD -MP -MF
> LuaJIT-src/src/.deps/lj_cconv.Tpo -c LuaJIT-src/src/lj_cconv.c  -fno-common
> -DPIC -o LuaJIT-src/src/.libs/lj_cconv.o
> LuaJIT-src/src/lj_cconv.c: In function 'lj_cconv_ct_ct':
> LuaJIT-src/src/lj_cconv.c:368:1: internal compiler error: in gen_reg_rtx, at
> emit-rtl.c:1025
>  }
>  ^
> libbacktrace could not find executable to open

Actually could you attach the preprocessed source for lj_cconv.c anyways? I want to compare to see if it really is the same bug as I was originally experiencing.
Comment 12 Ryan Schmidt 2018-10-20 04:06:44 UTC
How would I do that?
Comment 13 Eric Gallager 2018-10-20 15:20:42 UTC
(In reply to Ryan Schmidt from comment #12)
> How would I do that?

Add -save-temps to the compile command and then attach the lj_cconv.i file that is produced
Comment 14 Eric Gallager 2021-03-20 22:27:07 UTC
Note that I can't reproduce my original bug anymore. Ryan, would you like to keep this bug open for your variation on it, or are you going to open a separate bug for it?
Comment 15 Martin Liška 2021-03-22 07:57:14 UTC
I'm closing this, please open a separate issue.