Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(289)

Side by Side Diff: src/arm/full-codegen-arm.cc

Issue 63423004: Introduce %_IsMinusZero. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: extended test case Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | src/arm/lithium-arm.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 3086 matching lines...) Expand 10 before | Expand all | Expand 10 after
3097 3097
3098 __ JumpIfSmi(r0, if_false); 3098 __ JumpIfSmi(r0, if_false);
3099 __ CompareObjectType(r0, r1, r2, JS_FUNCTION_TYPE); 3099 __ CompareObjectType(r0, r1, r2, JS_FUNCTION_TYPE);
3100 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); 3100 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false);
3101 Split(eq, if_true, if_false, fall_through); 3101 Split(eq, if_true, if_false, fall_through);
3102 3102
3103 context()->Plug(if_true, if_false); 3103 context()->Plug(if_true, if_false);
3104 } 3104 }
3105 3105
3106 3106
3107 void FullCodeGenerator::EmitIsMinusZero(CallRuntime* expr) {
3108 ZoneList<Expression*>* args = expr->arguments();
3109 ASSERT(args->length() == 1);
3110
3111 VisitForAccumulatorValue(args->at(0));
3112
3113 Label materialize_true, materialize_false;
3114 Label* if_true = NULL;
3115 Label* if_false = NULL;
3116 Label* fall_through = NULL;
3117 context()->PrepareTest(&materialize_true, &materialize_false,
3118 &if_true, &if_false, &fall_through);
3119
3120 __ CheckMap(r0, r1, Heap::kHeapNumberMapRootIndex, if_false, DO_SMI_CHECK);
3121 __ ldr(r2, FieldMemOperand(r0, HeapNumber::kExponentOffset));
3122 __ ldr(r1, FieldMemOperand(r0, HeapNumber::kMantissaOffset));
3123 __ cmp(r2, Operand(0x80000000));
3124 __ cmp(r1, Operand(0x00000000), eq);
3125
3126 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false);
3127 Split(eq, if_true, if_false, fall_through);
3128
3129 context()->Plug(if_true, if_false);
3130 }
3131
3132
3107 void FullCodeGenerator::EmitIsArray(CallRuntime* expr) { 3133 void FullCodeGenerator::EmitIsArray(CallRuntime* expr) {
3108 ZoneList<Expression*>* args = expr->arguments(); 3134 ZoneList<Expression*>* args = expr->arguments();
3109 ASSERT(args->length() == 1); 3135 ASSERT(args->length() == 1);
3110 3136
3111 VisitForAccumulatorValue(args->at(0)); 3137 VisitForAccumulatorValue(args->at(0));
3112 3138
3113 Label materialize_true, materialize_false; 3139 Label materialize_true, materialize_false;
3114 Label* if_true = NULL; 3140 Label* if_true = NULL;
3115 Label* if_false = NULL; 3141 Label* if_false = NULL;
3116 Label* fall_through = NULL; 3142 Label* fall_through = NULL;
(...skipping 1861 matching lines...) Expand 10 before | Expand all | Expand 10 after
4978 ASSERT(Memory::uint32_at(interrupt_address_pointer) == 5004 ASSERT(Memory::uint32_at(interrupt_address_pointer) ==
4979 reinterpret_cast<uint32_t>( 5005 reinterpret_cast<uint32_t>(
4980 isolate->builtins()->OsrAfterStackCheck()->entry())); 5006 isolate->builtins()->OsrAfterStackCheck()->entry()));
4981 return OSR_AFTER_STACK_CHECK; 5007 return OSR_AFTER_STACK_CHECK;
4982 } 5008 }
4983 5009
4984 5010
4985 } } // namespace v8::internal 5011 } } // namespace v8::internal
4986 5012
4987 #endif // V8_TARGET_ARCH_ARM 5013 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « no previous file | src/arm/lithium-arm.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698