[Mono-list] [Gtk-sharp-list] pinvoke and benchmarks
Martin (OPENGeoMap)
martin at opengeomap.org
Tue Sep 16 09:12:37 EDT 2008
Hi:
> On Fri, Sep 12, 2008 at 11:22 AM, Martin (OpenGeoMap)
> <martin at opengeomap.org> wrote:
>
>> is it better used a library only created with C or the pinvoke is fast???
>> In my imagination i see the pinvoke system trying to find a funtion
>> every time and if i have 10 million of lidar data perhaps this is really
>> slowly....
>>
>
> I doubt that Mono is so dumb that it doesn't remember function entry
> points. More likely, it's taking some time to marshal data over the
> managed boundary.
>
I would like know like MONO and .NET do this job.
> Without seeing any code it's going to be difficult to diagnose
> anything. Note that things like Gtk# make heavy use of p/invoke and
> seem fairly fast, so I don't think the use of p/invoke alone is the
> problem.
>
Here is the CAPI in csharp:
http://liblas.org/browser/trunk/csharp/dotnetLibLAS/LibLASCAPI.cs
Here a module in c# creating the classes:
http://liblas.org/browser/trunk/csharp/dotnetLibLAS/LASPoint.cs
Here the C API:
http://liblas.org/browser/trunk/src/las_c_api.cpp
This library was created in C++ with exceptions, namespaces, overloads,
etc, etc...
The C API broke this C++ API in a C API.
> (Also, this question would be better directed to the main Mono mailing
> list, as it has nothing to do with Gtk#.)
>
>
Yes. thank you for redirect the mono list.
Regards.
More information about the Mono-list
mailing list