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

Unified Diff: src/mips64/simulator-mips64.cc

Issue 1545013002: Add assembler test. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: rebased Created 4 years, 11 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/mips64/simulator-mips64.h ('k') | test/cctest/test-assembler-mips.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/mips64/simulator-mips64.cc
diff --git a/src/mips64/simulator-mips64.cc b/src/mips64/simulator-mips64.cc
index 42b9ee0ed301945433dcd52b5ed8c6b61041ad7b..f9b6dd856ae9bb7c961725c04758c56fdf65326b 100644
--- a/src/mips64/simulator-mips64.cc
+++ b/src/mips64/simulator-mips64.cc
@@ -3494,6 +3494,20 @@ void Simulator::DecodeTypeRegisterSPECIAL() {
case DSRAV:
SetResult(rd_reg(), rt() >> rs());
break;
+ case LSA: {
+ DCHECK(kArchVariant == kMips64r6);
+ int8_t sa = lsa_sa() + 1;
+ int32_t _rt = static_cast<int32_t>(rt());
+ int32_t _rs = static_cast<int32_t>(rs());
+ int32_t res = _rs << sa;
+ res += _rt;
+ SetResult(rd_reg(), static_cast<int64_t>(res));
+ break;
+ }
+ case DLSA:
+ DCHECK(kArchVariant == kMips64r6);
+ SetResult(rd_reg(), (rs() << (lsa_sa() + 1)) + rt());
+ break;
case MFHI: // MFHI == CLZ on R6.
if (kArchVariant != kMips64r6) {
DCHECK(sa() == 0);
« no previous file with comments | « src/mips64/simulator-mips64.h ('k') | test/cctest/test-assembler-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698