夜归人blog.vning.vip·Jun 14, 2022C# 托管代码和垃圾回收什么是托管代码 托管代码就是执行过程交由运行时管理的代码。运行时一般是指 CLR,公共语言运行时。 CLR 负责提取托管代码、将其编译成机器代码,然后执行它。除此之外,运行时还负责自动内存管理、安全边界、类型安全等等。 如果在 .Net 里面直接调用 C/C++ 程序,此类代码也称为“非托管代码”。在非托管代码的环境中,操作系统将程序加载进内存,然后调用内部的二进制代码,所以从内存管理到安全等诸多因素都需要程序员自己处理。 正常使用 .Net 编写的代码,会先编译成中间语言 (IL)。执行的...Discuss·39 readsCSharpC#
Siben Nayaktheawesomenayak.hashnode.dev·Jan 22, 2021Garbage Collection in Java - Part 2In my previous article, I wrote about Garbage Collection in Java and how they work. In this article, you will learn more about the various types of GC available in Java and their advantages. I will also cover some of the new experimental Garbage Coll...Discuss·291 readsAdvanced JavaJava
Siben Nayaktheawesomenayak.hashnode.dev·Jan 22, 2021Garbage Collection in Java - Part 1In my previous article, I wrote about the Java Virtual Machine (JVM) and explained its architecture. As part of the Execution Engine component, I also briefly covered the Java Garbage Collector (GC). In this article, you will learn more about the Gar...Discuss·274 readsAdvanced JavaJava