MSDN TV: CLR Method Dispatch Internals

Joe Duffy and I recently did an MSDN TV stint on Method Dispatch Internals. Joe concentrated on the static end of the spectrum, while I talked about late-bound binding and dynamic calling convention.

I also appeared with fellow Australian Microsofties at the recent Whidbey Ship party. Lots of fun! 

Comments (3)

  1. Gustavo Guerra says:


    I actually already started on LCG, based on your previous blog posts about the subject, but that video is a great introduction also.

    Can you answer me two questions?

    1)I’m using LCG to optimize method calls in a custom Rpc framework, but I’ve stumbled across a problem with generic methods. Is it possible to generate a method using LCG that receives a type array and calls a generic method with those type parameters? I mean to replace code like this:

    MethodInfo method;

    object[] parameters;

    Type[] type_parameters;



    DynamicMethod dm = SomeMethodThatGeneratesAGenericDynamicMethod(method);

    dm.Invoke(null, new object[] { type_parameters, parameters)});

    2) Is there a performance difference between DynamicMethod.Invoke and DynamicMethod.CreateDelegate and then later calling the delegate?

    Best regards,

    Gustavo Guerra

Skip to main content