Optimized C++ o Websites and handouts Optional: Effective C++, Scott Meyers. Fall 2013

Similar documents
CS 241 Data Organization using C

Advanced Programming CMPS 109

CASPER COLLEGE COURSE SYLLABUS MSFT 1600 Managing Microsoft Exchange Server 2003 Semester/Year: Fall 2007

San José State University Department of Computer Science CS151, Object Oriented Design, Section 04, Fall, 2016 (42968)

Object-Oriented Programming for Managers

MWF 9:00-9:50AM & 12:00-12:50PM (ET)

CSE 504: Compiler Design

While waiting for the lecture to begin, please complete. the initial course questionnaire.

CS 235AM, Mobile Application Development: Android Spring 2016

ECE573 Introduction to Compilers & Translators

Syllabus COSC-051-x - Computer Science I Fall Office Hours: Daily hours will be entered on Course calendar (or by appointment)

Data Structures and Algorithms

INFS 2150 (Section A) Fall 2018

B. Subject-specific skills B1. Problem solving skills: Supply the student with the ability to solve different problems related to the topics

CoSci 440 SYLLABUS Programming in C++ INSTRUCTOR Mari Rettke cell SECTION : and 13345

Fundamentals of Computer Science CSCI 136 Syllabus Fall 2018

BOSTON UNIVERSITY Metropolitan College MET CS342 Data Structures with Java Dr. V.Shtern (Fall 2011) Course Syllabus

CS/SE 153 Concepts of Compiler Design

San Jose State University College of Science Department of Computer Science CS151, Object-Oriented Design, Sections 1,2 and 3, Spring 2017

COSC 115A: Introduction to Web Authoring Fall 2014

COSC 115: Introduction to Web Authoring Fall 2013

Object Oriented Programming

Introduction to Programming System Design CSCI 455x (4 Units)

San José State University Department of Computer Science CS-144, Advanced C++ Programming, Section 1, Spring 2018

Updated: 2/14/2017 Page 1 of 6

CS 241 Data Organization. August 21, 2018

WAYLAND BAPTIST UNIVERSITY VIRTUAL CAMPUS SCHOOL OF BUSINESS SYLLABUS

CS 375 UNIX System Programming Spring 2014 Syllabus

Catholic University of America. School of Library and Information Science Fall Semester 2012 COURSE DESCRIPTION. Randolph Hock, Ph.D.

IT 341 Fall 2017 Syllabus. Department of Information Sciences and Technology Volgenau School of Engineering George Mason University

CIS 3308 Web Application Programming Syllabus

CISC 3130 Data Structures Spring 2018

Division of Engineering, Computer Programming, and Technology

CMPUT 391 Database Management Systems. Fall Semester 2006, Section A1, Dr. Jörg Sander. Introduction

EECE.2160: ECE Application Programming Spring 2017

PC Applications IT102 estart Fall 2014

NOTE: This syllabus is subject to change during the semester. Please check this syllabus on a regular basis for any updates.

The Linux Command Line: A Complete Introduction, 1 st ed., by William E. Shotts, Jr., No Starch Press, 2012.

CIS-255 Object Oriented Programming in C++ Bristol Community College Computer Information Systems Department Fall 2018

CSCI 434 INTRODUCTION TO LOCAL AREA NETWORKS (SPRING 2015)

CSCI 528: OBJECT ORIENTED PROGRAMMING, Fall 2015

San José State University Department of Computer Science CS-144, Advanced C++ Programming, Section 1, Fall 2017

Nashville State Community College Computer and Engineering Technologies Division Computer Information Systems. Master Course Syllabus

Beijing Jiaotong University CS-23: C++ Programming Summer, 2019 Course Syllabus

PROPOSAL TO INTRODUCE A NEW COURSE

Course specification

CPSC 2380 Data Structures and Algorithms

New Undergraduate Course Proposal Form

N/A. Yes. Students are expected to review and understand all areas of the course outline.

Data Structures and OO Development II

Survey of Programming Languages Dr. R. M. Siegfried 407 Science (516) (not for homework submission)

Syllabus for HPE 120 Dance Aerobic Proficiency 0.0 Credit Hour Spring 2012

Syllabus Revised 08/21/17

CMSC 341. Shawn Lupoli (substituting for Nilanjan Banerjee) UMBC CMSC 341 Intro 1

Oklahoma State University Institute of Technology Face-to-Face Common Syllabus Fall 2017

SYLLABUS. CODE: NETW 243 TITLE: Computer Repair & Maintenance. DIVISION: Business and Technology DEPARTMENT: Engineering & Technology

COURSE OUTLINE PRE-REQUISITES/CO-REQUISITES: COMP228, COMP214 COURSE ELIGIBILITY FOR PRIOR LEARNING ASSESSMENT AND RECOGNITION (PLAR):

San José State University Department of Computer Science CS049J, Programming in Java, Section 2, Fall, 2016

COMP229. Joanne Filotti

Programming Game Engines ITP 485 (4 Units)

A: 90% - 100% B: 80% - <90% C: 70% - <80% D: 60% - <70% F: < 60% Important Dates:

KOMAR UNIVERSITY OF SCIENCE AND TECHNOLOGY (KUST)

Syllabus. Computer Science Information Technology 975. Information Storage and Management for Computer Networks

N/A. Yes. Students are expected to review and understand all areas of the course outline.

CS 1044: Introduction to Programming in C++

EECE.2160: ECE Application Programming Spring 2019

Philadelphia University Faculty of Information Technology Department of Computer Science --- Semester, 2007/2008. Course Syllabus

Syllabus for HPE 099 Aerobic Proficiency 1 Credit Hour Fall 2012

Database Systems (INFR10070) Dr Paolo Guagliardo. University of Edinburgh. Fall 2016

Oklahoma State University Oklahoma City ITD 1113: Windows Expert User Syllabus Fall, 2014

CS/SE 153 Concepts of Compiler Design

CMSC Introduction to Database Systems

COLLEGE OF DUPAGE CIS 2542 Advanced C++ with Data Structure Applications Course Syllabus

CENTRAL TEXAS COLLEGE ITCC 1414 CCNA 1: Introduction to Networks. Semester Hours Credit: 4

South Portland, Maine Computer Information Security

CS 3230 Object Oriented UI Development With Java Syllabus

BRAZOSPORT COLLEGE LAKE JACKSON, TEXAS SYLLABUS. ITNW 2313: NETWORKING HARDWARE Online Course Version COMPUTER TECHNOLOGY DEPARTMENT

San Jose State University - Department of Computer Science

CS 200, Section 1, Programming I, Fall 2017 College of Arts & Sciences Syllabus

INST Database Design and Modeling - Section 0101 Spring Tentative Syllabus

Syllabus for HPE 099 Aerobic Proficiency 1 Credit Hour Spring 2015

Al al-bayt University Prince Hussein Bin Abdullah College for Information Technology Computer Science Department

CMPE/SE 135 Object-Oriented Analysis and Design

IST359 - INTRODUCTION TO DATABASE MANAGEMENT SYSTEMS

Lecture 0 of 41: Part A Course Organization. Introduction to Computer Graphics: Course Organization and Survey

Course Administration

Course Title: Network+/Networking Fundamentals. Course Section: CNS-101-I1. FORMAT: Online

Rochester Institute of Technology Golisano College of Computing and Information Sciences Department of Information Sciences and Technologies

SAULTCOLLEGE OF APPLIED ARTS AND TECHNOLOGY SAULT STE. MARIE, ONTARIO COURSE OUTLINE

CS 3270 Mobile Development for Android Syllabus

CMPE 152 Compiler Design

San Jose State University College of Science Department of Computer Science CS151, Object-Oriented Design, Sections 1, 2, and 3, Spring 2018

Philadelphia University Faculty of Information Technology Department of Computer Science --- Semester, 2007/2008. Course Syllabus

CIS* Programming

ITNW 1425 Fundamentals of Networking Technologies Course Syllabus fall 2012

Welcome. Orientation to online CPS102 Computer Science 2 (Java 2)

CS503 Advanced Programming I CS305 Computer Algorithms I

GET 433 Course Syllabus Spring 2017

CS313T ADVANCED PROGRAMMING LANGUAGE

COURSE SYLLABUS ****************************************************************************** YEAR COURSE OFFERED: 2015

Transcription:

Optimized C++ Gam 371/471/391/491 Instructor: Ed Keenan Email: ekeenan2@cdm.depaul.edu office hours: Tues 9-10 pm, Wed 3-5pm or by Appt office: CDM 830 phone: (312) 362-6747 Ed Keenan Fall 2013 Course Description This game programming class will focus on developing software to efficiently use the fixed CPU power and resources that are found in today's console and mobile devices. This course will use real-world game examples that demonstrate performance and optimization issues that software architects face in game development. These problems include: performance enhancements through extended matrix instruction set, dynamic memory usages, performance related to increasing run-time systems to very large scale, C++ language enhancements and extensions, algorithms, streaming and profiling. Prerequisites: Data Structures in Java or C++ (CSC 301, CSC 383, CSC 393, CSC 403) Computer Systems II (CSC 374, CSC 407) Discrete Math (CSC 400) Required Texts: The C++ Programming Language: Stroustrup o 4th Edition (new edition) or 3rd Edition (either are acceptable) o Stroustrup Addison-Wesley Longman/Pearson, 2014. ISBN: 978-0321563842 STL Tutorial and Reference Guide: C++ Programming with the Standard Template Library (2nd Edition) (Hardcover) - Musser, Derge, Saini ISBN-13: 978-0201379235 Additional material provide in class o Websites and handouts Optional: Effective C++, Scott Meyers Learning goals: - Understanding performance issues related to software construction o Data Layout o Processor Caching o Compiler issues o Algorithmic considerations o Containers and supplied systems o Single instructions and multiple data (SIMD) - Understanding Performance profiling o Monitoring and tracking performance metrics o Understanding the in system side effects - Understanding external system interrelated computer systems o Hard drives o Network systems effect performance o I/O devices 1

Grading: Everyone 10 % - C++ Proficiency programs 60 % - Programming Assignments PA1: Assessment 5% PA2: Caching / Data Alignment 10% PA3 : Memory 20% PA4 : C++ Efficiency 10% PA5: Math Optimizations 10% PA6: File Systems (part A) - 5% 10% - Final Exam 10% - Final Project Undergraduate 10% - Perforce Changelist comments + Piazza Graduate 10% - PA6: File Systems (part B) + Changelist comments + Piazza participation NOTE: You must pass the final exam (60% or higher) to receive a passing grade in the class. (It s not an easy exam) Programming assignments The intent assignments: Assignment 1 is a warm-up. Assignment 2-6 is to teach and demonstrate a new optimization concept. Program Assignment #1: Programming Assessment Do a programming test (It s easy) Learn how to use version control and process Programming warm up Give material for our first code review Program Assignment #2: Caching / Data Alignment Identifying data layout and alignment for supplied data structures and C++ classes Rework several data structures to reduce memory size Rework the supplied linked list data structure to a hot / cold data structure Program Assignment #3: Dynamic Memory in Real-time Create a memory system within a heap Overloading new/delete C++ functions Placement New Create a different memory pools for the supplied C++ classes Program Assignment #4: C++ Efficiency Implicit conversions Return value optimizations Proxy Objects Taking advantage of the compilers Program Assignment #5: Math optimizations Algorithm optimization Refactor several matrices transformations to use SSE vector instruction set, Vector Unit or intrinsic math functions supplied by the compilers. 2

Program Assignment #6: Reading / Writing files Read / Write Buffers Streaming Data Layout Operating systems specific functionality Final project Given a particle system that dynamically updates several particles. Every particle and controlling object is dynamically allocated, often in very large blotted data structures. Each particle is controlled per frame by its own unique math transformations that are unoptimized. The memory allocations in the system are slow and fragments memory as the number of particles increase. Some of the system uses STL in a very inefficient manor. Many C++ classes are inefficient and naïve in nature. Loading and saving is done again in a very simple way with a lot of hard drive seeking, reading and writing. Students refactor this system to: Maximize the number of particles to be processed with the given memory and performance constraint o Keep the frame rate constant to specified o Keep the memory within a fixed specified size Real working system o Program needs to cleanly be created and destroyed with no memory or resource leaks o Error free o Warning level 3 free or higher Program control o Be able to have the number of particles dynamically increased or decreased o Program needs to be able to be paused / resumed o Needs to be saved /restored with everything in the same state from a file Dynamic monitoring o Total memory consumption o Memory / particle ratio o Performance cycles o Particle stats It s a contest o See how you can improve to original system. A reflective paper describing the optimization issues presented in this project, 5 or more pages in length Changelist Comments Everyone is expected to submit detail Perforce changelists comments o For every assignment 4-100 individual changelists are expected with detailed comments. o These comments are in leiu of standard blogs o Please describe in a high level with a few bullet points the task being submitted. 3

