Emolas Posted April 25, 2016 Share Posted April 25, 2016 So I have a script of about 1100 or so lines with several includes and other stuff making the .au3 about 45kb that compiles to 364KB. I have another 1KB script of ONE LINE "run(program.exe /q)" that compiles to 760KB. I'm completely baffled as to why that would be. Like I said in the title, the size isn't a problem but it is very weird and I was wondering if anyone knew why something like this might occur. Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted April 25, 2016 Moderators Share Posted April 25, 2016 Emolas, I imagine that you have the upx file compressor activated for the first script. How are you compiling them? M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
Emolas Posted April 25, 2016 Author Share Posted April 25, 2016 Both are using UPX. I did discover the smaller one was x86 and the larger was x64 so that had something to do with it. Compiling the single line script in x86 shrunk it to 396KB but that still seems inordinately large especially when comparing it to another script 45X larger with probably 2000X the amount of code. Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted April 25, 2016 Moderators Share Posted April 25, 2016 Emolas, Remember that the code itself is a very small fraction of the overall executable - the majority by far is the built-in interpreter. I have 2 compiled scripts: the first has some 8000 lines and a good few additional icons; the second is only a few hundred lines - the difference when compiled is a mere 50k. it is the price you pay for stand-alone executables. M23 Emolas 1 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
Developers Jos Posted April 25, 2016 Developers Share Posted April 25, 2016 54 minutes ago, Emolas said: larger was x64 Don't think upx is done for x64 executables as yet. Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Trong Posted April 25, 2016 Share Posted April 25, 2016 1TB Hard Drive now cheaper and very popular. 1MB program is acceptable (: Regards, Link to comment Share on other sites More sharing options...
alien4u Posted April 25, 2016 Share Posted April 25, 2016 (edited) 3 hours ago, VIP said: 1TB Hard Drive now cheaper and very popular. 1MB program is acceptable (: That is different based on the final deploy environment, if the final user have to download that or have to update that with a 54kbs dial-up connection then 1MB is not so acceptable for only 1 line of code. Anyways like @Melba23 point is the price you pay for stand-alone executables. One thing I like most about AutoIt is in fact this, because you don't need Microsoft Runtimes or anything, just Windows. Regards Alien. Edited April 25, 2016 by alien4u Fix typo Link to comment Share on other sites More sharing options...
Emolas Posted April 26, 2016 Author Share Posted April 26, 2016 20 hours ago, Jos said: Don't think upx is done for x64 executables as yet. Jos it has a check box in the compiler. Whether it actually does anything or not I couldn't tell you. Size really isn't an issue I was just interested at the fact that a one line script compiled was larger than a 3000 line one. I had already chalked it up to one of those "weird things programs do" but figured I would ask if anyone had any solid reasons as to why just to satisfy my curiosity. Common sense would say that the size difference between a 45 kb file and a 1 kb file would be 44 kb since they would both need the same interpreters and stuff so the smaller file compiling larger than the other one threw me. Thanks for all the answers. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now