2. PINTOS :: project 2 - System Call
·
CS/Computer System
/* The main system call interface */voidsyscall_handler (struct intr_frame *f UNUSED) { // TODO: Your implementation goes here. uint64_t syscall_no = f->R.rax; // 콜 넘버 // uint64_t a1 = f->R.rdi; // 파일 네임 // uint64_t a2 = f->R.rsi; // v(데이터) // uint64_t a3 = f->R.rdx; // 사이즈 // uint64_t a4 = f->R.r10; // uint64_t a5 = f->R.r8; // uint64_t a6 = f->R.r9; switch (f->R.rax) { // rax is the..
2. PINTOS :: project 2 - User Program
·
CS/Computer System
static boolload (const char *file_name, struct intr_frame *if_) { ... /* Start address. */ if_->rip = ehdr.e_entry; /* TODO: Your code goes here. * TODO: Implement argument passing (see project2/argument_passing.html). */ //1. 첫 주소 부터 글자의 길이(끝에 \0포함) 만큼 넣어준다 // 글자 길이 만큼 저장 위치가 감소 해야 한다. (거꾸로) // argv[0]까지 = RDI: 4 uintptr_t start_p = (if_ -> rsp); //초기 시작 포인터 저장 uintptr_t curr = 0; //계속 갱신 되는 임..
내 꿈은 어느 날 문득 그렇게 이루어졌다.
'sw jungle' 태그의 글 목록