X-Git-Url: https://git.webkit.org/?p=WebKit-https.git;a=blobdiff_plain;f=Source%2FJavaScriptCore%2Fbytecode%2FPredictedType.h;h=5835fdb746cefda7cfc3ad4ef69377c39096597c;hp=94da64edac93908805369549c5911a1b3ec5e1db;hb=510a5e81320b319685696ba0907ee52e41939d07;hpb=f2ca230be1b1a28bb0aeecad0669bdf782ebf786;ds=sidebyside diff --git a/Source/JavaScriptCore/bytecode/PredictedType.h b/Source/JavaScriptCore/bytecode/PredictedType.h index 94da64edac93..5835fdb746ce 100644 --- a/Source/JavaScriptCore/bytecode/PredictedType.h +++ b/Source/JavaScriptCore/bytecode/PredictedType.h @@ -151,6 +151,28 @@ inline bool isFloat64ArrayPrediction(PredictedType value) return value == PredictFloat64Array; } +inline bool isActionableMutableArrayPrediction(PredictedType value) +{ + return isArrayPrediction(value) + || isByteArrayPrediction(value) + || isInt8ArrayPrediction(value) + || isInt16ArrayPrediction(value) + || isInt32ArrayPrediction(value) + || isUint8ArrayPrediction(value) + || isUint16ArrayPrediction(value) + || isUint32ArrayPrediction(value) +#if CPU(X86) || CPU(X86_64) + || isFloat32ArrayPrediction(value) +#endif + || isFloat64ArrayPrediction(value); +} + +inline bool isActionableArrayPrediction(PredictedType value) +{ + return isStringPrediction(value) + || isActionableMutableArrayPrediction(value); +} + inline bool isArrayOrOtherPrediction(PredictedType value) { return !!(value & (PredictArray | PredictOther)) && !(value & ~(PredictArray | PredictOther));