OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 4614 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4625 Expression* sub_expr, | 4625 Expression* sub_expr, |
4626 Handle<String> check) { | 4626 Handle<String> check) { |
4627 Label materialize_true, materialize_false; | 4627 Label materialize_true, materialize_false; |
4628 Label* if_true = NULL; | 4628 Label* if_true = NULL; |
4629 Label* if_false = NULL; | 4629 Label* if_false = NULL; |
4630 Label* fall_through = NULL; | 4630 Label* fall_through = NULL; |
4631 context()->PrepareTest(&materialize_true, &materialize_false, | 4631 context()->PrepareTest(&materialize_true, &materialize_false, |
4632 &if_true, &if_false, &fall_through); | 4632 &if_true, &if_false, &fall_through); |
4633 | 4633 |
4634 { AccumulatorValueContext context(this); | 4634 { AccumulatorValueContext context(this); |
4635 VisitForTypeofValue(sub_expr); | 4635 VisitForTypeofValue(sub_expr->AsUnaryOperation()->expression()); |
4636 } | 4636 } |
4637 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); | 4637 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); |
4638 | 4638 |
4639 if (check->Equals(isolate()->heap()->number_string())) { | 4639 if (check->Equals(isolate()->heap()->number_string())) { |
4640 __ JumpIfSmi(v0, if_true); | 4640 __ JumpIfSmi(v0, if_true); |
4641 __ lw(v0, FieldMemOperand(v0, HeapObject::kMapOffset)); | 4641 __ lw(v0, FieldMemOperand(v0, HeapObject::kMapOffset)); |
4642 __ LoadRoot(at, Heap::kHeapNumberMapRootIndex); | 4642 __ LoadRoot(at, Heap::kHeapNumberMapRootIndex); |
4643 Split(eq, v0, Operand(at), if_true, if_false, fall_through); | 4643 Split(eq, v0, Operand(at), if_true, if_false, fall_through); |
4644 } else if (check->Equals(isolate()->heap()->string_string())) { | 4644 } else if (check->Equals(isolate()->heap()->string_string())) { |
4645 __ JumpIfSmi(v0, if_false); | 4645 __ JumpIfSmi(v0, if_false); |
(...skipping 299 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4945 *context_length = 0; | 4945 *context_length = 0; |
4946 return previous_; | 4946 return previous_; |
4947 } | 4947 } |
4948 | 4948 |
4949 | 4949 |
4950 #undef __ | 4950 #undef __ |
4951 | 4951 |
4952 } } // namespace v8::internal | 4952 } } // namespace v8::internal |
4953 | 4953 |
4954 #endif // V8_TARGET_ARCH_MIPS | 4954 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |