Hi Jb,

I am also looking for the flow analysis but I couldn't find it. Can you 
direct me to the right place?

Thanks,
Xiao

On Tuesday, April 22, 2008 3:37:43 AM UTC-4, Jb Evain wrote:
>
> Hey Scott,
>
> On 4/22/08, Scott Peterson <[email protected] <javascript:>> wrote:
> >  What's the easiest way of determining an instruction's stack depth?
> >  I'm trying to remove certain method calls from a MethodBody. The
> >  methods I'm removing return null and take a number of parameters. I'm
> >  walking backward through a MethodBody's instructions, looking for a
> >  call to a method I'd like to remove. I note the stack depth after the
> >  call and start removing instructions, beginning with the Code.Call and
> >  moving backward until I get to that stack depth again. That seems like
> >  the easiest way of getting rid of a method call and its arguments.
> >  Ideas?
>
> See the code in /cecil/flowanalysis
>
> You'll find there some code you could adapt to know the stack height
> depending on the instruction.
>
> -- 
> Jb Evain  <[email protected] <javascript:>>
>
>

-- 
--
mono-cecil

Reply via email to