Skip to main content
43 events
when toggle format what by license comment
Mar 27, 2014 at 20:25 history edited cocco CC BY-SA 3.0
added 153 characters in body
S Mar 27, 2014 at 19:25 history notice removed Jamal
S Mar 27, 2014 at 19:25 history unlocked Jamal
Mar 27, 2014 at 19:09 history edited Jamal CC BY-SA 3.0
1.) inserted original code (before answer invalidation) from revision11 to the top of the previous revision 2.) removed some redundant info found in both revisions 3.) cleaned up much of the grammar and spelling
S Mar 26, 2014 at 21:43 history notice added Jamal Content dispute
S Mar 26, 2014 at 21:43 history locked Jamal
Mar 26, 2014 at 21:20 history edited cocco CC BY-SA 3.0
added 339 characters in body
Mar 26, 2014 at 21:06 history rollback cocco
Rollback to Revision 22
Mar 26, 2014 at 21:02 history rollback Jamal
Rollback to Revision 4
Mar 26, 2014 at 20:58 history edited cocco CC BY-SA 3.0
added 120 characters in body
Mar 26, 2014 at 20:52 history edited cocco CC BY-SA 3.0
added 120 characters in body
Mar 26, 2014 at 20:34 history edited cocco CC BY-SA 3.0
added 120 characters in body
Mar 26, 2014 at 20:29 history edited cocco CC BY-SA 3.0
added 120 characters in body
Mar 26, 2014 at 20:12 history edited cocco CC BY-SA 3.0
added 120 characters in body
Mar 26, 2014 at 20:06 history edited cocco CC BY-SA 3.0
added 285 characters in body
Mar 26, 2014 at 19:56 history edited cocco CC BY-SA 3.0
added 294 characters in body
Mar 26, 2014 at 18:51 history edited cocco CC BY-SA 3.0
added 465 characters in body
Mar 26, 2014 at 18:23 history edited cocco CC BY-SA 3.0
added 316 characters in body; Post Made Community Wiki
Mar 26, 2014 at 18:11 history edited cocco CC BY-SA 3.0
added 14 characters in body
Mar 26, 2014 at 18:05 history edited cocco CC BY-SA 3.0
added 5697 characters in body
Mar 26, 2014 at 13:11 answer added konijn timeline score: 9
Mar 25, 2014 at 20:20 comment added Danny Looks pretty optimized to me, I can't see any faster ways of doing the operations you are doing.
Mar 25, 2014 at 19:55 history edited cocco CC BY-SA 3.0
added 3 characters in body
Mar 25, 2014 at 19:49 history edited cocco CC BY-SA 3.0
added 3 characters in body
Mar 25, 2014 at 19:40 history edited cocco CC BY-SA 3.0
added 128 characters in body
Mar 25, 2014 at 19:34 comment added cocco Looks like you are all talking about how unreadable this code is. but i'm searching for maximum performance. i could change the s to seconds,m to minutes, h to hours but i guessed h,m,s are enough to understand the function btw in the second one all variables are just temp ms variables.No concrete answers. explain : "Don't do it, don't do it yet, and don't do it unless test results show that a particular piece of code needs it." what has this to do with coding?
Mar 25, 2014 at 19:31 comment added cocco what you mean with test data ?
Mar 25, 2014 at 19:29 comment added AJMansfield @cocco You are also disregarding the golden rules of optimization, which are: Don't do it, don't do it yet, and don't do it unless test results show that a particular piece of code needs it.
Mar 25, 2014 at 19:28 comment added cocco time api? new Date()?
Mar 25, 2014 at 19:27 comment added AJMansfield @cocco If you really need that sort of speed, you should be using an existing time API, because that API can implement it as an assembly routine, which is much, much faster than anything you could ever write in javascript.
Mar 25, 2014 at 19:25 history edited cocco CC BY-SA 3.0
edited body
Mar 25, 2014 at 19:21 comment added cocco minifiers can't interprete/rewrite the code and convert math.round to bitwise, remove useless variables. They just convert it to shorthand and shorten the variable names.In the edit area is a link about minifiers.
Mar 25, 2014 at 19:19 history edited cocco CC BY-SA 3.0
added 206 characters in body
Mar 25, 2014 at 19:18 comment added AJMansfield @cocco For fast code, you write it out long, and then feed it through an minifier when you go to deploy. Minifying it yourself only makes it harder for you to find algorithmic simplifications, while a minifier program has the advantage that it can minify it well past the limit of comprehensibility, as well as optimize the code minification.
Mar 25, 2014 at 19:14 history edited cocco CC BY-SA 3.0
added 206 characters in body
Mar 25, 2014 at 19:09 comment added cocco At the other side ... i wanna contradict you as shorthand and bitwiser is faster than normal readable code most of the time... only in the advanced chrome and maybe firefox the compilation is done properly.
Mar 25, 2014 at 19:00 history edited cocco CC BY-SA 3.0
added 145 characters in body
Mar 25, 2014 at 18:57 history edited Jamal CC BY-SA 3.0
deleted 14 characters in body; edited tags
Mar 25, 2014 at 18:54 history edited cocco CC BY-SA 3.0
added 437 characters in body
Mar 25, 2014 at 18:46 comment added cocco i don't think you can minify more this code except the ms var.btw i'm asking for tips to improve the code. i know jsperf but if i have no new ideas on how to change the code. So there is no reason to use jsperf.if you are talking about the pad functions... then yep, i have already tested ... and no... they are slower... i just added them to just to show more ways to implement the padding maybe writing it in another way could also improve the code.
Mar 25, 2014 at 18:37 comment added Flambino Obfuscation/minification != optimization. Your code wouldn't run any slower if you made it more readable. Also, you can use jsperf.com to benchmark your code
Mar 25, 2014 at 18:32 history edited Mathieu Guindon CC BY-SA 3.0
tags
Mar 25, 2014 at 18:00 history asked cocco CC BY-SA 3.0