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

Side by Side Diff: src/ia32/lithium-ia32.cc

Issue 6982023: Don't emit code for HContext values with no uses. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 7 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/arm/lithium-arm.cc ('k') | src/x64/lithium-x64.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 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 1183 matching lines...) Expand 10 before | Expand all | Expand 10 after
1194 1194
1195 1195
1196 LInstruction* LChunkBuilder::DoPushArgument(HPushArgument* instr) { 1196 LInstruction* LChunkBuilder::DoPushArgument(HPushArgument* instr) {
1197 ++argument_count_; 1197 ++argument_count_;
1198 LOperand* argument = UseAny(instr->argument()); 1198 LOperand* argument = UseAny(instr->argument());
1199 return new LPushArgument(argument); 1199 return new LPushArgument(argument);
1200 } 1200 }
1201 1201
1202 1202
1203 LInstruction* LChunkBuilder::DoContext(HContext* instr) { 1203 LInstruction* LChunkBuilder::DoContext(HContext* instr) {
1204 return DefineAsRegister(new LContext); 1204 return instr->HasNoUses() ? NULL : DefineAsRegister(new LContext);
1205 } 1205 }
1206 1206
1207 1207
1208 LInstruction* LChunkBuilder::DoOuterContext(HOuterContext* instr) { 1208 LInstruction* LChunkBuilder::DoOuterContext(HOuterContext* instr) {
1209 LOperand* context = UseRegisterAtStart(instr->value()); 1209 LOperand* context = UseRegisterAtStart(instr->value());
1210 return DefineAsRegister(new LOuterContext(context)); 1210 return DefineAsRegister(new LOuterContext(context));
1211 } 1211 }
1212 1212
1213 1213
1214 LInstruction* LChunkBuilder::DoGlobalObject(HGlobalObject* instr) { 1214 LInstruction* LChunkBuilder::DoGlobalObject(HGlobalObject* instr) {
(...skipping 996 matching lines...) Expand 10 before | Expand all | Expand 10 after
2211 LOperand* key = UseOrConstantAtStart(instr->key()); 2211 LOperand* key = UseOrConstantAtStart(instr->key());
2212 LOperand* object = UseOrConstantAtStart(instr->object()); 2212 LOperand* object = UseOrConstantAtStart(instr->object());
2213 LIn* result = new LIn(key, object); 2213 LIn* result = new LIn(key, object);
2214 return MarkAsCall(DefineFixed(result, eax), instr); 2214 return MarkAsCall(DefineFixed(result, eax), instr);
2215 } 2215 }
2216 2216
2217 2217
2218 } } // namespace v8::internal 2218 } } // namespace v8::internal
2219 2219
2220 #endif // V8_TARGET_ARCH_IA32 2220 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/arm/lithium-arm.cc ('k') | src/x64/lithium-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698