LLDB

0.0(0)
studied byStudied by 3 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/16

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

17 Terms

1
New cards

-g

Compilation flag to be able to use a debugger

2
New cards

lldb <executable name>

Open debugger

3
New cards

quit/q

Exits debugger

4
New cards

run

Runs program up to break point

5
New cards

b <line number>

sets a breakpoint at the specified line number

6
New cards

l

See the code around the location where your execution is currently paused

7
New cards

p <variable name>

prints value of variable

8
New cards

p &<variable name>

prints address of variable

9
New cards

watchpoint set variable <variable name>

stop execution and notify if the value of the variable changes

10
New cards

next

Executes one line of code without entering function calls

11
New cards

step

Executes one line of code and will enter function calls

12
New cards

kill

exit current program

13
New cards

-fno-stack-protector

Removes compiler protections against buffer overflow

14
New cards

x/<#>x<unit>. &<var>

Read # of units from the memory address starting at &var. (ex: x/4xb &name reads four bytes from variable name)

15
New cards

word

4-byte block of memory

16
New cards

objdump -d <executable>

Gives addresses of all machine code for the executable

17
New cards

bt/backtrace

go back a frame