Go Back   Winamp Forums > Visualizations > AVS

Reply
Thread Tools Search this Thread Display Modes
Old 8th February 2007, 06:43   #1
0verhaul
Junior Member
 
Join Date: Nov 2006
Posts: 10
Expression library upgrade

Here is code for an upgraded expression compiler. On the good side, it runs all of the standard presets. On the not-so-good side, it doesn't seem to have much impact on AVS, which makes all the work that went into it kinda disappointing... but at least I had fun generating machine code.

What it does do: Reduces memory accesses by keeping values and intermediate results on the x87 stack as long as is safe. Reduces re-calculation by searching for duplicate expressions or sub-expressions that were already calculated. Places the branches of an 'if' within the bounds of conditional jumps instead of creating calls to separate blocks of code.

What it does not do (yet.. or well): Constant folding. SSE2/3 (MMX, 3DNow, and SSE are out of the question thanks to doubles. Not sure SSE2 would be much improvement anyway without parallelizing). Making sure all values on the stack are immediately useful

Other caveats: Many special cases thanks to the awkward meta-functions Code cleanup needed. APEs that provide custom functions would need to provide STDCALL or (untested) CDECL calls instead of FASTCALL, and take doubles instead of pointers to double. NSEEL_addfunctionex has changed.
Attached Files
File Type: zip nseel.zip (44.8 KB, 127 views)
0verhaul is offline   Reply With Quote
Reply
Go Back   Winamp Forums > Visualizations > AVS

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump