"what will happen when i do..."
Posted: Tue Feb 02, 2010 9:18 am
i really like Lisp because it allows me to develop everything in the purest way possible. with all this white magic - like higher-order functions and macros - you can to pretty neat stuff. sometimes i wonder however what will happen to memory and performance when i cast some of this spells.
in OOP for example the dispatching of virtual functions has to happen somewhere, even if the language hides it away (like Java), the moon is still there. Lisp makes you aware of this, in Java you start to forget about this basic stuff. when i create a lot of functions with higher-order function at runtime, what will happen? how is the code of the function stored (function-pointers in cons-cells or bytecode)? is it interpreted everytime i call it or compiled beforehand and how long does the compilation take?
i'm aware that the compiler will take care of most situations in the release build and the outcome has to be monitored in real situations. but is there some information and guidance about what will happen when i do some of this stuff, so i can get a feeling about the major does and don'ts and rethink my architecture early on? i hope i made myself clear
in OOP for example the dispatching of virtual functions has to happen somewhere, even if the language hides it away (like Java), the moon is still there. Lisp makes you aware of this, in Java you start to forget about this basic stuff. when i create a lot of functions with higher-order function at runtime, what will happen? how is the code of the function stored (function-pointers in cons-cells or bytecode)? is it interpreted everytime i call it or compiled beforehand and how long does the compilation take?
i'm aware that the compiler will take care of most situations in the release build and the outcome has to be monitored in real situations. but is there some information and guidance about what will happen when i do some of this stuff, so i can get a feeling about the major does and don'ts and rethink my architecture early on? i hope i made myself clear
