and Timing Analysis for Real-Time Networks RTN 2018 Stefan Reif, - - PowerPoint PPT Presentation

and timing analysis for real time networks
SMART_READER_LITE
LIVE PREVIEW

and Timing Analysis for Real-Time Networks RTN 2018 Stefan Reif, - - PowerPoint PPT Presentation

and Timing Analysis for Real-Time Networks RTN 2018 Stefan Reif, Timo Hnig, Wolfgang Schrder-Preikschat Department of Computer Science 4 (Distributed Systems and Operating Systems) Friedrich-Alexander-Universitt Erlangen-Nrnberg Andreas


slide-1
SLIDE 1

∆elta: Difgerential Energy-Effjciency, Latency, and Timing Analysis for Real-Time Networks

RTN 2018 Stefan Reif, Timo Hönig, Wolfgang Schröder-Preikschat Department of Computer Science 4 (Distributed Systems and Operating Systems) Friedrich-Alexander-Universität Erlangen-Nürnberg Andreas Schmidt, Thorsten Herfet Telecommunications Lab Saarland Informatics Campus - Saarbrücken

slide-2
SLIDE 2

Motivation

▶ Modern CPN/IoT systems are complex

▶ Application → Image processing, ... ▶ Hardware → Multi-core, caches, ... ▶ Network → Internet, WiFi, ...

▶ Energy supply is limited ▶ Static timing and energy analysis

techniques reach their limits

▶ Some aspects are unknown at

compile time

▶ Random environmental infmuences 2 / 16

slide-3
SLIDE 3

Motivation

▶ Modern CPN/IoT systems are complex

▶ Application → Image processing, ... ▶ Hardware → Multi-core, caches, ... ▶ Network → Internet, WiFi, ...

▶ Energy supply is limited ▶ Static timing and energy analysis

techniques reach their limits

▶ Some aspects are unknown at

compile time

▶ Random environmental infmuences

Need for on-line analysis

2 / 16

slide-4
SLIDE 4

The Predictably Reliable Real-Time Transport Protocol (PRRT)

PRRT:

▶ Soft real-time network protocol ▶ Latency awareness ▶ Congestion control ▶ Adaptive hybrid error control ▶ Bindings for C, Python, and others ▶ Source code is available:

→ http://prrt.larn.systems

3 / 16

slide-5
SLIDE 5

Background: X-Lap

Application Transport protocol Operating system Channel Time measurement:

  • 1. Insert timestamping points into

real-time network system

  • 2. Execute experiment
  • 3. Collect and combine traces
  • 4. Visualize traces

Timing information:

▶ Per-packet ▶ Cross-layer ▶ Multi-node

4 / 16

slide-6
SLIDE 6

Background: X-Lap

X-Lap Application Transport protocol Operating system Channel Time measurement:

  • 1. Insert timestamping points into

real-time network system

  • 2. Execute experiment
  • 3. Collect and combine traces
  • 4. Visualize traces

Timing information:

▶ Per-packet ▶ Cross-layer ▶ Multi-node

4 / 16

slide-7
SLIDE 7

Approach

Implement Evaluate Approach:

▶ Measurement-based protocol

evaluation Derive meaningful information Support protocol design Challenges: Identify critical code parts

Latency, Jitter, Energy

Analyze code modifjcations Automate feedback

5 / 16

slide-8
SLIDE 8

Approach

Implement Evaluate Analyze Approach:

▶ Measurement-based protocol

evaluation

▶ Derive meaningful information ▶ Support protocol design

Challenges: Identify critical code parts

Latency, Jitter, Energy

Analyze code modifjcations Automate feedback

5 / 16

slide-9
SLIDE 9

Approach

Implement Evaluate Analyze Approach:

▶ Measurement-based protocol

evaluation

▶ Derive meaningful information ▶ Support protocol design

Challenges: □ Identify critical code parts

→ Latency, Jitter, Energy

□ Analyze code modifjcations □ Automate feedback

5 / 16

slide-10
SLIDE 10

Outline

Introduction Timing Analysis and Automation Energy Effjciency Analysis Conclusion

6 / 16

slide-11
SLIDE 11

Outline

Introduction Timing Analysis and Automation Energy Effjciency Analysis Conclusion

6 / 16

slide-12
SLIDE 12

Control-Flow Reconstruction

E1 E2 E3 E4 E5 Goal:

▶ Reconstruct protocol information from

timestamps Control fmow reconstruction:

  • 1. Compute happens-before relation of

events

  • 2. Compute happens-directly-before

relation of events Edges represent: Code segments Ei Ej Thread communication False-positives

7 / 16

slide-13
SLIDE 13

Control-Flow Reconstruction

E1 E2 E3 E4 E5 Goal:

▶ Reconstruct protocol information from

