the "price" of a context switch/function call
JB
sundown at pacifier.com
Sat Oct 4 23:55:28 EDT 2014
I recently read a similar statement but I can’t rembenter
where. Maybe if was from Apple about Xcode. What
they said was even if you lose a little speed you are
better off writing code that is easy for you to rend and
understand instead of making it too complex.
John Balgenorth
On Oct 4, 2014, at 6:51 PM, Mark Wieder <mwieder at ahsoftware.net> wrote:
> Geoff-
>
> Saturday, October 4, 2014, 6:27:41 PM, you wrote:
>
>> On Sat, Oct 4, 2014 at 12:54 PM, Dr. Hawkins <dochawk at gmail.com> wrote:
>
>>> If I'm going to call a routine, say, 100 times in a fraction of a second,
>>> do I really save much by inlining it rather than calling it as a function?
>>>
>
>> Premature optimization is the root of <some> evil. If you write clean code,
>> it will be straightforward to optimize. If you write unclean optimized
>> code, it will never be clean.
>
> I think the proper adage here may be that first you write the code,
> then you make it work better, and finally you make it work faster.
>
> I spend much more time refactoring my code to make it more readable
> and more easily maintainable than I do optimizing for speed.
>
> But to answer the OP's question: no.
>
> --
> -Mark Wieder
> ahsoftware at gmail.com
>
> This communication may be unlawfully collected and stored by the National
> Security Agency (NSA) in secret. The parties to this email do not
> consent to the retrieving or storing of this communication and any
> related metadata, as well as printing, copying, re-transmitting,
> disseminating, or otherwise using it. If you believe you have received
> this communication in error, please delete it immediately.
>
>
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>
More information about the use-livecode
mailing list