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

Unified Diff: src/compiler/machine-operator.h

Issue 2785773002: [turbofan] introduce Int32/64AbsWithOverflow optional operator (Closed)
Patch Set: add base impl Created 3 years, 9 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/compiler/instruction-selector.cc ('k') | src/compiler/machine-operator.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/machine-operator.h
diff --git a/src/compiler/machine-operator.h b/src/compiler/machine-operator.h
index 2ae591aa4341dcd2d11fab1534f398e869920bbc..08f1bf5faaa95e360e4e28a4f017e5b626087438 100644
--- a/src/compiler/machine-operator.h
+++ b/src/compiler/machine-operator.h
@@ -131,13 +131,15 @@ class V8_EXPORT_PRIVATE MachineOperatorBuilder final
kWord64ReverseBits = 1u << 17,
kWord32ReverseBytes = 1u << 18,
kWord64ReverseBytes = 1u << 19,
- kAllOptionalOps = kFloat32RoundDown | kFloat64RoundDown | kFloat32RoundUp |
- kFloat64RoundUp | kFloat32RoundTruncate |
- kFloat64RoundTruncate | kFloat64RoundTiesAway |
- kFloat32RoundTiesEven | kFloat64RoundTiesEven |
- kWord32Ctz | kWord64Ctz | kWord32Popcnt | kWord64Popcnt |
- kWord32ReverseBits | kWord64ReverseBits |
- kWord32ReverseBytes | kWord64ReverseBytes
+ kInt32AbsWithOverflow = 1u << 20,
+ kInt64AbsWithOverflow = 1u << 21,
+ kAllOptionalOps =
+ kFloat32RoundDown | kFloat64RoundDown | kFloat32RoundUp |
+ kFloat64RoundUp | kFloat32RoundTruncate | kFloat64RoundTruncate |
+ kFloat64RoundTiesAway | kFloat32RoundTiesEven | kFloat64RoundTiesEven |
+ kWord32Ctz | kWord64Ctz | kWord32Popcnt | kWord64Popcnt |
+ kWord32ReverseBits | kWord64ReverseBits | kWord32ReverseBytes |
+ kWord64ReverseBytes | kInt32AbsWithOverflow | kInt64AbsWithOverflow
};
typedef base::Flags<Flag, unsigned> Flags;
@@ -230,6 +232,8 @@ class V8_EXPORT_PRIVATE MachineOperatorBuilder final
const OptionalOperator Word64ReverseBits();
const OptionalOperator Word32ReverseBytes();
const OptionalOperator Word64ReverseBytes();
+ const OptionalOperator Int32AbsWithOverflow();
+ const OptionalOperator Int64AbsWithOverflow();
bool Word32ShiftIsSafe() const { return flags_ & kWord32ShiftIsSafe; }
const Operator* Word64And();
« no previous file with comments | « src/compiler/instruction-selector.cc ('k') | src/compiler/machine-operator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698