That's exactly the reason why HLSL was developed, to make code reuse look more structured and readable
Try ello's suggestions since HLSL is more flexible than asm IMHO

Cheers

Frazzle


Antec® Case
Intel® X58 Chipset
Intel® i7 975 Quad Core
8 GB RAM DDR3
SSD OCZ®-VERTEX2 3.5 x4 ; HD 600 GB
NVIDIA® GeForce GTX 295 Memory 1795GB