Re: [fpc-pascal] inlining functions

2019-01-12 Thread denisgolovan
  12.01.2019, 19:44, "Benito van der Zander" :Hi,  something that appears  to help is to put units in the interface uses rather than the implementation uses.When the unit mentioned in the interface uses, uses the first unit in its implementation uses, it can inline the functions from the first unit

Re: [fpc-pascal] inlining functions

2019-01-12 Thread Benito van der Zander
Hi,  something that appears  to help is to put units in the interface uses rather than the implementation uses. When the unit mentioned in the interface uses, uses the first unit in its implementation uses, it can inline the functions from the first unit. Although I would have expected it to

Re: [fpc-pascal] inlining functions

2019-01-12 Thread denisgolovan
  12.01.2019, 16:03, "Sven Barth via fpc-pascal" :With WPO you need to compile at least twice as well as the first pass only collects information and acts on it in the second pass. Is it possible to make Lazarus do that automatically?According to Jonas it's a bit too unpractical. -- Regards,Denis G

Re: [fpc-pascal] inlining functions

2019-01-12 Thread denisgolovan
12.01.2019, 15:32, "Jonas Maebe" : > It's not yet integrated in the compiler, so you have to do it manually > right now: > a) compile everything with -al (including the RTL etc; add OPT="-a" to > the make command) > b) go in all the unit directories, and assemble the files to bitcode > using some

Re: [fpc-pascal] inlining functions

2019-01-12 Thread Sven Barth via fpc-pascal
Am Sa., 12. Jan. 2019, 13:05 hat denisgolovan geschrieben: > > However, what you actually can do, is manually recompile all units of > your program > > multiple times. While this won't help with inline functions called > > before they are parsed in those same units, it will allow inlining of > >

Re: [fpc-pascal] inlining functions

2019-01-12 Thread Jonas Maebe
On 12/01/19 13:05, denisgolovan wrote: 12.01.2019, 14:53, "Jonas Maebe" : Not at this time (unless you use the LLVM backend). Could you give some hints on how to enable WPO/LTO under LLVM backend? http://wiki.freepascal.org/LLVM does not seem to mention anything on that. It's not yet integ

Re: [fpc-pascal] inlining functions

2019-01-12 Thread denisgolovan
12.01.2019, 14:53, "Jonas Maebe" : > Not at this time (unless you use the LLVM backend). Could you give some hints on how to enable WPO/LTO under LLVM backend? http://wiki.freepascal.org/LLVM does not seem to mention anything on that. > However, what you actually can do, is manually recompile

Re: [fpc-pascal] inlining functions

2019-01-12 Thread Jonas Maebe
On 12/01/19 12:47, denisgolovan wrote: 07.01.2019, 00:45, "Jonas Maebe" : Not besides breaking your dependency cycles. Sorry, but for necro-posting, but shouldn't WPO is supposed to help to inline functions as well? Not at this time (unless you use the LLVM backend). However, what you act

Re: [fpc-pascal] inlining functions

2019-01-12 Thread denisgolovan
07.01.2019, 00:45, "Jonas Maebe" : > Not besides breaking your dependency cycles. Sorry, but for necro-posting, but shouldn't WPO is supposed to help to inline functions as well? -- Regards, Denis Golovan ___ fpc-pascal maillist - fpc-pascal@list