WEBVTT

00:01.070 --> 00:04.340
Hello and welcome to today's lecture.

00:04.340 --> 00:11.210
In this lecture, we are going to delve into the fascinating world of debugging and code execution analysis

00:11.210 --> 00:16.580
using a powerful tool known as data display debugger or triple D.

00:16.850 --> 00:22.310
So if you are a Linux enthusiast or software developer looking to enhance your debugging skills, you

00:22.310 --> 00:24.530
will learn that topic in this course.

00:24.530 --> 00:32.810
So let's jump right in the data display debugger, often abbreviated as d, d d is an indispensable

00:32.810 --> 00:38.750
debugging tool that comes with a user friendly graphical interface tailored for the Linux operating

00:38.750 --> 00:39.380
system.

00:39.380 --> 00:46.070
Its primary objective is to assist developers in diagnosing, understanding and rectifying issues with

00:46.070 --> 00:51.380
their code by providing an intuitive visual representation of program execution.

00:51.380 --> 00:57.710
So triple D, d, d, d, also known as the empowers developers to analyze the behavior of their code

00:57.710 --> 01:03.120
step by step, making the debugging process more efficient and productive.

01:03.150 --> 01:09.570
So before we dive deeper, uh, let's ensure you have a d d d up and running on your system.

01:10.020 --> 01:11.580
Installation is a breeze.

01:11.580 --> 01:15.690
Just open your terminal and execute this sudo here.

01:15.690 --> 01:22.350
Sudo apt install d d d and enter your password for account.

01:22.350 --> 01:23.430
And that's it.

01:23.430 --> 01:28.740
So this will fetch and install the package from your linux package manager.

01:28.740 --> 01:35.430
And once installed you will be ready to harness the power of triple D to its fullest potential.

01:35.430 --> 01:42.330
So before we proceed further, let's take a moment to understand why debugging is such a crucial aspect

01:42.330 --> 01:43.920
of software development.

01:43.920 --> 01:51.840
So even most experienced developers encounter bugs, unexpected behaviors and logical errors in their

01:51.840 --> 01:52.260
code.

01:52.260 --> 02:00.540
So debugging helps us identify, isolate and correct these issues, ensuring our programs run smoothly

02:00.540 --> 02:02.520
and reliably d d.

02:02.520 --> 02:11.040
D acts as a guiding light in this process, allowing us to gain insights into how our code is executed

02:11.040 --> 02:13.800
and where potential pitfalls lie.

02:14.010 --> 02:22.050
So to give you practical examples of D these capabilities, we will embark on our coding journey together.

02:22.050 --> 02:27.060
So in this section we will be working on a program that might not produce any visible output.

02:27.090 --> 02:32.550
However, our goal is not to see the output, but to explore the intricacies of the code, execution

02:32.550 --> 02:34.680
and concepts registers here.

02:34.680 --> 02:45.110
So but we will also, um, we might add some outputs here, but now we will need to open our this system

02:45.120 --> 02:47.100
and start our.

02:47.950 --> 02:49.440
Uh, process here.

02:49.450 --> 02:55.510
But, uh, here now, we will need to open the system, so we will name our.

02:59.630 --> 03:04.890
Then click on Create new project, delete this existing project here and that's it.

03:04.910 --> 03:12.140
So here, after installing the data display debugger, we will just write this short code here, which

03:12.800 --> 03:17.680
we will move this here and we will name it move that ASM here.

03:17.690 --> 03:27.650
So add the command, move that ASM, add the section data here so we will add almost six numbers be

03:27.800 --> 03:34.640
nom nom de nom and ki nam one ki nam two and ki nam three.

03:34.640 --> 03:35.300
Here.

03:35.930 --> 03:45.860
Now let's add this here be Nam db here DB one, two, three, W num.

03:45.860 --> 03:49.040
So these are the data variables here that we will use.

03:49.250 --> 03:53.720
W d is one, two, three, 45D num.

03:54.510 --> 04:00.390
Uh DD1, two, three, four, five, six, seven, 890.

04:00.660 --> 04:03.660
And q num one.

04:05.250 --> 04:07.560
D Q Here is.

04:09.650 --> 04:15.830
Is going to be like, you know, from 1 to 0 and 1 to 9, one to.

04:17.880 --> 04:18.270
Here.

04:21.520 --> 04:22.180
That's it.

04:22.210 --> 04:26.380
And we will also add M2 and M3 here.

04:27.250 --> 04:31.270
M2 is again available to the queue here.

04:31.450 --> 04:35.380
And one, two, three, four, five, six here.

04:35.500 --> 04:38.860
And queue number three is going to be the queue.

04:38.890 --> 04:43.620
This is going to be our number point 14.

04:43.630 --> 04:48.130
So we will also add this section VSS here.

04:49.630 --> 04:50.290
Action.

04:51.070 --> 04:55.690
We will not write anything for it and we will also add action text.

04:55.720 --> 04:57.670
Then we will create a global main.

04:59.240 --> 05:01.820
And in main function here.

05:02.440 --> 05:04.060
They will firstly pass.

05:05.680 --> 05:06.190
Uh, we will.

05:06.190 --> 05:08.200
Firstly, in this main function, we will pass the.

05:08.230 --> 05:12.970
Yes, uh, we will push the RPC and.

05:16.520 --> 05:17.180
Here?

05:17.360 --> 05:18.320
Uh parsh.

05:18.780 --> 05:19.250
RB.

05:20.610 --> 05:21.270
He.

05:22.360 --> 05:25.960
Who RSVP'd to RSVP.

