From e53986d203384c4b863210425c98472c01cc61a0 Mon Sep 17 00:00:00 2001 From: "plind44@gmail.com" Date: Sat, 30 Mar 2013 15:54:12 +0000 Subject: [PATCH] MIPS: Make the mips port build cleanly with clang. Port r13583 (b39b116b) and also fix a couple mips-specific warnings. BUG= Review URL: https://codereview.chromium.org/13321002 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14100 ce2b1a6d-e550-0410-aec6-3dcde31c8c00 --- src/mips/lithium-mips.h | 1 - src/mips/macro-assembler-mips.cc | 5 ++--- src/mips/macro-assembler-mips.h | 1 - src/mips/simulator-mips.cc | 2 +- 4 files changed, 3 insertions(+), 6 deletions(-) diff --git a/src/mips/lithium-mips.h b/src/mips/lithium-mips.h index 80635c3896..004e364ceb 100644 --- a/src/mips/lithium-mips.h +++ b/src/mips/lithium-mips.h @@ -291,7 +291,6 @@ class LInstruction: public ZoneObject { SetOncePointer pointer_map_; HValue* hydrogen_value_; bool is_call_; - bool is_save_doubles_; }; diff --git a/src/mips/macro-assembler-mips.cc b/src/mips/macro-assembler-mips.cc index 271c6d8cd5..12e1025045 100644 --- a/src/mips/macro-assembler-mips.cc +++ b/src/mips/macro-assembler-mips.cc @@ -1928,7 +1928,7 @@ void MacroAssembler::BranchShort(Label* L, Condition cond, Register rs, BranchDelaySlot bdslot) { BRANCH_ARGS_CHECK(cond, rs, rt); - int32_t offset; + int32_t offset = 0; Register r2 = no_reg; Register scratch = at; if (rt.is_reg()) { @@ -2361,7 +2361,7 @@ void MacroAssembler::BranchAndLinkShort(Label* L, Condition cond, Register rs, BranchDelaySlot bdslot) { BRANCH_ARGS_CHECK(cond, rs, rt); - int32_t offset; + int32_t offset = 0; Register r2 = no_reg; Register scratch = at; if (rt.is_reg()) { @@ -5514,7 +5514,6 @@ bool AreAliased(Register r1, Register r2, Register r3, Register r4) { CodePatcher::CodePatcher(byte* address, int instructions) : address_(address), - instructions_(instructions), size_(instructions * Assembler::kInstrSize), masm_(NULL, address, size_ + Assembler::kGap) { // Create a new macro assembler pointing to the address of the code to patch. diff --git a/src/mips/macro-assembler-mips.h b/src/mips/macro-assembler-mips.h index 4198f8ba16..125cc8aaf3 100644 --- a/src/mips/macro-assembler-mips.h +++ b/src/mips/macro-assembler-mips.h @@ -1565,7 +1565,6 @@ class CodePatcher { private: byte* address_; // The address of the code being patched. - int instructions_; // Number of instructions of the expected patch size. int size_; // Number of bytes of the expected patch size. MacroAssembler masm_; // Macro assembler used to generate the code. }; diff --git a/src/mips/simulator-mips.cc b/src/mips/simulator-mips.cc index be9f369d01..7f35fb37a0 100644 --- a/src/mips/simulator-mips.cc +++ b/src/mips/simulator-mips.cc @@ -513,7 +513,7 @@ void MipsDebugger::Debug() { int32_t words; if (argc == next_arg) { words = 10; - } else if (argc == next_arg + 1) { + } else { if (!GetValue(argv[next_arg], &words)) { words = 10; }