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

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

Issue 23437028: Revert "Fix phis for non-sse2 double values" (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-ia32.h ('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 936 matching lines...) Expand 10 before | Expand all | Expand 10 after
947 } 947 }
948 #endif 948 #endif
949 949
950 instr->set_position(position_); 950 instr->set_position(position_);
951 if (FLAG_stress_pointer_maps && !instr->HasPointerMap()) { 951 if (FLAG_stress_pointer_maps && !instr->HasPointerMap()) {
952 instr = AssignPointerMap(instr); 952 instr = AssignPointerMap(instr);
953 } 953 }
954 if (FLAG_stress_environments && !instr->HasEnvironment()) { 954 if (FLAG_stress_environments && !instr->HasEnvironment()) {
955 instr = AssignEnvironment(instr); 955 instr = AssignEnvironment(instr);
956 } 956 }
957 if (!CpuFeatures::IsSafeForSnapshot(SSE2) && instr->IsGoto() &&
958 LGoto::cast(instr)->jumps_to_join()) {
959 // TODO(olivf) Since phis of spilled values are joined as registers
960 // (not in the stack slot), we need to allow the goto gaps to keep one
961 // x87 register alive. To ensure all other values are still spilled, we
962 // insert a fpu register barrier right before.
963 LClobberDoubles* clobber = new(zone()) LClobberDoubles();
964 clobber->set_hydrogen_value(current);
965 chunk_->AddInstruction(clobber, current_block_);
966 }
967 instr->set_hydrogen_value(current); 957 instr->set_hydrogen_value(current);
968 chunk_->AddInstruction(instr, current_block_); 958 chunk_->AddInstruction(instr, current_block_);
969 } 959 }
970 current_instruction_ = old_current; 960 current_instruction_ = old_current;
971 } 961 }
972 962
973 963
974 LEnvironment* LChunkBuilder::CreateEnvironment( 964 LEnvironment* LChunkBuilder::CreateEnvironment(
975 HEnvironment* hydrogen_env, 965 HEnvironment* hydrogen_env,
976 int* argument_index_accumulator, 966 int* argument_index_accumulator,
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
1049 1039
1050 if (hydrogen_env->frame_type() == JS_FUNCTION) { 1040 if (hydrogen_env->frame_type() == JS_FUNCTION) {
1051 *argument_index_accumulator = argument_index; 1041 *argument_index_accumulator = argument_index;
1052 } 1042 }
1053 1043
1054 return result; 1044 return result;
1055 } 1045 }
1056 1046
1057 1047
1058 LInstruction* LChunkBuilder::DoGoto(HGoto* instr) { 1048 LInstruction* LChunkBuilder::DoGoto(HGoto* instr) {
1059 return new(zone()) LGoto(instr->FirstSuccessor()); 1049 return new(zone()) LGoto(instr->FirstSuccessor()->block_id());
1060 } 1050 }
1061 1051
1062 1052
1063 LInstruction* LChunkBuilder::DoBranch(HBranch* instr) { 1053 LInstruction* LChunkBuilder::DoBranch(HBranch* instr) {
1064 HValue* value = instr->value(); 1054 HValue* value = instr->value();
1065 if (value->EmitAtUses()) { 1055 if (value->EmitAtUses()) {
1066 ASSERT(value->IsConstant()); 1056 ASSERT(value->IsConstant());
1067 ASSERT(!value->representation().IsDouble()); 1057 ASSERT(!value->representation().IsDouble());
1068 HBasicBlock* successor = HConstant::cast(value)->BooleanValue() 1058 HBasicBlock* successor = HConstant::cast(value)->BooleanValue()
1069 ? instr->FirstSuccessor() 1059 ? instr->FirstSuccessor()
1070 : instr->SecondSuccessor(); 1060 : instr->SecondSuccessor();
1071 return new(zone()) LGoto(successor); 1061 return new(zone()) LGoto(successor->block_id());
1072 } 1062 }
1073 1063
1074 ToBooleanStub::Types expected = instr->expected_input_types(); 1064 ToBooleanStub::Types expected = instr->expected_input_types();
1075 1065
1076 // Tagged values that are not known smis or booleans require a 1066 // Tagged values that are not known smis or booleans require a
1077 // deoptimization environment. If the instruction is generic no 1067 // deoptimization environment. If the instruction is generic no
1078 // environment is needed since all cases are handled. 1068 // environment is needed since all cases are handled.
1079 Representation rep = value->representation(); 1069 Representation rep = value->representation();
1080 HType type = value->type(); 1070 HType type = value->type();
1081 if (!rep.IsTagged() || type.IsSmi() || type.IsBoolean()) { 1071 if (!rep.IsTagged() || type.IsSmi() || type.IsBoolean()) {
(...skipping 1662 matching lines...) Expand 10 before | Expand all | Expand 10 after
2744 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { 2734 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) {
2745 LOperand* object = UseRegister(instr->object()); 2735 LOperand* object = UseRegister(instr->object());
2746 LOperand* index = UseTempRegister(instr->index()); 2736 LOperand* index = UseTempRegister(instr->index());
2747 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index)); 2737 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index));
2748 } 2738 }
2749 2739
2750 2740
2751 } } // namespace v8::internal 2741 } } // namespace v8::internal
2752 2742
2753 #endif // V8_TARGET_ARCH_IA32 2743 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/ia32/lithium-ia32.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698