ruby-dev (Japanese) list archive (unofficial mirror)
 help / color / mirror / Atom feed
* [ruby-dev:50746] [Ruby trunk Bug#15513] MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
       [not found] <redmine.issue-15513.20190107095256@ruby-lang.org>
@ 2019-01-07  9:52 ` kajisha
  2019-01-07 10:08 ` [ruby-dev:50747] [Ruby trunk Bug#15513][Assigned] " hsbt
                   ` (10 subsequent siblings)
  11 siblings, 0 replies; 12+ messages in thread
From: kajisha @ 2019-01-07  9:52 UTC (permalink / raw)
  To: ruby-dev

Issue #15513 has been reported by kajisha (Hiroshi Kajisha).

----------------------------------------
Bug #15513: MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
https://bugs.ruby-lang.org/issues/15513

* Author: kajisha (Hiroshi Kajisha)
* Status: Open
* Priority: Normal
* Assignee: 
* Target version: 
* ruby -v: ruby 2.6.0p0 (2018-12-25 revision 66547) [x86_64-linux]
* Backport: 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
GCC 7.3.0 で MJIT を有効にしてみたところ、生成されたヘッダファイルがコンパイルエラーになるようです。

## GCC のバージョン
~~~
$ gcc --version
gcc (Gentoo 7.3.0-r3 p1.4) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
~~~

## 実行環境
~~~
$ uname -a
Linux localhost.localdomain 4.14.83-gentoo #3 SMP Mon Jan 7 13:56:38 JST 2019 x86_64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz GenuineIntel GNU/Linux
~~~

## サンプルコード(/tmp/t.rb)
~~~
def calculate(a, b, n = 40_000_000)
  n.times.count do
    a = a * 16807 % 2147483647
    b = b * 48271 % 2147483647

    (a & 0xffff) == (b & 0xffff)
  end
end

raise unless calculate(65, 8921) == 588
p result: calculate(699, 124)
~~~

## 実行結果
~~~
$ ruby --jit --jit-verbose=1 /tmp/t.rb
/tmp/_ruby_mjit_p18462u106.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u46.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u41.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u2.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u10.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u11.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u0.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u1.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u21.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u28.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u29.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u30.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u31.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u32.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u37.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u3.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u36.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u35.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u34.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u33.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u27.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u39.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u40.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u38.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u6.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u43.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u44.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u45.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u42.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u23.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u24.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u22.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u74.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u68.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u69.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u58.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u51.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u53.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u20.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u49.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u50.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u52.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u54.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u55.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u56.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u57.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u59.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u60.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u61.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u62.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u63.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u64.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u66.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u67.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u73.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u47.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u48.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u65.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u70.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u71.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u72.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u75.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u76.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u8.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u12.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u13.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u14.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u15.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u80.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u78.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u100.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u82.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u79.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u101.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u102.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u103.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u104.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u105.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u19.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u81.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u9.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u85.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u94.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u95.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u87.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u92.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u93.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u83.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u84.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u86.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u88.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u89.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u90.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u91.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u16.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u17.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u18.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u25.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u26.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u77.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u96.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u4.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u5.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u97.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u98.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u99.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u7.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
{:result=>600}
Successful MJIT finish
~~~



-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [ruby-dev:50747] [Ruby trunk Bug#15513][Assigned] MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
       [not found] <redmine.issue-15513.20190107095256@ruby-lang.org>
  2019-01-07  9:52 ` [ruby-dev:50746] [Ruby trunk Bug#15513] MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0 kajisha
@ 2019-01-07 10:08 ` hsbt
  2019-01-07 10:29 ` [ruby-dev:50748] [Ruby trunk Bug#15513][Feedback] " takashikkbn
                   ` (9 subsequent siblings)
  11 siblings, 0 replies; 12+ messages in thread
From: hsbt @ 2019-01-07 10:08 UTC (permalink / raw)
  To: ruby-dev

Issue #15513 has been updated by hsbt (Hiroshi SHIBATA).

Status changed from Open to Assigned
Assignee set to k0kubun (Takashi Kokubun)

----------------------------------------
Bug #15513: MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
https://bugs.ruby-lang.org/issues/15513#change-76101

* Author: kajisha (Hiroshi Kajisha)
* Status: Assigned
* Priority: Normal
* Assignee: k0kubun (Takashi Kokubun)
* Target version: 
* ruby -v: ruby 2.6.0p0 (2018-12-25 revision 66547) [x86_64-linux]
* Backport: 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
GCC 7.3.0 で MJIT を有効にしてみたところ、生成されたヘッダファイルがコンパイルエラーになるようです。

## GCC のバージョン
~~~
$ gcc --version
gcc (Gentoo 7.3.0-r3 p1.4) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
~~~

## 実行環境
~~~
$ uname -a
Linux localhost.localdomain 4.14.83-gentoo #3 SMP Mon Jan 7 13:56:38 JST 2019 x86_64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz GenuineIntel GNU/Linux
~~~

## サンプルコード(/tmp/t.rb)
~~~
def calculate(a, b, n = 40_000_000)
  n.times.count do
    a = a * 16807 % 2147483647
    b = b * 48271 % 2147483647

    (a & 0xffff) == (b & 0xffff)
  end
end

raise unless calculate(65, 8921) == 588
p result: calculate(699, 124)
~~~

## 実行結果
~~~
$ ruby --jit --jit-verbose=1 /tmp/t.rb
/tmp/_ruby_mjit_p18462u106.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u46.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u41.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u2.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u10.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u11.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u0.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u1.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u21.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u28.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u29.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u30.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u31.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u32.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u37.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u3.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u36.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u35.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u34.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u33.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u27.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u39.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u40.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u38.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u6.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u43.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u44.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u45.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u42.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u23.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u24.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u22.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u74.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u68.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u69.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u58.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u51.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u53.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u20.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u49.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u50.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u52.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u54.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u55.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u56.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u57.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u59.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u60.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u61.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u62.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u63.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u64.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u66.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u67.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u73.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u47.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u48.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u65.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u70.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u71.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u72.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u75.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u76.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u8.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u12.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u13.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u14.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u15.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u80.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u78.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u100.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u82.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u79.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u101.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u102.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u103.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u104.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u105.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u19.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u81.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u9.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u85.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u94.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u95.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u87.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u92.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u93.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u83.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u84.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u86.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u88.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u89.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u90.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u91.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u16.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u17.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u18.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u25.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u26.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u77.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u96.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u4.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u5.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u97.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u98.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u99.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u7.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
{:result=>600}
Successful MJIT finish
~~~



-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [ruby-dev:50748] [Ruby trunk Bug#15513][Feedback] MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
       [not found] <redmine.issue-15513.20190107095256@ruby-lang.org>
  2019-01-07  9:52 ` [ruby-dev:50746] [Ruby trunk Bug#15513] MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0 kajisha
  2019-01-07 10:08 ` [ruby-dev:50747] [Ruby trunk Bug#15513][Assigned] " hsbt
@ 2019-01-07 10:29 ` takashikkbn
  2019-01-07 10:40 ` [ruby-dev:50749] [Ruby trunk Bug#15513] " kajisha
                   ` (8 subsequent siblings)
  11 siblings, 0 replies; 12+ messages in thread
From: takashikkbn @ 2019-01-07 10:29 UTC (permalink / raw)
  To: ruby-dev

Issue #15513 has been updated by k0kubun (Takashi Kokubun).

Status changed from Assigned to Feedback

ご報告ありがとうございます。私も普段Linux上でgcc 7.3.0を使って開発をしていますが、現在同様の問題を再現できないので、デバッグのため以下の3つをいただけないでしょうか。

* (`rm -f /tmp/_ruby_mjit*` の後) `ruby -v --jit-verbose=2 --jit-save-temps --disable-gems /tmp/t.rb` を実行したログ全体
* ↑のログに出現する `include/ruby-2.6.0/x86_64-linux/rb_mjit_min_header-2.6.0.h` ファイル (アップロードでお願いします)
* `/tmp/_ruby_mjit*.c` ファイル (アップロードでお願いします)



----------------------------------------
Bug #15513: MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
https://bugs.ruby-lang.org/issues/15513#change-76103

* Author: kajisha (Hiroshi Kajisha)
* Status: Feedback
* Priority: Normal
* Assignee: k0kubun (Takashi Kokubun)
* Target version: 
* ruby -v: ruby 2.6.0p0 (2018-12-25 revision 66547) [x86_64-linux]
* Backport: 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
GCC 7.3.0 で MJIT を有効にしてみたところ、生成されたヘッダファイルがコンパイルエラーになるようです。

## GCC のバージョン
~~~
$ gcc --version
gcc (Gentoo 7.3.0-r3 p1.4) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
~~~

## 実行環境
~~~
$ uname -a
Linux localhost.localdomain 4.14.83-gentoo #3 SMP Mon Jan 7 13:56:38 JST 2019 x86_64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz GenuineIntel GNU/Linux
~~~

## サンプルコード(/tmp/t.rb)
~~~
def calculate(a, b, n = 40_000_000)
  n.times.count do
    a = a * 16807 % 2147483647
    b = b * 48271 % 2147483647

    (a & 0xffff) == (b & 0xffff)
  end
end

raise unless calculate(65, 8921) == 588
p result: calculate(699, 124)
~~~

## 実行結果
~~~
$ ruby --jit --jit-verbose=1 /tmp/t.rb
/tmp/_ruby_mjit_p18462u106.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u46.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u41.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u2.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u10.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u11.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u0.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u1.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u21.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u28.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u29.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u30.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u31.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u32.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u37.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u3.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u36.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u35.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u34.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u33.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u27.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u39.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u40.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u38.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u6.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u43.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u44.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u45.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u42.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u23.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u24.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u22.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u74.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u68.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u69.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u58.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u51.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u53.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u20.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u49.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u50.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u52.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u54.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u55.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u56.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u57.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u59.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u60.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u61.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u62.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u63.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u64.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u66.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u67.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u73.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u47.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u48.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u65.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u70.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u71.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u72.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u75.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u76.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u8.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u12.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u13.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u14.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u15.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u80.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u78.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u100.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u82.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u79.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u101.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u102.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u103.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u104.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u105.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u19.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u81.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u9.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u85.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u94.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u95.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u87.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u92.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u93.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u83.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u84.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u86.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u88.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u89.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u90.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u91.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u16.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u17.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u18.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u25.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u26.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u77.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u96.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u4.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u5.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u97.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u98.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u99.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u7.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
{:result=>600}
Successful MJIT finish
~~~



-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [ruby-dev:50749] [Ruby trunk Bug#15513] MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
       [not found] <redmine.issue-15513.20190107095256@ruby-lang.org>
                   ` (2 preceding siblings ...)
  2019-01-07 10:29 ` [ruby-dev:50748] [Ruby trunk Bug#15513][Feedback] " takashikkbn
@ 2019-01-07 10:40 ` kajisha
  2019-01-07 11:41 ` [ruby-dev:50750] " takashikkbn
                   ` (7 subsequent siblings)
  11 siblings, 0 replies; 12+ messages in thread
From: kajisha @ 2019-01-07 10:40 UTC (permalink / raw)
  To: ruby-dev

Issue #15513 has been updated by kajisha (Hiroshi Kajisha).

File rb_mjit_min_header-2.6.0.h added
File _ruby_mjit_p23890u0.c added

- (rm -f /tmp/_ruby_mjit* の後) ruby -v --jit-verbose=2 --jit-save-temps --disable-gems /tmp/t.rb を実行したログ全体

以下実行ログになります。

~~~
$ ruby -v --jit-verbose=2 --jit-save-temps --disable-gems /tmp/t.rb
ruby 2.6.0p0 (2018-12-25 revision 66547) +JIT [x86_64-linux]
MJIT: CC defaults to /usr/bin/gcc
MJIT: tmp_dir is /tmp
Creating precompiled header
Starting process: /usr/bin/gcc /usr/bin/gcc -w -Wfatal-errors -fPIC -shared -w -pipe -O3 -o /tmp/_ruby_mjit_hp23890u0.h.gch /home/hiroshi/.asdf/installs/ruby/2.6.0/include/ruby-2.6.0/x86_64-linux/rb_mjit_min_header-2.6.0.h
start compilation: block in calculate@/tmp/t.rb:2 -> /tmp/_ruby_mjit_p23890u0.c
Starting process: /usr/bin/gcc /usr/bin/gcc -w -Wfatal-errors -fPIC -shared -w -pipe -O3 -o /tmp/_ruby_mjit_p23890u0.o /tmp/_ruby_mjit_p23890u0.c -c -L/home/hiroshi/.asdf/installs/ruby/2.6.0/lib -Wl,--compress-debug-sections=zlib -nostartfiles -nodefaultlibs -nostdlib
/tmp/_ruby_mjit_p23890u0.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp23890u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
compile_c_to_o: compile error: 1
Failed to generate so: /tmp/_ruby_mjit_p23890u0.so
{:result=>600}
Stopping worker thread
Successful MJIT finish
~~~

- ↑のログに出現する include/ruby-2.6.0/x86_64-linux/rb_mjit_min_header-2.6.0.h ファイル (アップロードでお願いします)
- /tmp/_ruby_mjit*.c ファイル (アップロードでお願いします)

添付いたしました。

----------------------------------------
Bug #15513: MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
https://bugs.ruby-lang.org/issues/15513#change-76104

* Author: kajisha (Hiroshi Kajisha)
* Status: Feedback
* Priority: Normal
* Assignee: k0kubun (Takashi Kokubun)
* Target version: 
* ruby -v: ruby 2.6.0p0 (2018-12-25 revision 66547) [x86_64-linux]
* Backport: 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
GCC 7.3.0 で MJIT を有効にしてみたところ、生成されたヘッダファイルがコンパイルエラーになるようです。

## GCC のバージョン
~~~
$ gcc --version
gcc (Gentoo 7.3.0-r3 p1.4) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
~~~

## 実行環境
~~~
$ uname -a
Linux localhost.localdomain 4.14.83-gentoo #3 SMP Mon Jan 7 13:56:38 JST 2019 x86_64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz GenuineIntel GNU/Linux
~~~

## サンプルコード(/tmp/t.rb)
~~~
def calculate(a, b, n = 40_000_000)
  n.times.count do
    a = a * 16807 % 2147483647
    b = b * 48271 % 2147483647

    (a & 0xffff) == (b & 0xffff)
  end
end

raise unless calculate(65, 8921) == 588
p result: calculate(699, 124)
~~~

## 実行結果
~~~
$ ruby --jit --jit-verbose=1 /tmp/t.rb
/tmp/_ruby_mjit_p18462u106.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u46.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u41.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u2.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u10.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u11.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u0.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u1.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u21.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u28.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u29.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u30.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u31.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u32.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u37.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u3.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u36.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u35.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u34.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u33.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u27.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u39.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u40.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u38.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u6.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u43.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u44.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u45.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u42.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u23.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u24.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u22.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u74.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u68.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u69.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u58.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u51.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u53.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u20.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u49.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u50.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u52.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u54.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u55.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u56.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u57.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u59.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u60.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u61.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u62.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u63.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u64.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u66.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u67.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u73.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u47.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u48.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u65.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u70.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u71.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u72.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u75.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u76.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u8.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u12.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u13.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u14.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u15.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u80.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u78.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u100.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u82.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u79.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u101.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u102.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u103.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u104.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u105.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u19.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u81.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u9.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u85.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u94.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u95.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u87.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u92.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u93.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u83.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u84.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u86.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u88.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u89.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u90.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u91.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u16.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u17.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u18.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u25.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u26.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u77.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u96.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u4.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u5.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u97.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u98.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u99.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u7.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
{:result=>600}
Successful MJIT finish
~~~

---Files--------------------------------
rb_mjit_min_header-2.6.0.h (873 KB)
_ruby_mjit_p23890u0.c (8.95 KB)


-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [ruby-dev:50750] [Ruby trunk Bug#15513] MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
       [not found] <redmine.issue-15513.20190107095256@ruby-lang.org>
                   ` (3 preceding siblings ...)
  2019-01-07 10:40 ` [ruby-dev:50749] [Ruby trunk Bug#15513] " kajisha
@ 2019-01-07 11:41 ` takashikkbn
  2019-01-07 23:43 ` [ruby-dev:50751] " kajisha
                   ` (6 subsequent siblings)
  11 siblings, 0 replies; 12+ messages in thread
From: takashikkbn @ 2019-01-07 11:41 UTC (permalink / raw)
  To: ruby-dev

Issue #15513 has been updated by k0kubun (Takashi Kokubun).


共有ありがとうございます。いただいたファイルを手元で同様のコマンドにてコンパイルしたところコンパイルエラーにならないので、先ほどのファイルが /tmp にある状態で(削除済であれば再度実行し、pXXXXX 部分をご変更ください)以下のコマンドのログをご共有いただけないでしょうか。

```
/usr/bin/gcc -w -Winvalid-pch -fPIC -shared -w -pipe -O3 -o /tmp/_ruby_mjit_p23890u0.o /tmp/_ruby_mjit_p23890u0.c -c -L/home/hiroshi/.asdf/installs/ruby/2.6.0/lib -Wl,--compress-debug-sections=zlib -nostartfiles -nodefaultlibs -nostdlib
```

`-Wfatal-errors` を取り除き、 `-Winvalid-pch` を追加しています。また、念のため `ls -l /tmp/_ruby_mjit_hp23890u0.h.gch` の結果も確認したいです。

----------------------------------------
Bug #15513: MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
https://bugs.ruby-lang.org/issues/15513#change-76107

* Author: kajisha (Hiroshi Kajisha)
* Status: Feedback
* Priority: Normal
* Assignee: k0kubun (Takashi Kokubun)
* Target version: 
* ruby -v: ruby 2.6.0p0 (2018-12-25 revision 66547) [x86_64-linux]
* Backport: 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
GCC 7.3.0 で MJIT を有効にしてみたところ、生成されたヘッダファイルがコンパイルエラーになるようです。

## GCC のバージョン
~~~
$ gcc --version
gcc (Gentoo 7.3.0-r3 p1.4) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
~~~

## 実行環境
~~~
$ uname -a
Linux localhost.localdomain 4.14.83-gentoo #3 SMP Mon Jan 7 13:56:38 JST 2019 x86_64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz GenuineIntel GNU/Linux
~~~

## サンプルコード(/tmp/t.rb)
~~~
def calculate(a, b, n = 40_000_000)
  n.times.count do
    a = a * 16807 % 2147483647
    b = b * 48271 % 2147483647

    (a & 0xffff) == (b & 0xffff)
  end
end

raise unless calculate(65, 8921) == 588
p result: calculate(699, 124)
~~~

## 実行結果
~~~
$ ruby --jit --jit-verbose=1 /tmp/t.rb
/tmp/_ruby_mjit_p18462u106.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u46.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u41.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u2.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u10.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u11.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u0.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u1.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u21.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u28.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u29.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u30.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u31.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u32.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u37.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u3.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u36.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u35.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u34.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u33.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u27.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u39.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u40.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u38.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u6.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u43.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u44.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u45.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u42.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u23.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u24.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u22.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u74.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u68.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u69.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u58.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u51.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u53.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u20.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u49.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u50.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u52.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u54.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u55.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u56.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u57.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u59.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u60.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u61.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u62.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u63.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u64.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u66.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u67.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u73.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u47.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u48.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u65.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u70.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u71.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u72.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u75.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u76.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u8.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u12.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u13.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u14.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u15.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u80.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u78.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u100.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u82.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u79.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u101.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u102.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u103.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u104.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u105.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u19.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u81.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u9.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u85.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u94.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u95.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u87.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u92.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u93.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u83.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u84.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u86.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u88.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u89.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u90.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u91.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u16.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u17.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u18.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u25.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u26.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u77.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u96.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u4.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u5.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u97.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u98.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u99.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u7.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
{:result=>600}
Successful MJIT finish
~~~

---Files--------------------------------
rb_mjit_min_header-2.6.0.h (873 KB)
_ruby_mjit_p23890u0.c (8.95 KB)


-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [ruby-dev:50751] [Ruby trunk Bug#15513] MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
       [not found] <redmine.issue-15513.20190107095256@ruby-lang.org>
                   ` (4 preceding siblings ...)
  2019-01-07 11:41 ` [ruby-dev:50750] " takashikkbn
@ 2019-01-07 23:43 ` kajisha
  2019-01-08 12:07 ` [ruby-dev:50752] " s.wanabe
                   ` (5 subsequent siblings)
  11 siblings, 0 replies; 12+ messages in thread
From: kajisha @ 2019-01-07 23:43 UTC (permalink / raw)
  To: ruby-dev

Issue #15513 has been updated by kajisha (Hiroshi Kajisha).


再起動で /tmp 以下が消えたため `ruby -v --jit-verbose=2 --jit-save-temps --disable-gems /tmp/t.rb` から再度実行しました

~~~
$ ruby -v --jit-verbose=2 --jit-save-temps --disable-gems /tmp/t.rb
ruby 2.6.0p0 (2018-12-25 revision 66547) +JIT [x86_64-linux]
MJIT: CC defaults to /usr/bin/gcc
MJIT: tmp_dir is /tmp
Creating precompiled header
Starting process: /usr/bin/gcc /usr/bin/gcc -w -Wfatal-errors -fPIC -shared -w -pipe -O3 -o /tmp/_ruby_mjit_hp12174u0.h.gch /home/hiroshi/.asdf/installs/ruby/2.6.0/include/ruby-2.6.0/x86_64-linux/rb_mjit_min_header-2.6.0.h
start compilation: block in calculate@/tmp/t.rb:2 -> /tmp/_ruby_mjit_p12174u0.c
Starting process: /usr/bin/gcc /usr/bin/gcc -w -Wfatal-errors -fPIC -shared -w -pipe -O3 -o /tmp/_ruby_mjit_p12174u0.o /tmp/_ruby_mjit_p12174u0.c -c -L/home/hiroshi/.asdf/installs/ruby/2.6.0/lib -Wl,--compress-debug-sections=zlib -nostartfiles -nodefaultlibs -nostdlib
/tmp/_ruby_mjit_p12174u0.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp12174u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
compile_c_to_o: compile error: 1
Failed to generate so: /tmp/_ruby_mjit_p12174u0.so
{:result=>600}
Stopping worker thread
Successful MJIT finish
~~~

`-Winvalid-pch` を付与して実行しました。

~~~
$ /usr/bin/gcc -w -Winvalid-pch -fPIC -shared -w -pipe -O3 -o /tmp/_ruby_mjit_p12174u0.o /tmp/_ruby_mjit_p12174u0.c -c -L/home/hiroshi/.asdf/installs/ruby/2.6.0/lib -Wl,--compress-debug-sections=zlib -nostartfiles -nodefaultlibs -nostdlib
/tmp/_ruby_mjit_p12174u0.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp12174u0.h"
                                       ^
/tmp/_ruby_mjit_p12174u0.c:1:10: fatal error: /tmp/_ruby_mjit_hp12174u0.h: No such file or directory
 #include "/tmp/_ruby_mjit_hp12174u0.h"
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
~~~

~~~
$ ls -l /tmp/_ruby_mjit_hp12174u0.h.gch
-rw------- 1 hiroshi hiroshi 9695664 Jan  8 08:34 /tmp/_ruby_mjit_hp12174u0.h.gch
~~~

----------------------------------------
Bug #15513: MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
https://bugs.ruby-lang.org/issues/15513#change-76118

* Author: kajisha (Hiroshi Kajisha)
* Status: Feedback
* Priority: Normal
* Assignee: k0kubun (Takashi Kokubun)
* Target version: 
* ruby -v: ruby 2.6.0p0 (2018-12-25 revision 66547) [x86_64-linux]
* Backport: 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
GCC 7.3.0 で MJIT を有効にしてみたところ、生成されたヘッダファイルがコンパイルエラーになるようです。

## GCC のバージョン
~~~
$ gcc --version
gcc (Gentoo 7.3.0-r3 p1.4) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
~~~

## 実行環境
~~~
$ uname -a
Linux localhost.localdomain 4.14.83-gentoo #3 SMP Mon Jan 7 13:56:38 JST 2019 x86_64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz GenuineIntel GNU/Linux
~~~

## サンプルコード(/tmp/t.rb)
~~~
def calculate(a, b, n = 40_000_000)
  n.times.count do
    a = a * 16807 % 2147483647
    b = b * 48271 % 2147483647

    (a & 0xffff) == (b & 0xffff)
  end
end

raise unless calculate(65, 8921) == 588
p result: calculate(699, 124)
~~~

## 実行結果
~~~
$ ruby --jit --jit-verbose=1 /tmp/t.rb
/tmp/_ruby_mjit_p18462u106.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u46.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u41.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u2.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u10.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u11.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u0.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u1.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u21.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u28.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u29.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u30.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u31.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u32.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u37.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u3.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u36.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u35.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u34.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u33.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u27.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u39.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u40.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u38.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u6.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u43.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u44.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u45.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u42.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u23.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u24.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u22.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u74.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u68.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u69.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u58.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u51.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u53.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u20.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u49.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u50.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u52.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u54.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u55.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u56.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u57.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u59.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u60.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u61.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u62.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u63.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u64.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u66.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u67.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u73.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u47.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u48.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u65.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u70.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u71.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u72.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u75.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u76.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u8.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u12.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u13.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u14.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u15.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u80.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u78.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u100.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u82.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u79.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u101.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u102.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u103.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u104.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u105.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u19.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u81.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u9.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u85.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u94.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u95.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u87.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u92.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u93.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u83.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u84.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u86.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u88.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u89.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u90.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u91.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u16.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u17.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u18.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u25.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u26.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u77.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u96.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u4.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u5.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u97.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u98.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u99.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u7.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
{:result=>600}
Successful MJIT finish
~~~

---Files--------------------------------
rb_mjit_min_header-2.6.0.h (873 KB)
_ruby_mjit_p23890u0.c (8.95 KB)


-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [ruby-dev:50752] [Ruby trunk Bug#15513] MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
       [not found] <redmine.issue-15513.20190107095256@ruby-lang.org>
                   ` (5 preceding siblings ...)
  2019-01-07 23:43 ` [ruby-dev:50751] " kajisha
@ 2019-01-08 12:07 ` s.wanabe
  2019-01-08 12:18 ` [ruby-dev:50753] [Ruby trunk Bug#15513][Assigned] " takashikkbn
                   ` (4 subsequent siblings)
  11 siblings, 0 replies; 12+ messages in thread
From: s.wanabe @ 2019-01-08 12:07 UTC (permalink / raw)
  To: ruby-dev

Issue #15513 has been updated by wanabe (_ wanabe).


Dockerhub の gentoo/stage3-amd64:20190106 で再現しました。
Gentoo Linux では独自に https://gitweb.gentoo.org/proj/gcc-patches.git/tree/7.3.0/gentoo/13_all_default-ssp-fix.patch のようなパッチを当てていて、-nodefaultlibs オプションをつけると `-fno-stack-protector` オプションもあわせて cc1 に渡されるようです。

```
83c3480156c5 /bug15513 # echo "void main() {}" > a.c && /usr/bin/gcc -v a.c -c 2>&1|grep cc1
 /usr/libexec/gcc/x86_64-pc-linux-gnu/7.3.0/cc1 -quiet -v a.c -quiet -dumpbase a.c -mtune=generic -march=x86-64 -auxbase a -version -o /tmp/ccKwTDxC.s
83c3480156c5 /bug15513 # echo "void main() {}" > a.c && /usr/bin/gcc -v a.c -c -nodefaultlibs 2>&1|grep cc1
 /usr/libexec/gcc/x86_64-pc-linux-gnu/7.3.0/cc1 -quiet -v a.c -quiet -dumpbase a.c -mtune=generic -march=x86-64 -auxbase a -version -fno-stack-protector -o /tmp/cc8GG9aZ.s
83c3480156c5 /bug15513 # gcc --version
gcc (Gentoo 7.3.0-r3 p1.4) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 
```

このパッチが当てられた詳しい理由まではわかりませんでした。

----------------------------------------
Bug #15513: MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
https://bugs.ruby-lang.org/issues/15513#change-76124

* Author: kajisha (Hiroshi Kajisha)
* Status: Feedback
* Priority: Normal
* Assignee: k0kubun (Takashi Kokubun)
* Target version: 
* ruby -v: ruby 2.6.0p0 (2018-12-25 revision 66547) [x86_64-linux]
* Backport: 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
GCC 7.3.0 で MJIT を有効にしてみたところ、生成されたヘッダファイルがコンパイルエラーになるようです。

## GCC のバージョン
~~~
$ gcc --version
gcc (Gentoo 7.3.0-r3 p1.4) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
~~~

## 実行環境
~~~
$ uname -a
Linux localhost.localdomain 4.14.83-gentoo #3 SMP Mon Jan 7 13:56:38 JST 2019 x86_64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz GenuineIntel GNU/Linux
~~~

## サンプルコード(/tmp/t.rb)
~~~
def calculate(a, b, n = 40_000_000)
  n.times.count do
    a = a * 16807 % 2147483647
    b = b * 48271 % 2147483647

    (a & 0xffff) == (b & 0xffff)
  end
end

raise unless calculate(65, 8921) == 588
p result: calculate(699, 124)
~~~

## 実行結果
~~~
$ ruby --jit --jit-verbose=1 /tmp/t.rb
/tmp/_ruby_mjit_p18462u106.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u46.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u41.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u2.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u10.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u11.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u0.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u1.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u21.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u28.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u29.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u30.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u31.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u32.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u37.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u3.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u36.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u35.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u34.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u33.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u27.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u39.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u40.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u38.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u6.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u43.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u44.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u45.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u42.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u23.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u24.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u22.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u74.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u68.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u69.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u58.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u51.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u53.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u20.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u49.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u50.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u52.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u54.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u55.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u56.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u57.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u59.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u60.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u61.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u62.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u63.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u64.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u66.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u67.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u73.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u47.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u48.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u65.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u70.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u71.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u72.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u75.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u76.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u8.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u12.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u13.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u14.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u15.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u80.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u78.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u100.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u82.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u79.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u101.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u102.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u103.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u104.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u105.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u19.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u81.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u9.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u85.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u94.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u95.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u87.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u92.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u93.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u83.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u84.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u86.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u88.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u89.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u90.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u91.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u16.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u17.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u18.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u25.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u26.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u77.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u96.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u4.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u5.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u97.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u98.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u99.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u7.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
{:result=>600}
Successful MJIT finish
~~~

---Files--------------------------------
rb_mjit_min_header-2.6.0.h (873 KB)
_ruby_mjit_p23890u0.c (8.95 KB)


-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [ruby-dev:50753] [Ruby trunk Bug#15513][Assigned] MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
       [not found] <redmine.issue-15513.20190107095256@ruby-lang.org>
                   ` (6 preceding siblings ...)
  2019-01-08 12:07 ` [ruby-dev:50752] " s.wanabe
@ 2019-01-08 12:18 ` takashikkbn
  2019-01-14  7:30 ` [ruby-dev:50762] [Ruby trunk Bug#15513] MJIT compilation terminated due to-Wfatal-errors " takashikkbn
                   ` (3 subsequent siblings)
  11 siblings, 0 replies; 12+ messages in thread
From: takashikkbn @ 2019-01-08 12:18 UTC (permalink / raw)
  To: ruby-dev

Issue #15513 has been updated by k0kubun (Takashi Kokubun).

Status changed from Feedback to Assigned

お二人ともご強力ありがとうございます。

> Dockerhub の gentoo/stage3-amd64:20190106 で再現しました。
> Gentoo Linux では独自に https://gitweb.gentoo.org/proj/gcc-patches.git/tree/7.3.0/gentoo/13_all_default-ssp-fix.patch のようなパッチを当てていて、-nodefaultlibs オプションをつけると -fno-stack-protector オプションもあわせて cc1 に渡されるようです。

リンカ向けに渡していたフラグが(少なくともそのGentoo Linuxの環境では)cc1に渡るフラグにも影響を与えるようになっていたのですね。なるほど。

そのDockerイメージを利用し、現時点での情報量で何らか対応できそうなので、後で直しておきます。

----------------------------------------
Bug #15513: MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
https://bugs.ruby-lang.org/issues/15513#change-76125

* Author: kajisha (Hiroshi Kajisha)
* Status: Assigned
* Priority: Normal
* Assignee: k0kubun (Takashi Kokubun)
* Target version: 
* ruby -v: ruby 2.6.0p0 (2018-12-25 revision 66547) [x86_64-linux]
* Backport: 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
GCC 7.3.0 で MJIT を有効にしてみたところ、生成されたヘッダファイルがコンパイルエラーになるようです。

## GCC のバージョン
~~~
$ gcc --version
gcc (Gentoo 7.3.0-r3 p1.4) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
~~~

## 実行環境
~~~
$ uname -a
Linux localhost.localdomain 4.14.83-gentoo #3 SMP Mon Jan 7 13:56:38 JST 2019 x86_64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz GenuineIntel GNU/Linux
~~~

## サンプルコード(/tmp/t.rb)
~~~
def calculate(a, b, n = 40_000_000)
  n.times.count do
    a = a * 16807 % 2147483647
    b = b * 48271 % 2147483647

    (a & 0xffff) == (b & 0xffff)
  end
end

raise unless calculate(65, 8921) == 588
p result: calculate(699, 124)
~~~

## 実行結果
~~~
$ ruby --jit --jit-verbose=1 /tmp/t.rb
/tmp/_ruby_mjit_p18462u106.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u46.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u41.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u2.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u10.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u11.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u0.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u1.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u21.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u28.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u29.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u30.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u31.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u32.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u37.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u3.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u36.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u35.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u34.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u33.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u27.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u39.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u40.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u38.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u6.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u43.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u44.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u45.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u42.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u23.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u24.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u22.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u74.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u68.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u69.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u58.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u51.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u53.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u20.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u49.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u50.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u52.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u54.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u55.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u56.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u57.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u59.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u60.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u61.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u62.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u63.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u64.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u66.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u67.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u73.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u47.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u48.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u65.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u70.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u71.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u72.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u75.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u76.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u8.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u12.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u13.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u14.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u15.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u80.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u78.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u100.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u82.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u79.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u101.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u102.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u103.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u104.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u105.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u19.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u81.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u9.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u85.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u94.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u95.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u87.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u92.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u93.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u83.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u84.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u86.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u88.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u89.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u90.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u91.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u16.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u17.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u18.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u25.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u26.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u77.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u96.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u4.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u5.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u97.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u98.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u99.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u7.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
{:result=>600}
Successful MJIT finish
~~~

---Files--------------------------------
rb_mjit_min_header-2.6.0.h (873 KB)
_ruby_mjit_p23890u0.c (8.95 KB)


-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [ruby-dev:50762] [Ruby trunk Bug#15513] MJIT compilation terminated due to-Wfatal-errors on GCC 7.3.0
       [not found] <redmine.issue-15513.20190107095256@ruby-lang.org>
                   ` (7 preceding siblings ...)
  2019-01-08 12:18 ` [ruby-dev:50753] [Ruby trunk Bug#15513][Assigned] " takashikkbn
@ 2019-01-14  7:30 ` takashikkbn
  2019-01-15  6:00 ` [ruby-dev:50764] [Ruby trunk Bug#15513] MJIT compilation terminated due to -Wfatal-errors " kajisha
                   ` (2 subsequent siblings)
  11 siblings, 0 replies; 12+ messages in thread
From: takashikkbn @ 2019-01-14  7:30 UTC (permalink / raw)
  To: ruby-dev

Issue #15513 has been updated by k0kubun (Takashi Kokubun).


@kajisha 多分 r66817 で直ると思うのですが、最新のtrunkでMJITが動くかご確認いただけないでしょうか。

----------------------------------------
Bug #15513: MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
https://bugs.ruby-lang.org/issues/15513#change-76297

* Author: kajisha (Hiroshi Kajisha)
* Status: Closed
* Priority: Normal
* Assignee: k0kubun (Takashi Kokubun)
* Target version: 
* ruby -v: ruby 2.6.0p0 (2018-12-25 revision 66547) [x86_64-linux]
* Backport: 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
GCC 7.3.0 で MJIT を有効にしてみたところ、生成されたヘッダファイルがコンパイルエラーになるようです。

## GCC のバージョン
~~~
$ gcc --version
gcc (Gentoo 7.3.0-r3 p1.4) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
~~~

## 実行環境
~~~
$ uname -a
Linux localhost.localdomain 4.14.83-gentoo #3 SMP Mon Jan 7 13:56:38 JST 2019 x86_64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz GenuineIntel GNU/Linux
~~~

## サンプルコード(/tmp/t.rb)
~~~
def calculate(a, b, n = 40_000_000)
  n.times.count do
    a = a * 16807 % 2147483647
    b = b * 48271 % 2147483647

    (a & 0xffff) == (b & 0xffff)
  end
end

raise unless calculate(65, 8921) == 588
p result: calculate(699, 124)
~~~

## 実行結果
~~~
$ ruby --jit --jit-verbose=1 /tmp/t.rb
/tmp/_ruby_mjit_p18462u106.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u46.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u41.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u2.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u10.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u11.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u0.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u1.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u21.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u28.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u29.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u30.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u31.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u32.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u37.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u3.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u36.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u35.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u34.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u33.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u27.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u39.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u40.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u38.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u6.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u43.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u44.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u45.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u42.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u23.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u24.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u22.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u74.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u68.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u69.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u58.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u51.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u53.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u20.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u49.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u50.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u52.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u54.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u55.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u56.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u57.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u59.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u60.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u61.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u62.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u63.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u64.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u66.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u67.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u73.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u47.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u48.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u65.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u70.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u71.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u72.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u75.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u76.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u8.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u12.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u13.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u14.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u15.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u80.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u78.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u100.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u82.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u79.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u101.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u102.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u103.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u104.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u105.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u19.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u81.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u9.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u85.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u94.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u95.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u87.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u92.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u93.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u83.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u84.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u86.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u88.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u89.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u90.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u91.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u16.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u17.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u18.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u25.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u26.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u77.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u96.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u4.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u5.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u97.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u98.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u99.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u7.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
{:result=>600}
Successful MJIT finish
~~~

---Files--------------------------------
rb_mjit_min_header-2.6.0.h (873 KB)
_ruby_mjit_p23890u0.c (8.95 KB)


-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [ruby-dev:50764] [Ruby trunk Bug#15513] MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
       [not found] <redmine.issue-15513.20190107095256@ruby-lang.org>
                   ` (8 preceding siblings ...)
  2019-01-14  7:30 ` [ruby-dev:50762] [Ruby trunk Bug#15513] MJIT compilation terminated due to-Wfatal-errors " takashikkbn
@ 2019-01-15  6:00 ` kajisha
  2019-01-15  6:01 ` [ruby-dev:50765] " kajisha
  2019-01-17 21:55 ` [ruby-dev:50766] " naruse
  11 siblings, 0 replies; 12+ messages in thread
From: kajisha @ 2019-01-15  6:00 UTC (permalink / raw)
  To: ruby-dev

Issue #15513 has been updated by kajisha (Hiroshi Kajisha).

ruby -v changed from ruby 2.6.0p0 (2018-12-25 revision 66547) [x86_64-linux] to ruby 2.7.0dev (2019-01-15 trunk 66823) [x86_64-linux]

下記のとおりコンパルされることが確認できました!ありがとうございます。

~~~
$ time ruby -v --jit-verbose=2 --jit-save-temps --disable-gems /tmp/t.rb
ruby 2.7.0dev (2019-01-15 trunk 66823) +JIT [x86_64-linux]
MJIT: CC defaults to /usr/bin/gcc
MJIT: tmp_dir is /tmp
Creating precompiled header
Starting process: /usr/bin/gcc /usr/bin/gcc -w -Wfatal-errors -fPIC -shared -w -pipe -O3 -nodefaultlibs -nostdlib -o /tmp/_ruby_mjit_hp1832u0.h.gch /home/hiroshi/.asdf/installs/ruby/2.7.0-dev/include/ruby-2.7.0/x86_64-linux/rb_mjit_min_header-2.7.0.h
start compilation: block in calculate@/tmp/t.rb:2 -> /tmp/_ruby_mjit_p1832u0.c
Starting process: /usr/bin/gcc /usr/bin/gcc -w -Wfatal-errors -fPIC -shared -w -pipe -O3 -o /tmp/_ruby_mjit_p1832u0.o /tmp/_ruby_mjit_p1832u0.c -c -lgcc -L/home/hiroshi/.asdf/installs/ruby/2.7.0-dev/lib -Wl,--compress-debug-sections=zlib -nostartfiles -nodefaultlibs -nostdlib
Starting process: /usr/bin/gcc /usr/bin/gcc -shared -Wfatal-errors -fPIC -shared -w -pipe -O3 -o /tmp/_ruby_mjit_p1832u0.so /tmp/_ruby_mjit_p1832u0.o -lgcc -L/home/hiroshi/.asdf/installs/ruby/2.7.0-dev/lib -Wl,--compress-debug-sections=zlib -nostartfiles -nodefaultlibs -nostdlib
JIT success (81.1ms): block in calculate@/tmp/t.rb:2 -> /tmp/_ruby_mjit_p1832u0.c
{:result=>600}
Stopping worker thread
Successful MJIT finish

real    0m4.248s
user    0m4.470s
sys     0m0.084s
~~~

----------------------------------------
Bug #15513: MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
https://bugs.ruby-lang.org/issues/15513#change-76328

* Author: kajisha (Hiroshi Kajisha)
* Status: Closed
* Priority: Normal
* Assignee: k0kubun (Takashi Kokubun)
* Target version: 
* ruby -v: ruby 2.7.0dev (2019-01-15 trunk 66823) [x86_64-linux]
* Backport: 2.4: DONTNEED, 2.5: DONTNEED, 2.6: REQUIRED
----------------------------------------
GCC 7.3.0 で MJIT を有効にしてみたところ、生成されたヘッダファイルがコンパイルエラーになるようです。

## GCC のバージョン
~~~
$ gcc --version
gcc (Gentoo 7.3.0-r3 p1.4) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
~~~

## 実行環境
~~~
$ uname -a
Linux localhost.localdomain 4.14.83-gentoo #3 SMP Mon Jan 7 13:56:38 JST 2019 x86_64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz GenuineIntel GNU/Linux
~~~

## サンプルコード(/tmp/t.rb)
~~~
def calculate(a, b, n = 40_000_000)
  n.times.count do
    a = a * 16807 % 2147483647
    b = b * 48271 % 2147483647

    (a & 0xffff) == (b & 0xffff)
  end
end

raise unless calculate(65, 8921) == 588
p result: calculate(699, 124)
~~~

## 実行結果
~~~
$ ruby --jit --jit-verbose=1 /tmp/t.rb
/tmp/_ruby_mjit_p18462u106.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u46.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u41.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u2.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u10.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u11.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u0.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u1.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u21.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u28.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u29.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u30.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u31.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u32.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u37.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u3.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u36.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u35.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u34.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u33.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u27.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u39.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u40.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u38.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u6.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u43.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u44.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u45.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u42.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u23.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u24.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u22.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u74.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u68.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u69.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u58.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u51.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u53.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u20.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u49.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u50.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u52.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u54.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u55.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u56.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u57.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u59.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u60.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u61.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u62.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u63.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u64.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u66.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u67.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u73.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u47.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u48.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u65.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u70.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u71.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u72.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u75.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u76.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u8.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u12.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u13.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u14.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u15.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u80.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u78.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u100.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u82.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u79.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u101.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u102.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u103.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u104.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u105.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u19.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u81.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u9.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u85.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u94.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u95.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u87.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u92.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u93.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u83.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u84.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u86.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u88.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u89.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u90.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u91.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u16.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u17.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u18.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u25.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u26.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u77.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u96.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u4.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u5.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u97.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u98.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u99.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u7.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
{:result=>600}
Successful MJIT finish
~~~

---Files--------------------------------
rb_mjit_min_header-2.6.0.h (873 KB)
_ruby_mjit_p23890u0.c (8.95 KB)


-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [ruby-dev:50765] [Ruby trunk Bug#15513] MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
       [not found] <redmine.issue-15513.20190107095256@ruby-lang.org>
                   ` (9 preceding siblings ...)
  2019-01-15  6:00 ` [ruby-dev:50764] [Ruby trunk Bug#15513] MJIT compilation terminated due to -Wfatal-errors " kajisha
@ 2019-01-15  6:01 ` kajisha
  2019-01-17 21:55 ` [ruby-dev:50766] " naruse
  11 siblings, 0 replies; 12+ messages in thread
From: kajisha @ 2019-01-15  6:01 UTC (permalink / raw)
  To: ruby-dev

Issue #15513 has been updated by kajisha (Hiroshi Kajisha).

ruby -v changed from ruby 2.7.0dev (2019-01-15 trunk 66823) [x86_64-linux] to ruby 2.6.0p0 (2018-12-25 revision 66547) [x86_64-linux] 

バージョンがかわってしまったので元にもどしました。

----------------------------------------
Bug #15513: MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
https://bugs.ruby-lang.org/issues/15513#change-76329

* Author: kajisha (Hiroshi Kajisha)
* Status: Closed
* Priority: Normal
* Assignee: k0kubun (Takashi Kokubun)
* Target version: 
* ruby -v: ruby 2.6.0p0 (2018-12-25 revision 66547) [x86_64-linux] 
* Backport: 2.4: DONTNEED, 2.5: DONTNEED, 2.6: REQUIRED
----------------------------------------
GCC 7.3.0 で MJIT を有効にしてみたところ、生成されたヘッダファイルがコンパイルエラーになるようです。

## GCC のバージョン
~~~
$ gcc --version
gcc (Gentoo 7.3.0-r3 p1.4) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
~~~

## 実行環境
~~~
$ uname -a
Linux localhost.localdomain 4.14.83-gentoo #3 SMP Mon Jan 7 13:56:38 JST 2019 x86_64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz GenuineIntel GNU/Linux
~~~

## サンプルコード(/tmp/t.rb)
~~~
def calculate(a, b, n = 40_000_000)
  n.times.count do
    a = a * 16807 % 2147483647
    b = b * 48271 % 2147483647

    (a & 0xffff) == (b & 0xffff)
  end
end

raise unless calculate(65, 8921) == 588
p result: calculate(699, 124)
~~~

## 実行結果
~~~
$ ruby --jit --jit-verbose=1 /tmp/t.rb
/tmp/_ruby_mjit_p18462u106.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u46.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u41.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u2.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u10.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u11.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u0.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u1.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u21.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u28.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u29.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u30.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u31.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u32.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u37.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u3.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u36.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u35.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u34.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u33.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u27.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u39.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u40.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u38.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u6.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u43.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u44.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u45.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u42.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u23.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u24.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u22.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u74.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u68.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u69.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u58.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u51.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u53.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u20.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u49.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u50.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u52.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u54.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u55.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u56.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u57.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u59.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u60.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u61.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u62.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u63.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u64.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u66.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u67.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u73.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u47.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u48.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u65.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u70.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u71.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u72.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u75.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u76.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u8.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u12.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u13.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u14.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u15.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u80.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u78.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u100.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u82.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u79.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u101.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u102.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u103.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u104.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u105.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u19.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u81.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u9.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u85.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u94.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u95.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u87.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u92.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u93.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u83.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u84.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u86.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u88.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u89.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u90.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u91.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u16.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u17.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u18.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u25.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u26.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u77.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u96.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u4.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u5.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u97.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u98.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u99.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u7.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
{:result=>600}
Successful MJIT finish
~~~

---Files--------------------------------
rb_mjit_min_header-2.6.0.h (873 KB)
_ruby_mjit_p23890u0.c (8.95 KB)


-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [ruby-dev:50766] [Ruby trunk Bug#15513] MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
       [not found] <redmine.issue-15513.20190107095256@ruby-lang.org>
                   ` (10 preceding siblings ...)
  2019-01-15  6:01 ` [ruby-dev:50765] " kajisha
@ 2019-01-17 21:55 ` naruse
  11 siblings, 0 replies; 12+ messages in thread
From: naruse @ 2019-01-17 21:55 UTC (permalink / raw)
  To: ruby-dev

Issue #15513 has been updated by naruse (Yui NARUSE).

Backport changed from 2.4: DONTNEED, 2.5: DONTNEED, 2.6: REQUIRED to 2.4: DONTNEED, 2.5: DONTNEED, 2.6: DONE

ruby_2_6 r66850 merged revision(s) 66817.

----------------------------------------
Bug #15513: MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0
https://bugs.ruby-lang.org/issues/15513#change-76378

* Author: kajisha (Hiroshi Kajisha)
* Status: Closed
* Priority: Normal
* Assignee: k0kubun (Takashi Kokubun)
* Target version: 
* ruby -v: ruby 2.6.0p0 (2018-12-25 revision 66547) [x86_64-linux] 
* Backport: 2.4: DONTNEED, 2.5: DONTNEED, 2.6: DONE
----------------------------------------
GCC 7.3.0 で MJIT を有効にしてみたところ、生成されたヘッダファイルがコンパイルエラーになるようです。

## GCC のバージョン
~~~
$ gcc --version
gcc (Gentoo 7.3.0-r3 p1.4) 7.3.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
~~~

## 実行環境
~~~
$ uname -a
Linux localhost.localdomain 4.14.83-gentoo #3 SMP Mon Jan 7 13:56:38 JST 2019 x86_64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz GenuineIntel GNU/Linux
~~~

## サンプルコード(/tmp/t.rb)
~~~
def calculate(a, b, n = 40_000_000)
  n.times.count do
    a = a * 16807 % 2147483647
    b = b * 48271 % 2147483647

    (a & 0xffff) == (b & 0xffff)
  end
end

raise unless calculate(65, 8921) == 588
p result: calculate(699, 124)
~~~

## 実行結果
~~~
$ ruby --jit --jit-verbose=1 /tmp/t.rb
/tmp/_ruby_mjit_p18462u106.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u46.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u41.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u2.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u10.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u11.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u0.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u1.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u21.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u28.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u29.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u30.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u31.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u32.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u37.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u3.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u36.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u35.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u34.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u33.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u27.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u39.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u40.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u38.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u6.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u43.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u44.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u45.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u42.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u23.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u24.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u22.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u74.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u68.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u69.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u58.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u51.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u53.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u20.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u49.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u50.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u52.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u54.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u55.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u56.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u57.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u59.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u60.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u61.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u62.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u63.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u64.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u66.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u67.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u73.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u47.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u48.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u65.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u70.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u71.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u72.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u75.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u76.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u8.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u12.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u13.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u14.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u15.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u80.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u78.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u100.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u82.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u79.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u101.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u102.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u103.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u104.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u105.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u19.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u81.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u9.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u85.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u94.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u95.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u87.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u92.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u93.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u83.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u84.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u86.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u88.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u89.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u90.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u91.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u16.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u17.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u18.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u25.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u26.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u77.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u96.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u4.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u5.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u97.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u98.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u99.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
/tmp/_ruby_mjit_p18462u7.c:1:39: error: one or more PCH files were found, but they were invalid
 #include "/tmp/_ruby_mjit_hp18462u0.h"
                                       ^
compilation terminated due to -Wfatal-errors.
{:result=>600}
Successful MJIT finish
~~~

---Files--------------------------------
rb_mjit_min_header-2.6.0.h (873 KB)
_ruby_mjit_p23890u0.c (8.95 KB)


-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2019-01-17 21:55 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <redmine.issue-15513.20190107095256@ruby-lang.org>
2019-01-07  9:52 ` [ruby-dev:50746] [Ruby trunk Bug#15513] MJIT compilation terminated due to -Wfatal-errors on GCC 7.3.0 kajisha
2019-01-07 10:08 ` [ruby-dev:50747] [Ruby trunk Bug#15513][Assigned] " hsbt
2019-01-07 10:29 ` [ruby-dev:50748] [Ruby trunk Bug#15513][Feedback] " takashikkbn
2019-01-07 10:40 ` [ruby-dev:50749] [Ruby trunk Bug#15513] " kajisha
2019-01-07 11:41 ` [ruby-dev:50750] " takashikkbn
2019-01-07 23:43 ` [ruby-dev:50751] " kajisha
2019-01-08 12:07 ` [ruby-dev:50752] " s.wanabe
2019-01-08 12:18 ` [ruby-dev:50753] [Ruby trunk Bug#15513][Assigned] " takashikkbn
2019-01-14  7:30 ` [ruby-dev:50762] [Ruby trunk Bug#15513] MJIT compilation terminated due to-Wfatal-errors " takashikkbn
2019-01-15  6:00 ` [ruby-dev:50764] [Ruby trunk Bug#15513] MJIT compilation terminated due to -Wfatal-errors " kajisha
2019-01-15  6:01 ` [ruby-dev:50765] " kajisha
2019-01-17 21:55 ` [ruby-dev:50766] " naruse

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).