drym-org / qi

An embeddable flow-oriented language.
58 stars 12 forks source link

`ground` could be compiled to `(lambda _ (values))`, which might be more efficient #137

Open benknoble opened 8 months ago

benknoble commented 8 months ago

The compiler branch currently compiles through a number of other forms and ends up with (lambda args (apply values (append))), which seems like it might be inefficient (really we'd need to see how the CS compiler handled that).

countvajhula commented 8 months ago

I tried this in compiler explorer (courtesy of @jryans), and doesn't look like CS optimizes it (looking at cp0).