On Mon, Oct 08, 2001 at 06:36:32PM -0400, Dan Sugalski wrote:
> P1->vtable_funcs[VTABLE_ADD + P2->num_type](P1, P2, P0);
Uhm, since num_type and vtable_funcs are part of the vtable
structure, that would be more like
P1->vtable->vtable_funcs[VTABLE_ADD + P2->vtable->num_type](P1, P2, P0);
After preprocessing, this looks like the wonderful:
interpreter->pmc_reg->registers[cur_opcode[2]]->vtable->vtable_funcs[VTABLE_ADD +
interpreter->pmc_reg->registers[cur_opcode[3]]->vtable->num_type](interpreter->pmc_reg->registers[cur_opcode[2]],interpreter->pmc_reg->registers[cur_opcode[3]],interpreter->pmc_reg->registers[cur_opcode[1]]);
That's quite a shitload of dereferences in order to call a function
(call a function, mark you, not actually do anything!) to add two
things together.
--
In related wibbling, I can see an opening for the four lusers of the
Apocalypse... "I didn't change anything", "My e-mail doesn't work",
"I can't print" and "Is the network broken?".
- Paul Mc Auley