Models of What? - Open Wide Ingénierie

GreenSocs Overview
March 2015
Mark Burton
1
Guaranteeing success of SME’s
Enabling System Level Design
GreenSocs Ltd overview
• GreenSocs® is the trading name of GreenSocs Ltd. Registered
in England and Wales with registered number 05379256 and in
France with SIRET 797 495 595 00010.
• GreenSocs has been in business, and profitable, since 2005,
including within its client base large multi-nationals.
• GreenSocs operates on a service model, including open source
dissemination when appropriate.
• Dr Mark Burton is the founder of GreenSocs. Mark has worked
for ARM managing their modeling group. He was the chair of
the OSCI TLM WG. Mark is currently the chair of the OCP-IP
SLD WG.
2
Guaranteeing success of SME’s
Enabling System Level Design
Model Based Design IS your business.
Models are critical
to good design
decisions
Models are the
basis of re-use
decisions.
Research
Reuse
Realize
Revenue
Models enable
customer interactions,
during sales, and for
better support.
3
Guaranteeing success of SME’s
Enabling System Level Design
Models enable:
Parallel development
Team communication
Faster debug
Quicker bring up
Better test.
Models bring teams together
HW/SW team interaction
Early S/W bring up
Early S/W H/W feedback
Close loop development.
Verification Team
Model and scenario
reuse.
Architecture team
Investigate architectures
Provide executable specification
to HW/SW teams
Customer Interaction
Allow customers to engage early with the product
Using models to demonstrate and illicit customer feedback
4
Guaranteeing success of SME’s
Enabling System Level Design
Models bring teams together
HW/SW team interaction
Early S/W bring up
Early S/W H/W feedback
Close loop development.
Verification Team
Model and scenario
reuse.
Architecture team
Investigate architectures
Provide executable specification
to HW/SW teams
Customer Interaction
Allow customers to engage early with the product
Using models to demonstrate and illicit customer feedback
5
Guaranteeing success of SME’s
Enabling System Level Design
Models bring teams together
HW/SW team interaction
Early S/W bring up
Early S/W H/W feedback
Close loop development.
Verification Team
Model and scenario
reuse.
Architecture team
Investigate architectures
Provide executable specification
to HW/SW teams
Customer Interaction
Allow customers to engage early with the product
Using models to demonstrate and illicit customer feedback
6
Guaranteeing success of SME’s
Enabling System Level Design
It’s all about the models…
Idea
Use case/Scenario models
Use cases
Design
Exploration
Virtual Prototype models
HW/SW
Partitioning
Virtual
Platform
Mixed models
HW
Development
HW/SW
SW
co simulation
Development
verification
7
Guaranteeing success of SME’s
Enabling System Level Design
Models of What?
• GreenSocs specializes in models of programmable systems:
“Virtual Platforms”.
•
•
•
•
SOC’s
Cards
Racks of cards
Systems of interconnected racks of cards.
• Principle Used for Software development and validation,
• Also for H/W verification and architectural design.
• We model based on SystemC, TLM-2.0 and CCI STANDARDS.
•
•
•
•
8
We model traffic and resource issues prior to HW/SW partitioning
We model Cycle counts to performance analysis
We model functionality to enable software development and debug, and HW/SW
verification.
We can connect to functional models such as SysML, Matlab etc. e.g. for use case
verification.
Guaranteeing success of SME’s
Enabling System Level Design
Virtualization
Algorithm execution
Or full system virtualization
(Para-)Virtualization
Virtual Platform
Virtualization
Application
O/S
Virtual platform
‘real
binary’
Full binary execution
on virtual
platform (model)
(model)
Application
Emulation
O/S
FPGA
Application
Hardware
O/S
Hardware
9
Guaranteeing success of SME’s
Full binary execution
on REAL
platform (FPGA)
Full binary execution
on
Final Hardware
Enabling System Level Design
Virtual Platforms reduce Time and Risk.
Effort
Limited Critical
Integration points
Models become a critical tool for S/W
teams to do their job right
Continual
Integration
Reduce Risk
Reduce Time
Time…
10
Guaranteeing success of SME’s
Enabling System Level Design
EcoSystemC
Eco Systems exist:
• Intra-company
• Inter-company
vendor-lock = Each member
of the ecosystem needs to be
using the same tools.
With an open source approach, each member of the eco
system can choose their tools.
Must be based on open standards
(Hence GreenSocs works with Accellera to produce TLM-2.0, CCI etc)
11
Guaranteeing success of SME’s
Enabling System Level Design
GreenSocs Technology
12
Guaranteeing success of SME’s
Enabling System Level Design
GreenSocs SystemC Infrastructure.
•
Model to Model communication
• Busses and routers (e.g. AMBA, PCIe, OCP, etc)
• Signals (interrupts etc)
• Serial, Ethernet, Graphics etc….
•
Model to Tool communication
• Configuration, (inc Lua)
• Control (Run time re-configuration)
• Inspection (outputs and tracing).
•
Model IP
• Routers,
• simple IP blocks,
• libraries (Graphics, communication)
•
Tools
• Integration with Qemu, GEM5, Eclipse and other tools.
Guaranteeing success of SME’s
Enabling System Level Design
Tool Vendor Independent
Model Construction
• Eases building register definitions, state machines etc
• Scripting (Python)
OPEN SOURCE
13
•
Existing Model database overview:
CPU Family coverage:
X86
Fast
SW dev
model
(LT)
Cycle
Accurate
HW dev
model
(AT)
ARM
MIPS
Alph
a
✔ ✔ ✔
✔ ✔
✔
PowerP
C
SPARC
Microblaze
Cold
-fire
Cri
s
SH4
Xtensa
✔
✔
✔ ✔ ✔✔ ✔
✔
Full list (of several hundred) available on GreenSocs.com
14
Guaranteeing success of SME’s
Enabling System Level Design
Model Based Virtual Platform Architecture
Application Stack
O/S
Component
Library
Device Drivers
Processors
Communication
Devices
library
Command and control
Back-end
Or
Client Library
Virtual Platform Model
Interoperability Layer
Open source simulator,
or SystemC standard Vendor tool
15
Guaranteeing success of SME’s
Enabling System Level Design
GreenSocs : principle offers
SUPPORT
Access to existing model and infrastructure database
per seat pricing,
unlimited support.
MODEL DEVELOPMENT
Model Factory
All models adhere to STANDARDS
All model source provided.
Customer choice of licensing.
OPEN SOURCE DEVELOPMENT
Adding to the existing open source tools and models.
‘Upstreaming’ and dissemination
16
Guaranteeing success of SME’s
Enabling System Level Design
More information:
www.greensocs.com
[email protected]
17
Guaranteeing success of SME’s
Enabling System Level Design
Backup slides
18
Guaranteeing success of SME’s
Enabling System Level Design
Technology Expertise
• SystemC
• Used for System Construction
• GreenSocs has donated major parts of the SystemC standard (TLM2.0,
CCI…)
• GreenSocs has a large infrastructure library to assist in writing models.
• QEMU
• Used for ‘Programmer’s View (LT)’ models
• Contributions:
• VirtIO support
• Reverse Execution
• SystemC integration
• GEM5
• Used for ‘Architectural analysis (AT)’ models
• Contributions:
• SystemC integration
19
Guaranteeing success of SME’s
Enabling System Level Design
Qemu
• Qemu is a virtualization engine
• It uses Dynamic translation to be very very fast.
• We recommend that Qemu is used for software
development, test and debug.
• Qemu is extremely well known and very solid and
reliable.
• Qemu is under extremely active development
supported by a large community
• Qemu covers a vast range of CPU’s and Platforms
20
Guaranteeing success of SME’s
Enabling System Level Design
Qemu and SystemC
Processors
Communication
Devices
Command and control
Back-end
• SystemC is used to model h/w components in a
‘standard’ way.
• SystemC models can be used in a variety of EDA
tool environments.
• Combining Qemu and SystemC gives the ability to
use the power of Qemu’s CPU simulation
environment along with the standard approach to
adding devices.
21
Guaranteeing success of SME’s
Enabling System Level Design
Qemu in SystemC
Qemu_sc:
Qemu with SystemC
• SystemC used as peripheral
models to a Qemu based
platform.
• Main is Qemu.
• Advantages:
• Easy to set up
• Good performance
QBox:
Qemu in a SystemC box
• Qemu used as a CPU model.
• Main is SystemC.
• Advantages:
• Good for platforms written
in SystemC
• Integrates with existing
SystemC infrastructure
• Natural way to model
complex systems
Qemu
SystemC
TLM
TLM
22
SystemC
Guaranteeing success of SME’s
Enabling System Level Design
Qemu
QBox
• Wraps up Qemu in a TLM2*
API such that it can be used
in SystemC
• QEMU is a generic
and open source virtualizer – it covers almost all
CPU architectures and achieves extremely high
performance.
• Qbox’s are specific to CPU’s. GreenSocs makes
available a library of supported Qbox’s.
*
Requires the use of the TLM2C adapter in SystemC,
as Qemu is written in C.
23
Guaranteeing success of SME’s
Enabling System Level Design
TLM2C
TLM2C is a part of the GreenSocs interoperability library,
It allows TLM 2 models to be written in C
(and used within standard SystemC TLM 2).
Processors
Communication
Devices
Command and control
Back-end
Of TLM2 models
Written in ‘C’
TLM2
TLM2c
Interoperability Layer
Open source simulator,
or SystemC standard Vendor tool
24
Guaranteeing success of SME’s
Enabling System Level Design
Qbox features
• Qbox is multi-threaded – the Qemu CPU executes in
it’s own thread.
• SystemC code is always executed in it’s own thread
to preserve the integrity of SystemC code.
• (legacy code can be optimized to prevent too many context
switches)
• Qemu and SystemC are synchronized on ‘quantums’
(as defined by TLM 2.0).
• Interrupts are handled asynchronously by Qemu.
• Work in progress:
•
•
25
‘host time’ based synchronization: this is not TLM 2.0 standard, but may
be helpful and faster in some circumstances.
Multi-node Qemu with inter CPU synchronization (e.g. Atomicity and TLB
flushing etc) to support SMP outside of Qemu.
Guaranteeing success of SME’s
Enabling System Level Design
Extending Qemu for EDA virtulization
• Reverse Execution
• The ability to find a bug, and step backwards
(in time) to find the source of the bug.
• Major code up-streamed, GreenSocs has a fast
implementation which is compatible with
SystemC.
Processors
Communication
Command and control
Devices
Back-end
• SystemC integration
• The ability to mix SystemC models with Qemu.
• MULTI Thread Qemu
• A massive speed improvement for Qemu to
take advantage of multi-core hosts
• Currently in development – will be ready end
2015
26
Guaranteeing success of SME’s
Enabling System Level Design
Gem5
•
•
•
•
Gem5 is a cycle approximate simulator.
It is at least 10x slower than Qemu
It can be very accurate.
Companies such as ARM use Gem5 to
explore CPU architecture.
• Some models are available publically
• Gem5 can be very useful as the CPU model within a
SystemC simulation environment.
27
Guaranteeing success of SME’s
Enabling System Level Design
GreenSocs Summary
28
GreenSocs
Modelling
Services
GreenSocs
Open Source
Infrastructure
• GreenSocs specialises in
understanding the
problems of modelling,
and providing tailored
appropriate solutions
• Infrastructure freely provided
• keep your code
Tool Independent.
• Maximise productivity,
interoperability and re-use.
• Cost effective infrastructure
development and maintenance.
Guaranteeing success of SME’s
Enabling System Level Design
`