SlideShare a Scribd company logo
Future Directions For The
Windows CE Operating
System Architecture
John Hatch
Program Manager
Agenda
Overview - Introduction
5.0 – Overview
6.0 Beta – Overview
New Features
Performance and Size
Compatibility
Drivers Overview
Real-time
Windows CE Overview
Targeted to embedded devices
PPC, Smartphones, STBs, Thin clients, AutoPC,
PMC, control panels, robots, etc.
Benefits
Flexible, adaptable, configurable, small
Supports ARM, MIPS, SH, x86
Real-time
Simple driver model
Power conscious
Shared source
Tiered licensing model
Windows CE Overview
However, Windows CE 5.0 has a memory
model limitation
It only supports 32 processes and 32 MB
per process
These limitations has now been removed
with Windows CE 6.0
New Virtual Memory Model
CE 5.0 Overview
CE 5.0 Memory Model
Virtual Memory Map
2 GB for Kernel
Single 2 GB mapping for all processes
Divided up into 32 MB “slots”
32 Process Limit
Each process has one 32 MB slot
32 slots for processes
Shared memory
Upper half of user space is shared memory
Read/Write by all processes
Windows CE 5.0 Memory Model
32 Slots for
Processes
Single
2 GB VM
for all
Processes
2 GB
Kernel
Space
Execution Slot and
Shared DLL Slot
Shared Memory
Kernel
Slot 0 – Execution
Slot 1 – ROM DLLs
Slot 2 – Filesys.exe
Slot 3 – Device.exe
Slot 4 – GWES.exe
Slot 5 – Services.exe
Slot 31
Slot 32
Slot 33
:
:
Slot 6
Windows CE 5.0 System Calls
Thunked calls that cause prefetch
data abort
Kernel catches the exception
Dispatches the kernel to the right service
User thread “migrates” into the service
Kernel changes the threads permissions
Fixes up the pointers
Swaps in the service
Thread runs in service
Returns unwind the operation
Windows CE 6.0
Beta Overview
Introducing The New Kernel
2 GB of Virtual Memory per process
32,000 processes
Unified Kernel
Critical OS components moved into
kernel space
Improved system performance
Increased security and robustness
High degree of backwards compatibility
Windows CE 6.0
Beta Memory Model
Process Code
User VM
User VM
Memory Mapped files
User DLLs
Kernel
Filesystem
GWES
Drivers
32 K
Process
2 GB
per
Process
2 GB
Kernel
Space
User Space
Process space
1GB per process
Shared System Heap
255 MB
RAM Backed Mapfiles
256 MB
User Space
2 Gigabytes
Each process
has its own
mapping
0x00000000
0x80000000
0x40000000
Executable code and data
VM Allocations
File Back Mapfiles
All DLLs – code and data
Same mapping across all processes
Data pages are unique physical pages
Code pages are shared
RAM Backed Mapfiles
Mapped at fixed locations for
better backwards compatibility
Shared User DLLs
512 MB
R/W for OS components
Read only for user process
Kernel Space
Static Mapped Cached
512 MB
Static Mapped Uncached
512 MB
Kernel VM
256 MB
Kernel VM
(if supported by CPU)
256 MB
Object Store (128 MB)
CPU Specific VM
Kernel Space
2 Gigabytes
Fixed mapping
independent of
user space
Kernel XIP DLLs (128 MB)
Cached access to
physical memory
Uncached access to
physical memory
All XIP DLLs in kernel
Ram file system & ram registry
Kernel Virtual Memory
Shared by all kernel
servers and drivers
System Trap Area
0xFFFFFFFF
0x80000000
New OS Layout
Moving critical drivers, file system, and
graphical window manager into the kernel
Kernel version of Coredll.dll
Same APIs without the thunks
Benefit
Greatly reduces the overhead of system calls
between these components
Reduces overhead of all calls from user
space to kernel space
Increase code sharing between
base OS services
New OS Layout
OAL.DLL
FILESYS NETWORK
DEVICE.DLL
KERNEL.DLL
Applications
SERVICES.EXE
SHELL
Drivers
Hardware
Boot Loader
COREDLL / WINSOCK / COMMCTRL / WININET / COMMDLG
Kernel
Space
User
Space
KCOREDLL.DLL
Services
Services
Services
Services
Services
Services
Services
User Mode
Drivers
GWES
Kernel Security
Enhancements
Security
Early Threat Modeling of the kernel
Working with MS Secure Windows Team
and penetration testers
Double checked design to tighten up
System Calls
Handles
Exception Handling
Memory Allocation
Loader
and many other components
Security And Robustness Features
Improved parameter validation for system calls
Per-Process Page and Handle tables
Greatly improves Process isolation
Improves code robustness
Secure Stack
System calls run on special kernel side stacks
Safe guards system calls from stack tampering
Robust Heaps
Heap control structures separated from heap data
Safe Remote Heaps for OS components
OS servers can open heaps in user process
R/W for servers, R/only for user
Performance optimization and safe from tampering
New Features
New Features
Large Memory Mapped File Support
Support for Large Memory Mapped Files
Up to 64 bit files
Secure Loader
Enables of control of EXE and DLL loading
Virtual Alloc Ex functions
Memory management functions for drivers
Marshalling Helper Functions
Helper functions for interprocess data marshalling
User Mode UI service
Displays UI in user mode for kernel mode drivers
Monotonic clock
Always forward going clock independent of user clock
Performance And Size
Performance And Size
Improvements expected in
process switching
Same performance
Thread Switching
Memory Allocation
System Calls
Some slow down with interprocess calls
Now involves data marshalling
Size increase is less then 5%
Current System Calls
Application makes call
PSL jump
Kernel
Validates parameters
Maps Service into Slot 0
Possible Cache Flush
Calls into to the service
Service
Runs
Returns to Kernel
Kernel
Maps App into Slot 0
Possible cache flush
Returns to App
App Service
Kernel
Windows CE 6.0 Beta
System Calls Application makes call
Same PSL jump
App stays mapped during
the call
Kernel
Validates parameters
Calls into to the service
Service
Runs
Returns directly to the app
App
Service
Kernel
Compatibility
Compatibility
Binary compatibility for applications is the key goal
The general structure of the OS will be the same
Will maintain compatibility in CoreDLL
Minimize impact on Win32 APIs
Changes hidden in API libraries
Continue to shared DLL code
Well behaved SDK applications
Should work with little or no changes
Apps using undocumented techniques
Will likely have to be modified
Such as passing handles or pointers between processes
Main changes will be in how drivers access client
memory
Some drivers will migrate with little work
CPU Requirements
Currently the same as Windows 5.0
ARMV4I and above
MIPSII with sync instructions (ll, sc)
x86
SH4
Best performance on CPU’s with Physical
tagged caches
Virtual-tag-cached CPU have performance
penalty and limitation on virtual mappings
Same hardware as 5.0
Porting Incompatible Apps
Some applications will need work
Improper use of handles
nonstandard memory usage
Use of some Windows CE specific APIs
Remove old tricks and workarounds
Such as handle sharing and pointer tricks
Our verification approach
Ported Windows Mobile 5.0 to CE 6.0 Beta
Running 5.0 commercial applications
on 6.0 Beta
Other Porting
Drivers will require some work
System calls
Use of worker threads
Access to caller’s memory
BSP will need some work
New memory mappings
Changes to OAL to support image updates
Compatibility Tester
Identifies removed, deprecated, and
changed APIs
Supports both static and runtime analysis
Produces a detail report of any compatibility
issues it finds
Includes documentation and suggestions
We will release it before Windows
CE 6.0 RTM
Will allow customers to prepare
ahead of time
Drivers Overview
Drivers
The overall structure of the drivers
remains the same
Main changes are in how the drivers
access client memory
No SetKMode or SetProcPermissions
Two types of drivers will be supported
Kernel Mode for performance
User Mode for robustness
For full details attend –
WCE030 – Future Directions for the Windows
CE Device Driver Architecture
Kernel Mode Drivers
Drivers are loaded in the kernel
space by device.dll
Have full access to the kernel’s data
structures and memory
APIs used do not change
Link to a kernel version of coredll.dll
called kcoredll.dll
Thin layer for API compatibility
Directly links the services together
without thunk layer
User Mode Drivers
Loaded by udevices.exe
Mostly the same APIs as Kernel Mode
No access to kernel structures or memory
Kernel will marshal parameters during
system calls
Examples
Expansion buses like USB and SDIO
Keyboard and touch
Handling Calls
App memory already mapped correctly
Can access it without re-mapping pointers
Don’t need – these APIs are being removed
SetProcPermissions
MapPtrToProcess, UnMapPtr
Accessing callers memory
CopyIn/CopyOut
ReadProcessMemory/WriteProcessMemory
Virtual Alloc Ex APIs
Marshalling Helper Library
Provides APIs for handling user data
OAL Changes
OAL split from kernel
Merged into NKLoader
Enables separate updates
Overall OAL structure remains the same
Same OEM functions
Access kernel through kernel interface
Changes to the OAL initialization
Memory mappings for new memory model
Real-Time
Windows CE Is A Real-Time OS
Real time is being able to respond to an
interrupt in a bounded maximum time
Analysis by OMAC User Group shows that 95% of
real-time applications require between 0.5ms to 10
ms respond time
And tolerate 10% variations, or 50µs to 1ms jitter
Interrupt every
.5 ms to 10 ms
50µs to 1 ms Jitter
Real-Time Kernel
Windows CE achieves real-time by the
design of the kernel and the drivers
The majority of the kernel and driver code
can be interrupted
The uninterruptible parts are small discrete
units so interrupts can be handled quickly
The length of the largest part is
biggest latency
Windows CE 6.0 Beta kernel and drivers
are designed with the same
real-time constraints
Windows CE Test Results
Respond time test using the
following configuration
Samsung SMDK2410 development board
200 MHz ARM with 16x16 cache
Windows CE 5.0 with full UI
Running a WMV video
Here’s what we got –
ISR starts IST starts
Minimum 1.2 31.7
Average 3.3 67.2
Maximum 13.3 103.0
Time in microseconds (µs)
Windows CE 6.0 Beta Real-Time
The new kernel has the same response
times as the current kernel
May even perform slightly better because
of reduced system call overhead
Performance between app and kernel will be better
Drivers and services in services.exe will be
slightly worse
Call To Action
Attend the following talks
WCE032 – Windows CE Real-time Architecture
WCE030 – Future Directions for the Windows CE
Device Driver Architecture
© 2006 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries.
The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market
conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation.
MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.
Future Direction of WIndows CE System Architecture.ppt