timestamps Control fmow reconstruction:

  • 1. Compute happens-before relation of

events

  • 2. Compute happens-directly-before

relation of events Edges represent: Code segments Ei Ej Thread communication False-positives

7 / 16

slide-14
SLIDE 14

Control-Flow Reconstruction

E1 E2 E3 E4 E5 Goal:

▶ Reconstruct protocol information from

timestamps Control fmow reconstruction:

  • 1. Compute happens-before relation of

events

  • 2. Compute happens-directly-before

relation of events Edges represent:

▶ Code segments ⟨Ei, Ej⟩ ▶ Thread communication ▶ False-positives

7 / 16

slide-15
SLIDE 15

Latency Criticality Analysis

0.0 0.1 0.2 0.3 0.4 0.5 0.6 latency criticality <CopyOutputEnd, PrrtDeliver> <PrrtSubmitPackage, PrrtSendEnd> <HandlePacketStart, SendFeedbackStart> <CopyOutputStart, CopyOutputEnd> <PrrtReturnPackage, HandlePacketEnd> <DecodeStart, DecodeEnd> <HandlePacketEnd, PrrtReceivePackage> <SendFeedbackEnd, PrrtReturnPackage> <DecodeEnd, HandlePacketStart> <PrrtSendStart, PrrtSubmitPackage> <LinkTransmitStart, LinkTransmitEnd> <LinkReceive, DecodeStart> <PrrtTransmitStart, LinkTransmitStart> <SendFeedbackStart, SendFeedbackEnd> <PrrtSendEnd, LinkTransmitStart>

Goals:

▶ Filter out false-positive segments ▶ Identify code segments worth

  • ptimizing

Detect relevant code segments:

  • 1. Compute the correlation between

the segment latency and the E2E latency

  • 2. Ignore segments with negative

correlation

8 / 16

slide-16
SLIDE 16

Latency Criticality Analysis

0.0 0.1 0.2 0.3 0.4 0.5 0.6 latency criticality <CopyOutputEnd, PrrtDeliver> <PrrtSubmitPackage, PrrtSendEnd> <HandlePacketStart, SendFeedbackStart> <CopyOutputStart, CopyOutputEnd> <PrrtReturnPackage, HandlePacketEnd> <DecodeStart, DecodeEnd> <HandlePacketEnd, PrrtReceivePackage> <SendFeedbackEnd, PrrtReturnPackage> <DecodeEnd, HandlePacketStart> <PrrtSendStart, PrrtSubmitPackage> <LinkTransmitStart, LinkTransmitEnd> <LinkReceive, DecodeStart> <PrrtTransmitStart, LinkTransmitStart> <SendFeedbackStart, SendFeedbackEnd> <PrrtSendEnd, LinkTransmitStart>

Goals:

▶ Filter out false-positive segments ▶ Identify code segments worth

  • ptimizing

Detect relevant code segments:

  • 1. Compute the correlation between

the segment latency and the E2E latency

  • 2. Ignore segments with negative

correlation

8 / 16

slide-17
SLIDE 17

Timing Reproducibility Analysis

Goals:

▶ Identify code segments with

unpredictable timing

▶ “What happens if ...” analysis

Timing reproducibility analysis:

  • 1. Evaluate the code twice
  • 2. Apply the k-sample

Anderson-Darling-Test on the traces

  • 3. For each code segment, test

decides: “similar” or “difgerent”

9 / 16

slide-18
SLIDE 18

Timing Reproducibility Analysis

foobar(); ... ... ?? Goals:

▶ Identify code segments with

unpredictable timing

▶ “What happens if ...” analysis

Timing reproducibility analysis:

  • 1. Evaluate the code twice
  • 2. Apply the k-sample

Anderson-Darling-Test on the traces

  • 3. For each code segment, test

decides: “similar” or “difgerent”

9 / 16

slide-19
SLIDE 19

Timing Reproducibility Analysis

foobar(); ... ... ?? Goals:

▶ Identify code segments with

unpredictable timing

▶ “What happens if ...” analysis

Timing reproducibility analysis:

  • 1. Evaluate the code twice
  • 2. Apply the k-sample

Anderson-Darling-Test on the traces

  • 3. For each code segment, test

decides: “similar” or “difgerent”

9 / 16

slide-20
SLIDE 20

Code Modifjcation Analysis

foo(0); foo(1); Goals:

▶ Evaluate the infmuence of code changes ▶ Interferences are complex

Modifjcation impact analysis:

  • 1. Evaluate the original and the modifjed

versions of the protocol

  • 2. Apply the k-sample

Anderson-Darling-Test on the traces

  • 3. For each code segment, test decides:

“similar” or “difgerent”

10 / 16

slide-21
SLIDE 21

Code Modifjcation Analysis

