Re: [Lazarus] Startup delay of project (Qt)

2015-03-07 Thread Vojtěch Čihák

Thanks,
 
setting DisableLoadSymbolsForLibraries to True did the job. Now I'm on ~2 
seconds, it is usual time on my Core2Duo @2GHz.
 
V.
 
__

Od: Martin Frb laza...@mfriebe.de
Komu: Lazarus mailing list lazarus@lists.lazarus.freepascal.org
Datum: 07.03.2015 18:10
Předmět: Re: [Lazarus] Startup delay of project (Qt)


On 07/03/2015 11:37, Vojtěch Čihák wrote:
  
Hi,
  
I have noticed that Qt projects started with F9 have a delay (about ~12 seconds) before the form appears.

Its not only with large projects, its also with small projects or even empty 
forms.
  
The delay is there even if nothing in project changes and I start it by F9 repeatedly.

When I try to execute the same project externally (from Double Commander), it 
starts in ~ 0,3 s.
  
When i switch to GTk2, the startup is within 2 second (from IDE), which is normal.
  


Just a wild guess.
GDB checks libraries loaded. So depending on the info found on qt libs 
that may take time.


Try 
http://wiki.lazarus.freepascal.org/GDB_Debugger_Tips#internal-error:_clear_dangling_display_expressions http://wiki.lazarus.freepascal.org/GDB_Debugger_Tips#internal-error:_clear_dangling_display_expressions

set the field DisableLoadSymbolsForLibraries to True

Or check in options/debugger/event log what is logged.  Disable Module

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus 
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Startup delay of project (Qt)

2015-03-07 Thread Vojtěch Čihák

How can I detect it?
 
I have Qt 4.8.6 from repositories, it should be standart stable version for 
end-users.
__

Od: Martin Frb laza...@mfriebe.de
Komu: Lazarus mailing list lazarus@lists.lazarus.freepascal.org
Datum: 07.03.2015 18:44
Předmět: Re: [Lazarus] Startup delay of project (Qt)


Is it possible your qt libs have debug info? that might take gdb time to parse 
(and eat memory too).

Of course, with the above options, you can not debug inside libraries.


--

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus 
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Startup delay of project (Qt)

2015-03-07 Thread Martin Frb

On 07/03/2015 18:00, Vojtěch Čihák wrote:


How can I detect it?

I have Qt 4.8.6 from repositories, it should be standart stable 
version for end-users.


__
 Od: Martin Frb laza...@mfriebe.de
 Komu: Lazarus mailing list lazarus@lists.lazarus.freepascal.org
 Datum: 07.03.2015 18:44
 Předmět: Re: [Lazarus] Startup delay of project (Qt)


Is it possible your qt libs have debug info? that might take gdb time 
to parse (and eat memory too).


Of course, with the above options, you can not debug inside libraries.



Not sure objdump maybe?

I dont know if it is debug info.gdb also reads entrypoints and maybe 
other things.  But since it seems that not everyone has that issue, the 
question is what is different (not really importiant since the problem 
is solved).


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Startup delay of project (Qt)

2015-03-07 Thread Vojtěch Čihák
Thanks.
 
I execued Lazarus in strace but no it gives no special output.
 
TExternalTool.DoExecute Title=Compile Project, Mode: Default, Target: 
project1 Process.CurrentDirectory=/home/v1/tmp/ 
Executable=/usr/local/bin/fpc Params:
-Tlinux
-Px86_64
-MObjFPC
-Shi
-Cg
-g
-gl
-gh
-l
-vewnhibq
-Fiinclude
-Filib/x86_64-linux
-Fu.
-Fu/home/v1/Lazarus_Qt/lazarus/lcl/units/x86_64-linux/qt
-Fu/home/v1/Lazarus_Qt/lazarus/lcl/units/x86_64-linux
-Fu/home/v1/Lazarus_Qt/lazarus/components/lazutils/lib/x86_64-linux
-Fu/home/v1/Lazarus_Qt/lazarus/packager/units/x86_64-linux
-FUlib/x86_64-linux/
-dLCL
-dLCLqt
-godwarfsets
/home/v1/tmp/project1.lpr
 
