Operating Systems (CS 161) - 2022 Spring




First time reviewing a module? Click here.First time reviewing a module? Click here.

Click to access marginalia information, such as reflections from the module designer, pedagogical decisions, and additional sources.

Click "Download full module write-up” to download a copy of this module and all marginalia information available.

Module Topic: Ethical Tradeoffs in Operating Systems Design: A Look at Cost-Benefit Analysis
Module Author: Sophie Gibert

Download full module write-up

Course Level: Upper-level undergraduate
AY: 2020-2021

Course Description

“This course focuses on the design and implementation of modern operating systems. The course discusses threads, processes, virtual memory, schedulers, and the other fundamental primitives that an OS uses to represent active computations. An exploration of the system call interface explains how applications interact with hardware and other programs which are concurrently executing. Case studies of popular file systems reveal how an OS makes IO efficient and robust in the midst of crashes and unexpected reboots. Students also learn how virtualization allows a physical machine to partition its resources across multiple virtual machines. Class topics are reinforced through a series of intensive programming assignments which use a real operating system.” (Course description)

Semesters Taught: Spring 2019, Spring 2020, Spring 2021, Spring 2022


  • Operating systems [CS]
  • Virtualization [CS]
  • Cost-benefit analysis [Phil]
  • Tradeoffs [Phil]
  • Time discounting [Phil]
  • Social discount rate [Phil]
  • Marketed and non-marketed goods [Phil]
  • Incommensurability [Phil]
  • Monetization [Phil]
  • Aggregation [Phil]
  • Distribution [Phil]
  1. Module Overview: In designing operating systems, engineers must often make tradeoffs—for example, between speed and safety, or features and robustness. A common method for making such tradeoffs is cost-benefit analysis (CBA), a normative framework according to which one should do whatever maximizes the overall ratio of benefits to costs. This module acquaints students with CBA and has them apply key parts of CBA to a scenario in operating systems design. It also introduces students to important ethical objections to CBA and helps them identify situations in which CBA is a problematic way of resolving tradeoffs.
Connection to Course Technical Material: Select circle icon with letter 'i' to read the marginalia for this paragraph

The topic was chosen because of its direct connection to the technical material covered in the course. According to the professor, CBA is a common method for operating systems engineers to employ in their decision-making. The central case study used in the module involved virtualization technology, which is one of the main topics covered in the course. The case study was developed in collaboration with former Embedded EthiCS TAs and the professor.

Students in this course learn about operating systems design. CBA is commonly used to resolve the tradeoffs that inevitably arise in operating systems design. It is therefore worth examining CBA in more detail and considering the ethical issues it raises.


Module Goals

By the end of the module, students will be able to:

  1. Describe the steps of CBA and say how it can be used to resolve tradeoffs.
  2. Perform several key steps of CBA on a scenario in operating systems design.
  3. Explain and evaluate some prominent ethical objections to CBA and say how they are relevant to operating systems.
  4. Identify situations in which CBA is a problematic way of resolving tradeoffs.

Key Philosophical Questions Select circle icon with letter 'i' to read the marginalia for this paragraph

Question 1: Students will be familiar with the basic idea of CBA from daily work and life but will not have examined its steps or applied it to operating systems design.

Question 2: CBA is a highly controversial method for resolving tradeoffs. Some of the most prominent objections relate to incommensurability, distribution/aggregation, and time discounting.

Question 3: Students will learn to be cautious in applying CBA when the kinds of value at stake seem incommensurable with each other (or with monetary value) and when benefits and costs befall different groups. In addition, they will learn to apply time discounting selectively.

  1. What is CBA, and how is it used in operating systems design?
  2. What are some of the most prominent ethical objections to CBA, and at which steps of CBA do they arise?
  3. In what situations is CBA a problematic way of resolving tradeoffs?


Key Philosophical Concepts Select circle icon with letter 'i' to read the marginalia for this paragraph

Cost-benefit analysis (CBA) is a normative framework for resolving tradeoffs. According to CBA, one ought to take the option that has the highest ratio of benefits to costs.

One key step of CBA involves identifying a common measure of value, so that benefit-to-cost ratios can be computed and compared across options. Typically, monetary value is selected as the common measure; as such, each cost and benefit must be monetized, or assigned a monetary value.

Another important step in CBA calls for discounting future costs and benefits according to a social discount rate, to obtain their net present value. Ethical questions arise when future non-marketed goods, as opposed to marketed goods and money, are discounted, especially when they are expected to accrue to future generations.

Two prominent ethical objections to CBA are the incommensurability objection, according to which certain values or bearers of value have no common measure, and the aggregation or distribution objection, according to which costs and benefits should not be aggregated across individuals.

