, , , , ,

[SOLVED] Project 1a: sorting within a range

$25

File Name: Project_1a:_sorting_within_a_range.zip
File Size: 320.28 KB

Categories: , , , , , Tags: , , , , ,
5/5 - (1 vote)

To build a sorting program called rangesort that takes in one of the generated files and sorts it based on the 4-byte key (the remainder of the record should of course be kept with the same key). Keys which fall outside of lowvalue and highvalue should be discarded (and not written to the output file). The output is written to the specified output file.#### Project 1b: xv6 Intro
To add two system calls to xv6. The system calls are:1. getsyscallnumtotal() returns the total number of system calls that have been issued.
2. getsyscallnumsuccess() returns the number of system calls that have completed successfully (i.e., did not have a return value of -1).## My work#### Linux: rangesortDiscard the unqualified records when read-in, i.e. before sorting. Use strtoul() to convert the strings into numbers and do error handling. Store the lowValue and highValue into lowValue_ul and highValue_ul first and perform validation check. Assigned to lowValue_u and highValue_u if passed, which are used for discarding.#### xv6: add two system callsMake changes in the following files:
user/user.h, user/usys.S, kernel/sysfunc.h, kernel/proc.h, kernel/syscall.c, kernel/sysproc.c, include/syscall.hThe crucial part is in syscall() function of kernel/syscall.c. We increment the two global counters in it.

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.

Shopping Cart
[SOLVED] Project 1a: sorting within a range
$25