| Index: src/hydrogen.h
|
| diff --git a/src/hydrogen.h b/src/hydrogen.h
|
| index e9b8a2fa836c01e2316a3c884614c497657b7709..0633c733533919e2c02da32a77c73016abcd2f2f 100644
|
| --- a/src/hydrogen.h
|
| +++ b/src/hydrogen.h
|
| @@ -36,6 +36,7 @@
|
| #include "hydrogen-instructions.h"
|
| #include "type-info.h"
|
| #include "zone.h"
|
| +#include "scopes.h"
|
|
|
| namespace v8 {
|
| namespace internal {
|
| @@ -981,6 +982,11 @@ class HGraphBuilder {
|
| ElementsKind to_elements_kind,
|
| HValue* length);
|
|
|
| + bool IsOneTimeCode() {
|
| + return info_->scope()->is_global_scope() &&
|
| + current_block()->LoopNestingDepth() == 0;
|
| + }
|
| +
|
| private:
|
| HGraphBuilder();
|
| CompilationInfo* info_;
|
|
|