GLSL: Handle more intrinsics, fix bugs in code generation and texture transfer

Map intrinsics to correct GLSL functions:
- trigonometric functions (sin, cos, tan, asin, acos, atan, atan2)
- exponential functions (pow, exp, log)
- general functions (floor, ceil, lerp)

Since GLSL doesn't support bit arithmetic, don't use C backend to generate
code for "Mod" and "Div".
I'm sure it does, but we generate a few additional casts during codegen, for example when calling functions such as "min", "max", "mod" with integer arguments. Or do you think that calling simplify() on the new subexpressions would be a better idea?