Archive for October 2012
Introduction to x86 Assembly Language
CIS-77 Home http://www.c-jump.com/CIS77/CIS77syllabus.htm
Introduction to x86 Assembly Language
- Advantages of High-Level Languages
- Why program in Assembly ?
- Here is why...
- Speed, Efficiency, Debugging, Optimization...
- Why MASM ?
- Introduction to 80x86 Assembly Language
- Materials on the Web
- Useful books, in no particular order
- Fundamental Concepts
- Software Environment
- Runtime Environment
- M1.ASM
- Assembly and C Code Compared
- More Assembly and C Code
- Assembly vs. Machine Language
- Controlling Program Flow
- Conditional Jumps
- General-Purpose Registers
- Typical Uses of General-Purpose Registers
- x86 Registers
- x86 Registers, Cont
- x86 Control Registers
- MOV, Data Transfer Instructions
- Ambiguous MOVes: PTR and OFFSET
- INC and DEC Arithmetic Instructions
- ADD Arithmetic Instruction
- ADD vs. INC
- SUB Arithmetic Instruction
- SUB vs. DEC
- CMP instruction
- Unconditional Jumps
- Conditional Jumps
- Conditional Jumps, Cont
- Conditional Jumps, Cont
- LOOP Instruction
- Logical Instructions
- Logical Instructions, Cont.
- Shift Instructions
- SHL and SHR Shift Instructions
- Shift Instructions Examples
- Rotate Instructions
- ROL and ROR, Rotate Without Carry
- RCL and RCR, Rotate With Carry
- EQU directive
- EQU Directive Syntax
Bristol Community College
Computer Information Systems Department
CIS-77 Home http://www.c-jump.com/CIS77/CIS77syllabus.htm
CIS-77 Introduction to Computer Systems
- Welcome!
- ________________________________________________________
- Posted Dec 29:
- Please make sure that your read carefully and
understand course policies and formats.
Catalog Description
This course is an introduction to major components of computer systems. The course introduces fundamental concepts of computing systems such as binary arithmetic and data representation, the Von Neumann model for processing computer programs, the operation of memory, instruction set, and machine and assembly language programming. It systematically presents the levels of transformations from machine language to assembly language to high-level language. The course studies the role of such systems software components as assemblers, compilers, linkers, loaders, and operating systems. The course has a strong project component. Three class hours and two lab hours per week.
Igor.Kholodov@bristolcc.edu
Office: K211
Telephone: 508-678-2811 ext. 3328
Course Objectives
Upon completion of this course, the students should be able to do the following:
- Identify and describe different types of computing machines
- Describe distinguishing components of Von-Neumann Architecture
- Describe how computing machines are organized internally
- Identify and explain the design trade offs between different computing machines
- Describe how computers perform calculations
- Understand principals of machine language and program in assembly.
- Describe the relation between high level languages and assembly.
- Define systematic sequence of transformations between layers of abstraction.
- Explain how bits and bytes are organized to represent data electronically.
- Describe how digital logic is used to build circuits to process information
- Indicate program organization in memory
- Understand program stack, stack frames, procedure calls, and parameters
Course Outline
- Week 1. Number systems, Bits, Data Types, and Operations.
- Presentation: Introduction to Computer Systems (handout)
- Presentation: Bits, Numbers, and Binary Data Representation (handout)
Assignment A01: Pages 17-20, Exercises 1.4, 1.9, 1.10, 1.15-17, 1.21 and 1.23
Reading: Textbook Chapters 1 and 2.
Week 2. Digital Logic Structures- Presentation: Digital Logic (handout)
- Presentation: Arithmetic Operations and Logical Functions (handout)
Lab L01: Pages 43-50, Exercises 2.10-11, 2.13-14, 2.17 (interpret bits as signed
numbers, use calculator, sign-extend to 8 or 16 bit quantities as necessary), 2.18-19, 2.30, 2.32-35, 2.43 and 2.45-50 (use calculator as necessary), 2.53-54
Reading: Textbook Chapter 3.
Week 3. Memory and Sequential Logic Circuits- Presentation: Storage Elements (handout)
- Presentation: Sequential Logic Circuits (handout)
Lab L02: Using Digital Works- Download: Digital Works
- Assignment A02: Pages 43-50, Exercises 2.1-3, 2.5, 2.8, 2.12, 2.15, 2.21 (hint:
refer to the "Overflow Condition" described in first week's lecture), 2.23. 2.27-29, and 2.31
Reading: Textbook Chapter 4.
Week 4. The Von Neumann Model- Presentation: The von Neumann Computer Model (handout)
Lab L03: Two's Complement Adder/Subtractor- Assignment A03: Pages 82-91, Exercises 3.1, 3.10, 3.13-14, 3.23, and 3.32
Reading: Intel Basic Architecture Volume 1, Chapter 2, Introduction to the Intel Architecture.
Week 5. Introduction to x86 Assembly Language- Presentation: Introduction to x86 Assembly Language (handout)
- Presentation: The Assembly Process (handout)
Discussion: Overflow Detection Circuits (handout)- Lab L04: Overflow Detector
- Assignment A04: Pages 111-114, Exercises 4.1-4, 4.5a, 4.5b.1, 4.5b.2, 4.5b.4, and 4.9.
Reading: Intel Basic Architecture Volume 1, Chapter 3, Basic Execution Environment.
Week 6. Instruction Set Architecture Design- Presentation: Instruction Format Design (handout)
- Presentation: Encoding Real x86 Instructions (handout)
- Presentation: The Instruction Cycle (handout)
Quick Reference: x86 Instructions by Opcode- Quick Reference: x86 Instructions by Mnemonic
- Quick Reference: Brief x86 Instruction Set Reference
Lab L05: Design of a 4-bit Magnitude Comparator- Assignment A05:
- Install Visual Studio.
- Use Visual C++ Development Environment (handout) to assemble and debug a do-nothing program M1.ASM
Reading: Intel Instruction Set Reference Volume 2, Chapter 2, Instruction Format.
Week 7. Language Components of MASM- Presentation: Language Components of MASM (handout)
Registers, EFLAGS, Addressing Modes, Effective Address.
Lab L06: Boolean Algebra Theorems and Sum of Products
Reading: Intel Instruction Set Reference Volume 2, Appendix B, Instruction formats and encodings.
- Presentation: Language Components of MASM (handout)
Week 8. Data Types and Memory Allocation- Presentation: Data Types and Memory Allocation (handout)
Endianness, Integer Formats, Copying Data.
Reference: Intel Volume 1, Basic Architecture in HTML format,
or download single 1.9 MB ZIP archive.- Reference: Intel Volume 2, Instruction Set Reference in HTML format,
or download single 4.2 MB ZIP archive.
Lab M07: Opcode Analysis using OllyDbg
- Presentation: Data Types and Memory Allocation (handout)
Week 9. CPU Flags and Data Manipulation- Presentation: CPU Flags and Data Manipulation (handout)
ADD, INC, SUB, DEC, NEG, Carry Flag, Overflow Flag, SHL, SHR, and SAR
Quick Reference: Intel Basic Architecture Volume 1,
Appendix A: EFLAGS cross-reference
Appendix B: EFLAGS condition codes
Lab M08: Console Input/Output (slide version)
- Presentation: CPU Flags and Data Manipulation (handout)
Week 10. Controlling Program Flow- Presentation: Controlling Program Flow (handout)
Lab M09: Data Arrays, Windows API Calls (slide version)
Week 11. Modes of Memory Addressing on x86 and Logical Segments- Presentation: Modes of Memory Addressing on x86 (handout)
Reading: Intel System Programing Guide Volume 3, Chapter 3, Protected-mode memory management.
Lab M10: Integer Arithmetic Part 1: High-speed Multiplication by Powers of 2 (slideversion)
Week 12. Memory Protection, Paging, and Memory Model Directives- Presentation: Memory Protection (handout)
- Presentation: Logical Segments and Memory Model Directives (handout)
Reading: Intel System Programing Guide Volume 3, Chapter 4, Memory protection.
Lab M11: Integer Arithmetic Part 2: Extended Precision Techniques (slide version)
Week 13. Instruction Operand Addressing on x86- Presentation: Instruction Operand Addressing on x86 (handout)
Reading: Intel Basic Architecture Volume 1, Chapter 5, Data Types and Addressing Modes.
Lab M12: Step-by-step execution analysis (slide version)
Week 14. The Program Stack and Procedures- Presentation: The Program Stack (handout)
- Presentation: Procedures (handout)
Reading: Intel Basic Architecture Volume 1, Chapter 4, Procedure Calls, Interrupts, and Exceptions.
Lab M13: Building Your Own Stack Machine, Final Project (slide version)
Week 15. Final Project Review
Required Text
Authors: Sanjay J. Patel, Yale Patt
Title: Introduction to Computing Systems: From Bits and Gates to C and Beyond. See also: Student Resources. Publisher: McGraw-Hill, 2nd Edition, 2004. ISBN-13: 9780072467505 ISBN-10: 0072467509 |
Reference Materials
- Reference: Intel Volume 1, Basic Architecture in HTML format (or 1.9 MB ZIP)
- Reference: Intel Volume 2, Instruction Set Reference in HTML format (or 4.2 MB ZIP)
- Quick Reference: x86 Instructions by Opcode
- Quick Reference: x86 Instructions by Mnemonic
- Quick Reference: Brief x86 Instruction Set Reference
File M00.zip contains DOS batch files that used in class to assemble small ASM programs. To build your program, simply drag and drop your ASM file on top of- _release_build.bat - to build a program.
- _debug_build.bat - to build a program with debug info;
Same ASM file in M00project.zip added to MSVC 2005 project, which can be used to to assemble, link, and debug the program.
Another MSVC 2005 project, M08project.zip, can be used as a starting point for M08lab, Console Input/Output.
OllyDbg Debugger for Microsoft Windows: a debugger that emphasizes binary code analysis. Download OllyDbg 1.10 (final version).
Any opinions, findings, conclusions, and recommendations expressed in this material are those of the author(s) and do not necessarily reflect the views of the National Science Foundation (NSF).
Windows 7: Map a Network Drive
This tutorial will show two ways you can map a network share as a network drive. By mapping a network drive in this fashion, it will have a drive letters just like a local harddrive. This make access more efficient and convenient. Some programs that are unable to use network shares will function when mapped to a drive using this method.
There are several methods for mapping the network share to a drive. I’ll demonstrate two of these methods.
From Windows Explorer:
1.Go to your Start Menu and then Right-Click on Computer. Then choose the Map Network Drive option.
2.In the Map Network Drive window, fill in or browse for the network share. You will also set the drive letter to which you would like to assign the share.
If the network share has a different login or password, you can use the Connect using different credentials checkbox and fill in your username and password.
3.Click Finish and the drive will map and a new Windows Explorer window will open. The network share will not appear as a drive.
From Command Line:
1. Go to your Start Menu and type command and click on Command Prompt under the Programs section. This will open the classic Command Prompt terminal window.
2.From the command line, we will use the “net use” command. Here’s the command structure with explanation of each of the parts afterwards.
net use drive: \\computername\sharename /Persistent:yes
drive: = driver letter to map share (for example, M: or N:)
\\computername\sharename = UNC path to network share, (for example, \\jimmy7\shared or\\10.100.1.3\shared.
/Persistent:yes = This option will force the drive to remap each time you reboot. Remove this option if you only want it mapped during this session.
Additional Hints:
Using the command line instructions, you can create a batch file and run it from your desktop to map drives when you need them.
Additionally, the following command will unmap a network drive from the command prompt or a batch file:
net use drive: /delete
(where drive: = mapped drive, ie E: or N:)
Tag :
Window 7
How Do I Use Two Monitors with Windows 7?
These days everybody has more than one monitor available. However, running a dual monitor setup can be tricky to get working correctly. This tech-recipes tutorial will get you started.
These directions are for Windows 7 although the directions for XP and Vista are very similar.
Dual monitors rule! First things first, make sure your computer can support two monitors. The box will need the right outputs for dual monitors. I use a higher end GPU which allows me multiple HDMI outputs; however, Windows 7 is smart enough to use outputs of different types. For example, if you computer has a DVI and VGA outputs, you still can get a dual setup working. Most laptops have an external monitor connection which can be used as your second monitor.
How Do I Use Two Monitors with Windows 7?
These days everybody has more than one monitor available. However, running a dual monitor setup can be tricky to get working correctly. This tech-recipes tutorial will get you started.
These directions are for Windows 7 although the directions for XP and Vista are very similar.
Dual monitors rule! First things first, make sure your computer can support two monitors. The box will need the right outputs for dual monitors. I use a higher end GPU which allows me multiple HDMI outputs; however, Windows 7 is smart enough to use outputs of different types. For example, if you computer has a DVI and VGA outputs, you still can get a dual setup working. Most laptops have an external monitor connection which can be used as your second monitor.
1.Open the Start button on your desktop and in the search bar type Display. Click on theDisplay option when it appears.
2.From this control panel screen select Adjust Resolution on the left.
3.Your second monitor should be detected. If it is not click Detect then Identify. My favorite thing to do is use both monitors as one big desktop. To do this, under Multiply Display selectExtend these displays. You will likely want to make sure your left monitor is set as the main display where your Windows task bar will appear.
4.You can also duplicate the display which clone the image one one monitor to the second one.
Hopefully, you are now running a two monitor setup. If you find yourself having trouble getting your second monitor to display, just post in the comments and I will help you out. Check out Jimmy’s dual monitor tricks for additional cool things to do with a two monitor configuration.
Install Pear on Windows 7 64x using WAMP
Installing PEAR on Windows 7 seems simple; however, a few headaches with some recent versions of PHP can leave some people confused. The go-pear.bat file doesn’t exist in some 64x downloads of WAMP and PHP. By following these steps to workaround this issue, you should be able to get Pear installed into your WAMP setup.
You must have WAMP installed correctly first.
1We need to first locate the file go-pear.bat in our WAMP PHP install directory. In the current installation, this is located at C:\wamp\php\php5.3.13 although this will change based on your current version. In WAMP 64-bit versions sometimes this file is not included. Instead we can use the file go-pear.phar which can be downloaded here from pear.php.net.
2Put this file in the following directory:
C:\wamp\bin\php\php5.1.13
(This directory may be different depending on your version of PHP.)
3Now, pull up the Windows start menu, type in CMD, then hit enter. We need to look at the folder we just put the .phar file in, so enter this string:
cd C:\wamp\bin\php\php5.3.13
and hit enter. We should now be looking in this directory.
4Next, we will need to run this .phar file by using the following command:
php go-pear.phar
5It will ask “Are you installing a system-wide PEAR or local copy?” You will need to type “local” and hit enter. It will ask you to confirm by typing “yes” and hitting enter.
6You will be shown the 12 file locations corresponding to where PEAR will install packages, documents, config files and more. I just leave these on default in my WAMP PHP folder. Press enter to bypass this and accept this.
7You may receive the following error:
This is letting you know your php.ini file doesn’t have the path that you just specified above in the CMD. If you type a simple “Y” and hit enter, the php.ini file will automatically be updated. Go ahead and do this if needed.
8You should be done with the CMD part now. If everything worked correctly, you should be notified that “The ‘pear’ command is now at your service…”
9Next, we need to add pear’s path to make sure that installing packages work. Go to Windows and type in System and hit enter. Click on Advanced System Settings on the left, then under the Advanced tab click Environment Variables.
Edit the Path Variable and append the location to your PHP version folder in wamp:
C:\wamp\bin\php\php5.3.13;
Hit okay to save it. Be sure to include the semi-colon at the end of the folder path.
10Now open back up our CMD and type in pear followed by enter. If everything is working correctly, you should see pear’s list of commands.
Tag :
Window 7
Intro to Algorithms - Lydia Sinapova
Lecture Notes
Based on Mark Allen Weiss,
Based on Mark Allen Weiss,
ISBN 0-321-37013-9
- Mathematical review (PPT frames) (PPT printable) (PDF)
- Basic Algorithm Analysis
- Data structures
- Lists and Stacks (PPT frames) (PPT printable)
- Queues (PPT frames) (PPT printable)
- Trees (PPT frames) (PPT printable)
- Binary search trees, (PPT frames) (PPT printable)
- Digital / Radix trees (PPT frames) (PPT printable)
- AVL trees (PPT frames) (PPT printable)
- Hash tables
- Hash functions, Hash tables (PPT frames) (PPT printable)
- Collision resolution: Separate chaining (PPT frames) (PPT printable)
- Collision resolution: Open Addressing. Extendible hashing, (PPT frames) (PPT printable)
- Priority Queues (PPT frames) (PPT printable)
- Applications of Priority Queues - the Selection Problem (PPT frames) (PPT printable)
- Sorting Algorithms
- Insertion Sort (PPT frames) (PPT printable)
- Shell Sort (PPT frames) (PPT printable)
- Heapsort (PPT frames) (PPT printable)
- Recurrence relations
- Mergesort (PPT frames) (PPT printable)
- Quick Sort (PPT frames) (PPT printable)
- External Sort
- Review of sorting algorithms
- Elementary Graph Algorithms
- Graphs: Basic concepts (PPT frames) (PPT printable)
- Graphs: Topological sort (PPT frames) (PPT printable)
- Shortest Path Algorithms ( PPT frames) (PPT printable)
- Spanning Trees, Prim's algorithm, Kruskal's algorithm (PPT frames) (PPT printable)
- Scheduling Networks (PPT frames) (PPT printable )
- Breadth-First and Depth-First Search in a Graph (PPT frames) (PPT printable )
- Applications of Depth-First Search: Connectivity (PPT frames) (PPT printable )
- Applications of Depth-First Search in a Graph - Eulerian Graphs
- Summary of Graph Algorithms (PPT frames) (PPT printable )
- Algorithm Design Techniques (Summary) (PPT frames) (PPT printable )
- Complexity Issues (PPT frames) (PPT printable )
- Conclusion
Tag :
Algorithms
Download Student Files
Web Design | |
HTML for EmailsDownloadshtml_for_emails-course_files.zip (1687KB) | Introduction to HTMLDownloadsintroduction_ to_html-course_files.zip (2868KB) |
Introduction to JavaScriptDownloadsintroduction_to_javascript-course_files.zip (1702KB) | Advanced Website Design Using CSSDownloadscss_advanced_website_design-course_files.zip (1144KB) |
Dreamweaver CS6: Website DevelopmentDownloadsdreamweaver_cs6_website_development-course_files.zip(6718KB) | jQuery: Interactive Website CreationDownloadsjquery-interactive_website_creation-course_files.zip (3315KB) |
Microsoft Applications | |
Excel 2003 Level 1Downloadsexcel_2003_level1-course_files.zip (952KB) | Excel 2003 Level 2Downloadsexcel_2003_level2-course_files.zip (651KB) |
Advanced Project 2007Downloadsadvanced_project_2007-course_files.zip (1442KB) | Excel 2003 Level 3Downloadsexcel_2003_level3-course_files.zip (1213KB) |
Excel 2007 Visual Basic for ApplicationsDownloadsexcel_2007_vba-course_files.zip (1015KB) | Project 2007Downloadsproject-2007-course_files.zip (1451KB) |
Word 2007 Level 3Downloadsword_2007_level3_dyn135-course_files.zip (4844KB) | Excel 2007 Level 1Downloadsexcel_2007_level1_dyn110-course_files.zip (2839KB) |
Advanced Access 2007 - MasterclassDownloadsaccess_2007_masterclass_v1-course_files.zip (25541KB) | Excel 2007 Level 2Downloadsexcel_2007_level2_dyn115-course_files.zip (9889KB) |
Excel 2007 Level 3Downloadsexcel_2007_level3_dyn120-course_files.zip (2637KB) | Fast Track To Access 2007Downloadsfast_track_to_microsoft_access_2007_v1-course_files.zip(25541KB) |
Outlook 2007 Level 1Downloadsoutlook_2007_level1-course_files.zip (10835KB) | Outlook 2007 Level 2Downloadsoutlook_2007_level2-course_files.zip (15453KB) |
PowerPoint 2007 Level 1Downloadspowerpoint_2007_level1_inf732-course_files.zip (10393KB) | PowerPoint 2007 Level 2Downloadspowerpoint_2007_level2_inf733-course-files.zip (6932KB) |
Word 2007 Level 1Downloadsword_2007_level1_dyn125-course-files.zip (5240KB) | Word 2007 Level 2Downloadsword_2007_level2_dyn130-oourse_files.zip (20608KB) |
Excel 2010 Level 1Downloadsexcel_2010_level1-course_files.zip (2995KB) | Excel 2010 Level 2Downloadsexcel_2010_level2-course_files.zip (7640KB) |
Excel 2010 Level 3Downloadsexcel_2010_level3-course_files.zip (2616KB) | Word 2010 Level 1Downloadsword_2010_level1-course_files.zip (10655KB) |
Word 2010 Level 2Downloadsword_2010_level2-course_files.zip (7231KB) | Word 2010 Level 3Downloadsword_2010_level3-course_files.zip (7117KB) |
PowerPoint 2010 Level 1Downloadspowerpoint_2010_level1-course_files.zip (29378KB) | Upgrading to Office 2010Downloadsupgrading_to_office_2010-course_files.zip (9259KB) |
PowerPoint 2010 Level 2Downloadspowerpoint_2010_level2-course_files.zip (31275KB) | Outlook 2010 Level 1Downloadsoutlook_2010_level1-course_files.zip (26702KB) |
Outlook 2010 Level 2Downloadsoutlook_2010_level2-course_files.zip (49927KB) | Fast Track to Visio 2010Downloadsfast_track_to_visio_2010-course_files.zip (13361KB) |
Project 2010Downloadsproject_2010-course_files.zip (7454KB) | Fast Track To Access 2010Downloadsfast_track_to_access_2010_v1.0-course_files.zip (6384KB) |
Advanced Access 2010 - MasterclassDownloadsaccess_2010_masterclass_v1.0-course_files.zip (12496KB) | Access 2007 - Visual Basic for ApplicationsDownloadsaccess_2007_vba_v1.3-course_files.zip (14150KB) |
Computer Basics - Windows 7Downloadscomputer_basics_windows7-course_files.zip (3207KB) | |
Web Development | |
Dreamweaver CS6: Dynamic Application DevelopmentDownloadsdreamweaver_CS6_dynamicapplicationdev-course_files.zip(1683KB) | Introduction to PHP and MySQLDownloadsintroduction_to_php_mysql_5-course_files.zip (104KB) |
MYOB | |
Fast Track to MYOBDownloadsfast_track_to_myob_v19-course_files.zip (1601KB) | MYOB PayrollDownloadsmyob_v19_payroll-course_files.zip (1276KB) |
Tag :
Education