embedding testing 2015

43
In a world of bugs – How to become a successful bug-hunter? by Georg Lohrer from EmbeddedSuccess.com

Upload: georg-lohrer

Post on 16-Feb-2017

217 views

Category:

Engineering


0 download

TRANSCRIPT

In a world of bugs – How to become a successful

bug-hunter?

by Georg Lohrer

from EmbeddedSuccess.com

The Trains

The Trains

Training on the job

1st Carriage of the „People“-Train

Use your internal resources

Use a skill-matrix!

Compose Your Own Who‘s Who

2nd Carriage of the „People“-Train

Non-Destructive vs. Destructive

Analyze the logfiles

Search the history

Drill and strip off

Blablablabla blabla

#if 0

blabla {

bla = blabla();

blablabla(bla);

bla(bla; bla; bla) {

}

if (bla > bla) {

blabla;

} then {

bla;

}

}

bla (bla ? bla : bla);

#endif

bla(bla);

}

Blablablabla blabla

blabla {

bla = blabla();

#if 0

blablabla(bla);

bla(bla; bla; bla) {

}

#endif

if (bla > bla) {

blabla;

} then {

bla;

}

}

bla (bla ? bla : bla);

}

Blablablabla blabla

blabla {

bla = blabla();

blablabla(bla);

bla(bla; bla; bla) {

}

if (bla > bla) {

blabla;

} then {

bla;

}

}

bla (bla ? bla : bla);

}

Instrument your code

int foo(double& y) {

int x = 0;

x = enumerate(y);

return x;

}

int foo(double& y) {

int x = 0;

ENSURE(y >= 0.0);

x = enumerate(y);

ASSURE(x > 10);

return x;

}

int foo(double& y) {

CHECKPARAM1(y);

STARTMEMCHECK();

int x = 0;

ENSURE(y >= 0.0);

x = dofoo(y);

ASSURE(x > 10);

ENDMEMCHECK();

return x;

}

3rd Carriage of the „People“-Train

The Detective‘s Mindset

© ullrich / Fotolia

Collect facts

Collect Suspects

Do NOT trust witnesses!

Stay Patient

© HitToon.com / Fotolia

Sherlock Holmes

© HitToon.com / Fotolia

Once you eliminate the impossible, whatever remains, no matter how improbable, must be the truth. Arthur Conan Doyle

4th Carriage of the „People“-Train

Thinking out-of-the-box

Think the Impossible

Change …

Change Your Perspective

Good Cop – Bad Cop or

The Devil‘s Advocat

5th Carriage of the „People“-Train

„Tell Your Dog“-Principle

横 展開 Yoko Ten Kai

横 beside, lateral, horizontal 展開 deployment, development,

advance

Yoko Ten Kai

The Trains

Bug Hunting

… is a learnable skill

Finally

Bug Hunting

… is a learnable skill

Sometimes

You need a pinch of intuition and luck.

Keep in Mind

Stay Curious

Keep in Mind

Stay Curious Never Give Up