More Related Content

Similar to Future Direction of WIndows CE System Architecture.ppt

Evolution of the Windows Kernel Architecture, by Dave Probert
Evolution of the Windows Kernel Architecture, by Dave ProbertEvolution of the Windows Kernel Architecture, by Dave Probert
Evolution of the Windows Kernel Architecture, by Dave Probert
yang
 
Oracle R12 EBS Performance Tuning
Oracle R12 EBS Performance TuningOracle R12 EBS Performance Tuning
Oracle R12 EBS Performance Tuning
Scott Jenner
 
Understanding operating systems 5th ed ch15
Understanding operating systems 5th ed ch15Understanding operating systems 5th ed ch15
Understanding operating systems 5th ed ch15BarrBoy
 
Java Standard Edition 5 Performance
Java Standard Edition 5 PerformanceJava Standard Edition 5 Performance
Java Standard Edition 5 Performancewhite paper
 
directCell - Cell/B.E. tightly coupled via PCI Express
directCell - Cell/B.E. tightly coupled via PCI ExpressdirectCell - Cell/B.E. tightly coupled via PCI Express
directCell - Cell/B.E. tightly coupled via PCI ExpressHeiko Joerg Schick
 
Operating system Definition Structures
Operating  system Definition  StructuresOperating  system Definition  Structures
Operating system Definition Structures
anair23
 
