OS frontiers in the AI era

Felix Lin
Felix LinResearch at Nokia
OS frontiers in the AI era
Felix Xiaozhu Lin
1
Who Am I
• Fall 2020. Assoc. Prof, UVA CS – Looking forward to it!
• 2014 – 2020. Asst. Prof, Purdue ECE
• 2014 PhD in CS. Rice 
• 2008 MS + BS. Tsinghua
2
What is an OS?
Undergrads (Some) data scientists Tech media
4
Are these OSes?
the era of AI!
Where are 
we today?
5
https://en.wikipedia.org/wiki/Time_(xkcd)#/media/File:Xkcd_time_frame_0001.png
The 3rd boom of AI 
1960s 1970s 1980s 1990s 2000s 2010s 2020s
Classical AI Expert systems Machine learning
Ups
Downs
6
Two Pendulums
1960s 1970s 1980s 1990s 2000s 2010s 2020s
Expert systems Machine learning
Ups
Downs
Centralized
Decentralized
Dedicated
hw & net
PC + Internet
Datacenters
Cloud computing
5G, edge, 
embedded AI…
7
Classical AI
Two Pendulums
1960s 1970s 1980s 1990s 2000s 2010s 2020s
Expert systems Machine learning
Generalized
Specialized
Microcomputers,
x86, DBMS, PC
Mainframes,
Apollo11
Ups
Downs
Wearables/IoT, 
NoSQL, GPU/FPGA, RISCV
Centralized
Decentralized
Dedicated
hw & net
PC + Internet
Datacenters
Cloud computing
5G, edge, 
embedded AI…
8
Classical AI
Two Pendulums
1960s 1970s 1980s 1990s 2000s 2010s 2020s
Expert systems Machine learning
Generalized
Specialized
Microcomputers,
x86, DBMS, PC
Mainframes,
Apollo11
Ups
Downs
Wearables/IoT, 
NoSQL, GPU/FPGA, RISCV
Centralized
Decentralized
Dedicated
hw & net
PC + Internet
Datacenters
Cloud computing
5G, edge, 
embedded AI…
9
Classical AI
My view of OS
OS == System Software == Software Infrastructure 
12
What you have learnt from undergrad OS class
1960s 1970s 1980s 1990s 2000s 2010s 2020s
GOFAI Expert systems Machine 
learning
Generalized
Specialized
Microcomputers,
x86, DBMS, PC
Mainframes,
Apollo11
Ups
Downs
Wearables/IoT, 
NoSQL, GPU/FPGA, RISCV
Centralized
Decentraliz
ed
Dedicated
hw & net
PC + Internet
Datacenters
Cloud 
computing
5G, edge, 
embedded AI…
14
What OS people are working on
1960s 1970s 1980s 1990s 2000s 2010s 2020s
GOFAI Expert systems Machine 
learning
Generalized
Specialized
Microcomputers,
x86, DBMS, PC
Mainframes,
Apollo11
Ups
Downs
Wearables/IoT, 
NoSQL, GPU/FPGA, RISCV
Centralized
Decentraliz
ed
Dedicated
hw & net
PC + Internet
Datacenters
Cloud 
computing
5G, edge, 
embedded AI…
15
So, where are 
we today?
17
• Diverse 
• A few common OSes
• Many specialized ones
• Serving “things” in addition to humans
• Defined by scenarios
• Generic OSes  firmware
• Specialized OSes  overlays
• Blurry boundaries
• arch, runtime, compiler, kernel, 
hypervisor, trusted exec environment…
Cloud
Edge
Devices
18
Three flavors of OS research
1. Tune up
2. Do a specific thing well
3. Show possibility 
Common themes:
open blackboxes, 
break, & build
19
Case 1: A highspeed stream 
analytics engine
21
High‐throughput. Sub‐second delay.
Timely processing before data gets cold!  22
“Hot springs”: telemetry events
Power sensor
140M events/day
Oil rig
1‐2TB/day
Manufacturing machines
PBs/day
Stream analytics: state of the art
• Classic engines?
• StreamBase, Aurora, TelegraphCQ, NiagaraST…
• Single threaded. Not scaling well. 
• Modern engines for datacenters?
• Apache Flink, Spark Streaming, Beam…
• Designed for tens ‐ hundreds of machines. Scaling out. 
• Assuming okay if individual nodes perform poorly
• As analytics moves to the edge  bad
23
Project StreamBox
stream analytics at the memory speed
24
• RDMA
• Co‐designed with 
mm/scheduling
• RDMA
• Co‐designed with 
mm/scheduling
Stream pipeline Threads
Ingestion
Scheduler
Mem
• Squeeze parallelism for 
multi/manycore
• Manage NUMA domains
• Squeeze parallelism for 
multi/manycore
• Manage NUMA domains
Exploit high‐bandwidth memoryExploit high‐bandwidth memory
[ASPLOS'19] "StreamBox‐HBM: Stream Analytics on High Bandwidth Hybrid Memory," Hongyu Miao, Myeongjae Jeon, Gennady Pekhimenko, 
Kathryn S. McKinley, and Felix Xiaozhu Lin
[USENIX ATC'17] "StreamBox: Modern Stream Processing on a Multicore Machine," Hongyu Miao, Heejin Park, Myeongjae Jeon, Gennady 
Pekhimenko, Kathryn S. McKinley, and Felix Xiaozhu Lin, in Proc. USENIX Annual Technical Conference, 2017.
[ASPLOS'16] "memif: Towards Programming Heterogeneous Memory Asynchronously," Felix Xiaozhu Lin and Xu Liu, in Proc. ACM Int. Conf. 
Architectural Support for Programming Languages and Operating Systems, 2016.
CoresCores
High‐bandwidth hybrid memory
25
3D DRAM Normal DRAM
Tradeoffs: capacity vs. bandwidth
Untraditional memory hierarchy
No latency benefit 
Unlike SRAM+DRAM
16 GB
375 GB/s
~100 GB
~100 GB/s
26
Already on off‐the‐shelf machinesIntel Xeon Phi Knights Landing (KNL)
27
HBM
CoresCores
Normal DRAM
Streaming
data
Data Bundles
Index
{key, pointer}
Capacity: Use HBM only for grouping indexes
28
Cheap VM
(huge page)
Apps
OS
kernel
Fast net stack
(40 GbE or RDMA)
High task 
parallelism
Custom mem 
allocator
Sequential mem
access
Runtime
Thread pool 
+ custom task scheduler
Wide SIMD 
(avx512)
Hybrid
memory
A system software’s approach to 3D DRAM
Blurry boundaries
Case 2: Autonomous AI on 
Cameras
[MobiSys'20] "Approximate Query Processing on Autonomous Cameras," Mengwei Xu, Xiwen Zhang, Yunxin Liu, 
Xuanzhe Liu, and Felix Xiaozhu Lin 29
X1Video: a killer AI application
30
31
32
33
Cut the cords
Run on harvested energy
Solar 
Wind 
34
35
… and on wireless
Construction sites Farms
Boats/RVs Warehouses
Photos Credits: Reolink
36
Pervasive cameras
Object 
Counts
Elf
Running analytics on wire‐free 
cameras?
37
Query: (car, 30 mins)
Install
7:00AM-7:30AM [500 + 100] Cars
7:30AM-8:00AM [700 + 140] Cars
8:00AM-8:30AM [800 + 180] Cars
8:30AM-9:00AM [400 + 100] Cars
9:30AM-10:00AM [200 + 80] Cars
Sample & 
capture
200‐80 +80
Elf: Query model
38
Camera Operating System
Planning Energy via 
Reinforcement Learning
Planning Energy via 
Reinforcement Learning
Sampled frames
Aggregator
with error
Integration
Aggregator
with error
Integration
Selected NeuralNet
Object
counts
Elf: System Internals
39
Elf prototype: heterogeneous processors
40
7:00AM-7:30AM [500 + 100] Cars
7:30AM-8:00AM [700 + 140] Cars
8:00AM-8:30AM [800 + 180] Cars
8:30AM-9:00AM [400 + 100] Cars
9:30AM-10:00AM [200 + 80] Cars
Ground
Truth
Error:
11%
Confidence interval width: 17%
Auburn, AL
Hampton, NY Jackson, WY
Taipei Taipei
~1000 hours 
41
M4
AUTONOMOUS
Intelligence
OS for AI + AI for OS 
= Autonomous infrastructure
42
Case 3: Kernel IO on co‐processors 
43
44
45
Weak co‐processors
46
CPU Co
Proc
2.5GHz 50MHz
DRAM IO
A heterogeneous SoC
47
CPU Co
Proc
2.5GHz 50MHz
DRAM IO
Weak co‐processors: suits low‐power IO tasks!
high 
efficiency
Linux Kernel
IO 
tasks
48
CPU Co
Proc
2.5GHz 50MHz
DRAM IO
Kernel execution on weak co‐processors?
Linux Kernel
IO 
tasks
Diff ISA
No MMU
…
49
CPU Co
Proc
DRAM IO
Co‐processor translates unmodified kernel binary
Dynamic
Binary
Translation
Linux Kernel
IO 
tasks
[USENIX ATC 19] "Transkernel: An Executor for Commodity Kernels on Peripheral Cores," 
Liwei Guo, Shuang Zhai, Yi Qiao, and Felix Xiaozhu Lin
Take away: 
• Taming an OS kernel (a beast) for new hardware 
• … without re‐engineering much of the software stack 
50
Recap
• What are OSes in 2020?
• Three OS projects: 
• spanning IoT, mobile, and datacenters
• each with different flavors
• The builder culture 
• open blackboxes
• break things
• build things from the ground up
• Started by a small group of hardcore hackers
• Now more diverse and inclusive 
• A brave new world
51
StreamBox
Elf
Image credits
• https://dsportmag.com/the‐tech/test‐n‐tune/test‐tune‐2017‐subaru‐wrx‐
sti‐part3‐closer‐to‐the‐ej257s‐limits/
• https://techcrunch.com/2009/11/19/redneck‐rampage‐a‐truck‐with‐a‐jet‐
engine/?utm_source=feedburner#038;utm_medium=email
52
1 of 46

Recommended

ChatGPT and the Future of Work - Clark Boyd by
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
22.6K views69 slides
Getting into the tech field. what next by
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
5.5K views22 slides
Google's Just Not That Into You: Understanding Core Updates & Search Intent by
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
6.2K views99 slides
How to have difficult conversations by
How to have difficult conversations How to have difficult conversations
How to have difficult conversations Rajiv Jayarajah, MAppComm, ACC
4.7K views19 slides
Introduction to Data Science by
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data ScienceChristy Abraham Joy
82.2K views51 slides
Time Management & Productivity - Best Practices by
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
169.7K views42 slides

More Related Content

Recently uploaded

Evolving the Network Automation Journey from Python to Platforms by
Evolving the Network Automation Journey from Python to PlatformsEvolving the Network Automation Journey from Python to Platforms
Evolving the Network Automation Journey from Python to PlatformsNetwork Automation Forum
13 views21 slides
The Research Portal of Catalonia: Growing more (information) & more (services) by
The Research Portal of Catalonia: Growing more (information) & more (services)The Research Portal of Catalonia: Growing more (information) & more (services)
The Research Portal of Catalonia: Growing more (information) & more (services)CSUC - Consorci de Serveis Universitaris de Catalunya
80 views25 slides
"Running students' code in isolation. The hard way", Yurii Holiuk by
"Running students' code in isolation. The hard way", Yurii Holiuk "Running students' code in isolation. The hard way", Yurii Holiuk
"Running students' code in isolation. The hard way", Yurii Holiuk Fwdays
11 views34 slides
GDG Cloud Southlake 28 Brad Taylor and Shawn Augenstein Old Problems in the N... by
GDG Cloud Southlake 28 Brad Taylor and Shawn Augenstein Old Problems in the N...GDG Cloud Southlake 28 Brad Taylor and Shawn Augenstein Old Problems in the N...
GDG Cloud Southlake 28 Brad Taylor and Shawn Augenstein Old Problems in the N...James Anderson
85 views32 slides
Design Driven Network Assurance by
Design Driven Network AssuranceDesign Driven Network Assurance
Design Driven Network AssuranceNetwork Automation Forum
15 views42 slides
Powerful Google developer tools for immediate impact! (2023-24) by
Powerful Google developer tools for immediate impact! (2023-24)Powerful Google developer tools for immediate impact! (2023-24)
Powerful Google developer tools for immediate impact! (2023-24)wesley chun
10 views38 slides

Recently uploaded(20)

"Running students' code in isolation. The hard way", Yurii Holiuk by Fwdays
"Running students' code in isolation. The hard way", Yurii Holiuk "Running students' code in isolation. The hard way", Yurii Holiuk
"Running students' code in isolation. The hard way", Yurii Holiuk
Fwdays11 views
GDG Cloud Southlake 28 Brad Taylor and Shawn Augenstein Old Problems in the N... by James Anderson
GDG Cloud Southlake 28 Brad Taylor and Shawn Augenstein Old Problems in the N...GDG Cloud Southlake 28 Brad Taylor and Shawn Augenstein Old Problems in the N...
GDG Cloud Southlake 28 Brad Taylor and Shawn Augenstein Old Problems in the N...
James Anderson85 views
Powerful Google developer tools for immediate impact! (2023-24) by wesley chun
Powerful Google developer tools for immediate impact! (2023-24)Powerful Google developer tools for immediate impact! (2023-24)
Powerful Google developer tools for immediate impact! (2023-24)
wesley chun10 views
6g - REPORT.pdf by Liveplex
6g - REPORT.pdf6g - REPORT.pdf
6g - REPORT.pdf
Liveplex10 views
【USB韌體設計課程】精選講義節錄-USB的列舉過程_艾鍗學院 by IttrainingIttraining
【USB韌體設計課程】精選講義節錄-USB的列舉過程_艾鍗學院【USB韌體設計課程】精選講義節錄-USB的列舉過程_艾鍗學院
【USB韌體設計課程】精選講義節錄-USB的列舉過程_艾鍗學院
HTTP headers that make your website go faster - devs.gent November 2023 by Thijs Feryn
HTTP headers that make your website go faster - devs.gent November 2023HTTP headers that make your website go faster - devs.gent November 2023
HTTP headers that make your website go faster - devs.gent November 2023
Thijs Feryn22 views
Data Integrity for Banking and Financial Services by Precisely
Data Integrity for Banking and Financial ServicesData Integrity for Banking and Financial Services
Data Integrity for Banking and Financial Services
Precisely21 views
Voice Logger - Telephony Integration Solution at Aegis by Nirmal Sharma
Voice Logger - Telephony Integration Solution at AegisVoice Logger - Telephony Integration Solution at Aegis
Voice Logger - Telephony Integration Solution at Aegis
Nirmal Sharma39 views
Business Analyst Series 2023 - Week 3 Session 5 by DianaGray10
Business Analyst Series 2023 -  Week 3 Session 5Business Analyst Series 2023 -  Week 3 Session 5
Business Analyst Series 2023 - Week 3 Session 5
DianaGray10248 views

Featured

Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present... by
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Applitools
55.5K views138 slides
12 Ways to Increase Your Influence at Work by
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at WorkGetSmarter
401.6K views64 slides
ChatGPT webinar slides by
ChatGPT webinar slidesChatGPT webinar slides
ChatGPT webinar slidesAlireza Esmikhani
30.3K views36 slides
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G... by
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...DevGAMM Conference
3.6K views12 slides
Barbie - Brand Strategy Presentation by
Barbie - Brand Strategy PresentationBarbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationErica Santiago
25.1K views46 slides

Featured(20)

Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present... by Applitools
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Applitools55.5K views
12 Ways to Increase Your Influence at Work by GetSmarter
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work
GetSmarter401.6K views
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G... by DevGAMM Conference
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
DevGAMM Conference3.6K views
Barbie - Brand Strategy Presentation by Erica Santiago
Barbie - Brand Strategy PresentationBarbie - Brand Strategy Presentation
Barbie - Brand Strategy Presentation
Erica Santiago25.1K views
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well by Saba Software
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them wellGood Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Saba Software25.2K views
Introduction to C Programming Language by Simplilearn
Introduction to C Programming LanguageIntroduction to C Programming Language
Introduction to C Programming Language
Simplilearn8.4K views
The Pixar Way: 37 Quotes on Developing and Maintaining a Creative Company (fr... by Palo Alto Software
The Pixar Way: 37 Quotes on Developing and Maintaining a Creative Company (fr...The Pixar Way: 37 Quotes on Developing and Maintaining a Creative Company (fr...
The Pixar Way: 37 Quotes on Developing and Maintaining a Creative Company (fr...
Palo Alto Software88.4K views
9 Tips for a Work-free Vacation by Weekdone.com
9 Tips for a Work-free Vacation9 Tips for a Work-free Vacation
9 Tips for a Work-free Vacation
Weekdone.com7.2K views
How to Map Your Future by SlideShop.com
How to Map Your FutureHow to Map Your Future
How to Map Your Future
SlideShop.com275.1K views
Beyond Pride: Making Digital Marketing & SEO Authentically LGBTQ+ Inclusive -... by AccuraCast
Beyond Pride: Making Digital Marketing & SEO Authentically LGBTQ+ Inclusive -...Beyond Pride: Making Digital Marketing & SEO Authentically LGBTQ+ Inclusive -...
Beyond Pride: Making Digital Marketing & SEO Authentically LGBTQ+ Inclusive -...
AccuraCast3.4K views
Exploring ChatGPT for Effective Teaching and Learning.pptx by Stan Skrabut, Ed.D.
Exploring ChatGPT for Effective Teaching and Learning.pptxExploring ChatGPT for Effective Teaching and Learning.pptx
Exploring ChatGPT for Effective Teaching and Learning.pptx
Stan Skrabut, Ed.D.57.7K views
How to train your robot (with Deep Reinforcement Learning) by Lucas García, PhD
How to train your robot (with Deep Reinforcement Learning)How to train your robot (with Deep Reinforcement Learning)
How to train your robot (with Deep Reinforcement Learning)
Lucas García, PhD42.5K views
4 Strategies to Renew Your Career Passion by Daniel Goleman
4 Strategies to Renew Your Career Passion4 Strategies to Renew Your Career Passion
4 Strategies to Renew Your Career Passion
Daniel Goleman122K views
The Student's Guide to LinkedIn by LinkedIn
The Student's Guide to LinkedInThe Student's Guide to LinkedIn
The Student's Guide to LinkedIn
LinkedIn87.9K views
Different Roles in Machine Learning Career by Intellipaat
Different Roles in Machine Learning CareerDifferent Roles in Machine Learning Career
Different Roles in Machine Learning Career
Intellipaat12.4K views
Defining a Tech Project Vision in Eight Quick Steps pdf by TechSoup
Defining a Tech Project Vision in Eight Quick Steps pdfDefining a Tech Project Vision in Eight Quick Steps pdf
Defining a Tech Project Vision in Eight Quick Steps pdf
TechSoup 9.7K views

OS frontiers in the AI era