摘要: ###要点回顾: 上一篇段属性探测2中,我知道了当写一个段寄存器的时候,只给了16位的数,但段寄存器有96位,那剩下的80位从哪里来的?(从GDT中查出来的),这16位数是随便写的吗? ##GDT(Global Descriptor Table)全局描述符表和LDT(局部描述符表) GDT是一块内存 阅读全文
posted @ 2021-11-05 19:25 不会笑的孩子 阅读(263) 评论(0) 推荐(0)
摘要: ###要点回顾: 上一节课我们知道了段寄存器共96位 Selector//16位 Attribute//16位 Base //32位 Limit //32位 我们可以通过MOV指令进行读写(LDTR和TR除外) 但是我们只能看见16位,那我们证明Attribute,Base,Limit的存在呢? # 阅读全文
posted @ 2021-11-05 17:15 不会笑的孩子 阅读(104) 评论(0) 推荐(0)
摘要: ##保护模式简介 CPU分为实模式、保护模式、虚拟8086模式,大多数操作系统运行在保护模式下。 * 保护模式具有两个特点:段、页、保护模式真正保护的是数据结构、寄存器、指令。 * 实模式:16位汇编,访问的都是物理地址,非常危险。 * 保护模式:保护的是对内存的访问,相对实模式安全。段层保护,页层 阅读全文
posted @ 2021-11-05 15:50 不会笑的孩子 阅读(232) 评论(0) 推荐(0)
摘要: #include "stdafx.h" #include<stdio.h> #include<stdlib.h> typedef struct Node { int data ;//数据域 struct Node * pNext; //指针域 这个指针域它指向的是跟它本身一样的数据类型的另一个节点 阅读全文
posted @ 2021-11-05 12:47 不会笑的孩子 阅读(100) 评论(0) 推荐(0)
摘要: ![](https://img2020.cnblogs.com/blog/2069956/202110/2069956-20211010194458307-1118333427.png) 阅读全文
posted @ 2021-10-10 19:45 不会笑的孩子 阅读(82) 评论(0) 推荐(0)
摘要: #include<stdio.h> #include<malloc.h> struct Student{ int sid; int age; } struct Student* CreateStudent(void); void ShowStudent(strucent Student*) int 阅读全文
posted @ 2021-10-09 11:15 不会笑的孩子 阅读(46) 评论(0) 推荐(0)
摘要: typedef int INT; //相当于给int起了一个别名INT typedef struct Student { int sid; char name[100]; char sex; }ST; //ST st 就相当于struct Student st ,给struct Student 起了 阅读全文
posted @ 2021-10-09 11:13 不会笑的孩子 阅读(51) 评论(0) 推荐(0)
摘要: #include <stdio.h> //#为预处理命令 #include <malloc.h>//内存分配 int main(void) { //静态分配内存(数组) int a[5] = {2,3,5,6,9}; int len = 0; //len 为一维数组的长度,可以根据需求动态分配长度 阅读全文
posted @ 2021-10-09 10:55 不会笑的孩子 阅读(83) 评论(0) 推荐(0)
摘要: ![](https://img2020.cnblogs.com/blog/2069956/202110/2069956-20211008184954407-1117572973.gif) 阅读全文
posted @ 2021-10-08 18:50 不会笑的孩子 阅读(88) 评论(0) 推荐(0)