1 / 18

Course Outline

Course Outline. Computer System Programming. The programs implemented in either software and (or) firmware that makes the computer hardware usable. 系統程式就是驅動電腦硬體工作之 軟體 及 軔體 程式。 燒錄在硬體(例如 ROM 、 EPROM … )之軟體為軔體;基本輸出 / 輸入系統( Basic Input Output Systems ),它就是一種軔體 。. 系統程式所包含的範圍. SP.

toby
Télécharger la présentation

Course Outline

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Course Outline Computer System Programming The programs implemented in either software and (or) firmware that makes the computer hardware usable. 系統程式就是驅動電腦硬體工作之軟體及軔體程式。 燒錄在硬體(例如ROM、EPROM…)之軟體為軔體;基本輸出/輸入系統(Basic Input Output Systems),它就是一種軔體。

  2. 系統程式所包含的範圍 SP

  3. Types of System Software 1. Utility Program and Library(公用程式及庫存函數) a. System Command b. Library e.g. OCX,DLL 2. Debugging Aids(除錯工具) a. Program Trace (Assign Breakpoint) * 印出各個變數或暫存器(Register)的內容 b. Debug Command, Norton Utility,PC Tools,… * 在DOS環境下,可以使用Debug這個命令 c. Core Dump dbx or gdb(GNU Tool) d. Diagnostic 在程式內加上print敘述,是一種土法鍊鋼的方式。

  4. Types of System Software 3. Macro Processor(巨集處理器) • * Macro Definition • * Macro Call (Macro Expansion) (巨集呼叫、巨集的展開)

  5. Types of System Software * Macro Definition * Macro Call (Macro Expansion) The macro processor replaces each macro instruction with the corresponding group of source Language Statements 巨集處理器會將巨集所定義的原始程式敘述取代巨集呼叫 * Function Call (Closed Subroutine)(函數呼叫) Calling Program transfers of data and control to called program。 當函數被呼叫時,參數會傳至函數內,而且執行的控制權也會轉至函數內,一直到函數Return為止。 * Macro Call (Open Subroutine)(巨集呼叫) This means its code is inserted into the program。

  6. Types of System Software Run fast macro call use more memory space Less memory space function call spend more CPU time (STACK) * 通常我們講求執行速度的時候(希望執行速度快),會考慮使用巨集,這是以空間換取時間。 * 反之函數佔主記憶體空間較少,但是使用到疊堆 (STACK),速度相對會慢一些。時間換取空間

  7. Types of System Software 4. Text Editor(文字編譯器) a. Screen editor MS-Word b. Typesetting(排版)

  8. Types of System Software 5. Translator(轉譯器) The language translator translates source program to their machine language equivalents. 將原始程式翻譯成機器語言,必須靠轉譯器來執行。 轉譯器大概可以被區分為 編譯器(Compiler) 組譯器(Assembler) 解譯器(Interpreter)。

  9. Types of System Software 6. Compiler(編譯器) C,C++,COBOL,… language

  10. Types of System Software 7. Assembler(組譯器)

  11. Types of System Software 8. Interpreter (解譯器) BASIC, HTML,Java Script ,VB Script,……language a.將原始程式直接透過解譯器執行。 b.解譯器將原始程式的一個敘述翻成中間碼。 c.將中間碼送入解譯器相對功能之程式中,以便執行。 d.重複執行步驟b及步驟c。

  12. Types of System Software Interpreter (解譯器) Java好處 * Byte Code是一種與機器無關(Machine Independent)的語言 * 可以跨平台在不同種類的電腦內執行。

  13. Types of System Software 9. Linker(連結器) Combines two or more separate object programs and supplies the information needed to allow reference between them。

  14. Types of System Software Linker

  15. Types of System Software 10.Loader * 狹義的是指將執行模組載入主記憶體內,然後執行。 * 廣義的意思則包含四大功能 1.分派(Allocation) 指定執行模組所要擺放的記憶體位置。 2.連結 (Linking) 連結函數外部的變數。意思是說某個函數使用的(或參考到的)變數不在此函數內,而是被定義在別的函數內,我們透過連結器將它們連結在一起。

  16. Types of System Software 載入器 3.重定位 (Relocation) 修訂執行模組,使得它可以載入記憶體內不同位置。意思是說執行模組執行時,或許在主記憶體1000這個位置,下次執行時或許在3020這個位置,它是可以隨時定位的。 4.載入 (Loading) 將執行模組載入主記憶體內,然後執行。

  17. 何謂作業系統 11. Operating System(作業系統) 只有硬體而沒有加上軟體及軔體的電腦為裸機(Bare Machine) 作業系統四大管理 1. Memory Management(記憶體管理) 管理主記憶體,並決定那一支程式可以佔有主記憶體,那一支程式不能使用主記憶體,…。 2. Processor / Process Management(處理器 / 處理元管理) 中央處理器之使用。 3. Device Management(設備管理) 管理輸出輸入週邊設備之運作,尤其必須有設備驅動程式(Device Driver)來驅動設備工作。 4. Information Management(資訊管理) 管理磁碟、磁片、光碟內之檔案結構及其內容。

  18. 系統軟體與機器結構 12. Relationship between system software and machine architecture * Machine dependent(與機器相關) Instruction Set,Instruction Format,Addressing Mode, Assembly language… * Machine independent(與機器無關) General design logic/strategy, two passes assembler…

More Related