all-in-one
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1393 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
de5b4605b6
commit
a4d8eadc69
@ -39,7 +39,6 @@
|
||||
#include "v8threads.h"
|
||||
|
||||
|
||||
namespace i = v8::internal;
|
||||
#define LOG_API(expr) LOG(ApiEntryCall(expr))
|
||||
|
||||
|
||||
|
@ -32,8 +32,6 @@
|
||||
#include "platform.h"
|
||||
#include "top.h"
|
||||
|
||||
using namespace v8::internal;
|
||||
|
||||
static int fatal_error_handler_nesting_depth = 0;
|
||||
|
||||
// Contains protection against recursive calls (faults while handling faults).
|
||||
@ -41,21 +39,21 @@ extern "C" void V8_Fatal(const char* file, int line, const char* format, ...) {
|
||||
fatal_error_handler_nesting_depth++;
|
||||
// First time we try to print an error message
|
||||
if (fatal_error_handler_nesting_depth < 2) {
|
||||
OS::PrintError("\n\n#\n# Fatal error in %s, line %d\n# ", file, line);
|
||||
i::OS::PrintError("\n\n#\n# Fatal error in %s, line %d\n# ", file, line);
|
||||
va_list arguments;
|
||||
va_start(arguments, format);
|
||||
OS::VPrintError(format, arguments);
|
||||
i::OS::VPrintError(format, arguments);
|
||||
va_end(arguments);
|
||||
OS::PrintError("\n#\n\n");
|
||||
i::OS::PrintError("\n#\n\n");
|
||||
}
|
||||
// First two times we may try to print a stack dump.
|
||||
if (fatal_error_handler_nesting_depth < 3) {
|
||||
if (FLAG_stack_trace_on_abort) {
|
||||
if (i::FLAG_stack_trace_on_abort) {
|
||||
// Call this one twice on double fault
|
||||
Top::PrintStack();
|
||||
i::Top::PrintStack();
|
||||
}
|
||||
}
|
||||
OS::Abort();
|
||||
i::OS::Abort();
|
||||
}
|
||||
|
||||
|
||||
@ -90,11 +88,11 @@ void CheckNonEqualsHelper(const char* file,
|
||||
|
||||
|
||||
void API_Fatal(const char* location, const char* format, ...) {
|
||||
OS::PrintError("\n#\n# Fatal error in %s\n# ", location);
|
||||
i::OS::PrintError("\n#\n# Fatal error in %s\n# ", location);
|
||||
va_list arguments;
|
||||
va_start(arguments, format);
|
||||
OS::VPrintError(format, arguments);
|
||||
i::OS::VPrintError(format, arguments);
|
||||
va_end(arguments);
|
||||
OS::PrintError("\n#\n\n");
|
||||
OS::Abort();
|
||||
i::OS::PrintError("\n#\n\n");
|
||||
i::OS::Abort();
|
||||
}
|
||||
|
@ -141,6 +141,7 @@ const Address kFromSpaceZapValue = reinterpret_cast<Address>(0xbeefdad);
|
||||
|
||||
class AccessorInfo;
|
||||
class Allocation;
|
||||
class Arguments;
|
||||
class Assembler;
|
||||
class BreakableStatement;
|
||||
class Code;
|
||||
|
@ -39,7 +39,7 @@
|
||||
namespace v8 { namespace internal {
|
||||
|
||||
|
||||
static unibrow::Mapping<unibrow::Ecma262Canonicalize> canonicalize;
|
||||
static unibrow::Mapping<unibrow::Ecma262Canonicalize> interp_canonicalize;
|
||||
|
||||
|
||||
static bool BackRefMatchesNoCase(int from,
|
||||
@ -50,8 +50,8 @@ static bool BackRefMatchesNoCase(int from,
|
||||
unibrow::uchar old_char = subject[from++];
|
||||
unibrow::uchar new_char = subject[current++];
|
||||
if (old_char == new_char) continue;
|
||||
canonicalize.get(old_char, '\0', &old_char);
|
||||
canonicalize.get(new_char, '\0', &new_char);
|
||||
interp_canonicalize.get(old_char, '\0', &old_char);
|
||||
interp_canonicalize.get(new_char, '\0', &new_char);
|
||||
if (old_char != new_char) {
|
||||
return false;
|
||||
}
|
||||
|
@ -84,7 +84,7 @@ namespace v8 { namespace internal {
|
||||
type name = NumberTo##Type(obj);
|
||||
|
||||
// Non-reentrant string buffer for efficient general use in this file.
|
||||
static StaticResource<StringInputBuffer> string_input_buffer;
|
||||
static StaticResource<StringInputBuffer> runtime_string_input_buffer;
|
||||
|
||||
|
||||
static Object* IllegalOperation() {
|
||||
@ -2315,7 +2315,7 @@ static Object* Runtime_URIEscape(Arguments args) {
|
||||
int escaped_length = 0;
|
||||
int length = source->length();
|
||||
{
|
||||
Access<StringInputBuffer> buffer(&string_input_buffer);
|
||||
Access<StringInputBuffer> buffer(&runtime_string_input_buffer);
|
||||
buffer->Reset(source);
|
||||
while (buffer->has_more()) {
|
||||
uint16_t character = buffer->GetNext();
|
||||
@ -2343,7 +2343,7 @@ static Object* Runtime_URIEscape(Arguments args) {
|
||||
StringShape dshape(destination);
|
||||
int dest_position = 0;
|
||||
|
||||
Access<StringInputBuffer> buffer(&string_input_buffer);
|
||||
Access<StringInputBuffer> buffer(&runtime_string_input_buffer);
|
||||
buffer->Rewind();
|
||||
while (buffer->has_more()) {
|
||||
uint16_t chr = buffer->GetNext();
|
||||
@ -2579,7 +2579,7 @@ static Object* ConvertCase(Arguments args,
|
||||
|
||||
// Convert all characters to upper case, assuming that they will fit
|
||||
// in the buffer
|
||||
Access<StringInputBuffer> buffer(&string_input_buffer);
|
||||
Access<StringInputBuffer> buffer(&runtime_string_input_buffer);
|
||||
buffer->Reset(s);
|
||||
unibrow::uchar chars[Converter::kMaxWidth];
|
||||
int i = 0;
|
||||
|
Loading…
Reference in New Issue
Block a user