Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Code Insight: Rubinius 2.0 and Nikita

brixen
June 07, 2012

Code Insight: Rubinius 2.0 and Nikita

Presented at Euruko12 discussing features of the Rubinius 2.0 virtual machine and Nikita application.

brixen

June 07, 2012
Tweet

More Decks by brixen

Other Decks in Technology

Transcript

  1. class Array : public Object { private: Fixnum* total_; //

    slot Tuple* tuple_; // slot public: attr_accessor(total, Fixnum); attr_accessor(tuple, Tuple); }
  2. instruction send_method(literal) [ receiver -- value ] => send flush_ip();

    Object* recv = stack_top(); InlineCache* cache = reinterpret_cast<InlineCache*>(literal); SET_ALLOW_PRIVATE(false); Arguments args(cache->name, recv, Qnil, 0, 0); Object* ret = cache->execute(state, call_frame, args); (void)stack_pop(); CHECK_AND_PUSH(ret); end
  3. class OneArgument { public: static bool call(STATE, VMMethod* vmm, StackVariables*

    scope, Arguments& args) { if(args.total() != 1) return false; scope->set_local(0, args.get_argument(0)); return true; } };
  4. in-sight noun the capacity to gain an accurate and deep

    intuitive understanding of a person or thing