Descent 0.5.4 released

Saaa empty at needmail.com
Tue Jan 27 12:32:54 PST 2009


> Which ones are the -O ones?
Erm, the ones I invoke with -O :)
I thought they were seperate from the semantic pass van Bommel mentioned

> You can see which optimizations are applied in the front end in optimize.c
Thanks!

>
> For example this:
>
> ---
> int foo(int x) {
>   return x * 2 * 2;
> }
>
> int bar(int x) {
>   return 2 * 2 * x;
> }
> ---
>
> is transformed to this:
>
> ---
> int foo(int x) {
>   return x * 2 * 2;
> }
>
> int bar(int x) {
>   return 4 * x;
> }
> ---
>
> So it seems the optimize.c code just optimizes left subexpressions. I 
> wonder if -O does more that. Because if not, there's still a lof of room 
> for optimization in the compiler.
wow...

>
> Where can I find a version of obj2asm for Windows to see what's going on 
> in those cases?
I think it is in here:
http://www.digitalmars.com/eup.html
When is your birthday? :D





More information about the Digitalmars-d-announce mailing list