https://chromiumcodereview.appspot.com/10825071/diff/1/src/hydrogen-instructions.cc File src/hydrogen-instructions.cc (right):
https://chromiumcodereview.appspot.com/10825071/diff/1/src/hydrogen-instructions.cc#newcode1151 src/hydrogen-instructions.cc:1151: if (change->value()->IsDiv() && I did not realize normal double to integer representation changes are not truncating. I will add a check for that flag on "change". From what I can tell, if the optimization is only applied when the division has a use count of 1 then marking storing into a typed array as truncating won't have any effect since "x[0] = 0xFF / (x[0] + 1)" will always generate a simulate that pushes the division. What conditions would be necessary to apply this substitution in that case? Would it be valid to apply this substitution if there are one or more simulate instructions for which the division is a use but they occur after the change instruction (instead of before as in your example below)? https://chromiumcodereview.appspot.com/10825071/ -- v8-dev mailing list [email protected] http://groups.google.com/group/v8-dev
