Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Compiler Running Slow, could my source code be too long ?

Author
Message
DemonHill
18
Years of Service
User Offline
Joined: 20th Mar 2008
Location:
Posted: 10th Aug 2010 22:51
I have a program over 11800 lines long. The Compile time has recently gone from 10 seconds to between 30-45 secs.

If my program to big ?

Any options or optimization I can make to the editor ?
(Code pretty well optimized)

Any help appreciated as editing has now become more painful.

Thx
DVader
22
Years of Service
User Offline
Joined: 28th Jan 2004
Location:
Posted: 10th Aug 2010 23:42 Edited at: 10th Aug 2010 23:44
It depends on what your code is doing I would imagine. If it has only recently jumped up, that is a little odd. I would think the compile time would relate to program size and complexity. I am guessing that different commands will be of varying levels of complexity in the final c+ code, so maybe you have added in a bunch of more complicated commands of late?
Also do you mean the compile time or the actual time to compile and then run? Obviously the more media and such you add the slower it will be to load. Any programs I have been done that are that size or larger tend to have a lot of media which always makes them a little slow when testing.

http://s6.bitefight.org/c.php?uid=103081
Indicium
18
Years of Service
User Offline
Joined: 26th May 2008
Location:
Posted: 11th Aug 2010 00:37
Dbpro is arranged into plugins, each plugin controls different things. I'm not sure what different ones there are( look in your plugins folder ), but the more of them you utilize, the more time i suspect it takes to compile.

MASTER OF PUPPETS
22
Years of Service
User Offline
Joined: 9th Jun 2004
Location: Trapped Under Ice
Posted: 11th Aug 2010 01:54
Unless you have done something to your computer ASIDE from DBPRO...

I installed "Microsoft Security Essentials" recently and that immediately hacked my computers speed to less than half when I try to compile.

metal is not music but a way of life...all hail to the reigning king METALLICA!!! [EDIT] ...well... up until "Load" came out.
Neuro Fuzzy
19
Years of Service
User Offline
Joined: 11th Jun 2007
Location:
Posted: 11th Aug 2010 03:18
The compiler isn't runnning slow, there's just more to compile.
For big projects, there's a crap load of stuff to do.

My dad programs data management stuff - he showed me when he built a version of the software with a bug patch - it took ~10 minutes, and the compiler software was using all the cores on different idle computers in the building (about 20). Of course that's massive software, but i'd say in this case there probably isn't a compiler mess up or anything. The compiled application still runs the same right?


Is't life, I ask, is't even prudence, to bore thyself and bore thy students?
tiresius
23
Years of Service
User Offline
Joined: 13th Nov 2002
Location: MA USA
Posted: 11th Aug 2010 07:15
I'll just use this as a soapbox to vent that I wish the compiler was faster for DBPro. How can someone write large software projects in it when it takes 60+ seconds to compile a small change? PlayBasic compiler is very fast, perhaps Kevin could give Lee some pointers for source code parsing? Just saying...


A 3D marble platformer using Newton physics.
Neuro Fuzzy
19
Years of Service
User Offline
Joined: 11th Jun 2007
Location:
Posted: 11th Aug 2010 08:35
I do believe with my zero experience that compile times have always been an a very very annoying thing to the developer.


Is't life, I ask, is't even prudence, to bore thyself and bore thy students?
Mobiius
Valued Member
23
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 11th Aug 2010 09:01
Consider yourselves lucky. The compile time for the first black and white game was over an hour.

My signature is NOT a moderator plaything! Stop changing it!
BatVink
Moderator
23
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 11th Aug 2010 10:29
"could my source code be too long"

The answer to that part is no. It's compiling, and 11,800 line is not very big at all. I have much bigger projects and I believe FPSC is around 30,000 lines.

I have noticed that sometimes my code compiles much faster than other times, with very little change. Maybe it's a memory management issue.

=PRoF=
23
Years of Service
User Offline
Joined: 17th Mar 2003
Location: Milton Keynes, UK
Posted: 11th Aug 2010 12:31
45 secs doesn't seem a very long time to me...

Count yourself lucky

Green Gandalf
VIP Member
21
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 12th Aug 2010 00:40 Edited at: 12th Aug 2010 00:41
I think you should all count yourselves lucky.

When I was a student we had to type out our programs on to punch cards. Then fasten them together in the correct order with an elastic band and put them in the in-tray in the computer department.

One or two days later we would return to collect our cards plus a few sheets of lineprinter paper output unless our programs failed to compile in which case we just had an error code printed on the card (not sure now what form the error report took - it WAS a LONG time ago ).

Programs could fail because of a "parity error" (e.g. one of the punched holes hadn't had the card removed cleanly) or a more familiar "syntax error" (very often something silly like a colon [ : ] instead of a semicolon [ ; ]). You would then have to type out the offending card(s) again and re-submit your job - and wait another 1 or 2 days. .

Each punched card corresponded to a line of 80 characters - the first 8 often being reserved for line numbers, etc. There was also paper tape which may or may not have been a step forward (I forget which now ).

I now get annoyed if I have to wait for my programs to compile. Perhaps I'm just getting old and impatient?

Login to post a reply

Server time is: 2026-07-25 23:11:57
Your offset time is: 2026-07-25 23:11:57