Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

This project aims to design and implement a StackFrame module that provides the functionality to establish the base pointer and return address in the caller’s stack frame and also print out stackframe data. This project helps understand stack frames through inline assembly with x86-64 in AT&T syntax.

NotificationsYou must be signed in to change notification settings

ChedySmaoui/C-StackFrame-Printer

Repository files navigation

Please give me a star if this was useful to you!

Objective

This project aims to design and implement a StackFrame module that provides the functionality to establish the base pointer and return address in the caller’s stack frame and also print out stackframe data. This project helps understand stack frames through inline assembly with x86-64 in AT&T syntax.

Grade Received: 20/20

1. How to build

SeeMakefile for the build scripts.

To build theTryStackFrames executable, simply runmake at the command line in the current directory.

To compile and run the test suite, runmake Tests.

Important: the commandmake clean will try to delete any executable or .o files in the src directory (tests or main executable files included).

2. Project Overview

  1. My program implementation is inStackFrames.c
  2. Theheader file has been edited to add MACRO definitions
  3. TheMakefile has been edited to implement to make the test suite executables.

3. Testing Framework

To compile and run the test suite, runmake Tests. This will automatically print the Stack Frames for different variants of executeFactorial.The stack frames printed out are for the following factorial numbers: 0!, 1!, 7!, 10!, and 20!.

  1. TestFactorial0 is a variant almost identical toFactorial but performs factorial(0,1).
  2. TestFactorial1 is a variant almost identical toFactorial but performs factorial(1,1).
  3. TestFactorial7 is a variant almost identical toFactorial but performs factorial(7,1).
  4. TestFactorial10 is a variant almost identical toFactorial but performs factorial(10,1).
  5. TestFactorial20 is a variant almost identical toFactorial but performs factorial(20,1).

About

This project aims to design and implement a StackFrame module that provides the functionality to establish the base pointer and return address in the caller’s stack frame and also print out stackframe data. This project helps understand stack frames through inline assembly with x86-64 in AT&T syntax.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp