kd,
The JIT compiler will automatically inline small methods. I believe
the threshold is 32 bytes. Simple properties are ideal candidates.
One advantage of letting the JIT compiler do this automatically is that
it can inline methods across assembly boundaries.
Brian
[quoted text, click to view] kd wrote:
> Cor,
>
> I have a procedure which has few lines of code that I need to execute
> very frequently in the project. If the procedure were to be 'Inline',
> the overheads of a function call can be eliminated.
>
> If there is something like an 'Inline' function available in vb.net,
> I could use that feature.
>
> Thanks.
> kd
>
KD,
In my opinion do we not live anymore in the century from the invention of
the Unix computer.
You can be sure that using ILS language the processing is not direct, as it
is with almost every computersystem invented after 1960. (Not about
processors for coocking machines and things like that).
How many cycles of the processor you need to win?
You know that a computer needed for Net has at least something as 90Mhz.
What means 90 million cycles per second.
Cor
[quoted text, click to view] "kd" <kd@discussions.microsoft.com> wrote in message
news:3699D204-AC7D-42A7-AC5D-095161A06EBD@microsoft.com...
> Hi All,
>
> Does vb.net support inline functions?
>
> kd.
I've never seen any reference to it.
However, I think that the compiler makes the call whether to inline the
function and its not something you have explicit control over. This is based
on what little information I could find on the net.
Hope this helps,
Brian
www.cryer.co.uk/brian
"kd" <kd@discussions.microsoft.com> schrieb:
[quoted text, click to view] > Does vb.net support inline functions?
Some of the VB functions are inlined by the compiler. The JITter will
inline small functions automatically. However, you don't have control over
this process, which gives the JITter more flexibility to optimize your code.
--
M S Herfried K. Wagner
M V P <URL:
http://dotnet.mvps.org/> V B <URL:
http://dotnet.mvps.org/dotnet/faqs/>