CS162 Operating Systems and Systems Programming Lecture 28 ManyCore, Quantum Computing and Other TopicsRequests for Final TopicsManyCore Chips: The future is on the wayTraditional Parallel OSSome Tricky Things about Parallel OSsSlide 6ManyCore opportunities: Rethink the SinkImportant New Mechanism: Spatial PartitioningOS as Distributed SystemIt’s all about the communicationTessellation: The Exploded OSSpace-Time PartitioningAnother Look: Two-Level SchedulingTessellation Partition ManagerAdministriviaRealtime OS/Embedded ApplicationsManyCore and RealtimeAchieving Responsiveness & Agility in TessellationQuantum ComputingCan we Use Quantum Mechanics to Compute?Quantization: Use of “Spin”Kane Proposal II (First one didn’t quite work)Now add Superposition!Implications: A register can have many valuesSpooky action at a distanceModel? Operations on coefficients + measurementsSecurity of FactoringShor’s Factoring AlgorithmSome Issues in building quantum computerION Trap Quantum Computer: Promising technologyConclusionsGood Bye!CS162Operating Systems andSystems ProgrammingLecture 28ManyCore, Quantum Computingand Other TopicsDecember 10, 2008Prof. John Kubiatowiczhttp://inst.eecs.berkeley.edu/~cs162Lec 28.212/10/08 Kubiatowicz CS162 ©UCB Fall 2008Requests for Final Topics•Some topics people requested:–Dragons: too big of a topic for today–ManyCore Operating Systems–Quantum Computers (and factoring)–Mobile Operating Systems–User Sessions–Power Management–Data Privacy–Berkeley OS History•Today:–ManyCore/Parallel OS–Realtime OS–Quantum Computing and Quantum factoring•Other Topics:–Come look for me at office hours (Or any other time)Lec 28.312/10/08 Kubiatowicz CS162 ©UCB Fall 2008ManyCore Chips: The future is on the way•“ManyCore” refers to many processors/chip–64? 128? Hard to say exact boundary•How to program these?–Use 2 CPUs for video/audio–Use 1 for word processor, 1 for browser–76 for virus checking???•Something new is clearly needed here…•Intel 80-core multicore chip (Feb 2007)–80 simple cores–Two floating point engines /core–Mesh-like "network-on-a-chip“–100 million transistors–65nm feature sizeFrequency Voltage Power Bandwidth Performance3.16 GHz 0.95 V 62W 1.62 Terabits/s 1.01 Teraflops5.1 GHz 1.2 V 175W 2.61 Terabits/s 1.63 Teraflops5.7 GHz 1.35 V 265W 2.92 Terabits/s 1.81 TeraflopsLec 28.412/10/08 Kubiatowicz CS162 ©UCB Fall 2008Traditional Parallel OS•Job of OS is support and protect–Need to stay out of way of application•Traditional single-threaded OS–Only one thread active inside kernel at a time»One exception – interrupt handlers»Does not mean that that there aren’t many threads – just that all but one of them are asleep or in user-space»Easiest to think about – no problems introduced by sharing–Easy to enforce if only one processor (with single core)»Never context switch when thread is in middle of system call»Always disable interrupts when dangerous –Didn’t get in way of performance, since only one task could actually happen simultaneously anyway•Problem with Parallel OSs: code base already very large by time that parallel processing hit mainstream–Lots of code that couldn’t deal with multiple simultaneous threads One or two locks for whole systemLec 28.512/10/08 Kubiatowicz CS162 ©UCB Fall 2008Some Tricky Things about Parallel OSs•How to get truly multithreaded kernel?–More things happening simultaneouslyneed for:»Synchronization: thread-safe queues, critical sections, …»Reentrant Code – code that can have multiple threads executing in it at the same time»Removal of global variables – since multiple threads may need a variable at the same time–Potential for greater performanceneed for:»Splitting kernel tasks into pieces •Very labor intensive process of parallelizing kernel–Starting from pre-existing code base: very hard–Needed to rewrite major portions of kernel with finer-grained locks»Shared among multiple threads on multiple processors Must satisfy multiple parallel requests »Bottlenecks (coarse-grained locks) in resource allocation can kill all performance•Truly multithreaded mainstream kernels are recent: –Linux 2.6, Windows XP, …Lec 28.612/10/08 Kubiatowicz CS162 ©UCB Fall 2008How Should OSs Change for ManyCore?Lec 28.712/10/08 Kubiatowicz CS162 ©UCB Fall 2008ManyCore opportunities: Rethink the Sink•Computing Resources are not Limited–High Utilization of every core unnecessary–Partition Spatially rather than Temporally•Protection domains not necessarily heavyweight–Spatial Partitioning protection crossing as simple as sending a message from one part of chip to another•I/O devices not necessarily limited and do not need to be heavily multiplexed–High bandwidth devices available through network–FLASH or other persistent storage yields fast, flat hierarchy (not necessarily disk as bottleneck)•New constraints–Power/Energy major concern–Security extremely important–Parallelism must be exploited in applications»Extremely important for OS to get out of the wayLec 28.812/10/08 Kubiatowicz CS162 ©UCB Fall 2008Important New Mechanism: Spatial Partitioning•Spatial Partition: group of processors acting within hardware boundary –Boundaries are “hard”, communication between partitions controlled–Anything goes within partition•Each Partition receives a vector of resources–Some number of dedicated processors–Some set of dedicated resources (exclusive access)»Complete access to certain hardware devices»Dedicated raw storage partition–Some guaranteed fraction of other resources (QoS guarantee):»Memory bandwidth, Network bandwidth»fractional services from other partitions•Key Idea: Resource Isolation Between PartitionsLec 28.912/10/08 Kubiatowicz CS162 ©UCB Fall 2008•Use lessons from from Large Distributed Systems–Like Peer-to-Peer on chip–OS is a set of independent interacting components–Shared state across components minimized•Component-based design: –All applications designed with pieces from many sources–Requires composition: Performance, Interfaces, Security•Spatial Partitioning Advantages:–Protection of computing resources not required within partition»High walls between partitions anything goes within partition»“Bare Metal” access to hardware resources–Partitions exist simultaneously fast communication between
View Full Document