1 Win7 For Devs Fund Search
1 Win7 For Devs Fund Search1 Win7 For Devs Fund Search
1 Win7 For Devs Fund Search
llangit
 
70-410 Practice Test
70-410 Practice Test70-410 Practice Test
70-410 Practice Test
wrailebo
 
Low-level Graphics APIs
Low-level Graphics APIsLow-level Graphics APIs
Low-level Graphics APIs
Johan Andersson
 
Azure IaaS Feb 23 2016 Let's Dev This Cloud
Azure IaaS Feb 23 2016 Let's Dev This CloudAzure IaaS Feb 23 2016 Let's Dev This Cloud
Azure IaaS Feb 23 2016 Let's Dev This Cloud
Michael Blumenthal (Microsoft MVP)
 
Principles of operating system
Principles of operating systemPrinciples of operating system
Principles of operating system
Anil Dharmapuri
 
Keynote Microsoft Azure Summit
Keynote Microsoft Azure SummitKeynote Microsoft Azure Summit
Keynote Microsoft Azure Summit
Danilo Bordini
 
Solid-State diskA solid-state drive also known as a solid-state di.pdf
Solid-State diskA solid-state drive also known as a solid-state di.pdfSolid-State diskA solid-state drive also known as a solid-state di.pdf
Solid-State diskA solid-state drive also known as a solid-state di.pdf
saahinmanpam
 
