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

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

Issue 9467001: Fix a performance bug in the register contraints for polymorphic loads. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 8 years, 10 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 | « no previous file | no next file » | 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 1917 matching lines...) Expand 10 before | Expand all | Expand 10 after
1928 LInstruction* LChunkBuilder::DoLoadNamedField(HLoadNamedField* instr) { 1928 LInstruction* LChunkBuilder::DoLoadNamedField(HLoadNamedField* instr) {
1929 ASSERT(instr->representation().IsTagged()); 1929 ASSERT(instr->representation().IsTagged());
1930 LOperand* obj = UseRegisterAtStart(instr->object()); 1930 LOperand* obj = UseRegisterAtStart(instr->object());
1931 return DefineAsRegister(new(zone()) LLoadNamedField(obj)); 1931 return DefineAsRegister(new(zone()) LLoadNamedField(obj));
1932 } 1932 }
1933 1933
1934 1934
1935 LInstruction* LChunkBuilder::DoLoadNamedFieldPolymorphic( 1935 LInstruction* LChunkBuilder::DoLoadNamedFieldPolymorphic(
1936 HLoadNamedFieldPolymorphic* instr) { 1936 HLoadNamedFieldPolymorphic* instr) {
1937 ASSERT(instr->representation().IsTagged()); 1937 ASSERT(instr->representation().IsTagged());
1938 LOperand* context = UseFixed(instr->context(), esi);
1939 if (instr->need_generic()) { 1938 if (instr->need_generic()) {
1939 LOperand* context = UseFixed(instr->context(), esi);
1940 LOperand* obj = UseFixed(instr->object(), eax); 1940 LOperand* obj = UseFixed(instr->object(), eax);
1941 LLoadNamedFieldPolymorphic* result = 1941 LLoadNamedFieldPolymorphic* result =
1942 new(zone()) LLoadNamedFieldPolymorphic(context, obj); 1942 new(zone()) LLoadNamedFieldPolymorphic(context, obj);
1943 return MarkAsCall(DefineFixed(result, eax), instr); 1943 return MarkAsCall(DefineFixed(result, eax), instr);
1944 } else { 1944 } else {
1945 LOperand* context = UseAny(instr->context()); // Not actually used.
1945 LOperand* obj = UseRegisterAtStart(instr->object()); 1946 LOperand* obj = UseRegisterAtStart(instr->object());
1946 LLoadNamedFieldPolymorphic* result = 1947 LLoadNamedFieldPolymorphic* result =
1947 new(zone()) LLoadNamedFieldPolymorphic(context, obj); 1948 new(zone()) LLoadNamedFieldPolymorphic(context, obj);
1948 return AssignEnvironment(DefineAsRegister(result)); 1949 return AssignEnvironment(DefineAsRegister(result));
1949 } 1950 }
1950 } 1951 }
1951 1952
1952 1953
1953 LInstruction* LChunkBuilder::DoLoadNamedGeneric(HLoadNamedGeneric* instr) { 1954 LInstruction* LChunkBuilder::DoLoadNamedGeneric(HLoadNamedGeneric* instr) {
1954 LOperand* context = UseFixed(instr->context(), esi); 1955 LOperand* context = UseFixed(instr->context(), esi);
(...skipping 478 matching lines...) Expand 10 before | Expand all | Expand 10 after
2433 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { 2434 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) {
2434 LOperand* object = UseRegister(instr->object()); 2435 LOperand* object = UseRegister(instr->object());
2435 LOperand* index = UseTempRegister(instr->index()); 2436 LOperand* index = UseTempRegister(instr->index());
2436 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index)); 2437 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index));
2437 } 2438 }
2438 2439
2439 2440
2440 } } // namespace v8::internal 2441 } } // namespace v8::internal
2441 2442
2442 #endif // V8_TARGET_ARCH_IA32 2443 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698