473,322 Members | 1,501 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,322 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 6092
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
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.