Questions tagged [clr]
The Common Language Runtime (CLR) is the virtual machine component of Microsoft's .NET framework and is responsible for managing the execution of .NET programs.
25 questions
5
votes
1
answer
3k
views
How to separate "unmanaged" and "managed" code in my C++/CLI project
I am developing a project using C++/CLI and WinForms. It is a geometry project, which is why I have to use C++/CLI, because of the C++ geometry library CGAL. I chose to use WinForms for the UI because ...
11
votes
4
answers
5k
views
Is the C# EventHandler designed the wrong way?
State of the union:
C# Events/Eventhandlers are:
blocking
throwing Exceptions
sequential
deterministic executed in order
MulticastDelegates
a handler is always dependent on the behavior of the ...
0
votes
0
answers
132
views
.Net - "Thread is blocked/waiting" meaning for I/O bound operation
Caller waiting for method to return back and till it is not returning, we can say thread is waiting, right ? However, this behaviour is because that inner method is waiting for some other operation or ...
4
votes
2
answers
531
views
What algo/design pattern do i need to keep limited time series data constantly updated?
I'm a hobbyist coder; never worked professionally. I am not looking for anyone to write code for me, but I need to know how to approach this problem and, perhaps, ideas for further research. This ...
3
votes
2
answers
1k
views
What is the point of the Common Language Runtime (CLR)?
My understanding is that part of the point of the JVM was that the code could "run anywhere", but CLR code was designed to run only on Windows: so why have a virtual machine?
I know that the CLR ...
45
votes
4
answers
6k
views
Why are structs and classes separate concepts in C#?
While programming in C#, I stumbled upon a strange language design decision that I just can't understand.
So, C# (and the CLR) has two aggregate data types: struct (value-type, stored on the stack, ...
-1
votes
2
answers
933
views
How does the Common Language Runtime improve performance? [duplicate]
I read on the wikipedia article for Common Language Runtime that one of the benefits that the runtime provides is "Performance improvements".
Executing managed code (Or bytecode) must surely always ...
1
vote
1
answer
752
views
What does it mean when code "runs on" the .NET CLR?
The .NET CLR is not an interpreter, since code gets compiled to native code by the JIT compiler. So I find the usual description of code "running on" the CLR confusing.
How does the native code ...
15
votes
4
answers
13k
views
How are virtual methods slower in C#?
I read that virtual calls make the code slower than calling non-virtual ones in C#.
However, the IL instruction for both are the same callvirt except in cases where base.somemethod() is called.
So how ...
2
votes
3
answers
3k
views
How to evaluate CLR / C++ vs native C++?
How should I go about evaluating the performance or execution time of C++ with CLR versus native C++?
My personal bias is that I believe C++ with CLR to be slower since it has to run on a virtual ...
6
votes
4
answers
8k
views
Is it possible to implement an infinite IEnumerable without using yield with only C# code?
Motivation
The main idea is to explore and understand the limits of how far one can go with the basic LINQ primitives (Select, SelectMany, Concat, etc.). These primitives can all be considered ...
6
votes
2
answers
418
views
What does "because IL offers no instructions to manipulate registers, it is easy for people to create new languages" mean?
I am reading CLR via C# and came across this sentence in the first chapter and I did not understand what exactly it meant.
Full line here:
because IL offers no instructions to manipulate registers,...
7
votes
1
answer
234
views
.NET BCL Change Analysis - Uses Beyond Sating Curiosity
This is part of a series of questions which focuses on the Abstraction Project, which aims to abstract the concepts used in language design in the form of a framework. There is a sister project to ...
9
votes
4
answers
1k
views
Constants in C#
Why does the compiler store constant values in the assembly metadata?
Are they directly embedded to Intermediate Language code from the assembly metadata?
4
votes
3
answers
2k
views
Appropriate use of SQL CLR
We have some back end processes that runs* on our sql server (SQL Server), they involve processing claims. This requires both data manipulation (biz logic) and data read/write to tables. The biz ...
0
votes
1
answer
251
views
Coincidence or rule?
I was reading about Assemblies (modules, which Microsoft CLR works with). The Assembly contains so called Manifest, which by definition describes a set of files in the Assembly.
I know that Android ...
6
votes
4
answers
1k
views
Writing a new programming language - when and how to bootstrap datastructures?
I'm in the process of writing my own programming language which, thus far, has been going great in terms of what I set out to accomplish. However, now, I'd like to bootstrap some pre-existing data ...
2
votes
4
answers
913
views
Do I lose anything by coding in c# and using free online vb.net code convertors? [closed]
The company I work for uses vb.net since there are many programmers who moved up from vb6 to vb.net. Basically more vb.net resources in the company for support/maintenance vs c#. I am a c# coder and ...
3
votes
2
answers
1k
views
How to devise instruction set of a stack based machine?
Stack based virtual machines like CLR and JVM has different set of instructions. Is there any theory behind devising the instruction set while creating a virtual machine? e.g. there are JVM ...
4
votes
1
answer
2k
views
Build a native dll or .net dll to be used independently in either set-up
Here's a simple question (kind of), but I'm having a hard time taking a decision. First, a history on how I came to have this problem. In my new job, we need to use a third party API to communicate ...
8
votes
1
answer
2k
views
What language is the CLR written in?
Just out of curiosity, what language is the CLR written in? I read on the Java Virtual Machine wikipedia entry that it is programmed in C++; is this the same for the CLR?
Sorry if this is off-topic, ...
1
vote
1
answer
328
views
How DEP and ASLR play role in security?
Lines from CLR via C#:
A managed module is a standard
32-bit Microsoft Windows portable executable (PE32) file or a standard 64-bit Windows
portable executable (PE32+) file that requires the CLR to ...
18
votes
2
answers
3k
views
Is IronScheme complete enough or stable enough to be worth learning?
IronScheme is mentioned on Wikipedia as a successor to a failed project called IronLisp, bringing Lisp to CLR and .NET, the way Clojure does for the JVM.
Does anyone have experience with this language?...
4
votes
4
answers
2k
views
What has been your experience with SQL CLR for complex business logic?
So I thought I had a perfect use-case for a CLR SQL Procedure. I've search the Net for perhaps a similar example where data is retrieved, records added and updated. I have not looked at a SQL CLR ...
3
votes
4
answers
1k
views
How important is an in-depth knowledge of the Common Language Runtime to a .NET developer?
I wonder how many .NET developers have a working knowledge of CIL and where it has been useful to them.
In case you are missing my meaning, here is a simple CIL example to add two locations together:
...