Piazza Discussion forum Everyone is expected and encouraged to participate on the Piazza discussion forum. All class-related discussion here this term. The quicker you begin asking questions on Piazza (rather than via emails), the quicker you'll benefit from the collective knowledge of your classmates and instructors. We encourage you to ask questions when you're struggling to understand a concept. All correspondence that is not personal in nature should be vectored through Piazza Final Exam A comprehensive final exam, covering the concepts of this class. Closed book written exam. o 11 week of class You must pass the final exam (60% or higher) to receive a passing grade in the class. o It s not an easy exam C++ Proficiency Programs There will be 6-8 weekly proficiency exams, validating your C++ fundamental knowledge The programs are easy to implement, but is a motivator for those who need encouragement to learn more thoroughly the basics C++ material. Topics range from: o Overloading, pointers, STL and Templates o vtable, inheritance, C-Strings and debugging If you already know the material, the assignments are a way to validate that knowledge Collaborating together on programming assignments You are encourage to work together o Use the Piazza forums heavy o Even share your material with others in the common directory Everyone is 100% responsible for the work they do. o If you get help with a section of code, o Please refactor the code Comment and understand that material Transform the code to make it yours. System for Detecting Software Plagiarism o We will be using MOSS - Measure of Software Similarity (Standford University) o Indicates possible code infringements (plagiarism) If you gain significant support / help from another student o Fully disclose the support / help you had in a Readme.txt file submitted with your assignments. o Identify what code was heavily influence and how it helped you. Modifying any Unit Test to alter the outcome results is also an Academic Integrity Violation 4

Tentative Class Schedule Date Lecture Activity Due Week 1 Overview PA1 - Assessment 17-Sep General Optimizations Basics1 - Debugging Perforce Week 2 PA2 - Hot/Cold data Caching structures PA1 24-Sep Data Alignment Basics2 - Overloading Basics1 Hot/Cold Data Structures Week 3 Pointers PA3 - Memory System PA2 1-Oct Memory System Basics3 - Pointers Basics2 Week 4 Memory System Detail Basics4 - C Strings Basics3 8-Oct Implementation Testing and Verification Week 5 PA3 - complete Implicit Conversions PA4 - Proxy, Implicit, RVO 15-Oct Proxy Objects Basics5 - Inheritance Basics4 Return Value Optimization Week 6 Intrinsics - SSE, SIMD PA5 - SSE Math PA4 22-Oct Matrix Math Basics6 - vtable Basics5 Week 7 File system PA6 - File System PA5 29-Oct Load in Place Basics7 - Templates Week 8 Memory Overloading Particle System PA6 5-Nov Refactoring Basics8 - STL Basics7 Particle System Week 9 Profilers Basics8 12-Nov Strings PSE Week 10 C++ 11 / Boost 19-Nov Review Week 11 26-Nov Final Exam Performance Contest Particle System 5

School policies: Online Teaching Evaluation Evaluations are a way for students to provide valuable feedback regarding their instructor and the course. Detailed feedback will enable the instructor to continuously tailor teaching methods and course content to meet the learning goals of the course and the academic needs of the students. They are a requirement of the course and are key to continue to provide you with the highest quality of teaching. The evaluations are anonymous; the instructor and administration do not track who entered what responses. A program is used to check if the student completed the evaluations, but the evaluation is completely separate from the student s identity. Since 100% participation is our goal, students are sent periodic reminders over three weeks. Students do not receive reminders once they complete the evaluation. Students complete the evaluation online in CampusConnect. Email Email is the primary means of communication between faculty and students enrolled in this course outside of class time. Students should be sure their email listed under "demographic information" at CampusConnect is correct. Academic Integrity Policy This course will be subject to the academic integrity policy passed by faculty. More information can be found at http://academicintegrity.depaul.edu/ Plagiarism The university and school policy on plagiarism can be summarized as follows: Students in this course should be aware of the strong sanctions that can be imposed against someone guilty of plagiarism. If proven, a charge of plagiarism could result in an automatic F in the course and possible expulsion. The strongest of sanctions will be imposed on anyone who submits as his/her own work any assignment which has been prepared by someone else. If you have any questions or doubts about what plagiarism entails or how to properly acknowledge source materials be sure to consult the instructor. Incomplete An incomplete grade is given only for an exceptional reason such as a death in the family, a serious illness, etc. Any such reason must be documented. Any incomplete request must be made at least two weeks before the final, and approved by the Dean of the College of Computing and Digital Media. Any consequences resulting from a poor grade for the course will not be considered as valid reasons for such a request. Resources for Students with Disabilities Students who feel they may need an accommodation based on the impact of a disability should contact the instructor privately to discuss their specific needs. All discussions will remain confidential. To ensure that you receive the most appropriate accommodation based on your needs, contact the instructor as early as possible in the quarter (preferably within the first week of class), and make sure that you have contacted the Center for Students with Disabilities (CSD) at: Student Center, LPC, Suite #370 Phone number: (773)325.1677 Fax: (773)325.3720 TTY: (773)325.7296 6