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

Unified Diff: src/mips/macro-assembler-mips.cc

Issue 2225323002: MIPS: Implement Bovc and Bnvc instruction macros. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix typo Created 4 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/mips/macro-assembler-mips.h ('k') | src/mips64/macro-assembler-mips64.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/mips/macro-assembler-mips.cc
diff --git a/src/mips/macro-assembler-mips.cc b/src/mips/macro-assembler-mips.cc
index d1e60bd7f468dc1ab0844c472615e55b2126eaf8..9230f06eaf9673a1d33162ec0d12b6e2ed74b8be 100644
--- a/src/mips/macro-assembler-mips.cc
+++ b/src/mips/macro-assembler-mips.cc
@@ -1186,6 +1186,27 @@ void MacroAssembler::Lsa(Register rd, Register rt, Register rs, uint8_t sa,
}
}
+void MacroAssembler::Bovc(Register rs, Register rt, Label* L) {
+ if (is_trampoline_emitted()) {
+ Label skip;
+ bnvc(rs, rt, &skip);
+ BranchLong(L, PROTECT);
+ bind(&skip);
+ } else {
+ bovc(rs, rt, L);
+ }
+}
+
+void MacroAssembler::Bnvc(Register rs, Register rt, Label* L) {
+ if (is_trampoline_emitted()) {
+ Label skip;
+ bovc(rs, rt, &skip);
+ BranchLong(L, PROTECT);
+ bind(&skip);
+ } else {
+ bnvc(rs, rt, L);
+ }
+}
// ------------Pseudo-instructions-------------
@@ -3337,7 +3358,6 @@ bool MacroAssembler::BranchShortCheck(int32_t offset, Label* L, Condition cond,
Register rs, const Operand& rt,
BranchDelaySlot bdslot) {
BRANCH_ARGS_CHECK(cond, rs, rt);
-
if (!L) {
if (IsMipsArchVariant(kMips32r6) && bdslot == PROTECT) {
DCHECK(is_int26(offset));
@@ -5394,9 +5414,9 @@ void MacroAssembler::AddBranchOvf(Register dst, Register left, Register right,
Move(left_reg, left);
Move(right_reg, right);
addu(dst, left, right);
- bnvc(left_reg, right_reg, no_overflow_label);
+ Bnvc(left_reg, right_reg, no_overflow_label);
} else {
- bovc(left, right, overflow_label);
+ Bovc(left, right, overflow_label);
addu(dst, left, right);
if (no_overflow_label) bc(no_overflow_label);
}
« no previous file with comments | « src/mips/macro-assembler-mips.h ('k') | src/mips64/macro-assembler-mips64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698