http://codereview.chromium.org/5122005/diff/11001/src/ia32/codegen-ia32.cc File src/ia32/codegen-ia32.cc (right):
http://codereview.chromium.org/5122005/diff/11001/src/ia32/codegen-ia32.cc#newcode6703 src/ia32/codegen-ia32.cc:6703: __ mov(array_length, scratch); That is if you are reading it with a plan to change it or improve it, in which case you should be aware of the register shortage, and the need to put specific things in registers. But this can be changed when it is rewritten with a separate checking and counting loop, an allocation, and a copying loop. Taking the allocation out of the loops frees up a lot of variables. On 2010/11/18 17:49:09, Lasse Reichstein wrote:
But they are not equivalent. I was about to suggest that you used
array_length
in the calculations above, instead of using scratch and then moving
scratch to
array_length ... until I realized that array_length was an Operand.
Reading what's written doesn't need distinguishing, but understanding
why it's
written as it is, does.
http://codereview.chromium.org/5122005/diff/11001/src/ia32/codegen-ia32.cc#newcode6769 src/ia32/codegen-ia32.cc:6769: __ jmp(©_loop_1_entry); On 2010/11/18 17:49:09, Lasse Reichstein wrote:
You wouldn't need the entry label then, so the label count is the
same.
Go for optimal! Great isn't good enough! :)
Done. http://codereview.chromium.org/5122005/ -- v8-dev mailing list [email protected] http://groups.google.com/group/v8-dev
