clr

.net framework CLI standards hosting organization?

Does anyone know what organization is hosting the .net framework Common Language infrastructure (CLI) standards and where you can I go and read them? ...

.NET: What is typical garbage collector overhead?

5% of execution time spent on GC? 10%? 25%? Thanks. ...

How much does bytecode size impact JIT / Inlining / Performance?

I've been poking around mscorlib to see how the generic collection optimized their enumerators and I stumbled on this: // in List<T>.Enumerator<T> public bool MoveNext() { List<T> list = this.list; if ((this.version == list._version) && (this.index < list._size)) { this.current = list._items[this.index]; this...

What is the exactly Runtime Host?

What is the exactly definition of Runtime Host? From MSDN: The common language runtime has been designed to support a variety of different types of applications, from Web server applications to applications with a traditional rich Windows user interface. Each type of application requires a runtime host to start it. The runtime hos...

How to reference GAC assemblies when integrating a CLR extension into SQL Server

I've created an assembly for CLR integration in SQL Server 2008. It has one reference to System.Web.Extensions, which is an issue because when I try to add my assembly, I get the following error: Assembly 'system.web.extensions, version=3.5.0.0, culture=neutral, publickeytoken=31bf3856ad364e35.' was not found in the SQL catalog. (Mic...

Which CLR will an application that uses DLLs that have been compiled for different versions of .net use?

This is pretty obvious I think but I thought it better to ask: If an application (exe) is compiled to run on .net 3.5 and if the dlls it uses are compiled for .net 1.1 will the DLL automatically use the 2.0 CLR, i.e the parents? What about vice versa? If so, what about compatibility issues? ...

Finding number of runs for the .NET garbage collector for a executing application

Hello, My question is with regard to the .NET garbage collector. For any executing application, can I find out the number of times the GC has run (including the generation numbers for that collection) and how much time was spent on the same? I could find a lot of explanation on the internal framework and working of the G...

Web Service or Windows Service or SQL CLR Integration?

Good afternoon everybody, I am in a bit over my head and facing some tight deadlines, so hopefully someone can offer some advice. My starting point will be a table in a SQL Server database, two of whose fields are x,y coordinates obtained from a gps unit. I will be responsible for geocoding (getting physical street address) these loca...

Mismatch in object size returned by sos.dll and in-memory process size.

Hello, I have used the following sos command to enumerate all instances of a particular type in a running asp application (hosted on windows xp 4 GB machine). .foreach (obj { !dumpheap -type ::my type:: -short ::start of address space:: ::end of address space:: }) { !objsize ${obj} }. This enumerates all objects of the given type in ...

What is mean by reference in .net wrt CLR (managing objects)?

What is mean by reference in .net wrt CLR (managing objects)? ...

Please clarify my understanding regarding object and reference and value type is current?

Please clarify my understanding regarding object and reference and value type is current? Object means a memory location in RAM where we allocate memory while executing a program Reference means a location(address) in the memory. Passing by reference means - we are passing or pointing a memory location to the function to take the valu...

Registering Assemblies used In SQL CLR Stored Procedure

Hello, I have been messing around with writing some stored procedures in .NET code with SQL CLR Integration. In the stored procedure, I am calling a third-party dll. When I try to create the assembly in SQL Server containing my custom stored proc, it complains that the third-party dll is not registered with the database. Is there som...

CLR Profiler with WCF doesn't work for specific service

Hello, I need to profile a WCF service, but I get the message "Waiting for service to start common language runtime", it only occurs with this particular service; when I tried with other WCF services, it works fine. I was wondering if I should configure something in the wcf to allow the profile. Both services run with the same account(ad...

Using Type.GetType() with unreferenced assembly with Cassini/Visual Studio Dev. Server

I've got some code var type = Type.GetType("namespace, assembly"); return Activator.CreateInstance(type); thats works fine in most situations, however when this code is referenced in the Global.asax of a website that is debugged using Cassini/Visual Studio Development Server the type cannot be found. The type is in an assembly that...

SQL CLR Programmability - Synchronization

Hello All, I'm new to SQL CLR programmability. I have a CLR stored procedure that writes to a local file. But when I have multiple connections calling the same stored procedure, how do I synchronize access to the local file? Any inbuilt features? Or any other input is welcome. ...

What could explain over 5,000,000 System.WeakReference instances on the managed heap?

I have been running load tests against a production ASP.NET web application and am seeing a huge number of System.WeakReferences created on the heap. Within about 15 minutes under load managed heap memory has shot up to about 3GB and I have approximately 5,000,000 references to System.WeakReference. Performing a forced garbage collection...

What is CLR hosting?

What is CLR hosting? What is the use case for that? ...

Hosting the CLR: IHostAssemblyStore::ProvideAssembly causes exception " exception "The located assembly's manifest definition does not match the assembly reference"

Hi, PostSharp 2.0 includes a CLR host and implements IHostAssemblyStore::ProvideAssembly. From managed code, I invoke: Assembly.Load("logicnp.cryptolicensing, Version=3.0.0.0, Culture=neutral, PublicKeyToken=4a3c0a4c668b48b4") My implementation of IHostAssemblyStore::ProvideAssembly receives the following input for ...

Are there attributes that affect how the CLR optimizes during a JIT compile?

As the question says, I am curious if any of you know about attributes that affect how the CLR will compile/optimize the bytecode. Is there an attribute that will affect code inlining decisions? Unroll loops? Are there undocumented attributes on classes generated for anonymous types/delegates? There's probably attributes to disable op...

Passing c# string to unmanaged c++ DLL

Hi All, I have a simple application that loads an unmanaged dll and passes a few string values to it from C#. But in the C++ dll application, I receive an exception :: Tried to access a read/write protected memory. My DLL Import looks like this: [DllImport("X.dll", CallingConvention = CallingConvention.Cdecl) ] public static extern int...