Get more debugging data when crashing in Deoptimizer::GetOutputInfo.
BUG= Review URL: https://codereview.chromium.org/1138493004 Cr-Commit-Position: refs/heads/master@{#28373}
This commit is contained in:
parent
09ecf6cef7
commit
9dc99e9cc8
@ -723,6 +723,8 @@ int Deoptimizer::GetOutputInfo(DeoptimizationOutputData* data,
|
||||
<< "[method: " << shared->DebugName()->ToCString().get() << "]\n"
|
||||
<< "[source:\n" << SourceCodeOf(shared) << "\n]" << std::endl;
|
||||
|
||||
shared->GetHeap()->isolate()->PushStackTraceAndDie(0xfefefefe, data, shared,
|
||||
0xfefefeff);
|
||||
FATAL("unable to find pc offset during deoptimization");
|
||||
return -1;
|
||||
}
|
||||
|
@ -280,9 +280,7 @@ Handle<String> Isolate::StackTraceString() {
|
||||
}
|
||||
|
||||
|
||||
void Isolate::PushStackTraceAndDie(unsigned int magic,
|
||||
Object* object,
|
||||
Map* map,
|
||||
void Isolate::PushStackTraceAndDie(unsigned int magic, void* ptr1, void* ptr2,
|
||||
unsigned int magic2) {
|
||||
const int kMaxStackTraceSize = 32 * KB;
|
||||
Handle<String> trace = StackTraceString();
|
||||
@ -291,9 +289,8 @@ void Isolate::PushStackTraceAndDie(unsigned int magic,
|
||||
String::WriteToFlat(*trace, buffer, 0, length);
|
||||
buffer[length] = '\0';
|
||||
// TODO(dcarney): convert buffer to utf8?
|
||||
base::OS::PrintError("Stacktrace (%x-%x) %p %p: %s\n", magic, magic2,
|
||||
static_cast<void*>(object), static_cast<void*>(map),
|
||||
reinterpret_cast<char*>(buffer));
|
||||
base::OS::PrintError("Stacktrace (%x-%x) %p %p: %s\n", magic, magic2, ptr1,
|
||||
ptr2, reinterpret_cast<char*>(buffer));
|
||||
base::OS::Abort();
|
||||
}
|
||||
|
||||
|
@ -718,10 +718,8 @@ class Isolate {
|
||||
PrintStackMode mode = kPrintStackVerbose);
|
||||
void PrintStack(FILE* out, PrintStackMode mode = kPrintStackVerbose);
|
||||
Handle<String> StackTraceString();
|
||||
NO_INLINE(void PushStackTraceAndDie(unsigned int magic,
|
||||
Object* object,
|
||||
Map* map,
|
||||
unsigned int magic2));
|
||||
NO_INLINE(void PushStackTraceAndDie(unsigned int magic, void* ptr1,
|
||||
void* ptr2, unsigned int magic2));
|
||||
Handle<JSArray> CaptureCurrentStackTrace(
|
||||
int frame_limit,
|
||||
StackTrace::StackTraceOptions options);
|
||||
|
Loading…
Reference in New Issue
Block a user