1 00:00:00,270 --> 00:00:07,080 So guess now we'll be taking a look at this contraflow instructions, contraflow means controlling the 2 00:00:07,080 --> 00:00:08,080 program's flow. 3 00:00:08,520 --> 00:00:12,840 So how we can control the program through changing the instruction point? 4 00:00:13,600 --> 00:00:19,370 Well, I have already said that we cannot change the AP very normal instructions. 5 00:00:19,590 --> 00:00:27,410 That means we cannot change the system very by simply say more to subtract or multiplication, etc. 6 00:00:28,410 --> 00:00:32,120 But there are some instructions that can change the P value. 7 00:00:33,330 --> 00:00:36,470 OK, now let's take a look at that. 8 00:00:36,750 --> 00:00:40,130 Those instructions and these are divided into two types. 9 00:00:40,410 --> 00:00:43,940 Those are unconditional dump and conditional jumps. 10 00:00:44,220 --> 00:00:52,800 So unconditional dumpings, the program flow dumps from a particular point to another point, whatever 11 00:00:52,800 --> 00:00:53,710 the condition may be. 12 00:00:54,690 --> 00:00:59,790 OK, let's check the syntax and the syntax dump space address. 13 00:01:00,240 --> 00:01:08,340 So whenever this instruction has been executed and the program jumps to this address directly, so the 14 00:01:08,340 --> 00:01:13,580 instructions in between the next address and this address will not get executed. 15 00:01:14,160 --> 00:01:19,830 That's why this is called conditional, because we are not taking any condition before the jump and 16 00:01:19,830 --> 00:01:22,580 we are definitely performing a jump to this address. 17 00:01:22,920 --> 00:01:24,550 That's why this is called unconditional. 18 00:01:24,580 --> 00:01:32,130 You now, before we want you see there are conditions, we need to take a look at the Arizona instruction 19 00:01:32,130 --> 00:01:33,800 called COMPAR Instruction. 20 00:01:34,440 --> 00:01:39,550 So this instruction takes to values and compares each of them. 21 00:01:40,590 --> 00:01:43,040 So compare Ebix commonly. 22 00:01:43,350 --> 00:01:50,730 So it takes the Ebix values and the value and then compares the board to the values. 23 00:01:51,000 --> 00:02:00,510 But it does not show the result, but it affects the extended flaks like in 04, Exane Flag four, etc.. 24 00:02:00,690 --> 00:02:05,880 So based on those flags, these conditional jumps takes place. 25 00:02:06,600 --> 00:02:13,290 Actually, this company instruction subtracts both of these teachers, but both of these are different 26 00:02:13,290 --> 00:02:21,120 values and then sets the extended fact values based on those extended flag values, these conditional 27 00:02:21,120 --> 00:02:21,990 dump's takes place. 28 00:02:22,560 --> 00:02:24,240 Now, let's take a look at this. 29 00:02:24,750 --> 00:02:31,550 Are these conditional jumps first one is greater than jump greater then. 30 00:02:32,100 --> 00:02:38,100 So after this operation, Ebix, where say Ebix contains 50. 31 00:02:38,610 --> 00:02:43,740 So the next construction will be letting this dump is greater than to the address. 32 00:02:44,850 --> 00:02:47,920 So Fifi's obviously greater than can be. 33 00:02:48,180 --> 00:02:56,970 So the Democrats then will get a ticket and the jumps take place and in the same way jump if greater 34 00:02:56,970 --> 00:02:58,200 than or equal to. 35 00:02:59,980 --> 00:03:10,110 And jump, jump, start, so let's say Ebix contains the value and then I will shoot and then Contee 36 00:03:10,250 --> 00:03:15,700 then the next injection, if we write Jampolis then put this to any address. 37 00:03:16,910 --> 00:03:26,140 Since this dump takes place, if you will, its contents value 30 cents, that is not less than guaranteed, 38 00:03:26,150 --> 00:03:33,500 then this dump will not take place and program continue get normally in a similar way, jump less than 39 00:03:33,500 --> 00:03:36,920 equal, generally stands for less than are equal to. 40 00:03:37,580 --> 00:03:46,070 And finally, James jump is equal if sponte the exact value of this right upfront wanted 2010 only the 41 00:03:46,220 --> 00:03:47,310 jumps takes place. 42 00:03:48,110 --> 00:03:51,250 So these are the basic jumps you need to know. 43 00:03:51,440 --> 00:03:56,140 There are so many dumps based on the external facts. 44 00:03:56,660 --> 00:04:02,600 You you can check on Google that jump jump jumps injection table. 45 00:04:03,230 --> 00:04:12,500 These dumps are very important in the expectation perspective when in the Buffalo first, sometimes 46 00:04:12,500 --> 00:04:21,770 application will take the jump E.S.P Xcode as a backwater, then these jumps comes handy. 47 00:04:23,470 --> 00:04:31,010 OK, guys, that's all some expectation concept now we're going to want to you and let's take a look 48 00:04:31,010 --> 00:04:33,450 at some examples of this now. 49 00:04:33,470 --> 00:04:35,150 Let me create a new file. 50 00:04:40,580 --> 00:04:43,510 Now I'm reading the Groberg, Scott. 51 00:04:47,580 --> 00:04:50,670 Now, I am that in the section. 52 00:04:56,900 --> 00:04:58,940 Now, let's start our chat function. 53 00:05:03,160 --> 00:05:07,840 Now, what I'm going to do is I'm going to move your camera. 54 00:05:09,640 --> 00:05:10,210 30. 55 00:05:13,900 --> 00:05:16,690 More e-books, karma, Condee. 56 00:05:21,600 --> 00:05:34,740 No, what I am going to do is I will say jump blue and so there is no simple label or function in our 57 00:05:35,610 --> 00:05:36,410 assembly code. 58 00:05:36,460 --> 00:05:38,630 No, we are going to create a temp. 59 00:05:38,940 --> 00:05:41,280 This is the temp label and. 60 00:05:43,580 --> 00:05:44,780 OK, actually, right. 61 00:05:47,100 --> 00:05:54,090 OK, let's say some normal instructions, easy cover 50. 62 00:05:58,190 --> 00:06:08,660 Politics, karma, and so whenever my program is executing this court, this is the unconditional jump 63 00:06:08,660 --> 00:06:12,760 that means the program jumps to this level directly. 64 00:06:20,650 --> 00:06:29,830 Now, let's write one instruction after this dump instruction that is moving X comma 40 to show you 65 00:06:29,830 --> 00:06:38,200 guys that year while you will study, because this jump radically changes the education properties level 66 00:06:38,440 --> 00:06:40,780 and this instruction will not get executed. 67 00:06:41,860 --> 00:06:44,050 Now, let's show this. 68 00:06:44,050 --> 00:06:47,620 While not somebody with an awesome. 69 00:06:58,310 --> 00:07:01,290 Down the street with Ali. 70 00:07:12,590 --> 00:07:18,890 Since we're not printing any output, I will be opening likely died during delivery worker. 71 00:07:21,360 --> 00:07:28,970 Now, let me start with the breakpoint at the start function, since we know that there is a short function. 72 00:07:30,570 --> 00:07:31,910 Now let's run our program. 73 00:07:36,070 --> 00:07:47,040 So we are moving the money value, which is OK, one value that is in hexadecimal, so e X contains 74 00:07:47,050 --> 00:07:47,950 one value. 75 00:07:49,570 --> 00:07:56,800 Now we are placing the Dirac's one quarter into e-books, so I'll give an absolutely fine. 76 00:07:57,040 --> 00:07:59,920 Yes, contents one, e-books, contents one. 77 00:07:59,920 --> 00:08:04,090 For now, the instruction takes place. 78 00:08:04,150 --> 00:08:06,610 Jump to this address, which is them. 79 00:08:07,030 --> 00:08:14,380 Now, as you can see, there is a little arrow mark here, arrow pointing to that level. 80 00:08:15,790 --> 00:08:20,990 Now you can see the next section is what we direct onto. 81 00:08:21,220 --> 00:08:28,540 That is we we have we are trying to modify it again, but it won't get more difficult because we are 82 00:08:28,930 --> 00:08:30,030 jumping to the stamp. 83 00:08:30,820 --> 00:08:32,630 So this instruction is kepel. 84 00:08:35,090 --> 00:08:39,310 If they're on this, you can see the exact content still funny. 85 00:08:42,840 --> 00:08:52,890 So this an you see now, this temporary contains some coal, which most an area that is not very much 86 00:08:52,890 --> 00:08:53,350 important. 87 00:08:53,380 --> 00:08:54,720 Now let's cut our program. 88 00:08:54,800 --> 00:08:56,400 Now let's see the conditional jumps. 89 00:09:11,280 --> 00:09:15,420 No, I'm going to compare your ex on. 90 00:09:17,560 --> 00:09:25,100 Thirty six eggs, condensed day, and we are also comparing with 30, it will be equal value. 91 00:09:25,540 --> 00:09:27,250 Now I'm going to jump you. 92 00:09:27,280 --> 00:09:27,790 We call. 93 00:09:35,410 --> 00:09:36,690 Now, let's. 94 00:09:40,470 --> 00:09:47,480 OK, at the same time, we will move to another jumper here to show you are conditional jumps in the 95 00:09:47,490 --> 00:09:48,290 singular program. 96 00:09:49,620 --> 00:09:58,560 I mean, at a time no issues content 50 is a compare you see with. 97 00:10:00,560 --> 00:10:06,380 Hundred since six is going to be less than a hundred. 98 00:10:07,490 --> 00:10:11,700 Now, if I said jump for less, then to test. 99 00:10:14,010 --> 00:10:22,200 Then our program for now that the court at the test level gets a DeCoutere. 100 00:10:24,750 --> 00:10:28,170 Now, let's stop right there, a town called. 101 00:10:36,660 --> 00:10:46,530 OK, guys, now what we have done is we are taking the exit party, so this is so dump president takes 102 00:10:46,530 --> 00:10:48,480 place to the top and bottom. 103 00:10:49,410 --> 00:10:52,840 The core of the template will get a bit more comfy. 104 00:10:52,950 --> 00:10:58,780 And then we are comparing you six hundred since he is less than 100. 105 00:10:59,310 --> 00:11:03,230 This dump takes place and this section will not get executed. 106 00:11:03,540 --> 00:11:06,020 Now, let's see all of this inaudible good. 107 00:11:24,900 --> 00:11:26,880 Now, I'm pushing the break point at the start. 108 00:11:29,450 --> 00:11:30,610 Now, let's run the program. 109 00:11:35,020 --> 00:11:42,930 Now we are moving the value for money in politics and one foot into e-books, just like previous matter, 110 00:11:43,720 --> 00:11:45,170 previous example? 111 00:11:45,580 --> 00:11:49,630 No, we are comparing year with one year since EGS also contains only. 112 00:11:52,140 --> 00:11:59,610 Now the flag is set, you can see the flag here because this combat operation subtracts these values 113 00:11:59,940 --> 00:12:06,770 and checks since these two areas are same, the same production business, the Gedo and the producer, 114 00:12:07,290 --> 00:12:11,600 so difficult districts, this takes the flag. 115 00:12:11,610 --> 00:12:14,040 And you can see there is a Aramark. 116 00:12:14,040 --> 00:12:17,510 Again, it tells us that our jump is successful. 117 00:12:19,260 --> 00:12:22,710 So this more direction did not get executed. 118 00:12:24,210 --> 00:12:26,090 Now we're going to try to do that easy. 119 00:12:26,140 --> 00:12:29,640 It's so easy to do. 120 00:12:29,790 --> 00:12:30,380 That's fine. 121 00:12:31,740 --> 00:12:34,920 No, we are comparing it to 64. 122 00:12:37,920 --> 00:12:49,980 Shin, 64, is greater than the 32 dumpy president, so this is the reason that why don't pay for this 123 00:12:49,980 --> 00:12:56,200 done and the dumped program jumps to this test function global. 124 00:12:58,700 --> 00:13:07,160 And as you can see, politics come out here did not get executed because it contains zero, that means 125 00:13:07,160 --> 00:13:08,900 the jump has successfully taken. 126 00:13:09,650 --> 00:13:18,300 No, we can see the normal Shankaracharya if we can run this program, as it would normally. 127 00:13:19,130 --> 00:13:22,130 So that's all you need to know about the basic jumps. 128 00:13:22,200 --> 00:13:23,990 Yes, I hope we have understood.