s196675m
February 29th, 2008, 09:12 PM
My GUI application called a function in a library (image processing library) but it takes 20 to 30 times more time to execute this function when comparing to the time required when calling standalone .exe file.
Both library and GUI compiled with managed c++ (pure:clr) and in the GUI there is a reference for the library as a additional dependencies in the linker input.
When I make .exe (using pure:MSIL) file instead of .lib and run from command line passing the required argument is just take one to one and half minute to execute it .
When I make the library file (bypassing the main function) from the same source code and calling the function from GUI takes arround 20 to 30 minutes. The source code for the library orginially written in C/C++ but I compiled it using manged c++ pure MSIL to match with the GUI.
Compilation and linking everything is fine and I can not find and explain the cause of 20 to 30 times slow running when library is used.
Is there anybody here in this forum help me or explain the possible cause of slow running.
Any idea, link, suggestion will be highly appreciated.
Thank you.
Both library and GUI compiled with managed c++ (pure:clr) and in the GUI there is a reference for the library as a additional dependencies in the linker input.
When I make .exe (using pure:MSIL) file instead of .lib and run from command line passing the required argument is just take one to one and half minute to execute it .
When I make the library file (bypassing the main function) from the same source code and calling the function from GUI takes arround 20 to 30 minutes. The source code for the library orginially written in C/C++ but I compiled it using manged c++ pure MSIL to match with the GUI.
Compilation and linking everything is fine and I can not find and explain the cause of 20 to 30 times slow running when library is used.
Is there anybody here in this forum help me or explain the possible cause of slow running.
Any idea, link, suggestion will be highly appreciated.
Thank you.