Changes

Jump to: navigation, search

Winter 2015 SPO600 Weekly Schedule

2,941 bytes added, 16:08, 4 January 2015
Introduction to the Problem
=== Tuesday (Jan 13) ===
==== Introduction to the Problem Problems ====
===== Porting and Portability =====* Most software is written in a '''high-level language''' which can be compiled into [[Machine Language|machine code]] for a specific computer architecture. In many cases, this code can be compiled for multiple architectures. However, there is a lot of existing code that contains some architecture-specific code fragments written in [[Assembly Language]] (or, in some cases, machine-specific high-level code).
* Reasons for writing code in Assembly Langauge include:
** Performance
* Most of the historical reasons for including assembler are no longer valid. Modern compilers can out-perform most hand-optimized assembly code, atomic operations can be handled by libraries or [[Compiler Intrinsics|compiler intrinsics]], and most hardware access should be performed through the operating system or appropriate libraries.
* A new architecture has appeared: Aarch64, which is part of [http://www.arm.com/products/processors/instruction-set-architectures/armv8-architecture.php ARMv8]. This is the first new [[Computer Architecture|computer architecture]] to appear in several years (at least, the first mainstream computer architecture).
* There are over 1400 At this point, most key open source software (the software packages/modules typically present in GNU a Linux systems which contain distribution such as Ubuntu or Fedora, for example) now runs on AArch64. However, it may not run as well as on older architectures (such as x86_64). ===== Benchmarking and Profiling =====Benchmarking involves testing software performance under controlled conditions so that the performance can be compared to other software, the same software operating on other types of computers, or so that the impact of a change to the software can be gauged. Profiling is the process of analyzing software performance on finer scale, determining resource usage per program part (typically per function/method). This can identify software bottlenecks and potential targets for optimization. ===== Optimization =====Optimization is the process of evaluating different ways that software can be written or built and selecting the option that has the best performance tradeoffs. Optimization may involve substituting software algorithms, altering the sequence of operations, using architecture-specific [[Assembly Language|assembly language code]] , or altering the build process. It is important to ensure that the optimized software produces correct results and does not cause an unacceptable performance regression for other use-cases, system configurations, operating systems, or architectures. The definition of "performance" varies according to the target system and the operating goals. For example, in some contexts, low memory or have storage usage is important; in other cases, fast operation; and in other portability issuescases, low CPU utilization or long battery life may be the most important factor. It is often possible to trade off performance in one area for another; using a lookup table, for example, can reduce CPU utilization and improve battery life in some algorithms, in return for increased memory consumption.  Most advanced compilers perform some level of optimization, and the options selected for compilation can have a significant effect on the trade-offs made by the compiler, affecting memory usage, execution speed, executable size, power consumption, and debuggability. ===== Build Process =====Building software is a complex task that many developers gloss over. The simple act of these compiling a program invokes a process with five or more stages, including pre-proccessing, compiling, optimizing, assembling, and linking. However, a complex software system will have hundreds or even thousands of source files, as well as dozens or hundreds of build configuration options, auto configuration scripts (cmake, autotools), build scripts (such as Makefiles) to coordinate the process, test suites, and more. The build process varies significantly between software packages cannot . Most software distribution projects (including Linux distributions such as Ubuntu and Fedora) use a packaging system that further wraps the build process in a standardized script format, so that different software packages can be built on Aarch64 systems without modificationusing a consistent processNote that the build time for a complex package can range up to hours or even days to perform a full build!
==== Course Projects ====

Navigation menu