Assigned Readings

  • Boardman et al., “The Basic Steps of CBA: Coquihalla Highway Example,” in Chapter 1 of Cost-Benefit Analysis: Concepts and Practice, 3rd Edition (1996). Select circle icon with letter 'i' to read the marginalia for this paragraph

    Boardman et al. introduce the steps of CBA, using the example of highway construction.

  • Hansson, Sven Ove, “Cost-Benefit Analysis: Philosophical Issues,” in The New Palgrave Dictionary of Economics (2010). Select circle icon with letter 'i' to read the marginalia for this paragraph

    Hansson briefly explains the most prominent ethical and philosophical objections to CBA, including those related to incommensurability and distribution/aggregation.


Class Agenda

  1. Professor introduces technical material regarding virtualization and motivates the topic by presenting a real-life case of computer scientists using CBA to resolve a tradeoff (10 minutes)
  2. Introduction and preparation for small-group discussion (5 minutes)
  3. Activity in small groups: Scaffolded application of CBA to a scenario in operating systems design, aided by a worksheet, pausing at multiple points for class-wide discussion (50 minutes)
  4. Class-wide summative discussion of CBA as a method for resolving tradeoffs in operating systems design; concluding remarks (10 minutes)

Sample Class Activity Select circle icon with letter 'i' to read the marginalia for this paragraph

The fictionalized case focused on virtualization technology because this is a central topic covered in the course.

The worksheet questions were designed to break CBA into manageable parts and generate discussion. They focused on the incommensurability and aggregation/distribution objections in large part because these were the two objections that students reported finding most concerning in their reading responses.

Students work in small groups to apply CBA to a fictionalized scenario in operating systems design. They are provided with a worksheet that breaks CBA into 7 steps and prompts them to consider two prominent ethical issues along the way. The 7 steps are:

  • Specify the options
  • Identify stakeholders
  • Determine the costs and benefits of each option
  • Identify a common measure of value
  • Discount future costs and benefits
  • Account for uncertainty
  • Recommend

Steps 1 and 2 are not the focus of this module, so students are provided with two plausible options and a list of key stakeholders. Students do not perform steps 5 or 6 during the module, but step 5 is explored in the post-module assignment. The worksheet therefore focuses on steps 3, 4, and 7. During step 4, students discuss the incommensurability objection to CBA. During step 7, students discuss the distribution/aggregation objection.

The fictionalized case is designed by the TA in collaboration with the professor and former TAs. In the case, engineers design an operating system called “Sparrow,” which uses virtualization technology. As the system is tested in preparation for its release, two bugs are discovered: one that disproportionately affects users with non-English keyboard setups, and one that disproportionately affects Windows app users. Students consider whether to proceed in launching the system with the bugs or delay the release date (thereby upsetting shareholders) and fix them.

Module Assignment Select circle icon with letter 'i' to read the marginalia for this paragraph

According to the reading responses, the vast majority of students found the incommensurability problem to be the most concerning and intractable problem for CBA. The aggregation problem was the next most common answer.

Before the module, students answer two reading response questions:

  1. Boardman, Greenberg, Vining, and Weimer introduce the steps of Cost-Benefit Analysis. Which step seems the most difficult to perform, and why?
  2. Sven Ove Hansson identifies several philosophical and ethical issues with Cost-Benefit Analysis. Which issue seems the most concerning to you, and why?

After the module, students complete an assignment as part of a problem set. The assignment focuses on step 5, discounting future costs and benefits. Students are introduced to the distinction between marketed and non-marketed goods and the reasons in favor of applying time-discounting to marketed goods and money. They are asked to consider the extent to which these reasons also apply to non-marketed goods, such as human wellbeing. They are then asked to examine some of the future costs and benefits that they identified in step 3 of the in-class activity and explain whether they should be discounted or not. Lastly, the assignment touches on the idea of intergenerational justice and the additional ethical problems that arise when future costs and benefits are likely to befall not-yet-existing future people.

Lessons Learned

Students responded very positively to this module. Engagement was high during the activity portion, and class-wide discussions were lively. The vast majority of the students shared or asked a question at some point.

Students reported that they enjoyed learning about CBA and applying it to the operating systems context. They also reported having gained a lot from discussing the worksheet questions with their classmates and hearing other people share responses they hadn’t thought of.

Pedagogical lessons learned:

  • Worksheets are highly effective in this setting. They set clear expectations and provide a lot of structure. This is important in classrooms where students are not used to discussing ethics with their peers.
  • They also contribute to engagement by giving students something to write on and minimizing their use of electronics. Writing forces students to put their thoughts onto paper, which can reveal gaps in their reasoning and understanding that would go overlooked in a typical conversation.
  • Having students introduce themselves to their small groups at the start of class is effective and especially important in lecture-style classrooms where students are not often asked to speak with their peers.
    Operating Systems (CS 161) - 2022 Spring122 KB