Operating Systems File Types Sort by usage A system files A user files E library files e Sort by data format A source files object files H executable files e Sort by access control attribution E executable-only files d-only file H read/write files Gao Haichang, Software School, Xidian University
Operating Systems Gao Haichang , Software School, Xidian University 8 File Types Sort by usage system files user files library files Sort by data format source files object files executable files Sort by access control attribution executable-only files read-only files read/write files
Operating Systems File Types(2) Sort by fi y le logical structure H structured files H unstructured files G Sort by file physical structure w sequential files H linking files A index files Gao Haichang, Software School, Xidian University
Operating Systems Gao Haichang , Software School, Xidian University 9 File Types (2) Sort by file logical structure structured files unstructured files Sort by file physical structure sequential files linking files index files
Operating Systems File Types (3) G uNX and windows have regular files and directories UNIX also has character and block special files. H Regular files: contain user information H Directories: system files for maintaining the structure of the file system a Character special files: related to lO r Block special files: used to model disks Regular files are generally either asci files or binary files. Gao Haichang, Software School, Xidian University 10
Operating Systems Gao Haichang , Software School, Xidian University 10 File Types (3) UNIX and Windows have regular files and directories. UNIX also has character and block special files. Regular files: contain user information. Directories: system files for maintaining the structure of the file system. Character special files: related to I/O. Block special files: used to model disks. Regular files are generally either ASCII files or binary files
Operating Systems File Types(4) Module Magic number Header Text size Data siz Date BSS size Object Symbol table size Owner module Entry point Protection Flag Header Text Object Data Relocation (a)an executable file symbol (b) An archive存档文件 Gao Haichang, Software School, Xidian University
Operating Systems Gao Haichang , Software School, Xidian University 11 File Types (4) (a) An executable file (b) An archive 存档文件
Operating Systems File Types(exercise) In an executable file, the instructions are usually put into the text segment. header, text, data, relocation bits, symbol table Gao Haichang, Software School, Xidian University 12
Operating Systems Gao Haichang , Software School, Xidian University 12 File Types (exercise) In an executable file, the instructions are usually put into the _______ segment. header, text, data, relocation bits, symbol table text