http://robsite.de/php/pureboard-archiv/ ... a17bb2c7f0
Wollte das nur nochmals zeigen und meinen Beitrag dazu leisten:
Ich habe einige der Punkte nochmals getesten und feststellen müssen, dass da so ziemlich nichts implementiert wurde ("Nice one. I will implement them soon .")
Ich habe hier selbst einige aufgeführt, die ich noch gefunden habe:
Code: Alles auswählen
1) PB erkennt zwar x * 1, aber nicht x = x * 1:
x = x * 1
wird zu:
MOV ebx,dword [v_x]
MOV dword [v_x],ebx
2) etwa gleich wie 1)
; x = x
PUSH dword [v_x]
POP dword [v_x]
3) x + 1 wird zu INC v_x, aber x - 1 nicht zu DEC v_x:
; x + 1
INC dword [v_x]
; x - 1
MOV ebx,dword [v_x]
ADD ebx,-1
MOV dword [v_x],ebx
Ich denke nicht, dass das schneller sein soll...
4) x - y / z
PB:
MOV ebx,dword [v_x]
MOV edi,dword [v_y]
PUSH dword [v_z]
MOV eax,edi
POP edi
CDQ
IDIV edi
MOV edi, eax
SUB ebx,edi
MOV dword [v_x],ebx
Vorschlag:
MOV ebx,dword [v_x]
MOV eax,dword [v_y]
MOV edi,dword [v_z]
CDQ
IDIV edi
SUB ebx,eax
MOV dword [v_x],ebx
greetz
remi