05:27.940 --> 05:28.870
Racks.

05:31.310 --> 05:32.000
And this one.

05:32.000 --> 05:33.740
So this is to.

05:35.000 --> 05:36.350
Uh, this is Phil.

05:37.210 --> 05:39.480
The racks with once.

05:41.610 --> 05:46.080
And move a little bit.

05:46.980 --> 05:50.550
And here we will enter the byte num here.

05:51.300 --> 05:53.320
The p norm.

05:53.790 --> 06:08.160
This is this actually does not clear upper bits of rax so does not does not clear upper bits of Rax.

06:08.160 --> 06:14.610
So you can also write the crucial points like upper case here.

06:15.560 --> 06:17.360
Uh, to make attention.

06:19.450 --> 06:24.220
So we will also add X or here.

06:35.020 --> 06:39.370
Better so x or racks rax here.

06:39.460 --> 06:44.050
So this is for the, uh, clearing the rax.

06:47.300 --> 06:52.220
Clear the racks and move again.

06:59.690 --> 07:02.930
L and bite here.

07:03.640 --> 07:11.830
So again, we will pass this beenham here to make the rags to have the correct value here with this.

07:13.270 --> 07:21.070
In in here we have now racks has the correct value.

07:21.910 --> 07:25.720
And after that we will move the racks minus one.

07:25.720 --> 07:27.880
So we will fill the.

07:28.880 --> 07:30.720
Racks with ones.

07:32.980 --> 07:35.710
And here, Rex.

07:37.000 --> 07:37.690
One.

07:39.380 --> 07:43.630
Or will racks with once.

07:44.930 --> 07:51.800
And after that, move the axe here to war here.

07:51.800 --> 07:54.260
And we will also pass the numb here.

07:55.440 --> 07:56.370
W nom.

07:56.670 --> 08:00.600
This does not clear the upper bits of rax again.

08:01.820 --> 08:03.710
Actually, since we are.

08:04.700 --> 08:08.180
Again copying this here so it will be better.

08:09.140 --> 08:11.630
As one spaces new lines here.

08:13.220 --> 08:23.630
So fill racks with once and again this does does not clear does not clear upper bits of racks.

08:24.970 --> 08:27.470
And again XOR here.

08:27.970 --> 08:28.740
Racks.

08:28.810 --> 08:31.330
Racks Here we are clearing the racks.

08:31.330 --> 08:34.930
You you learned that X or in lecture actually.

08:34.930 --> 08:38.740
But it's same here and now.

08:38.740 --> 08:42.910
We will move the ax word.

08:44.150 --> 08:45.530
W name again.

08:45.530 --> 08:55.580
And here again our now racks again here now Racks has the correct value.

08:57.360 --> 08:59.700
And after that we will move the.

09:01.980 --> 09:04.350
We will move the racks.

09:06.960 --> 09:09.210
Rags minus one.

09:09.480 --> 09:10.680
This is for.

09:12.200 --> 09:17.720
Uh, fill racks with ones and move racks.

09:22.250 --> 09:23.630
He walked here.

09:25.170 --> 09:28.350
In this case, we will also pass the Num one.

09:28.440 --> 09:29.490
This again.

09:29.490 --> 09:34.380
Uh, does does this actually, uh, does clear upper.

09:35.490 --> 09:43.350
It's off racks and you will learn why these are not actually, this one is clear.

09:43.440 --> 09:43.950
Right.

09:44.460 --> 09:50.880
So now we're going to do after that is we will, uh, make that one apparent.

09:50.880 --> 09:51.380
Um.

09:52.380 --> 09:54.120
Always in a register.

09:54.120 --> 09:59.310
And after that we will need to source operand to an immediate value.

09:59.400 --> 10:02.030
So we'll learn that here.

10:02.730 --> 10:04.530
Or here.

10:05.260 --> 10:07.090
You numb to.

10:08.790 --> 10:10.440
Racks here.

10:11.160 --> 10:13.500
One operand.

10:13.500 --> 10:17.490
Always a register.

10:20.120 --> 10:22.880
And move here Cracks.

10:28.590 --> 10:33.330
This is the source of her.

10:36.310 --> 10:36.680
Um.

10:37.390 --> 10:40.060
Immediate value.

10:42.090 --> 10:42.390
Move.

10:42.510 --> 10:46.380
KXM0 here.

10:48.360 --> 10:48.750
And.

10:52.360 --> 10:52.500
X.

10:52.590 --> 10:53.980
X zero.

10:55.640 --> 10:56.510
And here.

10:56.510 --> 10:58.460
Paascu Norm three.

11:02.830 --> 11:04.310
The instruction.

11:05.440 --> 11:09.840
And floating point.

11:09.840 --> 11:13.220
And after that we will move RSP.

11:14.960 --> 11:15.140
To.

11:18.220 --> 11:20.800
And pop here.

11:21.590 --> 11:23.810
And after that, we'll finally read.

11:23.840 --> 11:25.990
So we will save the source file.

11:26.010 --> 11:32.420
A source file as the move that move that RSM.

11:33.740 --> 11:39.890
And we will build and run it to see if it works in the next lecture.

11:39.890 --> 11:41.090
So actually, let's.

11:42.690 --> 11:44.410
Create a new folder.

11:44.430 --> 11:45.270
Move.

11:48.240 --> 11:50.880
And I will save it.

11:51.120 --> 11:52.830
Move that --.

11:53.700 --> 11:54.420
So that's it.

11:54.420 --> 11:56.430
And I'm waiting you in next lecture.
