News:

Function Finder  Find all the functions within source code files

Main Menu

I need a little bit of information on PB2DLL :-)

Started by cybermind, July 29, 2014, 10:32:07 AM

Previous topic - Next topic

cybermind

I have been reading about this PB2DLL on these forums for a while now but I still have some questions.

Would I be able to port nearly all of my source code to a DLL and then call that DLL from the main program/exe file thus get a faster program that can run on even smaller machines than my current exe (without PB2DLL) can? Or is this PB2DLL only for functions that are called from my main program?

Thanks in advance :-)

kevin

Quote from: cybermind on July 29, 2014, 10:32:07 AM

Would I be able to port nearly all of my source code to a DLL and then call that DLL from the main program/exe file thus get a faster program that can run on even smaller machines than my current exe (without PB2DLL) can? Or is this PB2DLL only for functions that are called from my main program?


    Yep.. it's possible to convert entire programs into a single or multiple dlls.    While possible, it's not recommended though, as the behavior of the some internal commands such as SYNC are different (among others) and may lead to all sorts of problems.

    The recommended approach is to break the program down into independent stand alone library modules.  Then build DLL's from those chunks.   This means the libraries needs to be stand alone, so they can  be compiled separately.    The size of the libs can be as  big or small as you like.  You could pack lots of stuff into a library or only a few key functions.

    In terms of execution speed.. well that depends really, obviously translating it is more efficient, but those benefits might be analogous to optimizing the 'joy stick' stick code in some programs (ie point loss).   Programs/routines that are mostly CPU bound are will see a huge improvement, where as code that's largely GPU bound not so much.