Mainframe Architecture & Product Overview
Mainframe Architecture & Product OverviewMainframe Architecture & Product Overview
Mainframe Architecture & Product Overviewabhi1112
 
What is new in .NET 4.5
What is new in .NET 4.5What is new in .NET 4.5
What is new in .NET 4.5Robert MacLean
 
Ceph Day Taipei - Accelerate Ceph via SPDK
Ceph Day Taipei - Accelerate Ceph via SPDK Ceph Day Taipei - Accelerate Ceph via SPDK
Ceph Day Taipei - Accelerate Ceph via SPDK
Ceph Community
 
Momentum Webcast HP Virtualization
Momentum Webcast HP VirtualizationMomentum Webcast HP Virtualization
Momentum Webcast HP Virtualization
aljimenez
 

Similar to Future Direction of WIndows CE System Architecture.ppt (20)

Evolution of the Windows Kernel Architecture, by Dave Probert
Evolution of the Windows Kernel Architecture, by Dave ProbertEvolution of the Windows Kernel Architecture, by Dave Probert
Evolution of the Windows Kernel Architecture, by Dave Probert
 
Oct2009
Oct2009Oct2009
Oct2009
 
Oracle R12 EBS Performance Tuning
Oracle R12 EBS Performance TuningOracle R12 EBS Performance Tuning
Oracle R12 EBS Performance Tuning
 
Understanding operating systems 5th ed ch15
Understanding operating systems 5th ed ch15Understanding operating systems 5th ed ch15
Understanding operating systems 5th ed ch15
 
Java Standard Edition 5 Performance
Java Standard Edition 5 PerformanceJava Standard Edition 5 Performance
Java Standard Edition 5 Performance
 
directCell - Cell/B.E. tightly coupled via PCI Express
directCell - Cell/B.E. tightly coupled via PCI ExpressdirectCell - Cell/B.E. tightly coupled via PCI Express
directCell - Cell/B.E. tightly coupled via PCI Express
 
Operating system Definition Structures
Operating  system Definition  StructuresOperating  system Definition  Structures
Operating system Definition Structures
 
1 Win7 For Devs Fund Search
1 Win7 For Devs Fund Search1 Win7 For Devs Fund Search
1 Win7 For Devs Fund Search
 
70-410 Practice Test
70-410 Practice Test70-410 Practice Test
70-410 Practice Test
 
Low-level Graphics APIs
Low-level Graphics APIsLow-level Graphics APIs
Low-level Graphics APIs
 
Azure IaaS Feb 23 2016 Let's Dev This Cloud
Azure IaaS Feb 23 2016 Let's Dev This CloudAzure IaaS Feb 23 2016 Let's Dev This Cloud
Azure IaaS Feb 23 2016 Let's Dev This Cloud
 
Principles of operating system
Principles of operating systemPrinciples of operating system
Principles of operating system
 
