Re: Denial of denial of service

[prev] [thread] [next] [lurker] [Date index for 2007/01/29]

From: Martin Ebourne
Subject: Re: Denial of denial of service
Date: 01:17 on 29 Jan 2007
On Sun, 2007-01-28 at 14:15 +0200, Yossi Kreinin wrote:
>  > gcc -S try.cpp -O6 -fomit-frame-pointer
>  > cat try.s
> # tons of labels and such deleted
> _Z1gv:
>          pushl   %esi
>          pushl   %ebx
>          subl    $32, %esp
>          leal    12(%esp), %esi
>          pushl   %esi
>          call    _ZN1CC1Ev
>          addl    $16, %esp
>          call    _Z1fv
>          subl    $12, %esp
>          pushl   %esi
>          call    _ZN1CD1Ev
>          addl    $36, %esp
>          popl    %ebx
>          popl    %esi
>          ret
> 
>  > gcc -S try.cpp -O6 -o try2.s -fno-exceptions -fomit-frame-pointer
>  > cat try2.s
> # same shit without pushl/popl %esi:
> _Z1gv:
>          pushl   %ebx
>          subl    $36, %esp
>          leal    12(%esp), %ebx
>          pushl   %ebx
>          call    _ZN1CC1Ev
>          addl    $16, %esp
>          call    _Z1fv
>          subl    $12, %esp
>          pushl   %ebx
>          call    _ZN1CD1Ev
>          addl    $40, %esp
>          popl    %ebx
>          ret

Sorry, can't help you here. I'm happy to report I (intentionally) know
absolutely no x86 assembler at all. I could probably guess some of it
but I wouldn't want to. I suppose the instructions are obvious enough,
but I vaguely remember from z80 that the registers are all wierd so I
wouldn't understand the context anyway. (The fact that the processor has
a register called 'ESP' makes me wonder if that explains the sometimes
weird behaviour of PCs over the years.)

Find me an example in ARM, SPARC, even 68k and I'll try and help you
out. Heck, there's quite a lot of wasted brain cells on TI 32 series
DSP, PIC microprocessor, 6502 and other rubbish, but I don't think gcc
compiles to any of those.

Cheers,

Martin.

There's stuff above here

Generated at 23:01 on 06 Feb 2007 by mariachi 0.52