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

Side by Side Diff: src/hydrogen.cc

Issue 18037002: Clean up the usage of V8_TARGET_ARCH_${arch} and V8_HOST_ARCH_${arch} (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 7 years, 6 months 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 | « src/heap.cc ('k') | src/hydrogen-instructions.cc » ('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 7870 matching lines...) Expand 10 before | Expand all | Expand 10 after
7881 int nodes_added = InliningAstSize(target); 7881 int nodes_added = InliningAstSize(target);
7882 if (nodes_added == kNotInlinable) return false; 7882 if (nodes_added == kNotInlinable) return false;
7883 7883
7884 Handle<JSFunction> caller = current_info()->closure(); 7884 Handle<JSFunction> caller = current_info()->closure();
7885 7885
7886 if (nodes_added > Min(FLAG_max_inlined_nodes, kUnlimitedMaxInlinedNodes)) { 7886 if (nodes_added > Min(FLAG_max_inlined_nodes, kUnlimitedMaxInlinedNodes)) {
7887 TraceInline(target, caller, "target AST is too large [early]"); 7887 TraceInline(target, caller, "target AST is too large [early]");
7888 return false; 7888 return false;
7889 } 7889 }
7890 7890
7891 #if !defined(V8_TARGET_ARCH_IA32) 7891 #if !V8_TARGET_ARCH_IA32
7892 // Target must be able to use caller's context. 7892 // Target must be able to use caller's context.
7893 CompilationInfo* outer_info = current_info(); 7893 CompilationInfo* outer_info = current_info();
7894 if (target->context() != outer_info->closure()->context() || 7894 if (target->context() != outer_info->closure()->context() ||
7895 outer_info->scope()->contains_with() || 7895 outer_info->scope()->contains_with() ||
7896 outer_info->scope()->num_heap_slots() > 0) { 7896 outer_info->scope()->num_heap_slots() > 0) {
7897 TraceInline(target, caller, "target requires context change"); 7897 TraceInline(target, caller, "target requires context change");
7898 return false; 7898 return false;
7899 } 7899 }
7900 #endif 7900 #endif
7901 7901
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after
8030 HConstant* undefined = graph()->GetConstantUndefined(); 8030 HConstant* undefined = graph()->GetConstantUndefined();
8031 bool undefined_receiver = HEnvironment::UseUndefinedReceiver( 8031 bool undefined_receiver = HEnvironment::UseUndefinedReceiver(
8032 target, function, call_kind, inlining_kind); 8032 target, function, call_kind, inlining_kind);
8033 HEnvironment* inner_env = 8033 HEnvironment* inner_env =
8034 environment()->CopyForInlining(target, 8034 environment()->CopyForInlining(target,
8035 arguments_count, 8035 arguments_count,
8036 function, 8036 function,
8037 undefined, 8037 undefined,
8038 function_state()->inlining_kind(), 8038 function_state()->inlining_kind(),
8039 undefined_receiver); 8039 undefined_receiver);
8040 #ifdef V8_TARGET_ARCH_IA32 8040 #if V8_TARGET_ARCH_IA32
8041 // IA32 only, overwrite the caller's context in the deoptimization 8041 // IA32 only, overwrite the caller's context in the deoptimization
8042 // environment with the correct one. 8042 // environment with the correct one.
8043 // 8043 //
8044 // TODO(kmillikin): implement the same inlining on other platforms so we 8044 // TODO(kmillikin): implement the same inlining on other platforms so we
8045 // can remove the unsightly ifdefs in this function. 8045 // can remove the unsightly ifdefs in this function.
8046 HConstant* context = 8046 HConstant* context =
8047 new(zone()) HConstant(Handle<Context>(target->context())); 8047 new(zone()) HConstant(Handle<Context>(target->context()));
8048 AddInstruction(context); 8048 AddInstruction(context);
8049 inner_env->BindContext(context); 8049 inner_env->BindContext(context);
8050 #endif 8050 #endif
(...skipping 3503 matching lines...) Expand 10 before | Expand all | Expand 10 after
11554 if (ShouldProduceTraceOutput()) { 11554 if (ShouldProduceTraceOutput()) {
11555 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); 11555 isolate()->GetHTracer()->TraceHydrogen(name(), graph_);
11556 } 11556 }
11557 11557
11558 #ifdef DEBUG 11558 #ifdef DEBUG
11559 graph_->Verify(false); // No full verify. 11559 graph_->Verify(false); // No full verify.
11560 #endif 11560 #endif
11561 } 11561 }
11562 11562
11563 } } // namespace v8::internal 11563 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/heap.cc ('k') | src/hydrogen-instructions.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698