Home > Lectures > Lecture Details

Review of Compilation Process of a Simple Program

By Jerry Cain - Stanford
get flash player

Lecture Description

Review of Compilation Process of a Simple Program Into a .O File, Effect of Commenting Out a C Standard Library .H File on the Resulting Translation Unit, How Gcc Infers a Prototype When None Is Found and the .O File Remains the Same, How the Gcc Linker Is Able to Link Standard Library Files Without a #Include, The (Similar) Result When the .H File with Malloc's Prototype Is Not Included, How Commenting Out Assert.H Creates Different Results, Failing In the Linker Since Assert Is a Macro, As Opposed to a Function In the Standard Libraries, Effect of Calling Strlen with the Wrong Number of Arguments on the Compilation/Linking Process, Effect of Calling Memcmp with too Few Arguments on the Compilation/Linking Process, How C++ Disambiguates Between Different Function Prototypes to Avoid the Problems Posed By the Previous Two Examples, Debugging Information - Seg Faults (Usually Dereferencing a Bad Pointer) Vs. Bus Errors (Dereferencing Data that Isn't Correctly Aligned), Debugging Example Where Overflowing an Integer Array Leads to an Infinite Loop, Similar Example with a Short Array that Works Differently on Big-Endian Systems Vs. Little-Endian Systems, Example Where an Array Overflow Overwrites the Saved PC and Leads to an Infinite Loop

Course Description

Related Resources

Transcript

Course Index

  1. Introduction to Programming Paradigms Course
  2. Data Types - Interpretations
  3. Converting Between Types of Different Sizes and Bit Representations Using Pointers
  4. Creating a Generic Swap Function for Data Types of Arbitrary Size
  5. Generic Lsearch - Prototype
  6. Integer Stack Implementation - Constructor and Destructor
  7. Problems with Ownership of Memory
  8. Heap Management - How Information about Allocations are Stored in the Heap
  9. How a Code Snippet is Translated into Assembly Instructions
  10. More Detail about Activation Records - Layout of Memory During a Function Call
  11. Moving from C Code Generation to C++ Code Generation: Basic Swap Example
  12. Preprocessing Commands
  13. Review of Compilation Process of a Simple Program
  14. Sequential Programming vs. Concurrent Programming
  15. Transitioning from Sequential Programming to Concurrent Programming in the Ticket Sale Example
  16. Semaphores
  17. Review of the Dining Philosopher Problem
  18. Ice Cream Store Problem
  19. Introduction to the Functional Paradigm (Scheme)
  20. Car-Cdr Recursion Problem
  21. Introduction to the Kawa Development Environment: Evaluation of Expressions
  22. Writing a Recursive Power Set Function in Scheme
  23. Scheme Memory Model
  24. Overarching Features of Python
  25. Python Object Model
  26. XML Processing and Python
  27. Introduction to Haskell