elsewhere home of a .NET geek

  Home  |   Contact  |   Syndication    |   Login
  21 Posts | 1 Stories | 52 Comments | 35 Trackbacks

News

This blog has random information about Managed Code and Design Pattern. Every day, while i code, the thoughts come in mind are the one you would be reading here.

If you're seeking me for asking any questions, please use the contact page of this site.

Twitter












Article Categories

Archives

Post Categories

I came across a msdn page today which is about transforming the code to 64-bit programming. I was wondering how native code based applications can be ported to 64-bit computing. I know 32 bit .NET code can be executed with out any modifications in the 64 bit environment, read below the excerpt,

In most cases, applications developed using the 32-bit .NET Framework can be ported to the 64-bit version of the .NET Framework and executed as 64-bit native applications without any source code modifications. However, 32-bit .NET Framework applications that have floating-point or native code (e.g. DLLs or COM InProc Servers) dependencies may require modifications when porting to 64-platforms.
 
The key to writing portable code is to write verifiable code. Verifiable code is code that can be proven to be typesafe. .NET Framework applications are built using types defined in class libraries. Each type in a class library defines fields, properties and methods that are used to access the types functionality. The fields, properties and methods defined by a type represent a contract between the type (which provides functionality) and the user of the type (which consumes functionality). Typesafe code is code that obeys ALL type contracts. Types represent memory. And the fields, properties and methods defined by types represent ways to access memory. Ultimately, this means that typesafe code is code that doesnt improperly access memory. And because typesafe code doesnt improperly access memory, the common language runtime is able to safely execute multiple verifiable applications, each isolated in its own AppDomain, within a single (more expensive) operating system process. Also, because typesafe code doesnt improperly access memory it also reduces memory corruption which results in a more stable execution environment.

The C#, VB.NET, J# and managed C+ compilers that ship with the .NET Framework 2.0 SDK all produce verifiable (typesafe) code. The C#, VB.NET and J# compilers produce verifiable code by default, while the managed C++ compiler produces verifiable (typesafe) code when the /clr:safe flag is used. In addition, the .NET Framework SDK ships a tool (PEVerify.exe) that allows developers to determine if their code is verifiable.

BTW, the link is this for the full article

posted on Tuesday, February 28, 2006 10:32 AM