Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
Mono organizations on
GitHub to continue tracking issues. Bugzilla will remain
available for reference in read-only mode. We will continue to work
on open Bugzilla bugs, copy them to the new locations
as needed for follow-up, and add the new items under Related
Our sincere thanks to everyone who has contributed on this bug
tracker over the years. Thanks also for your understanding as we
make these adjustments and improvements for the future.
Please create a new report on
GitHub or Developer Community with
your current version information, steps to reproduce, and relevant error
messages or log files if you are hitting an issue that looks similar to
this resolved bug and you do not yet see a matching new report.
Created attachment 25047 [details]
native so with 65537 exported functions and dotnet that imports them and try to call latest
Its impossible to call 65536 imported function and above. Works fine on .Net Framework 4.
Platform: Ubuntu 16. Can reproduce on master and 18.104.22.168.
I created the minimal example to reproduce the bug. big_dllexport.c gives the native library with 65537 exported functions. Each of the function prints a unique number. dllimport.cs imports them all and calls ExportedFunc65537 function, which suppose to print 65537, but instead you get 1.
The attached archive contains three files. build.sh describes how to compile both native so and mono app. Run ./dllimport after compilation to see the unexpected output.
Fixed by mono master 9369ed6e23ee9e822a3aa2318ed55f083241fbcb.