Fix build with GCC 4.7, which fails with "narrowing conversion of 'id' from 'int' to 'unsigned int' inside { } is ill-formed in C++11"
Contributed by burnus@net-b.de Review URL: http://codereview.chromium.org/8724003 Patch from Tobias Burnus <burnus@net-b.de>. git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10101 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
4d0f2839ed
commit
f5d9c1bef8
@ -362,7 +362,7 @@ void FullCodeGenerator::RecordJSReturnSite(Call* call) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void FullCodeGenerator::PrepareForBailoutForId(int id, State state) {
|
void FullCodeGenerator::PrepareForBailoutForId(unsigned id, State state) {
|
||||||
// There's no need to prepare this code for bailouts from already optimized
|
// There's no need to prepare this code for bailouts from already optimized
|
||||||
// code or code that can't be optimized.
|
// code or code that can't be optimized.
|
||||||
if (!FLAG_deopt || !info_->HasDeoptimizationSupport()) return;
|
if (!FLAG_deopt || !info_->HasDeoptimizationSupport()) return;
|
||||||
@ -383,10 +383,11 @@ void FullCodeGenerator::PrepareForBailoutForId(int id, State state) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void FullCodeGenerator::RecordStackCheck(int ast_id) {
|
void FullCodeGenerator::RecordStackCheck(unsigned ast_id) {
|
||||||
// The pc offset does not need to be encoded and packed together with a
|
// The pc offset does not need to be encoded and packed together with a
|
||||||
// state.
|
// state.
|
||||||
BailoutEntry entry = { ast_id, masm_->pc_offset() };
|
ASSERT(masm_->pc_offset() > 0);
|
||||||
|
BailoutEntry entry = { ast_id, static_cast<unsigned>(masm_->pc_offset()) };
|
||||||
stack_checks_.Add(entry);
|
stack_checks_.Add(entry);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -390,7 +390,7 @@ class FullCodeGenerator: public AstVisitor {
|
|||||||
|
|
||||||
// Bailout support.
|
// Bailout support.
|
||||||
void PrepareForBailout(Expression* node, State state);
|
void PrepareForBailout(Expression* node, State state);
|
||||||
void PrepareForBailoutForId(int id, State state);
|
void PrepareForBailoutForId(unsigned id, State state);
|
||||||
|
|
||||||
// Record a call's return site offset, used to rebuild the frame if the
|
// Record a call's return site offset, used to rebuild the frame if the
|
||||||
// called function was inlined at the site.
|
// called function was inlined at the site.
|
||||||
@ -417,7 +417,7 @@ class FullCodeGenerator: public AstVisitor {
|
|||||||
// a loop.
|
// a loop.
|
||||||
void EmitStackCheck(IterationStatement* stmt);
|
void EmitStackCheck(IterationStatement* stmt);
|
||||||
// Record the OSR AST id corresponding to a stack check in the code.
|
// Record the OSR AST id corresponding to a stack check in the code.
|
||||||
void RecordStackCheck(int osr_ast_id);
|
void RecordStackCheck(unsigned osr_ast_id);
|
||||||
// Emit a table of stack check ids and pcs into the code stream. Return
|
// Emit a table of stack check ids and pcs into the code stream. Return
|
||||||
// the offset of the start of the table.
|
// the offset of the start of the table.
|
||||||
unsigned EmitStackCheckTable();
|
unsigned EmitStackCheckTable();
|
||||||
|
Loading…
Reference in New Issue
Block a user