Keynote Microsoft Azure Summit
Keynote Microsoft Azure SummitKeynote Microsoft Azure Summit
Keynote Microsoft Azure Summit
 
Solid-State diskA solid-state drive also known as a solid-state di.pdf
Solid-State diskA solid-state drive also known as a solid-state di.pdfSolid-State diskA solid-state drive also known as a solid-state di.pdf
Solid-State diskA solid-state drive also known as a solid-state di.pdf
 
The Cell Processor
The Cell ProcessorThe Cell Processor
The Cell Processor
 
Mainframe Architecture & Product Overview
Mainframe Architecture & Product OverviewMainframe Architecture & Product Overview
Mainframe Architecture & Product Overview
 
What is new in .NET 4.5
What is new in .NET 4.5What is new in .NET 4.5
What is new in .NET 4.5
 
Ceph Day Taipei - Accelerate Ceph via SPDK
Ceph Day Taipei - Accelerate Ceph via SPDK Ceph Day Taipei - Accelerate Ceph via SPDK
Ceph Day Taipei - Accelerate Ceph via SPDK
 
3 Hyper V
3 Hyper V3 Hyper V
3 Hyper V
 
Momentum Webcast HP Virtualization
Momentum Webcast HP VirtualizationMomentum Webcast HP Virtualization
Momentum Webcast HP Virtualization
 

Recently uploaded

Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...
Globus
 
Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604
Fermin Galan
 
A Comprehensive Look at Generative AI in Retail App Testing.pdf
A Comprehensive Look at Generative AI in Retail App Testing.pdfA Comprehensive Look at Generative AI in Retail App Testing.pdf
A Comprehensive Look at Generative AI in Retail App Testing.pdf
kalichargn70th171
 
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdfDominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
AMB-Review
 
How Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptxHow Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptx
wottaspaceseo
 
A Sighting of filterA in Typelevel Rite of Passage
A Sighting of filterA in Typelevel Rite of PassageA Sighting of filterA in Typelevel Rite of Passage
A Sighting of filterA in Typelevel Rite of Passage
Philip Schwarz
 
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoam
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoamOpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoam
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoam
takuyayamamoto1800
 
Enterprise Resource Planning System in Telangana
Enterprise Resource Planning System in TelanganaEnterprise Resource Planning System in Telangana
Enterprise Resource Planning System in Telangana
NYGGS Automation Suite
 
AI Pilot Review: The World’s First Virtual Assistant Marketing Suite
AI Pilot Review: The World’s First Virtual Assistant Marketing SuiteAI Pilot Review: The World’s First Virtual Assistant Marketing Suite
AI Pilot Review: The World’s First Virtual Assistant Marketing Suite
Google
 
Providing Globus Services to Users of JASMIN for Environmental Data Analysis
Providing Globus Services to Users of JASMIN for Environmental Data AnalysisProviding Globus Services to Users of JASMIN for Environmental Data Analysis
Providing Globus Services to Users of JASMIN for Environmental Data Analysis
Globus
 
Large Language Models and the End of Programming
Large Language Models and the End of ProgrammingLarge Language Models and the End of Programming
Large Language Models and the End of Programming
Matt Welsh
 
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
Juraj Vysvader
 
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERRORTROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
Tier1 app
 
SOCRadar Research Team: Latest Activities of IntelBroker
SOCRadar Research Team: Latest Activities of IntelBrokerSOCRadar Research Team: Latest Activities of IntelBroker
SOCRadar Research Team: Latest Activities of IntelBroker
SOCRadar
 
Graphic Design Crash Course for beginners
Graphic Design Crash Course for beginnersGraphic Design Crash Course for beginners
Graphic Design Crash Course for beginners
e20449
 
Into the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdfInto the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdf
Ortus Solutions, Corp
 
Cracking the code review at SpringIO 2024
Cracking the code review at SpringIO 2024Cracking the code review at SpringIO 2024
Cracking the code review at SpringIO 2024
Paco van Beckhoven
 
Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024
Globus
 
Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024
Globus
 
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptxTop Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
rickgrimesss22
 

Recently uploaded (20)

Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...
 
Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604
 
