473,396 Members | 2,108 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

NOP Statements in IL

When I look at the IL, using ILDASM, why does the VB.NET version have so
many NOP statements? The C# version doesn't seem to. What gives?
Nov 21 '05 #1
8 6096
Randy,
VB.NET, as does C# 2.0, injects NOP statements into the IL to simplify
debugging, I understand mostly to allow you to put breakpoints on statements
that otherwise you could not (such as End If). I want to say .NET 2.0 puts
more NOP statements to help with the Edit & Continue feature of the debugger
(I don't have the specific reference handy, I just remember reading
something to that effect).

To remove them simply compile your project under the Release build, see
"Project - Configuration Manager - Active Solution Configuration" or simply
use the drop down on the tool bar.

Hope this helps
Jay

"Randy Given" <Gi********@aol.com> wrote in message
news:LX8td.3675$wp.2817@lakeread05...
When I look at the IL, using ILDASM, why does the VB.NET version have so
many NOP statements? The C# version doesn't seem to. What gives?

Nov 21 '05 #2
Randy,
VB.NET, as does C# 2.0, injects NOP statements into the IL to simplify
debugging, I understand mostly to allow you to put breakpoints on statements
that otherwise you could not (such as End If). I want to say .NET 2.0 puts
more NOP statements to help with the Edit & Continue feature of the debugger
(I don't have the specific reference handy, I just remember reading
something to that effect).

To remove them simply compile your project under the Release build, see
"Project - Configuration Manager - Active Solution Configuration" or simply
use the drop down on the tool bar.

Hope this helps
Jay

"Randy Given" <Gi********@aol.com> wrote in message
news:LX8td.3675$wp.2817@lakeread05...
When I look at the IL, using ILDASM, why does the VB.NET version have so
many NOP statements? The C# version doesn't seem to. What gives?

Nov 21 '05 #3
Hi,
Check the 'Debugging and nop instructions' section of this artilce:
http://msdn.microsoft.com/library/de...tinternals.asp

"Randy Given" <Gi********@aol.com> wrote in message
news:LX8td.3675$wp.2817@lakeread05...
When I look at the IL, using ILDASM, why does the VB.NET version have so
many NOP statements? The C# version doesn't seem to. What gives?

Nov 21 '05 #4
Hi,
Check the 'Debugging and nop instructions' section of this artilce:
http://msdn.microsoft.com/library/de...tinternals.asp

"Randy Given" <Gi********@aol.com> wrote in message
news:LX8td.3675$wp.2817@lakeread05...
When I look at the IL, using ILDASM, why does the VB.NET version have so
many NOP statements? The C# version doesn't seem to. What gives?

Nov 21 '05 #5
Thanks!
Nov 21 '05 #6
Thanks!
Nov 21 '05 #7
Thanks for the URL!
Nov 21 '05 #8
Thanks for the URL!
Nov 21 '05 #9

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Bart Nessux | last post by:
Should an if statement have a corresponding else statement? Or, is it OK to have an if statement by itself. For completeness, it seems the two should be together, but from experience I know that a...
9
by: Jaime Wyant | last post by:
I know I've seen this somewhere, but can't seem to google it. Is there a way to use an alternate statement separator, other than the default ';'? jw
1
by: Tom D | last post by:
I'm rewriting a database interface that our company currently has. Currently it's using the Pear::DB interface, but we found that that was introducing a bit too much overhead. I'm rewriting the...
39
by: slogging_away | last post by:
Hi - I'm running Python 2.4.2 (#67, Sep 28 2005, 12:41:11) on win32, and have a script that makes numerous checks on text files, (configuration files), so discrepancies can be reported. The script...
0
by: Fuzzyman | last post by:
Hello all, The following is a copy of a blog entry. It's asking a question about future statements and the built in compile function. I'd appreciate any pointers or comments about possible...
20
by: Neroku | last post by:
Hello, i would like to know what the serious definition of statements and expressions is: i know an expression are evaluated to a value, i.e: 1 == 2 5+7 foo( 1,2) and a statement is...
2
by: ojorus | last post by:
Hi! Some questions regarding the mysqli-extension (php5) 1) Prepared statements: If I understand things right, prepared statements will give better performance if you make several similar...
3
by: Dmitri | last post by:
Hello! I have a developer that is playing around with some SQL statements using VB.NET. He has a test table in a SQL 2000 database, and he has about 2000 generated INSERT statements. When the...
0
by: Gary Herron | last post by:
Ohad Frand wrote: There is no way you can consider 'elif', 'else', 'except', and 'from' statements. However, as someone pointed out, the kwlist from the keyword module is the closest thing we...
0
by: Ohad Frand | last post by:
Hi Thanks a lot for your reply I think the main uses for it is to study the language and to see that I didn't miss anything else or that something is changed from one version to another. The...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.