4 ms·
"On mobile, it takes 3–4× longer for a median phone (Moto G4) to execute Reddit’s JavaScript compared to a high-end device (Pixel 3), and over 6× as long on a l
by tyingq 7y ago
"On mobile, it takes 3–4× longer for a median phone (Moto G4) to execute Reddit’s JavaScript compared to a high-end device (Pixel 3), and over 6× as long on a low-end device (the <$100 Alcatel 1X)"
Notable that they avoid the iPhone comparison. It runs circles around even the top end Androids for JS performance.
- Irelando 7y agoIsn't that a little bit irrelevant? It's not an analysis of phones, it's an analysis of javascript. If my $70 android phone takes forever to execute something, I dont really care if my friend's iphone does it almost instantly.
- tyingq 7y agoIf you are trying to make the point that low end phones are slower, comparing to the actual high end makes the point stronger.
- addicted 7y agoThese are V8 devs. Why would they bother mentioning what happens on an iPhone which explicitly disallows V8? As a result, they don’t have the tools they use to measure these stats on the iPhone either.
- cromwellian 7y agoThey’re comparing like with like. iPhone cannot run v8, if you throw the iPhone into the mix then you are not measuring v8.
- simion314 7y agoMaybe you misunderstand what this article is about, s not about what is the best phone, is about how JS is run in real world where not everyone has super fast internet all the time and not everyone has a super fast phone or computer. So if you are a web developer you get some good advice from this article related to JS not what phone to buy.
- tyingq 7y agoThey are making the point that low end phones are much slower in executing JS than high end phones. Perhaps to remind developers that their experience, on their phone, isn't the experience everyone has. I imagine a lot of developers have recent iPhones. They are, depending on benchmark, up to 3x faster than a flagship Android. Which means the top to bottom chasm is much larger than the snippet suggests. Noting it would strengthen their point.
- BubRoss 7y agoThis article is about the v8 just in time engine, which does not run on an iPhone.
- simion314 7y agoOK, sorry I missundertoo then the iPhone point, my bad, I interpreted it as iPhone is super fast so nobody should forget to mention in any article the iPhone is the fastest phone and Intel i9s are the fastest CPUs. I agree that we the developers should not forget that a lot of people have less powerful hardware. I sometimes hit thus problem at work, say we offer feature X like uploading an image and you can crop that image and apply a filter, how should I add this feature but not have the code even load in the browser if you don't intend to use, is there a pure JS way to do it? AFAIK thee is no good way to load a script at runtime and get an even when the file is loaded and parsed.
- Stratoscope 7y ago> AFAIK [there] is no good way to load a script at runtime and get an [event] when the file is loaded and parsed. You can do this easily by creating a script element dynamically and then either: 1) Listen for the load event on that element, or 2) Have the dynamic script call a function that is already loaded. Here is an example of the first technique: let script = document.createElement( 'script' ); script.addEventListener( 'load', () => { alert( 'three.js is loaded: ' + THREE ); }); script.src = 'https://ajax.googleapis.com/ajax/libs/threejs/r84/three.min.js'; document.head.appendChild( script ); https://jsfiddle.net/geary/szmc1L0h/9/ https://jsfiddle.net/geary/szmc1L0h/9/
- ksec 7y ago1. v8 isn't available on iPhone, so they couldn't really show any results. 2. Unless you have the Samsung SoC variant of just released Galaxy S10, pretty much all Android JS performance, including flagship, will be slower than the current entry iPhone, which is the iPhone 7. And since the current Android flagship, along with middle range and lower end still has another 4 years of life in it, with roadmap that shows very slow improvement in the middle to low end Smartphones. May be we should just go back and ship HTML instead?
- pmarreck 7y agoNot sure if this is news to you but the Chrome browser on iOS (as well as ALL other browsers on iOS, by Apple stipulation via app-store rules) uses WebKit underneath