};
#define GENERIC_OPTIMIZATION(name, bit) \
- public: \
- void Set##name() { SetBit(k##name); } \
- bool Get##name() const { return IsBitSet(k##name); } \
- private: \
- static constexpr int k##name = bit
+public: \
+void Set##name() { SetBit(k##name); } \
+bool Get##name() const { return IsBitSet(k##name); } \
+private: \
+static constexpr int k##name = bit
class IntrinsicOptimizations : public ValueObject {
public:
- IntrinsicOptimizations(HInvoke* invoke) : value_(invoke->GetIntrinsicOptimizations()) {}
- IntrinsicOptimizations(const HInvoke& invoke) : value_(invoke.GetIntrinsicOptimizations()) {}
+ explicit IntrinsicOptimizations(HInvoke* invoke) : value_(invoke->GetIntrinsicOptimizations()) {}
+ explicit IntrinsicOptimizations(const HInvoke& invoke)
+ : value_(invoke.GetIntrinsicOptimizations()) {}
static constexpr int kNumberOfGenericOptimizations = 2;
GENERIC_OPTIMIZATION(DoesNotNeedDexCache, 0);
#undef GENERIC_OPTIMIZATION
#define INTRINSIC_OPTIMIZATION(name, bit) \
- public: \
- void Set##name() { SetBit(k##name); } \
- bool Get##name() const { return IsBitSet(k##name); } \
- private: \
- static constexpr int k##name = bit + kNumberOfGenericOptimizations
+public: \
+void Set##name() { SetBit(k##name); } \
+bool Get##name() const { return IsBitSet(k##name); } \
+private: \
+static constexpr int k##name = bit + kNumberOfGenericOptimizations
class StringEqualsOptimizations : public IntrinsicOptimizations {
public:
- StringEqualsOptimizations(HInvoke* invoke) : IntrinsicOptimizations(invoke) {}
+ explicit StringEqualsOptimizations(HInvoke* invoke) : IntrinsicOptimizations(invoke) {}
INTRINSIC_OPTIMIZATION(ArgumentNotNull, 0);
INTRINSIC_OPTIMIZATION(ArgumentIsString, 1);