Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2009-06

No target CPU's in combobox dropdown

8 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Graeme Geldenhuys

Hi,

I tried to rebuild Lazarus IDE and add some optimisation settings like SSE2 and Pentium4.

In the "Tools > Configure Build Lazarus > Advanced > Target CUP" there are no options in the combobox to select from. See attached screenshot.

I'm using Lazarus 0.9.27 r20538 FPC 2.2.5 i386-linux-gtk2. I got a update about 2 hours ago.

Also, where do I specify the -Cfsse2 option? In the Advanced tab, "Options" edit box?

Regards, - Graeme - _______________________________________________________ fpGUI - a cross-platform GUI toolkit using Free Pascal http://opensoft.homeip.net/fpgui/ -------------- next part -------------- A non-text attachment was scrubbed... Name: Screenshot-Build Lazarus.png Type: image/png Size: 4080 bytes Desc: not available URL: <http://lists.lazarus.freepascal.org/pipermail/lazarus/attachments/20090609/02495079/attachment.png>

Reply by email

Vincent Snijders
to Graeme Geldenhuys
Graeme Geldenhuys wrote
Hi, In the "Tools > Configure Build Lazarus > Advanced > Target CUP" there are no options in the combobox to select from. See attached screenshot.

That is right. It should be a textbox like the target os, until somebody creates a list of target cpus.

Also, where do I specify the -Cfsse2 option? In the Advanced tab, "Options" edit box?

Correct.

Vincent

Reply by email

Graeme Geldenhuys
to Vincent Snijders
Vincent Snijders wrote
That is right. It should be a textbox like the target os, until somebody creates a list of target cpus.

But if I go to any of my own projects... "Projects > Compiler Options > Code > Target CPU combobox" I _do_ see a list of options to select from. So if Projects can have those options populated, then why can't the IDE project build options as well?

> Also, where do I specify the -Cfsse2 option? In the Advanced tab, > "Options" edit box? Correct.

Thanks. In the mean time, I used that edit box for the CPU type as well.

Regards,
- Graeme -

_______________________________________________________ fpGUI - a cross-platform GUI toolkit using Free Pascal http://opensoft.homeip.net/fpgui/

Reply by email

Vincent Snijders
to Graeme Geldenhuys
Graeme Geldenhuys wrote 9 lines
Vincent Snijders wrote: > That is right. It should be a textbox like the target os, until somebody > creates a list of target cpus. But if I go to any of my own projects... "Projects > Compiler Options > Code > Target CPU combobox" I _do_ see a list of options to select from. So if Projects can have those options populated, then why can't the IDE project build options as well?

Because the developer that committed that part of the build lazarus dialog didn't think about it, or did not find an easy way to retrieve that list or was just lazy.

Vincent

Reply by email

Graeme Geldenhuys
to Vincent Snijders
Vincent Snijders wrote
dialog didn't think about it, or did not find an easy way to retrieve that list or was just lazy.

I implemented the missing functionality. TargetCPU now gets populated and I also added a new option Target Processor - the same as is done in Project > Compiler Options.

http://bugs.freepascal.org/view.php?id=13941

Sorry for the large patch. The Lazarus Form Designer created a lot of noise which mean the patch is larger than normal. Because of that I included the full *.pas, *.lrs and *.lfm files as well, if that will make applying the code easier.

Regards, - Graeme - _______________________________________________________ fpGUI - a cross-platform GUI toolkit using Free Pascal http://opensoft.homeip.net/fpgui/

Reply by email

Vincent Snijders
to Graeme Geldenhuys
Graeme Geldenhuys wrote 8 lines
Vincent Snijders wrote: > dialog didn't think about it, or did not find an easy way to retrieve > that list or was just lazy. I implemented the missing functionality. TargetCPU now gets populated and I also added a new option Target Processor - the same as is done in Project > Compiler Options.

Thanks. That is what I hoped for. :-)

I am not sure adding yet an extra option on that page is a good idea. May for such a rarely used option as Target Processor an extra option and not for an option that I use often like -gh or -O1. I would leave the Target Process (optimization option) out and if people using i386 want to add they can do so in the options textbox. It is the advanced tab page, so advanced users may be expected.

Vincent

Reply by email

Graeme Geldenhuys
to Vincent Snijders
Vincent Snijders wrote
Thanks. That is what I hoped for. :-)

We (normal users of Lazarus IDE) can't expect you guys to do everything. :-)

I am not sure adding yet an extra option on that page is a good idea.

Now you tell, after all the struggle to get it implemented. :-( I just thought, seeing that it is in the Project > Compiler Options, why not add it to the LazBuildDlg as well. After all, I would like to have my copy of Lazarus IDE optimized for my processor. It's the project I run the most during the day.

The other thing I wasn't sure about, so rather left it out, was that the Target Processor Combobox could add the following extra options automatically:

-Op<x> -Cp<x>

At the moment that combobox acts exactly like the one in Project > Compiler Options, by ONLY adding the -Op parameter.

Doesn't the -Op<x> and -Cp<x> go hand-in-hand, or don't I fully understand those options?

Regards,
- Graeme -

_______________________________________________________ fpGUI - a cross-platform GUI toolkit using Free Pascal http://opensoft.homeip.net/fpgui/

Reply by email

Vincent Snijders
to Graeme Geldenhuys
Graeme Geldenhuys wrote 6 lines
Vincent Snijders wrote: > Thanks. That is what I hoped for. :-) We (normal users of Lazarus IDE) can't expect you guys to do everything. :-)

:-)

Show quoted text 20 lines
> I am not sure adding yet an extra option on that page is a good idea. Now you tell, after all the struggle to get it implemented. :-( I just thought, seeing that it is in the Project > Compiler Options, why not add it to the LazBuildDlg as well. After all, I would like to have my copy of Lazarus IDE optimized for my processor. It's the project I run the most during the day. The other thing I wasn't sure about, so rather left it out, was that the Target Processor Combobox could add the following extra options automatically: -Op<x> -Cp<x> At the moment that combobox acts exactly like the one in Project > Compiler Options, by ONLY adding the -Op parameter. Doesn't the -Op<x> and -Cp<x> go hand-in-hand, or don't I fully understand those options?

-Op<x> uses those general i386 instructions which work best on the CPU <x>, but still work on other i386 processors. So compiled with -OpPENTIUM4, it still works on a pentium processor.

-Cp<x> enables the use of instructions from processor <x>. If it -CpPENTIUM4 is used, it may cause illegal instruction exceptions on an ordinary pentium processor.

-Cp is about the available instruction set. -Op is an optimization parameter, which tells what processor to optimize for.

Only -Op is safe to add, but it is only about some optimization, not as important as -P<x>.

Note that AFAIK -Op is only useful for the i386 target.

Vincent

Reply by email