Chromium Code Reviews| Index: runtime/vm/object.cc |
| =================================================================== |
| --- runtime/vm/object.cc (revision 13897) |
| +++ runtime/vm/object.cc (working copy) |
| @@ -3361,10 +3361,21 @@ |
| set_kind_tag(AbstractBit::update(value, raw_ptr()->kind_tag_)); |
| } |
| + |
| void Function::set_is_inlinable(bool value) const { |
| set_kind_tag(InlinableBit::update(value, raw_ptr()->kind_tag_)); |
| } |
| + |
| +bool Function::IsInlineable() const { |
| + // '==' call is handled specially. |
| + const String& equality_name = String::Handle(Symbols::New("==")); |
|
hausner
2012/10/22 20:00:29
I expect this will be called quite often. It might
srdjan
2012/10/22 20:30:51
Symbols::New does not create new symbol each time,
|
| + return InlinableBit::decode(raw_ptr()->kind_tag_) && |
| + HasCode() && |
| + name() != equality_name.raw(); |
| +} |
| + |
| + |
| intptr_t Function::NumParameters() const { |
| return num_fixed_parameters() + NumOptionalParameters(); |
| } |