Welcome, Guest. Please login or register.

Author Topic: WinUAE getting a 64bit JIT upgrade?  (Read 3646 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline Karlos

  • Sockologist
  • Global Moderator
  • Hero Member
  • *****
  • Join Date: Nov 2002
  • Posts: 16878
  • Country: gb
  • Thanked: 5 times
    • Show all replies
Re: WinUAE getting a 64bit JIT upgrade?
« on: April 25, 2010, 12:20:02 PM »
You guys want to be careful what you wish for.

Experimenting with GCC 4.2.4 64-bit, I found some very strange behaviour with code performance for my old virtual machine project.

The code compiled for 32-bit and -mtuned for P4 runs about 30% faster on my core2 than exactly the same code compiled for my core2 64-bit native and -mtuned for core2:

Code: [Select]

karlos@Megaburken-II:/extropia/exvm/bin$ ./exvm_x64
VM compiled 64-bit native
There are presently 239 core instructions defined

Beginning Virtual Program
-----------------------

Allocated buffer [512 x 512]
Wrote buffer 'framebuffer.pgm'
Freed buffer
Executed 319360443 statements
Time taken :3306.496ms

-----------------------

VMCore dump

rX:  64-bit (hex dump) :          s32 :    s16 :   s8 : c
 1: 0x0000000000000000 :            0 :      0 :    0 : . : 0.00000000
 2: 0x0000000000000200 :          512 :    512 :    0 : . : 0.00000000
 3: 0x0000000000000200 :          512 :    512 :    0 : . : 0.00000000
 4: 0x000000003FA00000 :   1067450368 :      0 :    0 : . : 1.25000000
 5: 0x0000000000000200 :          512 :    512 :    0 : . : 0.00000000
 6: 0x00000000BFE00000 :   3219128320 :      0 :    0 : . : -1.75000000
 7: 0x000000003F400000 :   1061158912 :      0 :    0 : . : 0.75000000
 8: 0x000000003BA00000 :   1000341504 :      0 :    0 : . : 0.00488281
 9: 0x0000000000000200 :          512 :    512 :    0 : . : 0.00000000
10: 0x00000000000000FF :          255 :    255 :   -1 : . : 0.00000000
11: 0x00000000C10CE6A7 :   3238848167 :  -6489 :  -89 : . : -8.80631161
12: 0x00000000BE9C4320 :   3197911840 :  17184 :   32 : . : -0.30519962
13: 0x0000000000000004 :            4 :      4 :    4 : . : 0.00000000
14: 0x00000000411AD2A7 :   1092276903 : -11609 :  -89 : . : 9.67642879
15: 0x00000000BE9C4320 :   3197911840 :  17184 :   32 : . : -0.30519962
16: 0x0000000000404868 :      4212840 :  18536 :  104 : h : 0.00000000
PC: 0x605af2
RS: 0x606010 (0)
DS: 0x608020 (0)
CS: 0x609030 (0)
ST: 0x00000002 (Completed)

Code: [Select]

karlos@Megaburken-II:/extropia/exvm/bin$ ./exvm_x86
VM compiled 32-bit native
There are presently 239 core instructions defined

Beginning Virtual Program
-----------------------

Allocated buffer [512 x 512]
Wrote buffer 'framebuffer.pgm'
Freed buffer
Executed 319360443 statements
Time taken :2191.308ms

-----------------------

VMCore dump

rX:  64-bit (hex dump) :          s32 :    s16 :   s8 : c
 1: 0x0000000000000000 :            0 :      0 :    0 : . : 0.00000000
 2: 0x0000000000000200 :          512 :    512 :    0 : . : 0.00000000
 3: 0x0000000000000200 :          512 :    512 :    0 : . : 0.00000000
 4: 0x000000003FA00000 :   1067450368 :      0 :    0 : . : 1.25000000
 5: 0x0000000000000200 :          512 :    512 :    0 : . : 0.00000000
 6: 0x00000000BFE00000 :  -1075838976 :      0 :    0 : . : -1.75000000
 7: 0x000000003F400000 :   1061158912 :      0 :    0 : . : 0.75000000
 8: 0x000000003BA00000 :   1000341504 :      0 :    0 : . : 0.00488281
 9: 0x0000000000000200 :          512 :    512 :    0 : . : 0.00000000
10: 0x00000000000000FF :          255 :    255 :   -1 : . : 0.00000000
11: 0x00000000C10CE6A7 :  -1056119129 :  -6489 :  -89 : . : -8.80631161
12: 0x00000000BE9C4320 :  -1097055456 :  17184 :   32 : . : -0.30519962
13: 0x0000000000000004 :            4 :      4 :    4 : . : 0.00000000
14: 0x00000000411AD2A7 :   1092276903 : -11609 :  -89 : . : 9.67642879
15: 0x00000000BE9C4320 :  -1097055456 :  17184 :   32 : . : -0.30519962
16: 0x000000000804C81C :    134531100 : -14308 :   28 : . : 0.00000000
PC: 0x0804E3B2
RS: 0x0804F008 (0)
DS: 0x08051010 (0)
CS: 0x08052018 (0)
ST: 0x00000002 (Completed)





This trend was not observed with AMD Athlon 64.
int p; // A