week 9 -slicing and debugging Flashcards

(7 cards)

1
Q

What is a slice

A

slice - smallest subset of program that contains all statements that directly or indirctly influence the value or behaviour of a variable at a given point

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Inverse denominator

A

IDen(n): nodes that appear on all paths from n to program termination.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Nearest inverse denominator

A

NIDen(n): the closest node to n among the nodes that appear on all paths from n to program termination.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Influenced

A

Nodes that appear on at least one path from n to NIDen(n)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

delta debugging

A

Start with a failing test case C.
Divide C into n parts
𝐶1,𝐶2,…,𝐶𝑛

If there exists a part Cᵢ such that C \ Cᵢ still fails, remove Cᵢ and repeat with C \ Cᵢ.
If no such part exists, increase n (use smaller parts) and repeat.
Stop when no part can be removed without losing the failure; the result is a minimal failing test case.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is debugging

A

Debugging is the process of identifying, analyzing, and fixing defects or issues in a program.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Debugging Process (TRAFFIC Method):

A
  1. Track: Identify and understand the issue.
  2. Reproduce: Ensure the bug can be consistently recreated.
  3. Automate and Simplify: Minimize the test case to its simplest form.
  4. Find: Locate the origin of the problem (where the defect starts).
  5. Focus: Pinpoint the infected state or variables.
  6. Isolate: Determine what causes the infection (chain of events).
  7. Correct: Fix the issue and validate the solution
How well did you know this?
1
Not at all
2
3
4
5
Perfectly