| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 554 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 565 } | 565 } |
| 566 } | 566 } |
| 567 | 567 |
| 568 | 568 |
| 569 void FullCodeGenerator::DoTest(Expression* condition, | 569 void FullCodeGenerator::DoTest(Expression* condition, |
| 570 Label* if_true, | 570 Label* if_true, |
| 571 Label* if_false, | 571 Label* if_false, |
| 572 Label* fall_through) { | 572 Label* fall_through) { |
| 573 ToBooleanStub stub(result_register()); | 573 ToBooleanStub stub(result_register()); |
| 574 __ push(result_register()); | 574 __ push(result_register()); |
| 575 __ CallStub(&stub); | 575 __ CallStub(&stub, condition->test_id()); |
| 576 __ test(result_register(), Operand(result_register())); | 576 __ test(result_register(), Operand(result_register())); |
| 577 // The stub returns nonzero for true. | 577 // The stub returns nonzero for true. |
| 578 Split(not_zero, if_true, if_false, fall_through); | 578 Split(not_zero, if_true, if_false, fall_through); |
| 579 } | 579 } |
| 580 | 580 |
| 581 | 581 |
| 582 void FullCodeGenerator::Split(Condition cc, | 582 void FullCodeGenerator::Split(Condition cc, |
| 583 Label* if_true, | 583 Label* if_true, |
| 584 Label* if_false, | 584 Label* if_false, |
| 585 Label* fall_through) { | 585 Label* fall_through) { |
| (...skipping 3663 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4249 __ add(Operand(edx), Immediate(masm_->CodeObject())); | 4249 __ add(Operand(edx), Immediate(masm_->CodeObject())); |
| 4250 __ jmp(Operand(edx)); | 4250 __ jmp(Operand(edx)); |
| 4251 } | 4251 } |
| 4252 | 4252 |
| 4253 | 4253 |
| 4254 #undef __ | 4254 #undef __ |
| 4255 | 4255 |
| 4256 } } // namespace v8::internal | 4256 } } // namespace v8::internal |
| 4257 | 4257 |
| 4258 #endif // V8_TARGET_ARCH_IA32 | 4258 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |