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

Side by Side Diff: src/mips/lithium-codegen-mips.cc

Issue 1092353002: [strong] Disallow implicit conversions for binary arithmetic operations (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: cl feedback 5 Created 5 years, 8 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
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved.7 1 // Copyright 2012 the V8 project authors. All rights reserved.7
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 2041 matching lines...) Expand 10 before | Expand all | Expand 10 after
2052 } 2052 }
2053 } 2053 }
2054 2054
2055 2055
2056 void LCodeGen::DoArithmeticT(LArithmeticT* instr) { 2056 void LCodeGen::DoArithmeticT(LArithmeticT* instr) {
2057 DCHECK(ToRegister(instr->context()).is(cp)); 2057 DCHECK(ToRegister(instr->context()).is(cp));
2058 DCHECK(ToRegister(instr->left()).is(a1)); 2058 DCHECK(ToRegister(instr->left()).is(a1));
2059 DCHECK(ToRegister(instr->right()).is(a0)); 2059 DCHECK(ToRegister(instr->right()).is(a0));
2060 DCHECK(ToRegister(instr->result()).is(v0)); 2060 DCHECK(ToRegister(instr->result()).is(v0));
2061 2061
2062 Handle<Code> code = CodeFactory::BinaryOpIC(isolate(), instr->op()).code(); 2062 Handle<Code> code = CodeFactory::BinaryOpIC(
2063 isolate(), instr->op(), language_mode()).code();
2063 CallCode(code, RelocInfo::CODE_TARGET, instr); 2064 CallCode(code, RelocInfo::CODE_TARGET, instr);
2064 // Other arch use a nop here, to signal that there is no inlined 2065 // Other arch use a nop here, to signal that there is no inlined
2065 // patchable code. Mips does not need the nop, since our marker 2066 // patchable code. Mips does not need the nop, since our marker
2066 // instruction (andi zero_reg) will never be used in normal code. 2067 // instruction (andi zero_reg) will never be used in normal code.
2067 } 2068 }
2068 2069
2069 2070
2070 template<class InstrType> 2071 template<class InstrType>
2071 void LCodeGen::EmitBranch(InstrType instr, 2072 void LCodeGen::EmitBranch(InstrType instr,
2072 Condition condition, 2073 Condition condition,
(...skipping 3891 matching lines...) Expand 10 before | Expand all | Expand 10 after
5964 __ li(at, scope_info); 5965 __ li(at, scope_info);
5965 __ Push(at, ToRegister(instr->function())); 5966 __ Push(at, ToRegister(instr->function()));
5966 CallRuntime(Runtime::kPushBlockContext, 2, instr); 5967 CallRuntime(Runtime::kPushBlockContext, 2, instr);
5967 RecordSafepoint(Safepoint::kNoLazyDeopt); 5968 RecordSafepoint(Safepoint::kNoLazyDeopt);
5968 } 5969 }
5969 5970
5970 5971
5971 #undef __ 5972 #undef __
5972 5973
5973 } } // namespace v8::internal 5974 } } // namespace v8::internal
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698