Inertia's picture

Offtopic: ODE and OpenMP

Hello,

there's no hostile intend to spam your forum with Tao related questions, but i have no idea where else to ask since the "create topic" function at the Tao forum appears broken.

This time it's about ODE, is that part of Tao still alive? Should one rather use the Ode.Net bindings from their website, rather than Tao.Ode? The main reason for this question is, that i found that Tao.Ode.dContact and Tao.Ode.dContactGeom structs have no layout specified in the bindings, which is dangerous since ODE writes directly into these structs and also requires a stride parameter to indicate the size of the struct. Ode.Net has those layouts specified and binds ODE 0.9, while the Tao bindings seem to use ODE 0.6?

I'm really not obsessed with using the latest bleeding-edge builds, it's just that the missing layout could potentially lead to very hard to track errors which i try to avoid (if i would enjoy debugging, i'd code C++) :p

-----------------------------------------------------

Theres another topic I tried to post at the Tao forums, it's not really related to Tao but might be of interest for Tao users.
Here's copy&paste of the post:

For some this might be old news, but since most of you don't speak german I think it might be worth mentioning. I haven't found other info on this topic, so maybe this will help some of you.

Some time ago, there has been a webcast about using OpenMP _without_ implementing the loops themselves in C++. The idea behind it is that you can write your methods in C# as anonymous delegates and only write a simple C++ function to accept the delegate as parameter, that will be executed in parallel.

Webcast:
http://www.microsoft.com/germany/msdn/webcasts/library.aspx?id=103234100...

Source Code Examples from the Webcast: ( click "Webcast: OpenMP mit C#? - Demos" )
http://www.gosky.de/dotNet/default.htm

-Inertia


Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
the Fiddler.'s picture

I'm not sure what's the matter with the Tao forums, but they have been quite unstable these last two months. I'll fire an email to jendave to see if he knows what's going on. Anyhow,

This time it's about ODE, is that part of Tao still alive? Should one rather use the Ode.Net bindings from their website, rather than Tao.Ode?
I think it's better to switch to the Ode.Net bindings. I think this was discussed around the Tao 2.0 timeframe, and was decided that Tao.Ode would stop being maintained in favor of Ode.Net. The actual thread isn't available anymore (lost in some database purge of the forums), but the last commit was more than 9 months ago.

Some time ago, there has been a webcast about using OpenMP _without_ implementing the loops themselves in C++. The idea behind it is that you can write your methods in C# as anonymous delegates and only write a simple C++ function to accept the delegate as parameter, that will be executed in parallel.
That's quite cool! This opens some interesting possibilities; do you know how well it works with gcc+Mono?

Inertia's picture

Thanks for forwarding the issue. I've mentioned it in the Tao forum in a reply, but kinda ended the whole discussion when pointing out the mistakes and suggesting to the guy to read a book about OpenGL...

[ODE]
Thanks again, that was my assumption.

[OpenMP]
Neither tried gcc nor mono so far, so cannot really comment on that. My guess is as long as you write managed C++ code it will probably work tho. For further reading I recommend www.devx.com. There are some interesting articles about parallel computing, a few of them were actually written by an Intel engineer, rather informative imho.

I've tried to compile the example code with Visual C++ 2005 Express Edition, but it seems the OpenMP pragmas are only supported with the commercial Visual Studio 2005 .NET and it wouldn't build properly. After trying a trial version of Intel's C compiler I decided this is way too much hassle for my current project and kinda put this on hold. Anyway, some Tao users may have a compiler that properly builds the program and put this to some use. I just posted this because it might be not obvious that such a technique exists, and reducing the C++ part of your application to a minimum might make OpenMP alot more interesting for some people.

the Fiddler.'s picture

Good link, lots of interesting stuff there. Added to bookmarks.