Csound Csound-dev Csound-tekno Search About

[Cs-dev] new parser producing slower code?

Date2010-08-02 09:03
FromVictor Lazzarini
Subject[Cs-dev] new parser producing slower code?
Attachmentssheppard.csd  None  None  
I was surprised to see that the new parser ('normal'  csound) seems to  
produce slower-running code.
Why would that be?

You can check with the attached CSD. Here it runs in 7.6 secs (old  
parser) and 13.9 (new parser). Almost
twice as slow!

On the other hand, trapped does not show that much difference 3.9 (old  
parser) and 4.2 (new parser).


Victor


Date2010-08-02 15:09
FromSteven Yi
SubjectRe: [Cs-dev] new parser producing slower code?
Hi Victor,

This is not too much of a surprise as optimization phase of the
compiling was never implemented (see Engine/csound_orc_optimize.c).
Things that are done in expression-opt in the old parser are therefore
not done.  When I was working on the parser, I separated out the
compilation steps to match what is done in other compilers I was
looking into (particularly the tree-ssa stuff done in GCC).  By having
a formal tree to work with, we should be able to do more optimizations
than the old parser, but just need to implement them. I don't remember
if the tree currently is in SSA form, however.

steven

On Mon, Aug 2, 2010 at 4:03 AM, Victor Lazzarini
 wrote:
> I was surprised to see that the new parser ('normal'  csound) seems to
> produce slower-running code.
> Why would that be?
>
> You can check with the attached CSD. Here it runs in 7.6 secs (old parser)
> and 13.9 (new parser). Almost
> twice as slow!
>
> On the other hand, trapped does not show that much difference 3.9 (old
> parser) and 4.2 (new parser).
>
>
> Victor
>
>
>
> ------------------------------------------------------------------------------
> The Palm PDK Hot Apps Program offers developers who use the
> Plug-In Development Kit to bring their C/C++ apps to Palm for a share
> of $1 Million in cash or HP Products. Visit us here for more details:
> http://p.sf.net/sfu/dev2dev-palm
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel
>
>

------------------------------------------------------------------------------
The Palm PDK Hot Apps Program offers developers who use the
Plug-In Development Kit to bring their C/C++ apps to Palm for a share
of $1 Million in cash or HP Products. Visit us here for more details:
http://p.sf.net/sfu/dev2dev-palm
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2010-08-02 15:53
FromVictor Lazzarini
SubjectRe: [Cs-dev] new parser producing slower code?
Steven,

thanks for the explanation. Well, it makes sense that when fully  
implemented, we should have a better, more optimised, parser output.

Victor
On 2 Aug 2010, at 15:09, Steven Yi wrote:

> Hi Victor,
>
> This is not too much of a surprise as optimization phase of the
> compiling was never implemented (see Engine/csound_orc_optimize.c).
> Things that are done in expression-opt in the old parser are therefore
> not done.  When I was working on the parser, I separated out the
> compilation steps to match what is done in other compilers I was
> looking into (particularly the tree-ssa stuff done in GCC).  By having
> a formal tree to work with, we should be able to do more optimizations
> than the old parser, but just need to implement them. I don't remember
> if the tree currently is in SSA form, however.
>
> steven
>
> On Mon, Aug 2, 2010 at 4:03 AM, Victor Lazzarini
>  wrote:
>> I was surprised to see that the new parser ('normal'  csound) seems  
>> to
>> produce slower-running code.
>> Why would that be?
>>
>> You can check with the attached CSD. Here it runs in 7.6 secs (old  
>> parser)
>> and 13.9 (new parser). Almost
>> twice as slow!
>>
>> On the other hand, trapped does not show that much difference 3.9  
>> (old
>> parser) and 4.2 (new parser).
>>
>>
>> Victor
>>
>>
>>
>> ------------------------------------------------------------------------------
>> The Palm PDK Hot Apps Program offers developers who use the
>> Plug-In Development Kit to bring their C/C++ apps to Palm for a share
>> of $1 Million in cash or HP Products. Visit us here for more details:
>> http://p.sf.net/sfu/dev2dev-palm
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>>
>
> ------------------------------------------------------------------------------
> The Palm PDK Hot Apps Program offers developers who use the
> Plug-In Development Kit to bring their C/C++ apps to Palm for a share
> of $1 Million in cash or HP Products. Visit us here for more details:
> http://p.sf.net/sfu/dev2dev-palm
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel


------------------------------------------------------------------------------
The Palm PDK Hot Apps Program offers developers who use the
Plug-In Development Kit to bring their C/C++ apps to Palm for a share
of $1 Million in cash or HP Products. Visit us here for more details:
http://p.sf.net/sfu/dev2dev-palm
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net