A Comprehensive Look at Generative AI in Retail App Testing.pdf
A Comprehensive Look at Generative AI in Retail App Testing.pdfA Comprehensive Look at Generative AI in Retail App Testing.pdf
A Comprehensive Look at Generative AI in Retail App Testing.pdf
 
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdfDominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
 
How Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptxHow Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptx
 
A Sighting of filterA in Typelevel Rite of Passage
A Sighting of filterA in Typelevel Rite of PassageA Sighting of filterA in Typelevel Rite of Passage
A Sighting of filterA in Typelevel Rite of Passage
 
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoam
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoamOpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoam
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoam
 
Enterprise Resource Planning System in Telangana
Enterprise Resource Planning System in TelanganaEnterprise Resource Planning System in Telangana
Enterprise Resource Planning System in Telangana
 
AI Pilot Review: The World’s First Virtual Assistant Marketing Suite
AI Pilot Review: The World’s First Virtual Assistant Marketing SuiteAI Pilot Review: The World’s First Virtual Assistant Marketing Suite
AI Pilot Review: The World’s First Virtual Assistant Marketing Suite
 
Providing Globus Services to Users of JASMIN for Environmental Data Analysis
Providing Globus Services to Users of JASMIN for Environmental Data AnalysisProviding Globus Services to Users of JASMIN for Environmental Data Analysis
Providing Globus Services to Users of JASMIN for Environmental Data Analysis
 
Large Language Models and the End of Programming
Large Language Models and the End of ProgrammingLarge Language Models and the End of Programming
Large Language Models and the End of Programming
 
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
 
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERRORTROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
 
SOCRadar Research Team: Latest Activities of IntelBroker
SOCRadar Research Team: Latest Activities of IntelBrokerSOCRadar Research Team: Latest Activities of IntelBroker
SOCRadar Research Team: Latest Activities of IntelBroker
 
Graphic Design Crash Course for beginners
Graphic Design Crash Course for beginnersGraphic Design Crash Course for beginners
Graphic Design Crash Course for beginners
 
Into the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdfInto the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdf
 
Cracking the code review at SpringIO 2024
Cracking the code review at SpringIO 2024Cracking the code review at SpringIO 2024
Cracking the code review at SpringIO 2024
 
Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024
 
Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024
 
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptxTop Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
 

