Thread: Quicksort Error
View Single Post
Old Nov 2nd, 2006, 4:38 AM   #3
lectricpharaoh
SEXY SHOELESS GOD OF WAR!
 
lectricpharaoh's Avatar
 
Join Date: Jun 2005
Location: Wet west coast of Canada
Posts: 1,197
Rep Power: 5 lectricpharaoh will become famous soon enough
Quote:
Originally Posted by Ambuoroko
So adding a test in the beginning to return if DI is greater than, say, 100, fixes the problem, since I can't/don't know how to check if it's less than zero.
cmp di, 0
jl <address offset>
It seems really odd to me that they seem to have taught you how to pass args on the stack (or at least access passed ones), compare register to register, compare register to memory, jump around, but have not yet shown that you can use immediate values in many instructions.
__________________
And once again, Probability proves itself willing to sneak into a back alley and service Drama as would a copper-piece harlot.
- Vaarsuvius, Order of the Stick
lectricpharaoh is offline   Reply With Quote