[v8-dev] Re: Lower heap space size limits if is_memory_constrained(). (issue 24269003)

2013-09-24 Thread hpayer
https://codereview.chromium.org/24269003/diff/12001/src/api.cc File src/api.cc (right): https://codereview.chromium.org/24269003/diff/12001/src/api.cc#newcode636 src/api.cc:636: bool ConfigureResourceConstraintsForCurrentPlatform( We had another discussion about that function right now... can we

[v8-dev] Re: Lower heap space size limits if is_memory_constrained(). (issue 24269003)

2013-09-23 Thread hpayer
I think this is a good first step in the right direction. Currently we base these limits on static ifdefs. Checking for available memory is already an improvement over the current approach. In an ideal world we would dynamically check at runtime the system utilization and adjust the memory limi

[v8-dev] Re: Lower heap space size limits if is_memory_constrained(). (issue 24269003)

2013-09-23 Thread bmeurer
On 2013/09/23 17:25:46, rmcilroy wrote: As discussed this morning, I've moved this to a API call which sets device specific heap sizes. WDYT? I've based the code in platform-X.cc on code in chrome's base::SysInfo class, but I don't have the platforms available to test these - is there any way

[v8-dev] Re: Lower heap space size limits if is_memory_constrained(). (issue 24269003)

2013-09-23 Thread rmcilroy
As discussed this morning, I've moved this to a API call which sets device specific heap sizes. WDYT? I've based the code in platform-X.cc on code in chrome's base::SysInfo class, but I don't have the platforms available to test these - is there any way I can test these on trybots for the di

Re: [v8-dev] Re: Lower heap space size limits if is_memory_constrained(). (issue 24269003)

2013-09-20 Thread Ross McIlroy
> > -1 on new entry points. SetResourceConstraints is the way to go, finding > the right place to call it from Chrome shouldn't be an issue. In the > not-too-far future this should be an optional argument for Isolate > creation, anyway, and I don't want to design something now which will be > dead

[v8-dev] Re: Lower heap space size limits if is_memory_constrained(). (issue 24269003)

2013-09-20 Thread Sven Panne
On Fri, Sep 20, 2013 at 1:25 PM, wrote: > [...] then I think it would be best to have some clear entry point > to initialize V8 where it's explicit to the embedder that they should be > setting > these constraints. This is difficult right now due to the default isolate, > and I > don't think havi

[v8-dev] Re: Lower heap space size limits if is_memory_constrained(). (issue 24269003)

2013-09-20 Thread rmcilroy
On 2013/09/20 07:12:32, danno wrote: I don't think adding more #ifdefs to V8 or adding memory_constrained is the right way to go. The core of V8 is not the best place to consolidate the logic for the multiple devices and configurations where it needs to run well. Defaults should be just that

[v8-dev] Re: Lower heap space size limits if is_memory_constrained(). (issue 24269003)

2013-09-20 Thread danno
I don't think adding more #ifdefs to V8 or adding memory_constrained is the right way to go. The core of V8 is not the best place to consolidate the logic for the multiple devices and configurations where it needs to run well. Defaults should be just that, defaults, and I really don't think th

[v8-dev] Re: Lower heap space size limits if is_memory_constrained(). (issue 24269003)

2013-09-19 Thread rmcilroy
https://codereview.chromium.org/24269003/diff/1/src/heap.cc File src/heap.cc (right): https://codereview.chromium.org/24269003/diff/1/src/heap.cc#newcode75 src/heap.cc:75: #if defined(ANDROID) || V8_TARGET_ARCH_MIPS On 2013/09/19 16:25:28, Hannes Payer wrote: On 2013/09/19 15:01:34, rmcilroy wr

[v8-dev] Re: Lower heap space size limits if is_memory_constrained(). (issue 24269003)

2013-09-19 Thread hpayer
https://codereview.chromium.org/24269003/diff/1/src/heap.cc File src/heap.cc (right): https://codereview.chromium.org/24269003/diff/1/src/heap.cc#newcode75 src/heap.cc:75: #if defined(ANDROID) || V8_TARGET_ARCH_MIPS On 2013/09/19 15:01:34, rmcilroy wrote: On 2013/09/19 14:50:57, Hannes Payer wr

[v8-dev] Re: Lower heap space size limits if is_memory_constrained(). (issue 24269003)

2013-09-19 Thread rmcilroy
https://codereview.chromium.org/24269003/diff/1/src/heap.cc File src/heap.cc (right): https://codereview.chromium.org/24269003/diff/1/src/heap.cc#newcode75 src/heap.cc:75: #if defined(ANDROID) || V8_TARGET_ARCH_MIPS On 2013/09/19 14:50:57, Hannes Payer wrote: I never liked the ifdef here. Now i

[v8-dev] Re: Lower heap space size limits if is_memory_constrained(). (issue 24269003)

2013-09-19 Thread hpayer
https://codereview.chromium.org/24269003/diff/1/src/heap.cc File src/heap.cc (right): https://codereview.chromium.org/24269003/diff/1/src/heap.cc#newcode75 src/heap.cc:75: #if defined(ANDROID) || V8_TARGET_ARCH_MIPS I never liked the ifdef here. Now it's time to get rid of it while you are there