|
-
Nov 26th, 2008, 05:30 PM
#1
Thread Starter
Hyperactive Member
backward and forward loops?
Hello fellow assembly programmers, i am here seeking some help on clarifying a topic that I've read about in "Professional Assembly Language".
The author explains the differences in forward and backward loop statements, but i cant picture the two different loops in my head....
All i am looking for is an example of both kinds with some tips on how to distinguish between the two. i understand why the backward loops are beneficial to the processor but cant picture the two different kinds of loops in my head.
P.S thanks in advance for clarifying this.
Coding's a Breeze if you'r at ease! GOD THATS CORNY!!
 - 
-
Dec 3rd, 2008, 05:05 PM
#2
Thread Starter
Hyperactive Member
Re: backward and forward loops?
well i guess not too many people out there understand assembly all that much any more.....
Anyways, i ended up answering my own question while read several other books. All i can say is, too bad there's not enough people to help....
Anyways, Thanks for viewing?
Coding's a Breeze if you'r at ease! GOD THATS CORNY!!
 - 
-
Dec 16th, 2008, 06:01 AM
#3
New Member
Re: backward and forward loops?
Hi g4hsean,
You are not only the person who wait for the answer of your question but i also waiting for your answer.So if you got your answer please post in your thread.
-
Dec 18th, 2008, 09:52 PM
#4
Thread Starter
Hyperactive Member
Re: backward and forward loops?
ok well the answer to my question was, if i remember correctly. backward loops are sort of like do while loops where the code between the loop tag and the conditional jump is the most likely to occur.
Example:
Code:
loop:
code
code
more code
cmp
jnz loop
and as for the forward loop, its more like a time synchronizer, it checks if the time is correct and if it isnt it will correct it. example:
Code:
checked:
cmp computertime, internet time
jne fix
jmp checked
fix:
set time routine
jmp checked
so basically the most likely code to be executed is the "jmp checked" which follows the cmp and the "jmp fix" code and the least likely is the fix time routine. And that is the difference between the two. if something is not clear dont hesitate to ask for help. im willing to help.
P.S if you need help, i do Assembly on IA32 processors on either Intel or GNU assemblers for UNIX and or Microshaft (Microsoft). Please specify the operating system and assembler used so as not to confuse the syntax.
Coding's a Breeze if you'r at ease! GOD THATS CORNY!!
 - 
-
Dec 21st, 2008, 12:32 PM
#5
Re: backward and forward loops?
what was the original statement you didn't understand?
-
Dec 21st, 2008, 05:16 PM
#6
Thread Starter
Hyperactive Member
Re: backward and forward loops?
the statement is found in the book i was reading.... they way the author put it was really misleading in my opinion, so i asked if someone could clarify what the true meaning of backward and forward loops were, for i haven't found any explanation concerning my question on Google. So after a couple of days programming in assembly the answer hit me and then it became clear to what the author meant by backward and forward loops.
I know its nothing hard to understand, i was just not sure what the author meant by backward and forward loops. Anyways i recalled when i first started learning java about the while and do-while loops and now i know in what context the author was putting the backward and forward loop statement.
In all i figured it would be good to have the question up on the net for future programmers looking to take up assembly such as i.
Coding's a Breeze if you'r at ease! GOD THATS CORNY!!
 - 
-
Dec 22nd, 2008, 01:10 PM
#7
Re: backward and forward loops?
like i said it would be helpful to see what the author said, otherwise i have no comment.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|