Results 1 to 8 of 8

Thread: Can DLL's speed up my App.?

  1. #1

    Thread Starter
    Fanatic Member kinjalgp's Avatar
    Join Date
    Apr 2000
    Location
    India
    Posts
    535

    Lightbulb

    Does use of DLL's make my application run faster than using standard modules and procedures?


    Kinjal

  2. #2
    Hyperactive Member
    Join Date
    Mar 2000
    Location
    Boulder, Colorado, USA
    Posts
    325
    Yeah makes your code faster to write. =) That's the purpose of a DLL. DLL's make your exe file smaller and allows for more code re-use.
    -Shickadance

  3. #3
    Guest
    It also makes it faster by allowing other of your Apps to use it as well. (So you don't have to program the same thing in every app, you just get it from the dll)

  4. #4
    Fanatic Member
    Join Date
    Feb 2000
    Location
    Japan
    Posts
    840
    MAYBE...

    In App speed though it depends what your calculating.

    If you have a highly optimised C Dll and you call it once and it spends time calculating then returns, Probably.

    BUT, if you have a DLL that a loop continually calls then the overhead of calling the dll can be higher than the performance increase.

    So it depends on what it does. A sorting algorithm is more likely to be quicker that way than VB, but a Dll that just returns the sum of two vars is more likely to be quicker in just VB once you figure in the call time.

    Paul Dwyer
    Network Engineer
    Aussie In Tokyo

    Using Powerbasic 6 & VB6 SP4 (Please also add your VB Version to your signature!)

  5. #5

    Thread Starter
    Fanatic Member kinjalgp's Avatar
    Join Date
    Apr 2000
    Location
    India
    Posts
    535
    So can I use DLL's instead of modules in my application?


    Kinjal

  6. #6
    Fanatic Member
    Join Date
    Feb 2000
    Location
    Japan
    Posts
    840
    Are you talking normal Dlls or ActiveX dlls?

    Either way the answer is... (to Quote Hunt for Red October)

    ..."Sure, Why would you want to?"

    Paul Dwyer
    Network Engineer
    Aussie In Tokyo

    Using Powerbasic 6 & VB6 SP4 (Please also add your VB Version to your signature!)

  7. #7
    transcendental analytic kedaman's Avatar
    Join Date
    Mar 2000
    Location
    0x002F2EA8
    Posts
    7,221
    I would use modules as much as possible and leave dll's, as dll's can be used by others, and make your app looks like "borrowing code". Of course there is fusioning dll's, but that makes no sense having external dll's an just fusion them again. And for the performance thing, there's probably no performance gain in having stored your functions made in vb in a dll instead of a module.
    Use
    writing software in C++ is like driving rivets into steel beam with a toothpick.
    writing haskell makes your life easier:
    reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
    To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.

  8. #8
    Fanatic Member
    Join Date
    Feb 2000
    Location
    Japan
    Posts
    840
    Do you mean that crappy Fusion program?

    (assuming you do)
    I got the demo and had a look, It's not real static linking (maybe), it's the whole dll tacked onto the back of the exe in compressed form as far as I can guess.

    What do you think?

    VB6 runtime dll = 1.3 mb
    My app = 0.1 mb
    Total = 1.4 Mb

    Winzip (or cabs) compresses this 57%
    New size = 800k

    Fusion of the app = 900k
    Winzip fusion of the app = 880k (3% in winzip)

    There seems to be compression happening here as an exe usually gets 40-60% compression in winzip, not 3%

    very suspicious
    Paul Dwyer
    Network Engineer
    Aussie In Tokyo

    Using Powerbasic 6 & VB6 SP4 (Please also add your VB Version to your signature!)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width