[TCompiler.Compile] end
TMainIDE.DoBuildProject compiler time in s: 3,04200032260269
TMainIDE.DoInitProjectRun ProgramFilename=/home/v1/tmp/project1
[TMainIDE.DoRunProject] Debugger=TGDBMIDebugger
[TMainIDE.DoRunProject] END
TGDBMIDebugger.StartDebugging WorkingDir=/home/v1/tmp/
However, I noticed that when I run project in xterm (via Run parameters ... - 
Use launching application), execution is much faster.
 
Also, I tried add 'strace' to command:
 
/usr/bin/xterm -T  'strace Lazarus Run Output' -e 
$(LazarusDir)/tools/runwait.sh $(TargetCmdLine)
 
It also executes project quickly, but gives no output.
 
V.
__
 Od: zeljko zel...@holobit.net
 Komu: Lazarus mailing list lazarus@lists.lazarus.freepascal.org
 Datum: 07.03.2015 16:48
 Předmět: Re: [Lazarus] Startup delay of project (Qt)


Maybe strace could help.

zeljko

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Startup delay of project (Qt)

2015-03-07 Thread Martin Frb

On 07/03/2015 11:37, Vojtěch Čihák wrote:
  
Hi,
  
I have noticed that Qt projects started with F9 have a delay (about ~12 seconds) before the form appears.

Its not only with large projects, its also with small projects or even empty 
forms.
  
The delay is there even if nothing in project changes and I start it by F9 repeatedly.

When I try to execute the same project externally (from Double Commander), it 
starts in ~ 0,3 s.
  
When i switch to GTk2, the startup is within 2 second (from IDE), which is normal.
  


Just a wild guess.
GDB checks libraries loaded. So depending on the info found on qt libs 
that may take time.


Try 
http://wiki.lazarus.freepascal.org/GDB_Debugger_Tips#internal-error:_clear_dangling_display_expressions

set the field DisableLoadSymbolsForLibraries to True

Or check in options/debugger/event log what is logged.  Disable Module

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Startup delay of project (Qt)

2015-03-07 Thread Martin Frb

On 07/03/2015 17:31, Vojtěch Čihák wrote:


Thanks,

setting DisableLoadSymbolsForLibraries to True did the job. Now I'm on 
~2 seconds, it is usual time on my Core2Duo @2GHz.





Is it possible your qt libs have debug info? that might take gdb time to 
parse (and eat memory too).


Of course, with the above options, you can not debug inside libraries.
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Startup delay of project (Qt)

2015-03-07 Thread Giuliano Colla

Il 07/03/2015 12:37, Vojtěch Čihák ha scritto:
  
Hi,
  
I have noticed that Qt projects started with F9 have a delay (about ~12 seconds) before the form appears.

Its not only with large projects, its also with small projects or even empty 
forms.
  
The delay is there even if nothing in project changes and I start it by F9 repeatedly.

When I try to execute the same project externally (from Double Commander), it 
starts in ~ 0,3 s.
  

[...]
  
I use Lazarus 1.5 r48159M FPC 3.1.1 x86_64-linux-qt, Qt 4.8.6.


In a similar setup, only with a slightly  older Qt (4.7.4), I don't 
experience the same problem. Qt startup with F9 is a bit slower than 
GTK2, but within reasonable limits (3 - 4 seconds). A Qt issue?


Giuliano

--
Giuliano Colla

Project planning question: when it's 90% done, are we halfway or not yet?


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Startup delay of project (Qt)

2015-03-07 Thread zeljko

On 03/07/2015 12:37 PM, Vojtěch Čihák wrote:


Hi,

I have noticed that Qt projects started with F9 have a delay (about ~12 
seconds) before the form appears.
Its not only with large projects, its also with small projects or even empty 
forms.

The delay is there even if nothing in project changes and I start it by F9 
repeatedly.
When I try to execute the same project externally (from Double Commander), it 
starts in ~ 0,3 s.

When i switch to GTk2, the startup is within 2 second (from IDE), which is 
normal.

I tried to run Lazarus from console, the last output is:

TGDBMIDebugger.StartDebugging 
WorkingDir=/media/disk/v1/Projects/Components/DividerBevelStyle/

and then it hangs.
The output of Qt and GTk2 doens't differ.

I use Lazarus 1.5 r48159M FPC 3.1.1 x86_64-linux-qt, Qt 4.8.6.

I tried to install former revision, I went 1000 commits back but the issue 
persisted.


Maybe strace could help.

zeljko


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus