On 2013/08/01 12:02:13, Jakob wrote:
DBC.

Could you explain briefly what the motivation for this change is?

https://codereview.chromium.org/20843012/diff/6001/src/compiler.cc
File src/compiler.cc (right):

https://codereview.chromium.org/20843012/diff/6001/src/compiler.cc#newcode488
src/compiler.cc:488: info()->set_bailout_reason(kCodeGenerationFailed);
While you're here, please wrap this into an "if (info()->bailout_reason() != kNoReason) {...}" check (otherwise it overwrites the more detailed reason that
the Lithium code generator might have set).

https://codereview.chromium.org/20843012/diff/6001/src/ia32/stub-cache-ia32.cc
File src/ia32/stub-cache-ia32.cc (right):


https://codereview.chromium.org/20843012/diff/6001/src/ia32/stub-cache-ia32.cc#newcode3156
src/ia32/stub-cache-ia32.cc:3156: __ Check(not_equal,
kDontDeleteCellsCanTContainTheHole);
nit: s/CanT/Cannot/

https://codereview.chromium.org/20843012/diff/6001/src/objects.cc
File src/objects.cc (right):

https://codereview.chromium.org/20843012/diff/6001/src/objects.cc#newcode15970
src/objects.cc:15970: static const char* error_messages_[] =
{ERROR_MESSAGES_LIST(ERROR_MESSAGES_TEXTS)};
nit: 80col

In cpu profiler we are showing the times for a function.
Sometimes the function needs unacceptable amount of time.
It might happen if the function was deoptimized for some reason.
I'd like to expose that fact in the cpu-profile and show to the web developer the reason of that. Otherwise they can detect that only with help of js-flags
magic.

It happens that we have the reason only in CompilationInfo which has
limited lifetime. So I'd like to propagate the reason to SharedFunctionInfo as a
property.
But SharedFunctionInfo is a heap object, so I have to convert the reason into
String.
That may introduce unnecessary overhead in the code and affects the performance.

Yesterday I was optimistic and thought that we have a handful of reasons.
So I decided to use an enum for that and save it into SharedFunctionInfo.
Today morning I found that we have a little bit more reasons (184).
But from the other hand I found that all these strings actually are error
messages.

I think it would be nice to have them collected in one place.
It allows us to keep this set of messages under control.
It reduces the binary footprint.
It gives us a chance to internationalize them.



https://codereview.chromium.org/20843012/

--
--
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.


Reply via email to