登录
首页 » C/C++ » virtual-memory-allocation--tracking

virtual-memory-allocation--tracking

于 2011-04-14 发布 文件大小:7704KB
0 77
下载积分: 1 下载次数: 0

代码说明:

说明:  编写一个程序,包括两个线程,一个线程用于模拟内存分配活动,另一个用于跟踪第一个线程的内存行为,要求两个线程之间通过信号量实现同步,模拟内存活动的线程可以从一个文件中读出要进行的内存操作。将VirtualAlloc函数的参数flAllocationType分别设置为MEM_RESET,MEM_TOP_DOWN,将flProtect参数分别设置为PAGE_GUARD,PAGE_NOACCESS,PAGE_NOCACHE,执行并查看内存分配的结果。(Write a program that consists of two threads, one thread is used to simulate the memory allocation activities, one for tracking the memory behavior of the first thread, requiring between two threads synchronize through semaphores to simulate the activities of the thread of memory from a read the file memory operations to be carried out. FlAllocationType the VirtualAlloc function parameters were set to MEM_RESET, MEM_TOP_DOWN, will flProtect parameters are set to PAGE_GUARD, PAGE_NOACCESS, PAGE_NOCACHE, execute and view the results of memory allocation.)

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • 696518资源总数
  • 104271会员总数
  • 57今日下载