foo(0); foo(1); ... ... ?? Goals:

▶ Evaluate the infmuence of code changes ▶ Interferences are complex

Modifjcation impact analysis:

  • 1. Evaluate the original and the modifjed

versions of the protocol

  • 2. Apply the k-sample

Anderson-Darling-Test on the traces

  • 3. For each code segment, test decides:

“similar” or “difgerent”

10 / 16

slide-22
SLIDE 22

Code Modifjcation Analysis

foo(0); foo(1); ... ... ?? Goals:

▶ Evaluate the infmuence of code changes ▶ Interferences are complex

Modifjcation impact analysis:

  • 1. Evaluate the original and the modifjed

versions of the protocol

  • 2. Apply the k-sample

Anderson-Darling-Test on the traces

  • 3. For each code segment, test decides:

“similar” or “difgerent”

10 / 16

slide-23
SLIDE 23

Code Modifjcation Analysis

<PrrtSendPacketStart,PrrtSendPacketEnd> has not changed <CopyOutputStart,CopyOutputEnd> has not changed <SendFeedbackStart,SendFeedbackEnd> has not changed ... <PrrtSubmitPackage,PrrtSendEnd> has changed: 2.85±0.91 µs → 4.94±0.58 µs <LinkReceive,DecodeStart> has changed: 2.36±3.80 µs → 3.56±4.88 µs ...

11 / 16

slide-24
SLIDE 24

Outline

Introduction Timing Analysis and Automation Energy Effjciency Analysis Conclusion

12 / 16

slide-25
SLIDE 25

Energy Effjciency Analysis

1 2 3 Frequency (GHz) 0.00 0.05 0.10 0.15 0.20 0.25 0.30 Per-package ET² (nJs²)

Goals:

▶ Identify energy-effjcient hardware

confjgurations Energy effjciency evaluation:

  • 1. Evaluate slow and fast

confjgurations

→ Measure execution times and energy demand

  • 2. Compute ET2 metric per packet

13 / 16

slide-26
SLIDE 26

Energy Effjciency Analysis

1 2 3 Frequency (GHz) 0.00 0.05 0.10 0.15 0.20 0.25 0.30 Per-package ET² (nJs²)

Goals:

▶ Identify energy-effjcient hardware

confjgurations Energy effjciency evaluation:

  • 1. Evaluate slow and fast

confjgurations

→ Measure execution times and energy demand

  • 2. Compute ET2 metric per packet

13 / 16

slide-27
SLIDE 27

Slowdown Analysis

0.0 0.5 1.0 1.5 2.0 2.5 3.0 Normalized slowdown <CopyOutputStart,CopyOutputEnd> <PrrtTransmitStart,LinkTransmitStart> <PrrtReturnPackage,SendFeedbackStart> <HandlePacketEnd,ChannelReceive> <PrrtDeliver,ChannelReceive> <ChannelReceive,ChannelTransmit> <HandlePacketStart,PrrtReturnPackage> <PrrtReturnPackage,PrrtReceivePackage> <DecodeEnd,HandlePacketStart> <LinkTransmitStart,LinkTransmitEnd> <LinkTransmitStart,LinkReceive> <PrrtSubmitPackage,PrrtSendEnd> <SendFeedbackEnd,HandlePacketEnd> <PrrtSendEnd,PrrtTransmitStart> <SendFeedbackStart,SendFeedbackEnd> <CopyOutputEnd,PrrtDeliver> <PrrtSendStart,PrrtSubmitPackage> <PrrtTransmitEnd,HandlePacketStart> <DecodeStart,DecodeEnd>

Goals:

▶ Identify code segments susceptible

to slowdown Slowdown computation:

  • 1. Evaluate slow and fast

confjgurations

  • 2. Compute S (⟨Ei, Ej⟩) = Dslow(⟨Ei,Ej⟩)

Dfast(⟨Ei,Ej⟩)

  • 3. Normalize with S (End-to-End)

14 / 16

slide-28
SLIDE 28

Slowdown Analysis

0.0 0.5 1.0 1.5 2.0 2.5 3.0 Normalized slowdown <CopyOutputStart,CopyOutputEnd> <PrrtTransmitStart,LinkTransmitStart> <PrrtReturnPackage,SendFeedbackStart> <HandlePacketEnd,ChannelReceive> <PrrtDeliver,ChannelReceive> <ChannelReceive,ChannelTransmit> <HandlePacketStart,PrrtReturnPackage> <PrrtReturnPackage,PrrtReceivePackage> <DecodeEnd,HandlePacketStart> <LinkTransmitStart,LinkTransmitEnd> <LinkTransmitStart,LinkReceive> <PrrtSubmitPackage,PrrtSendEnd> <SendFeedbackEnd,HandlePacketEnd> <PrrtSendEnd,PrrtTransmitStart> <SendFeedbackStart,SendFeedbackEnd> <CopyOutputEnd,PrrtDeliver> <PrrtSendStart,PrrtSubmitPackage> <PrrtTransmitEnd,HandlePacketStart> <DecodeStart,DecodeEnd>