Future Direction of WIndows CE System Architecture.ppt

  • 1. Future Directions For The Windows CE Operating System Architecture John Hatch Program Manager
  • 2. Agenda Overview - Introduction 5.0 – Overview 6.0 Beta – Overview New Features Performance and Size Compatibility Drivers Overview Real-time
  • 3. Windows CE Overview Targeted to embedded devices PPC, Smartphones, STBs, Thin clients, AutoPC, PMC, control panels, robots, etc. Benefits Flexible, adaptable, configurable, small Supports ARM, MIPS, SH, x86 Real-time Simple driver model Power conscious Shared source Tiered licensing model
  • 4. Windows CE Overview However, Windows CE 5.0 has a memory model limitation It only supports 32 processes and 32 MB per process These limitations has now been removed with Windows CE 6.0 New Virtual Memory Model
  • 6. CE 5.0 Memory Model Virtual Memory Map 2 GB for Kernel Single 2 GB mapping for all processes Divided up into 32 MB “slots” 32 Process Limit Each process has one 32 MB slot 32 slots for processes Shared memory Upper half of user space is shared memory Read/Write by all processes
  • 7. Windows CE 5.0 Memory Model 32 Slots for Processes Single 2 GB VM for all Processes 2 GB Kernel Space Execution Slot and Shared DLL Slot Shared Memory Kernel Slot 0 – Execution Slot 1 – ROM DLLs Slot 2 – Filesys.exe Slot 3 – Device.exe Slot 4 – GWES.exe Slot 5 – Services.exe Slot 31 Slot 32 Slot 33 : : Slot 6
  • 8. Windows CE 5.0 System Calls Thunked calls that cause prefetch data abort Kernel catches the exception Dispatches the kernel to the right service User thread “migrates” into the service Kernel changes the threads permissions Fixes up the pointers Swaps in the service Thread runs in service Returns unwind the operation
  • 10. Introducing The New Kernel 2 GB of Virtual Memory per process 32,000 processes Unified Kernel Critical OS components moved into kernel space Improved system performance Increased security and robustness High degree of backwards compatibility
  • 11. Windows CE 6.0 Beta Memory Model Process Code User VM User VM Memory Mapped files User DLLs Kernel Filesystem GWES Drivers 32 K Process 2 GB per Process 2 GB Kernel Space
  • 12. User Space Process space 1GB per process Shared System Heap 255 MB RAM Backed Mapfiles 256 MB User Space 2 Gigabytes Each process has its own mapping 0x00000000 0x80000000 0x40000000 Executable code and data VM Allocations File Back Mapfiles All DLLs – code and data Same mapping across all processes Data pages are unique physical pages Code pages are shared RAM Backed Mapfiles Mapped at fixed locations for better backwards compatibility Shared User DLLs 512 MB R/W for OS components Read only for user process
  • 13. Kernel Space Static Mapped Cached 512 MB Static Mapped Uncached 512 MB Kernel VM 256 MB Kernel VM (if supported by CPU) 256 MB Object Store (128 MB) CPU Specific VM Kernel Space 2 Gigabytes Fixed mapping independent of user space Kernel XIP DLLs (128 MB) Cached access to physical memory Uncached access to physical memory All XIP DLLs in kernel Ram file system & ram registry Kernel Virtual Memory Shared by all kernel servers and drivers System Trap Area 0xFFFFFFFF 0x80000000
  • 14. New OS Layout Moving critical drivers, file system, and graphical window manager into the kernel Kernel version of Coredll.dll Same APIs without the thunks Benefit Greatly reduces the overhead of system calls between these components Reduces overhead of all calls from user space to kernel space Increase code sharing between base OS services
  • 15. New OS Layout OAL.DLL FILESYS NETWORK DEVICE.DLL KERNEL.DLL Applications SERVICES.EXE SHELL Drivers Hardware Boot Loader COREDLL / WINSOCK / COMMCTRL / WININET / COMMDLG Kernel Space User Space KCOREDLL.DLL Services Services Services Services Services Services Services User Mode Drivers GWES
  • 17. Security Early Threat Modeling of the kernel Working with MS Secure Windows Team and penetration testers Double checked design to tighten up System Calls Handles Exception Handling Memory Allocation Loader and many other components
  • 18. Security And Robustness Features Improved parameter validation for system calls Per-Process Page and Handle tables Greatly improves Process isolation Improves code robustness Secure Stack System calls run on special kernel side stacks Safe guards system calls from stack tampering Robust Heaps Heap control structures separated from heap data Safe Remote Heaps for OS components OS servers can open heaps in user process R/W for servers, R/only for user Performance optimization and safe from tampering
  • 20. New Features Large Memory Mapped File Support Support for Large Memory Mapped Files Up to 64 bit files Secure Loader Enables of control of EXE and DLL loading Virtual Alloc Ex functions Memory management functions for drivers Marshalling Helper Functions Helper functions for interprocess data marshalling User Mode UI service Displays UI in user mode for kernel mode drivers Monotonic clock Always forward going clock independent of user clock
  • 22. Performance And Size Improvements expected in process switching Same performance Thread Switching Memory Allocation System Calls Some slow down with interprocess calls Now involves data marshalling Size increase is less then 5%
  • 23. Current System Calls Application makes call PSL jump Kernel Validates parameters Maps Service into Slot 0 Possible Cache Flush Calls into to the service Service Runs Returns to Kernel Kernel Maps App into Slot 0 Possible cache flush Returns to App App Service Kernel
  • 24. Windows CE 6.0 Beta System Calls Application makes call Same PSL jump App stays mapped during the call Kernel Validates parameters Calls into to the service Service Runs Returns directly to the app App Service Kernel
  • 26. Compatibility Binary compatibility for applications is the key goal The general structure of the OS will be the same Will maintain compatibility in CoreDLL Minimize impact on Win32 APIs Changes hidden in API libraries Continue to shared DLL code Well behaved SDK applications Should work with little or no changes Apps using undocumented techniques Will likely have to be modified Such as passing handles or pointers between processes Main changes will be in how drivers access client memory Some drivers will migrate with little work
  • 27. CPU Requirements Currently the same as Windows 5.0 ARMV4I and above MIPSII with sync instructions (ll, sc) x86 SH4 Best performance on CPU’s with Physical tagged caches Virtual-tag-cached CPU have performance penalty and limitation on virtual mappings Same hardware as 5.0
  • 28. Porting Incompatible Apps Some applications will need work Improper use of handles nonstandard memory usage Use of some Windows CE specific APIs Remove old tricks and workarounds Such as handle sharing and pointer tricks Our verification approach Ported Windows Mobile 5.0 to CE 6.0 Beta Running 5.0 commercial applications on 6.0 Beta
  • 29. Other Porting Drivers will require some work System calls Use of worker threads Access to caller’s memory BSP will need some work New memory mappings Changes to OAL to support image updates
  • 30. Compatibility Tester Identifies removed, deprecated, and changed APIs Supports both static and runtime analysis Produces a detail report of any compatibility issues it finds Includes documentation and suggestions We will release it before Windows CE 6.0 RTM Will allow customers to prepare ahead of time
  • 32. Drivers The overall structure of the drivers remains the same Main changes are in how the drivers access client memory No SetKMode or SetProcPermissions Two types of drivers will be supported Kernel Mode for performance User Mode for robustness For full details attend – WCE030 – Future Directions for the Windows CE Device Driver Architecture
  • 33. Kernel Mode Drivers Drivers are loaded in the kernel space by device.dll Have full access to the kernel’s data structures and memory APIs used do not change Link to a kernel version of coredll.dll called kcoredll.dll Thin layer for API compatibility Directly links the services together without thunk layer
  • 34. User Mode Drivers Loaded by udevices.exe Mostly the same APIs as Kernel Mode No access to kernel structures or memory Kernel will marshal parameters during system calls Examples Expansion buses like USB and SDIO Keyboard and touch
  • 35. Handling Calls App memory already mapped correctly Can access it without re-mapping pointers Don’t need – these APIs are being removed SetProcPermissions MapPtrToProcess, UnMapPtr Accessing callers memory CopyIn/CopyOut ReadProcessMemory/WriteProcessMemory Virtual Alloc Ex APIs Marshalling Helper Library Provides APIs for handling user data
  • 36. OAL Changes OAL split from kernel Merged into NKLoader Enables separate updates Overall OAL structure remains the same Same OEM functions Access kernel through kernel interface Changes to the OAL initialization Memory mappings for new memory model
  • 38. Windows CE Is A Real-Time OS Real time is being able to respond to an interrupt in a bounded maximum time Analysis by OMAC User Group shows that 95% of real-time applications require between 0.5ms to 10 ms respond time And tolerate 10% variations, or 50µs to 1ms jitter Interrupt every .5 ms to 10 ms 50µs to 1 ms Jitter
  • 39. Real-Time Kernel Windows CE achieves real-time by the design of the kernel and the drivers The majority of the kernel and driver code can be interrupted The uninterruptible parts are small discrete units so interrupts can be handled quickly The length of the largest part is biggest latency Windows CE 6.0 Beta kernel and drivers are designed with the same real-time constraints
  • 40. Windows CE Test Results Respond time test using the following configuration Samsung SMDK2410 development board 200 MHz ARM with 16x16 cache Windows CE 5.0 with full UI Running a WMV video Here’s what we got – ISR starts IST starts Minimum 1.2 31.7 Average 3.3 67.2 Maximum 13.3 103.0 Time in microseconds (µs)
  • 41. Windows CE 6.0 Beta Real-Time The new kernel has the same response times as the current kernel May even perform slightly better because of reduced system call overhead Performance between app and kernel will be better Drivers and services in services.exe will be slightly worse
  • 42. Call To Action Attend the following talks WCE032 – Windows CE Real-time Architecture WCE030 – Future Directions for the Windows CE Device Driver Architecture
  • 43. © 2006 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.