On 2014/05/01 18:29:11, rmcilroy wrote:
> Since we added UseScratchRegisterScope, I don't think this is true.
> It used to be important so we could do `Push(..., ip0, ...)`, but we
> don't do that any more unless we first acquire ip0 (making it
> unavailable). It might be worth checking that now, since it would
> greatly simplify this function.
Yes I had hoped that was true and tried it originally, however,
unfortunately we still reach here with no remaining temp registers in
LCodeGen::PushSafepointRegistersScope.
Ok, fair enough.
Sure I understand your concern. We are not yet sure whether this CL
will be necessary (it has a very big impact currently, but there may
be other ways around the issue. I will investigate whether this can
be gated on the platform if we decide to land this.
There's something else I considered when we first learned about the
stack pointer problem: We could set csp to the V8 stack limit, then
leave it there. We'd have to move it for calls into C code, and restore
it afterwards, but normal 'Push' calls could just ignore it. I didn't do
this to start with because there are some complications:
- Can the (real) stack limit move? If so, we'd need to update csp
accordingly. If it's only C calls that can move it, we could reload
the stack limit on return to generated code.
- There needs to be enough valid below the VM stack limit to allow
signal handlers to run. I didn't know if we could guarantee this.
I see what you mean, but actually, looking at it again I actually
think PrepareForPop should be called after the PopHelper - it doesn't
actually prepare anything it just asserts that the stack is in a valid
state and I think this makes more sense to do after the PopHelper has
been run. I've made a change to call it PushPreamble and PopPostamble
and moved the calls about as appropriate. Wdyt?
Yep, that makes perfect sense.
https://codereview.chromium.org/264773004/
--
--
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/d/optout.