11 Matching Annotations
  1. Nov 2024
    1. Since a local variable’s declaration always occurs before it is used, the VM can resolve them at compile time, even in a simple single-pass compiler. That will let us use a smarter representation for locals.

      Local variables' declaration always occurs before it is used, the VM can resolve them at compile time, even in a simple single-pass compiler.

  2. Jun 2024
  3. Mar 2022
    1. ● Relocatable object file (.o file)○ Code and data that can be combined with other relocatable object files to form executable object file■ Each .o file is produced from exactly one source (.c) file● Executable object file (a.out file)○ Code and data that can be copied directly into memory and then executed● Shared object file (.so file)○ Special type of relocatable object file that can be loaded into memory and linked dynamically, at either load time or run-time

      compile 之后的 object files 有哪几种类型?

    2. ● Modularity○ Program can be written as a collection of smaller source files, rather than one monolithic mass.● Efficiency○ Time: Separate compilation■ Change one source file, compile, and then relink. No need to recompile other source files.○ Space: Libraries■ Common functions can be aggregated into a single file...

      linker 有什么好处?

    3. ● Processes #include, #define, #if, macros○ Combines main source file with headers (textually)○ Defines and expands macros (token-based shorthand)○ Conditionally removes parts of the code (e.g. specialize for Linux, Mac, ...)● Removes all comments

      Pre-Processor 部分的流程是什么?

  4. Nov 2021
  5. Nov 2020