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

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

Issue 23684056: NumberUntagD is faster when untagging in a temp register (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 3 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/ia32/lithium-codegen-ia32.cc ('k') | 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 1915 matching lines...) Expand 10 before | Expand all | Expand 10 after
1926 from = Representation::Tagged(); 1926 from = Representation::Tagged();
1927 } 1927 }
1928 // Only mark conversions that might need to allocate as calling rather than 1928 // Only mark conversions that might need to allocate as calling rather than
1929 // all changes. This makes simple, non-allocating conversion not have to force 1929 // all changes. This makes simple, non-allocating conversion not have to force
1930 // building a stack frame. 1930 // building a stack frame.
1931 if (from.IsTagged()) { 1931 if (from.IsTagged()) {
1932 if (to.IsDouble()) { 1932 if (to.IsDouble()) {
1933 info()->MarkAsDeferredCalling(); 1933 info()->MarkAsDeferredCalling();
1934 LOperand* value = UseRegister(instr->value()); 1934 LOperand* value = UseRegister(instr->value());
1935 // Temp register only necessary for minus zero check. 1935 // Temp register only necessary for minus zero check.
1936 LOperand* temp = instr->deoptimize_on_minus_zero() 1936 LOperand* temp = TempRegister();
ulan 2013/09/12 08:35:04 Doesn't this increase register pressure?
1937 ? TempRegister()
1938 : NULL;
1939 LNumberUntagD* res = new(zone()) LNumberUntagD(value, temp); 1937 LNumberUntagD* res = new(zone()) LNumberUntagD(value, temp);
1940 return AssignEnvironment(DefineAsRegister(res)); 1938 return AssignEnvironment(DefineAsRegister(res));
1941 } else if (to.IsSmi()) { 1939 } else if (to.IsSmi()) {
1942 HValue* val = instr->value(); 1940 HValue* val = instr->value();
1943 LOperand* value = UseRegister(val); 1941 LOperand* value = UseRegister(val);
1944 if (val->type().IsSmi()) { 1942 if (val->type().IsSmi()) {
1945 return DefineSameAsFirst(new(zone()) LDummyUse(value)); 1943 return DefineSameAsFirst(new(zone()) LDummyUse(value));
1946 } 1944 }
1947 return AssignEnvironment(DefineSameAsFirst(new(zone()) LCheckSmi(value))); 1945 return AssignEnvironment(DefineSameAsFirst(new(zone()) LCheckSmi(value)));
1948 } else { 1946 } else {
(...skipping 785 matching lines...) Expand 10 before | Expand all | Expand 10 after
2734 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { 2732 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) {
2735 LOperand* object = UseRegister(instr->object()); 2733 LOperand* object = UseRegister(instr->object());
2736 LOperand* index = UseTempRegister(instr->index()); 2734 LOperand* index = UseTempRegister(instr->index());
2737 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index)); 2735 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index));
2738 } 2736 }
2739 2737
2740 2738
2741 } } // namespace v8::internal 2739 } } // namespace v8::internal
2742 2740
2743 #endif // V8_TARGET_ARCH_IA32 2741 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/ia32/lithium-codegen-ia32.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698