News for hackers. Stuff that matters.
Re:Int 80h (2001) by pcwalton on Sunday August 21, 2016 @01:58PM (#12331913)
I dunno. I think by any measure being able to write "x / 3" will gain you productivity vs. "imul eax,2863311531; shr eax,1" (with the trip to the Hacker's Delight page necessary to look up the magic number).
Re:Int 80h (2001) by psyklic on Sunday August 21, 2016 @03:48PM (#12332429)
Or just use DIV/FDIV/FIDIV.
Re:Int 80h (2001) by mschuster91 on Sunday August 21, 2016 @06:00PM (#12332914)
DIV is way slower than MUL, so unless you need the extra precision or the result of the modulo, don't use DIV.
Re:Int 80h (2001) by psyklic on Tuesday August 23, 2016 @12:39AM (#12341444)
We were talking about readability, not speed. (Of course, you could also just write a macro.)