OLD | NEW |
1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 3318 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3329 switch (op) { | 3329 switch (op) { |
3330 case Token::IN: | 3330 case Token::IN: |
3331 VisitForStackValue(expr->right()); | 3331 VisitForStackValue(expr->right()); |
3332 __ InvokeBuiltin(Builtins::IN, CALL_FUNCTION); | 3332 __ InvokeBuiltin(Builtins::IN, CALL_FUNCTION); |
3333 __ CompareRoot(rax, Heap::kTrueValueRootIndex); | 3333 __ CompareRoot(rax, Heap::kTrueValueRootIndex); |
3334 Split(equal, if_true, if_false, fall_through); | 3334 Split(equal, if_true, if_false, fall_through); |
3335 break; | 3335 break; |
3336 | 3336 |
3337 case Token::INSTANCEOF: { | 3337 case Token::INSTANCEOF: { |
3338 VisitForStackValue(expr->right()); | 3338 VisitForStackValue(expr->right()); |
3339 InstanceofStub stub; | 3339 InstanceofStub stub(InstanceofStub::kNoFlags); |
3340 __ CallStub(&stub); | 3340 __ CallStub(&stub); |
3341 __ testq(rax, rax); | 3341 __ testq(rax, rax); |
3342 // The stub returns 0 for true. | 3342 // The stub returns 0 for true. |
3343 Split(zero, if_true, if_false, fall_through); | 3343 Split(zero, if_true, if_false, fall_through); |
3344 break; | 3344 break; |
3345 } | 3345 } |
3346 | 3346 |
3347 default: { | 3347 default: { |
3348 VisitForAccumulatorValue(expr->right()); | 3348 VisitForAccumulatorValue(expr->right()); |
3349 Condition cc = no_condition; | 3349 Condition cc = no_condition; |
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3521 __ ret(0); | 3521 __ ret(0); |
3522 } | 3522 } |
3523 | 3523 |
3524 | 3524 |
3525 #undef __ | 3525 #undef __ |
3526 | 3526 |
3527 | 3527 |
3528 } } // namespace v8::internal | 3528 } } // namespace v8::internal |
3529 | 3529 |
3530 #endif // V8_TARGET_ARCH_X64 | 3530 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |