- 博客(149)
- 收藏
- 关注
原创 【PNFS】工作队列
工作队列(workqueue)一般用来做滞后的工作,比如在中断里面要做很多事,但是比较耗时,这时就可以把耗时的工作放到工作队列。说白了就是系统延时调度的函数。工作队列的使用又分两种情况,一种是利用系统共享的工作队列来添加自己的工作,这种情况处理函数不能消耗太多时间,这样会影响共享队列中其他任务的处理;另外一种是创建自己的工作队列并添加工作。如果使用系统自带的分为以下几步:1.声明或编写一个...
2019-01-21 10:37:07
274
原创 【PNFS学习】extent
ext2/3 以 block 为基本单位,将磁盘划分为多个 block 。为了管理磁盘空间,文件系统需要知道哪些 block 是空闲的,它们使用 bitmap 来达到这个目的。 Bitmap 中的每一个 bit 对应磁盘上的一个 block,当相应 block 被分配后,bitmap 中的相应 bit 被设置为 1 。这是很经典也很清晰的一个设计,但不幸的是当磁盘容量变大时,bitmap 自身所占...
2019-01-21 10:35:56
301
原创 【PNFS学习】编解码实验记录
1 实验要求修改编解码函数,在客户端执行链接操作后,能在日志中打印出f_blocks、f_bfree、f_bavail、f_files、f_ffree信息。2 相关知识2.1 rpc发送过程2.2 详解statfs过程上图是客户端和服务器之间发送rpc的简单流程图,下面结合statfs函数,具体解释发送rpc过程中的编解码过程(以下顺序是按照实际编解码的过程)。Clie...
2018-10-23 16:33:54
566
原创 【PNFS学习】pNFS读流程追踪
一、如何追踪NFS客户端(client)和服务器(server)端的日志分别为:nfs_debug、nfsd_debug。它们的位置为:/proc/sys/sunrpc。这两个日志文件初始内容为:0,表示关闭,写入其他数字可以把它们打开。若不打开日志,运行dmesg命令之后,是无法看到在nfs源代码中输出的打印信息的。打开日志后,方可看到。二、打开日志AS端echo 32767 >...
2018-10-23 11:03:23
791
原创 Bandwidth
Given a graph (V,E) where V is a set of nodesand E is a set of arcs in VxV, and an ordering on the elementsin V, then the bandwidth of a node v isdefined as the maximum distance in the ordering betwee
2015-03-20 22:02:53
576
原创 Krypton Factor
ou have been employed by the organisers of aSuper Krypton Factor Contest in which contestants have very high mental andphysical abilities. In one section of the contest the contestants are tested onth
2015-03-20 22:00:20
711
原创 Prime Ring Problem
Description Aring is composed of n (even number) circles as shown in diagram. Put naturalnumbers into each circleseparately, and the sum of numbers in two adjacent circles should be a prime.
2015-03-20 21:58:19
422
原创 生成1~n的全排列
一、不可重集#includeusing namespace std;const int maxn=1000+5;void print_n(int n,int* A,int cur) //A是储存全排列的数组,cur是插入的位置{ if(cur==n) { for(int i=0;i<n;i++) printf("%d ",A[i]); printf("\n")
2015-03-20 21:44:16
1276
原创 Fractions Again?!
Fractions Again?!It is easy to see that for every fraction in the form 1/k (k > 0), we can always find two positive integers x and y, x >= y, such that: .Now our question is: can you write a pro
2015-03-04 22:26:50
767
原创 Maximum Product
Maximum ProductGiven a sequence of integers S = {S1, S2, ..., Sn}, you should determine what is the value of the maximum positive product involving consecutive terms of S. If you cannot find a posit
2015-03-04 22:23:49
525
原创 Division
Division Write a program that finds and displays all pairs of 5-digit numbers that between them use the digits 0 through 9 once each, such that the first number divided by the second is equal to an
2015-03-04 22:18:46
595
原创 【Jason's_ACM_解题报告】Partitioning by Palindromes
Partitioning by Palindromes 解题报告
2015-03-04 11:13:49
457
原创 Play On Words
DescriptionSome of the secret doors contain a very interesting word puzzle. The team of archaeologists has to solveit to open that doors. Because there is no other way to open the doors, the puzzl
2015-03-03 22:12:23
506
原创 Ordering Tasks
DescriptionJohn has n tasks to do. Unfortunately, the tasks are not independent and the execution of one task is only possible if other tasks have already been executed.InputThe input will consi
2015-03-03 19:35:50
548
原创 Abbott‘s Revenge
DescriptionThe 1999 World Finals Contest included a problem based on a “dice maze.” At the time the problem was written, the judges were unable to discover the original source of the dice maze conce
2015-03-03 16:56:15
1085
原创 Ancient Messages
DescriptionIn order to understand early civilizations, archaeologists often study texts written in ancient languages. One such language, used in Egypt more than 3000 years ago, is based on character
2015-03-02 12:58:09
658
原创 Oil Deposits
DescriptionThe GeoSurvComp geologic survey company is responsible for detecting underground oil deposits. GeoSurvComp works with one large rectangular region of land at a time, and creates a grid
2015-02-28 17:31:00
321
原创 【Jason's_ACM_解题报告】Amphiphilic Carbon Molecules
Amphiphilic Carbon Molecules 解题报告
2015-02-28 16:22:05
701
原创 Quadtrees
DescriptionA quadtree is a representation format used to encode images. The fundamental idea behind the quadtree is that any image can be split into four quadrants. Each quadrant may again be spli
2015-02-27 22:29:39
302
原创 The Falling Leaves
DescriptionEach year, fall in the North Central region is accompanied by the brilliant colors of the leaves on the trees, followed quickly by the falling leaves accumulating under the trees. If th
2015-02-27 16:38:30
379
原创 Not so Mobile
DescriptionBefore being an ubiquous communications gadget, a mobile was just a structure made of strings and wires suspending colourfull things. This kind of mobile is usually found hanging over c
2015-02-26 17:41:37
338
原创 Tree
DescriptionYou are to determine the value of the leaf node in a given binary tree that is the terminal node of a path of least value from the root of the binary tree to any leaf. The value of a pa
2015-02-26 15:35:29
328
原创 Trees on the level
BackgroundTrees are fundamental in many branches of computer science. Current state-of-the art parallel computers such as Thinking Machines' CM-5 are based on fat trees. Quad- and octal-trees are
2015-02-25 14:06:14
438
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人