> > -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 soon just because the current API is so fragile. >
Fair enough, I think an optional argument on Isolate creation is the perfect place for this, and until we get rid of the default isolate, I guess SetResourceConstraints is as good as any for configuring the default isolate. Apart from that, I don't have any strong opinion on the topic itself, apart > from the fact that v8 should never decide on its own how much memory it > should use at most. We simply don't know how much the embedder/user wants > us to use, even if we have e.g. a 64GB machine the app using v8 might want > to limit it to let's say 2GB because a lot of app instances are spawned. We > just don't know the scenario from within v8, so this should be controlled > somehow from the outside, and this is the reason why all runtimes I know of > have some controllable limits. > I absolutely agree that there should be controllable limits! However, for the defaults I think it should either be that we explicitly don't have any default limits at all (i.e., the embedder has to set these limits explicitly / the ResourceConstraint argument is not optional in Isolate creation), or we should set sensible limits based on the available memory of the device (i.e., assuming the embedder is only spawning a single instance). In my opinion, having a default limit which is only valid for a particular scenario on a single device type is the worst of both worlds - it encourages lazyness of just using the default value because it's there, and the default value won't be a good one for any other different device types. However, if we have a sensible way of setting these values for Chrome I don't mind too much, I just worry about all the other embedders of V8. Cheers, Ross -- -- v8-dev mailing list [email protected] http://groups.google.com/group/v8-dev --- You received this message because you are subscribed to the Google Groups "v8-dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
