Welcome, Guest. Please login or register.

Author Topic: Threaded Code  (Read 6380 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline skurk

  • Hero Member
  • *****
  • Join Date: Dec 2006
  • Posts: 929
    • Show all replies
Re: Threaded Code
« on: November 24, 2010, 02:57:33 PM »
Yes, something like this should work

void (*app)() = (void(*))0x123456;

and then later

app();

I can't test this right now, but I'm pretty sure the above would jump to addres 0x123456.
Code 6502 asm or... DIE!!

[C64, C128, A500, A600, A1200, A3000, MBP+Mini, Efika/MOS2.1, Sam440 w/AOS4.1
 

Offline skurk

  • Hero Member
  • *****
  • Join Date: Dec 2006
  • Posts: 929
    • Show all replies
Re: Threaded Code
« Reply #1 on: November 24, 2010, 03:08:04 PM »
Quote from: bloodline;594074
No, that's a function pointer which will invoke the calling convention (saving registers etc) which would add a lot of overhead a threaded code Virtual Machine...


Oh, then I misunderstood your question. :-)
Code 6502 asm or... DIE!!

[C64, C128, A500, A600, A1200, A3000, MBP+Mini, Efika/MOS2.1, Sam440 w/AOS4.1