Author |
Topic: File or path not found at line 0 Error? (Read 451 times) |
|
Coda
New Member
member is offline


Gender: 
Posts: 3
|
 |
Re: File or path not found at line 0 Error?
« Reply #3 on: Jul 3rd, 2016, 05:21am » |
|
Thanks for the advice, Richard. I think I know what is happening with the slowing issue. I took your advice and ran the profiler. The main calculations loop of my program has quite a number of print statement so that I can easily debug as working. When you issue the nomainwin directive in standard LB, these are ignored by the runtime engine and the program speeds up dramatically as if they are not there and only slows down again when you allow a mainwin for debugging. According to the profiler, LBB is not ignoring these and still executing them in the absence of a main window and taking up valuable processor time. I can remove them or rem them to solve this but it might be worth making LBB ignore these if a nomainwin directive is issued if it's possible to do and if you plan any updates. I often program like this as I find debuggers very cumbersome and I often only need to know the value of 1 or 2 specific variables at one specific point to work out what is going wrong. So it's very easy to print it to a main window and then remove these lines before compilation or tokenisation. Perhaps it's a bad habit of mine but as I learnt to program prior to anything resembling a debugger became standard, it's force of habit that isn't going to change at this point...
That said, I'm not sure removing them will still make it much FASTER than LB though... but it will likely bring it to a comparable speed.
As for the relative paths problem, I am still trying to work that one out. I will report back what I find if anything.
|
| « Last Edit: Jul 3rd, 2016, 05:28am by Coda » |
Logged
|
|
|
|
Richard Russell
Administrator
member is offline


Posts: 1348
|
 |
Re: File or path not found at line 0 Error?
« Reply #4 on: Jul 3rd, 2016, 10:41am » |
|
on Jul 3rd, 2016, 05:21am, Coda wrote:| my program has quite a number of print statement so that I can easily debug as working... According to the profiler, LBB is not ignoring these |
|
That's very interesting, and it isn't something I have considered previously. In LBB nomainwin only hides the main window, it does not actually close it, so as you say any print statements still execute and they may take a significant amount of time.
I don't think there's an easy way for me to fix this, at least for programs running in the IDE. As things stand, in LBB you can debug a program without having to 'recompile' it, and because the debugger overrides the presence of nomainwin I need any print statements to be active. In principle I could automatically delete the print statements in a program compiled to an EXE which would solve the problem, but you'd have to accept a slow-running program when run in the IDE.
Quote:| That said, I'm not sure removing them will still make it much FASTER than LB though... but it will likely bring it to a comparable speed. |
|
If your program outputs a fair amount of graphics you may find that using the technique described in this wiki article speeds things up somewhat.
Richard.
|
|
Logged
|
|
|
|
|