Thanks for the comments. The new patch will be uploaded on Monday.
I tested it on ia32 and it works fine.
There might be a better way to handle the double case, but I don't how how
to
handle that for ia32/x64.
Again I could not test the x64 code.
If minor changes are needed, could you please do it?
Thanks!
Alexandre
http://codereview.chromium.org/7489045/diff/16001/src/assembler.cc
File src/assembler.cc (right):
http://codereview.chromium.org/7489045/diff/16001/src/assembler.cc#newcode1115
src/assembler.cc:1115: ASSERT(IsCompareOp(op));
On 2011/09/09 11:14:46, William Hesse wrote:
Needs to be Token::IsCompareOp(op).
Done.
http://codereview.chromium.org/7489045/diff/16001/src/x64/lithium-codegen-x64.cc
File src/x64/lithium-codegen-x64.cc (right):
http://codereview.chromium.org/7489045/diff/16001/src/x64/lithium-codegen-x64.cc#newcode1556
src/x64/lithium-codegen-x64.cc:1556: __ cmpl(ToOperand(left),
Immediate(value));
On 2011/09/09 11:14:46, William Hesse wrote:
This case is not needed, because left is created with
"UseRegisterAtStart".
None of the new code is ever hit, because of how left and right are
created in
lithium-x64.cc.
This needs to be changed - I would recommend
UseRegisterOrConstantAtStart for integer left
UseOrConstantAtStart for integer right
UseRegisterOrConstantAtStart for double left
UseRegisterOrConstantAtStart for double right.
Then the only one that could be a memory operand is right.
These changes should also be made to the ia32 platform.
I cleaned up this case. I hope ToRegister will work here.
Changed the integer register allocation in lithium.
For the double I added code to check that the two values are constant.
Else we use registers. Otherwise one double reg + one double constant
fails.
I did the same on x64.
http://codereview.chromium.org/7489045/diff/16001/src/x64/lithium-codegen-x64.cc#newcode1568
src/x64/lithium-codegen-x64.cc:1568: __ cmp(ToRegister(left),
ToOperand(right));
On 2011/09/09 11:14:46, William Hesse wrote:
This must be a cmpl.
Done on x64.
http://codereview.chromium.org/7489045/
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev