Reorder mrb_vtype

This allows the compiler to optimise the case in obj_iv_p into a range check. There does not seem to be any other very hot uses of this index and it grants a pretty big gain on optcarrot.
This commit is contained in:
Aurora Nockert
2024-06-27 22:45:28 +02:00
parent a0d4c63f9a
commit 27f972b048
+4 -4
View File
@@ -143,16 +143,16 @@ static const unsigned int IEEE754_INFINITY_BITS_SINGLE = 0x7F800000;
f(MRB_TT_OBJECT, struct RObject, "Object") \
f(MRB_TT_CLASS, struct RClass, "Class") \
f(MRB_TT_MODULE, struct RClass, "Module") \
f(MRB_TT_ICLASS, struct RClass, "iClass") \
f(MRB_TT_SCLASS, struct RClass, "SClass") \
f(MRB_TT_HASH, struct RHash, "Hash") \
f(MRB_TT_CDATA, struct RData, "C data") \
f(MRB_TT_EXCEPTION, struct RException, "Exception") \
f(MRB_TT_ICLASS, struct RClass, "iClass") \
f(MRB_TT_PROC, struct RProc, "Proc") \
f(MRB_TT_ARRAY, struct RArray, "Array") \
f(MRB_TT_HASH, struct RHash, "Hash") \
f(MRB_TT_STRING, struct RString, "String") \
f(MRB_TT_RANGE, struct RRange, "Range") \
f(MRB_TT_EXCEPTION, struct RException, "Exception") \
f(MRB_TT_ENV, struct REnv, "env") \
f(MRB_TT_CDATA, struct RData, "C data") \
f(MRB_TT_FIBER, struct RFiber, "Fiber") \
f(MRB_TT_STRUCT, struct RArray, "Struct") \
f(MRB_TT_ISTRUCT, struct RIStruct, "istruct") \