Mono AOT をテストしたかったので、MonoDevelop で簡単なコンソール アプリケーションを作成しました。
using System;
namespace abc
{
public class Program
{
public static void Main()
{
Console.WriteLine("Hello World!");
}
}
}
bin/debug に「abc.exe」という名前のファイルが作成されました。私がやろうとすると:
mono abc.exe
出来た。というわけでAOTしてみました。やった:
mono --aot abc.exe
abc.exe.so という名前のファイルが作成されました。起動しようとすると、「Segmentation fault (core dumped)」エラーがスローされます。mono --aot の出力は次のとおりです。
Code: 51 Info: 5 Ex Info: 8 Unwind Info: 31 Class Info: 30 PLT: 2 GOT Info: 11 GOT Info Offsets: 16 GOT: 20 Offsets: 48
Compiled 2 out of 3 methods (66%)
1 methods have other problems (33%)
Methods without GOT slots: 1 (33%)
Direct calls: 0 (100%)
JIT time: 1 ms, Generation time: 0 ms, Assembly+Link time: 0 ms.
どうすれば修正できますか?
ありがとう。