... | @@ -82,24 +82,24 @@ CLI명세를 기반으로 Microsoft에서 작성한 Virtual Execution System을 |
... | @@ -82,24 +82,24 @@ CLI명세를 기반으로 Microsoft에서 작성한 Virtual Execution System을 |
|
##### A common runtime for all .NET languages
|
|
##### A common runtime for all .NET languages
|
|
1. Common type system (CTS)
|
|
1. Common type system (CTS)
|
|
2. Common metadata
|
|
2. Common metadata
|
|
3. Intermediate Language (IL) to native code compilers
|
|
3. native code로 컴파일 하기 위한 Intermediate Language (IL)
|
|
4. Memory allocation and garbage collection
|
|
4. 메모리 할당과 garbage collection
|
|
5. Code execution and security
|
|
5. Intermediate Language (IL) 코드의 실행과 보안
|
|
|
|
|
|
|
|
|
|
|
|
<br>
|
|
##### CLR Execution model
|
|
##### CLR Execution model
|
|
todo-이미지 추가
|
|
todo-이미지 추가
|
|
|
|
|
|
|
|
<br>
|
|
##### Execution engine
|
|
##### 실행 엔진
|
|
1. Compiles Microsoft Intermediate Language (MSIL) into native code
|
|
1. Compiles Microsoft Intermediate Language (MSIL) into native code
|
|
2. Handles garbage collection
|
|
2. Handles garbage collection
|
|
3. Handles exception
|
|
3. Handles exception
|
|
4. Enforces code access security
|
|
4. Enforces code access security
|
|
5. Handles verification
|
|
5. Handles verification
|
|
|
|
|
|
##### Advantages of CLR
|
|
##### CLR의 장점
|
|
1. Interoperation between managed code and unmanaged code (COM, DLLs)
|
|
1. Inter-operation between managed code and unmanaged code (COM, DLLs)
|
|
2. Managed code environment
|
|
2. Managed code environment
|
|
3. Improved memory handling
|
|
3. Improved memory handling
|
|
4. Improved "garbage collection"
|
|
4. Improved "garbage collection"
|
... | @@ -116,45 +116,36 @@ The Base Class Library (BCL) is literally that, the base. It contains basic, fun |
... | @@ -116,45 +116,36 @@ The Base Class Library (BCL) is literally that, the base. It contains basic, fun |
|
The Framework Class Library (FCL) is the wider library that contains the totality: ASP.NET, WinForms, the XML stack, ADO.NET and more. You could say that the FCL includes the BCL.
|
|
The Framework Class Library (FCL) is the wider library that contains the totality: ASP.NET, WinForms, the XML stack, ADO.NET and more. You could say that the FCL includes the BCL.
|
|
|
|
|
|
### Assembly
|
|
### Assembly
|
|
C#.VB.Net 및다른.Net 언어들로짜여진소스코드를컴파일하여생성되는결과인.exe or .dll파일을Assembly라고한다.
|
|
C#.VB.Net 및 다른 .Net 언어들로 짜여진 소스코드를 컴파일 하여 생성되는 결과인 .exe or .dll파일을 Assembly라고 한다.
|
|
|
|
<br>
|
|
|
|
|
|
##### Assembly 구조:
|
|
##### Assembly 구조:
|
|
todo-이미지추가
|
|
todo-이미지추가
|
|
|
|
|
|
|
|
<br>
|
|
##### Assembly 실행과정:
|
|
##### Assembly 실행과정:
|
|
1. 어셈블리가 CLR로 로드 된다.
|
|
1. 어셈블리가 CLR로 로드 된다.
|
|
2. CLR은 manifest 포함 된 정보를 기반으로 다양한 작업을 수행한다.
|
|
2. CLR은 manifest 포함 된 정보를 기반으로 다양한 작업을 수행한다.
|
|
3. 보안 요구사항이 충족되면 CLR은 JIT(Just In Time) 컴파일을 수행하여 IL코드를(Native Code)로 변환 한다.
|
|
3. 보안 요구사항이 충족되면 CLR은 JIT(Just In Time) 컴파일을 수행하여 IL코드를(Native Code)로 변환 한다.
|
|
|
|
|
|
|
|
|
|
|
|
<br>
|
|
### Managed vs. Unmanaged
|
|
### Managed vs. Unmanaged
|
|
<br>
|
|
<br>
|
|
##### Managed code is:
|
|
##### Managed code is:
|
|
1. CLR executed code is called managed code. (any .NET language)
|
|
1. CLR에서 실행되는 코드이다. (any .NET language)
|
|
Code that contains enough information to allow the CLI to provide a set of core services
|
|
2. low level language인 IL(MSIL) 코드로 표현된다.
|
|
2. Represents programming code in the low level language MSIL.
|
|
3. metadata를 가진다.
|
|
3. Contains metadata
|
|
4. 타입의 불법적인 사용으로 부터 보호된다.(type-safe)
|
|
4. Description of classes
|
|
5. 플랫폼 독립적이다.(Windows, Linux, Max OS x, etc.)
|
|
A. Interfaces
|
|
<br>
|
|
B. Properties
|
|
|
|
C. Fields
|
|
|
|
D. Methods
|
|
|
|
E. Parameters
|
|
|
|
|
|
|
|
5. Protected from irregular use of types (type-safe)
|
|
|
|
6. Portable between different platforms (Windows, Linux, Max OS x, etc.)
|
|
|
|
|
|
|
|
|
|
|
|
##### Managed data is:
|
|
##### Managed data is:
|
|
1. Data that is allocated and released automatically by the CLI, through a process called garbage collection
|
|
1. garbage collection를 통해 자동으로 할당되고, 해제되는 데이터
|
|
|
|
<br>
|
|
##### Unmanaged code is:
|
|
##### Unmanaged code is:
|
|
1. No protection of memory and type-safety
|
|
1. 메모리 및 타입의 불법 사용에 대한 보호가 없다. (No protection of memory and type-safety)
|
|
2. Doesn't contain metadata
|
|
2. metadata가 없다.
|
|
3. Compiled to machine-dependent code.
|
|
3. 실행되는 machine에 종속적인 코드로 컴파일 된다.
|
|
|
|
|
|
|
|
|
|
|
|
|
... | | ... | |