freenode/#sbcl - IRC Chatlog
Search
15:59:22
citizenajb
I do a lot of floating point computations with lisp. I've been thinking around trying to get SBCL to compile (incf (the double-float x) (aref (the simple-array double-float (*)) x i)) into ADDSD XMM1, [RAX+4*RCX...] instead of: MOV XMM2, [RAX+4*RCX...] then ADDSD XMM1, XMM2. There is no direct execution speed-up because cache / memory access dominates but it reduces FP register pressure (and code size), which can
15:59:22
citizenajb
be a small win in some cases. From my position of ignorance, I do not think IR1 transforms make sense for this, nor does hackish pattern matching in IR2 (replace-vops, etc). But I am currently dreaming about teaching the VM about a new storage class, an effective address which carries a dependency on various registers. Then I can just implement VOPs for things like +, -, etc that take effective addresses instead
15:59:22
citizenajb
of double-regs (in this case). BUT I have a complete lack of understanding of the IR2/VM phase and am hoping someone might short circuit my thinking or save me some time going down the wrong rabbit hole.