update
[staff/goc4/2018bti7061.git] / c-project / INSTRUCTIONS.txt
CommitLineData
462e967d
CG
1You are to implement a C tool similar to "ps x -o pid,comm,rss"
2that will show for each process that shares your user ID the amount of
3memory it is using. Scan the /proc directory to find all active
4processes by their process ID (PID). You can find all of the
5information you need for each process under /proc/$PID/status, in
6particular the lines "Name", "Uid" and "VmRSS".
7
8Your output should list on seperate lines the PID, binary name of the
9process and the resident set size (RSS), separated by spaces.
10Your process must return 0 upon successful completion.
11
12Your C program must be called "ps.c". You will be graded for style
13(compiler warnings (-Wall), memory leaks, etc.) as well as for correct
14output.
15
16Test your program using the "test.sh".