Goals:

▶ Identify code segments susceptible

to slowdown Slowdown computation:

  • 1. Evaluate slow and fast

confjgurations

  • 2. Compute S (⟨Ei, Ej⟩) = Dslow(⟨Ei,Ej⟩)

Dfast(⟨Ei,Ej⟩)

  • 3. Normalize with S (End-to-End)

14 / 16

slide-29
SLIDE 29

Outline

Introduction Timing Analysis and Automation Energy Effjciency Analysis Conclusion

15 / 16

slide-30
SLIDE 30

Summary

∆elta

▶ Analyze the run-time behavior of real-time networks ▶ Provide valuable feedback to improve implementations ▶ Based on X-Lap

16 / 16

slide-31
SLIDE 31

Summary

∆elta

▶ Analyze the run-time behavior of real-time networks ▶ Provide valuable feedback to improve implementations ▶ Based on X-Lap

Analyse energy, latency, and jitter □ ✓ Identify problematic code parts □ ✓ Analyze code modifjcations □ ✓ Automate feedback

Implement Evaluate Analyze

16 / 16

slide-32
SLIDE 32

Summary

∆elta

▶ Analyze the run-time behavior of real-time networks ▶ Provide valuable feedback to improve implementations ▶ Based on X-Lap

Analyse energy, latency, and jitter □ ✓ Identify problematic code parts □ ✓ Analyze code modifjcations □ ✓ Automate feedback

Implement Evaluate Analyze

Source code available online: → http://xlap.larn.systems

16 / 16

slide-33
SLIDE 33

Summary

∆elta

▶ Analyze the run-time behavior of real-time networks ▶ Provide valuable feedback to improve implementations ▶ Based on X-Lap

Analyse energy, latency, and jitter □ ✓ Identify problematic code parts □ ✓ Analyze code modifjcations □ ✓ Automate feedback

Implement Evaluate Analyze

Thank you for your attention. Questions? Source code available online: → http://xlap.larn.systems

16 / 16

slide-34
SLIDE 34

Acknowledgements

HE 2584/4-1 SCHR 603/15-1 Supported by:

16 / 16

slide-35
SLIDE 35

Latency Criticality Analysis

0.0 0.1 0.2 0.3 0.4 0.5 0.6 latency criticality <CopyOutputEnd, PrrtDeliver> <PrrtSubmitPackage, PrrtSendEnd> <HandlePacketStart, SendFeedbackStart> <CopyOutputStart, CopyOutputEnd> <PrrtReturnPackage, HandlePacketEnd> <DecodeStart, DecodeEnd> <HandlePacketEnd, PrrtReceivePackage> <SendFeedbackEnd, PrrtReturnPackage> <DecodeEnd, HandlePacketStart> <PrrtSendStart, PrrtSubmitPackage> <LinkTransmitStart, LinkTransmitEnd> <LinkReceive, DecodeStart> <PrrtTransmitStart, LinkTransmitStart> <SendFeedbackStart, SendFeedbackEnd> <PrrtSendEnd, LinkTransmitStart>

16 / 16

slide-36
SLIDE 36

Energy Effjciency Analysis

1 2 3 Frequency (GHz) 0.00 0.05 0.10 0.15 0.20 0.25 0.30 Per-package ET² (nJs²)

16 / 16

slide-37
SLIDE 37

Slowdown Analysis

0.0 0.5 1.0 1.5 2.0 2.5 3.0 Normalized slowdown <CopyOutputStart,CopyOutputEnd> <PrrtTransmitStart,LinkTransmitStart> <PrrtReturnPackage,SendFeedbackStart> <HandlePacketEnd,ChannelReceive> <PrrtDeliver,ChannelReceive> <ChannelReceive,ChannelTransmit> <HandlePacketStart,PrrtReturnPackage> <PrrtReturnPackage,PrrtReceivePackage> <DecodeEnd,HandlePacketStart> <LinkTransmitStart,LinkTransmitEnd> <LinkTransmitStart,LinkReceive> <PrrtSubmitPackage,PrrtSendEnd> <SendFeedbackEnd,HandlePacketEnd> <PrrtSendEnd,PrrtTransmitStart> <SendFeedbackStart,SendFeedbackEnd> <CopyOutputEnd,PrrtDeliver> <PrrtSendStart,PrrtSubmitPackage> <PrrtTransmitEnd,HandlePacketStart> <DecodeStart,DecodeEnd>

16 / 16