OpenMP在llvm里是如何实现的?

基础知识:编译器的结构 编译器中的“前端”和“后端”是两个重要的组成部分,它们负责编译过程的不同阶段。我们可以将编译器看作一个“处理流水线”,前端和后端各自执行不同的任务。 前端:负责将源代码解析成抽象语法树并生成中间代码,确保代码的语法和语义正确。 词法分析、语法分析、语义分析和中间代码生成。 后端:负责优化中间代码并生成目标机器代码,最终输出可执行文件。 优化、目标代码生成、汇编、链接。 前端

Experiment

Run on WSL Setup WSL X11 environment Run the image # load asterinas 0.11.0 docker load -i .\asterinas.tar # run the image with X11 forwarding sudo docker run -it --privileged -v $(pwd)/asterinas:/root

[WIP] 实验:用gdb观察gdb

Can I use gdb to observe gdb? I always forget how gdb was made. for me, I went though the website on stackoverflow of Zhihu serveral times only for this question, and I always forget everything about

[WIP] Perf 是怎么做的

好像跟gdb怎么做的还是有差别的 gdb用的ptrace 【一文看懂 | GDB 底层实现原理】【转载】_gdb底层原理-CSDN博客 用图文带你彻底弄懂GDB调试原理-腾讯云开发者社区-腾讯云

Operating System Assignment 7

OpHaibin Lai 12211612 在实验室服务器玩的时候,宕机了5次,Asterinas的profile模式似乎会逐渐把tcp堵死,然后就连不上机器。差点被学长学姐杀了( 本次作业将分成如下几个部分: 执行的环境脚本和命令脚本(pipe_lat) lmbench测试结果与gdb profiling情况 OS pipe管道介绍与Asterinas pipe源码学习 gdb flame gr

Operating System Assignment 4

Author: Haibin Lai 12211612 OS: Virtual Memory - Haibin's blog Q1 Explain how do the CPU hardware and the operating system cooperate in the procedure of address translation. Ans: The hardware-based ad

How can lscpu get Cache size

Since Operating System corporate little with Cache, How can lscpu knows the size of them? The CPUID Explorer: Part 2 Answer: CPUID Register From CPUID register! CPUID is an instruction in x86 and x86-

OS Assignment 5

赖海斌 12211612 1. Question1 In a demand-paging memory management system, suppose the page table contents for a certain process are as follows (for a single-level page table, with H denoting hexa

OS Project part I VirtIO, a biref summary

制作基于VirtIO设备驱动 设备驱动需要做什么? 设备初始化 从硬件读取数据,将数据传送进内核 读取内核数据,写入硬件 检测和处理设备错误 Intro: 虚拟化 全虚拟化是指虚拟化软件(VMM)遵循硬件的规范,完整模拟硬件逻辑,这种方式对 guest 操作系统是透明的,即 guest 操作系统不需要做任何修改。全虚拟化模拟的设备与硬件设备对于驱动程序并无不同。全虚拟化的设备性能较低,因为完全按照

OS: Virtual Memory

Author: Haibin Lai 12211612 OS: Virtual Memory - Haibin's blog Q1 Address Translation Explain how do the CPU hardware and the operating system cooperate in the procedure of address translation. Ans: T

TLB, ASID, TTBR And Context Switching

本文是在实验课上看一些文章和GPT整理的,不完全 Linux内存管理笔记----TLB-阿里云开发者社区 面试官:不同进程对应相同的虚拟地址,在 TLB 是如何区分的?-腾讯云开发者社区-腾讯云 Linux进程管理+内存管理:进程切换的TLB处理(ASID-address space ID、PCID-process context ID)_进程的asid-CSDN博客 TLB、PCID与ASID的

OS Assignment: Process

Author: Haibin Lai Student ID: 12211612 1 Three "Easy" Pieces 1.1 Three Easy pieces of Operating System: Virtualization Concurrency Persistence Explain: Virtualization means OS will make a h

Wireshark 是如何实现抓包的?

PPT: 为什么wireshark抓不到HTTP My summary web page: BPF与npcap库.drawio Wireshark 是如何实现的 wireshark的总体结构如下图所示。 【wireshark】Wireshark原理分析与二次开发系列 - 赵子清 - 博客园 (cnblogs.com) 抓包 捕获从网络适配器提取包,并将其保存到硬盘上. 访问底层网络适配器需要提升的

How does OS shut down your PC?

J## 处理器:Everything is a State Machine CPU 程序是在状态中循环往复 return指令的行为: 从刚刚的状态出来,然后改掉 所以:你写的程序是无法退出的。你写的程序是无法退出的。 了解windows关机过程 - 久月 - 博客园 (cnblogs.com) Linux系统自带poweroff命令,快速关闭电脑 (linux系统poweroff)