CLR Fundamentals
Demo for .NET IL program via Command window
Use of IL-DASM to see .NET assembly code
Use of Reflector too to see .NET code
Demo for JIT compilation via Command window
CLR Compaction in Action
Assemblies and Versioning
Demo of Assembly Qualified name
DEMO of Simple(UnSigned) Assembly Resolution
To give explicit permission to CLR to look the Assembly at our desired location
DEMO of Strong(Signed) Assembly Resolution
Demo of Version Policy
Demo of Strong Name Validation
Edit some binary content over there
GAC checks strong name assembly validation at the time of installation via "gacutil"
Win32 and COM Interop
Demo of P/Invoke for font smoothing
P/Invoke Error Handling
Demo of RCW
.NET VS will automatically import type library from COM component when we add it via Reference
CLRInternals and Advanced Debugging Techniques
Example:
class Test { static void Main() { int i = 1; object o = i; // boxing int j = (int) o; // unboxing } }
Core Debugging Tasks
A program database (.pdb) file, also called a symbol file, maps the identifiers that you create in source files for classes, methods, and other code to the identifiers that are used in the compiled executables of your project. The .pdb file also maps the statements in the source code to the execution instructions in the executables. The debugger uses this information to determine two key pieces of information: the source file and line number that are displayed in the Visual Studio IDE and the location in the executable to stop at when you set a breakpoint. A symbol file also contains the original location of the source files, and optionally, the location of a source server where the source files can be retrieved from.
Please follow the below link for more info. of Debugging Symbol
http://msdn.microsoft.com/en-us/library/vstudio/ms241613.aspx
In C#.NET Diagnostic is used for below purpose
The System.Diagnostics namespace provides classes that allow you to interact with system processes, event logs, and performance counters.
-
The EventLog
component provides functionality to write to event logs, read event log
entries, and create and delete event logs and event sources on the
network. The EntryWrittenEventHandler
provides a way to interact with event logs asynchronously. Supporting
classes provide access to more detailed control, including: permission
restrictions, the ability to specify event log types (which controls the
type of default data that is written with an event log entry), and
iterate through collections of event log entries. For more information
about these tasks, see the EventLogPermission, EventLogEntryType, and EventLogEntryCollection classes.
-
The Process
class provides functionality to monitor system processes across the
network, and to start and stop local system processes. In addition to
retrieving lists of running processes (by specifying either the
computer, the process name, or the process id) or viewing information
about the process that currently has access to the processor, you can
get detailed knowledge of process threads and modules both through the Process class itself, and by interacting with the ProcessThread and ProcessModule classes. The ProcessStartInfo
class enables you to specify a variety of elements with which to start a
new process, such as input, output, and error streams, working
directories, and command line verbs and arguments. These give you fine
control over the behavior of your processes. Other related classes let
you specify window styles, process and thread priorities, and interact
with collections of threads and modules.
- The PerformanceCounter class enables you to monitor system performance, while the PerformanceCounterCategory class provides a way to create new custom counters and categories. You can write to local custom counters and read from both local and remote counters (system as well as custom). You can sample counters using the PerformanceCounter class, and calculate results from successive performance counter samples using the CounterSample class. The CounterCreationData class enables you to create multiple counters in a category and specify their types. Other classes associated with the performance counter component provide access to collections of counters, counter permission, and counter types.
No comments:
Post a Comment