| OLD | NEW | 
|    1 // Copyright 2011 the V8 project authors. All rights reserved. |    1 // Copyright 2011 the V8 project authors. All rights reserved. | 
|    2 // Redistribution and use in source and binary forms, with or without |    2 // Redistribution and use in source and binary forms, with or without | 
|    3 // modification, are permitted provided that the following conditions are |    3 // modification, are permitted provided that the following conditions are | 
|    4 // met: |    4 // met: | 
|    5 // |    5 // | 
|    6 //     * Redistributions of source code must retain the above copyright |    6 //     * Redistributions of source code must retain the above copyright | 
|    7 //       notice, this list of conditions and the following disclaimer. |    7 //       notice, this list of conditions and the following disclaimer. | 
|    8 //     * Redistributions in binary form must reproduce the above |    8 //     * Redistributions in binary form must reproduce the above | 
|    9 //       copyright notice, this list of conditions and the following |    9 //       copyright notice, this list of conditions and the following | 
|   10 //       disclaimer in the documentation and/or other materials provided |   10 //       disclaimer in the documentation and/or other materials provided | 
| (...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  187       JSObject* receiver, |  187       JSObject* receiver, | 
|  188       bool is_store, |  188       bool is_store, | 
|  189       StrictModeFlag strict_mode); |  189       StrictModeFlag strict_mode); | 
|  190  |  190  | 
|  191   MUST_USE_RESULT MaybeObject* ComputeKeyedLoadOrStoreFastElement( |  191   MUST_USE_RESULT MaybeObject* ComputeKeyedLoadOrStoreFastElement( | 
|  192       JSObject* receiver, |  192       JSObject* receiver, | 
|  193       bool is_store, |  193       bool is_store, | 
|  194       StrictModeFlag strict_mode); |  194       StrictModeFlag strict_mode); | 
|  195   // --- |  195   // --- | 
|  196  |  196  | 
|  197   MUST_USE_RESULT MaybeObject* ComputeCallField(int argc, |  197   MUST_USE_RESULT MaybeObject* ComputeCallField( | 
|  198                                                 InLoopFlag in_loop, |  198       int argc, | 
|  199                                                 Code::Kind, |  199       InLoopFlag in_loop, | 
|  200                                                 String* name, |  200       Code::Kind, | 
|  201                                                 Object* object, |  201       Code::ExtraICState extra_ic_state, | 
|  202                                                 JSObject* holder, |  202       String* name, | 
|  203                                                 int index); |  203       Object* object, | 
 |  204       JSObject* holder, | 
 |  205       int index); | 
|  204  |  206  | 
|  205   MUST_USE_RESULT MaybeObject* ComputeCallConstant( |  207   MUST_USE_RESULT MaybeObject* ComputeCallConstant( | 
|  206       int argc, |  208       int argc, | 
|  207       InLoopFlag in_loop, |  209       InLoopFlag in_loop, | 
|  208       Code::Kind, |  210       Code::Kind, | 
|  209       Code::ExtraICState extra_ic_state, |  211       Code::ExtraICState extra_ic_state, | 
|  210       String* name, |  212       String* name, | 
|  211       Object* object, |  213       Object* object, | 
|  212       JSObject* holder, |  214       JSObject* holder, | 
|  213       JSFunction* function); |  215       JSFunction* function); | 
|  214  |  216  | 
|  215   MUST_USE_RESULT MaybeObject* ComputeCallNormal(int argc, |  217   MUST_USE_RESULT MaybeObject* ComputeCallNormal( | 
|  216                                                  InLoopFlag in_loop, |  218       int argc, | 
|  217                                                  Code::Kind, |  219       InLoopFlag in_loop, | 
|  218                                                  String* name, |  220       Code::Kind, | 
|  219                                                  JSObject* receiver); |  221       Code::ExtraICState extra_ic_state, | 
 |  222       String* name, | 
 |  223       JSObject* receiver); | 
|  220  |  224  | 
|  221   MUST_USE_RESULT MaybeObject* ComputeCallInterceptor(int argc, |  225   MUST_USE_RESULT MaybeObject* ComputeCallInterceptor( | 
|  222                                                       Code::Kind, |  226       int argc, | 
|  223                                                       String* name, |  227       Code::Kind, | 
|  224                                                       Object* object, |  228       Code::ExtraICState extra_ic_state, | 
|  225                                                       JSObject* holder); |  229       String* name, | 
 |  230       Object* object, | 
 |  231       JSObject* holder); | 
|  226  |  232  | 
|  227   MUST_USE_RESULT MaybeObject* ComputeCallGlobal( |  233   MUST_USE_RESULT MaybeObject* ComputeCallGlobal( | 
|  228       int argc, |  234       int argc, | 
|  229       InLoopFlag in_loop, |  235       InLoopFlag in_loop, | 
|  230       Code::Kind, |  236       Code::Kind, | 
 |  237       Code::ExtraICState extra_ic_state, | 
|  231       String* name, |  238       String* name, | 
|  232       JSObject* receiver, |  239       JSObject* receiver, | 
|  233       GlobalObject* holder, |  240       GlobalObject* holder, | 
|  234       JSGlobalPropertyCell* cell, |  241       JSGlobalPropertyCell* cell, | 
|  235       JSFunction* function); |  242       JSFunction* function); | 
|  236  |  243  | 
|  237   // --- |  244   // --- | 
|  238  |  245  | 
|  239   MUST_USE_RESULT MaybeObject* ComputeCallInitialize(int argc, |  246   MUST_USE_RESULT MaybeObject* ComputeCallInitialize(int argc, | 
|  240                                                      InLoopFlag in_loop, |  247                                                      InLoopFlag in_loop, | 
 |  248                                                      RelocInfo::Mode mode, | 
|  241                                                      Code::Kind kind); |  249                                                      Code::Kind kind); | 
|  242  |  250  | 
|  243   Handle<Code> ComputeCallInitialize(int argc, InLoopFlag in_loop); |  251   Handle<Code> ComputeCallInitialize(int argc, | 
 |  252                                      InLoopFlag in_loop, | 
 |  253                                      RelocInfo::Mode mode); | 
|  244  |  254  | 
|  245   Handle<Code> ComputeKeyedCallInitialize(int argc, InLoopFlag in_loop); |  255   Handle<Code> ComputeKeyedCallInitialize(int argc, InLoopFlag in_loop); | 
|  246  |  256  | 
|  247   MUST_USE_RESULT MaybeObject* ComputeCallPreMonomorphic( |  257   MUST_USE_RESULT MaybeObject* ComputeCallPreMonomorphic( | 
|  248       int argc, |  258       int argc, | 
|  249       InLoopFlag in_loop, |  259       InLoopFlag in_loop, | 
|  250       Code::Kind kind); |  260       Code::Kind kind, | 
 |  261       Code::ExtraICState extra_ic_state); | 
|  251  |  262  | 
|  252   MUST_USE_RESULT MaybeObject* ComputeCallNormal(int argc, |  263   MUST_USE_RESULT MaybeObject* ComputeCallNormal(int argc, | 
|  253                                                  InLoopFlag in_loop, |  264                                                  InLoopFlag in_loop, | 
|  254                                                  Code::Kind kind); |  265                                                  Code::Kind kind, | 
 |  266                                                  Code::ExtraICState state); | 
|  255  |  267  | 
|  256   MUST_USE_RESULT MaybeObject* ComputeCallMegamorphic(int argc, |  268   MUST_USE_RESULT MaybeObject* ComputeCallMegamorphic(int argc, | 
|  257                                                       InLoopFlag in_loop, |  269                                                       InLoopFlag in_loop, | 
|  258                                                       Code::Kind kind); |  270                                                       Code::Kind kind, | 
 |  271                                                       Code::ExtraICState state); | 
|  259  |  272  | 
|  260   MUST_USE_RESULT MaybeObject* ComputeCallMiss(int argc, Code::Kind kind); |  273   MUST_USE_RESULT MaybeObject* ComputeCallMiss(int argc, | 
 |  274                                                Code::Kind kind, | 
 |  275                                                Code::ExtraICState state); | 
|  261  |  276  | 
|  262   // Finds the Code object stored in the Heap::non_monomorphic_cache(). |  277   // Finds the Code object stored in the Heap::non_monomorphic_cache(). | 
|  263   MUST_USE_RESULT Code* FindCallInitialize(int argc, |  278   MUST_USE_RESULT Code* FindCallInitialize(int argc, | 
|  264                                            InLoopFlag in_loop, |  279                                            InLoopFlag in_loop, | 
 |  280                                            RelocInfo::Mode mode, | 
|  265                                            Code::Kind kind); |  281                                            Code::Kind kind); | 
|  266  |  282  | 
|  267 #ifdef ENABLE_DEBUGGER_SUPPORT |  283 #ifdef ENABLE_DEBUGGER_SUPPORT | 
|  268   MUST_USE_RESULT MaybeObject* ComputeCallDebugBreak(int argc, Code::Kind kind); |  284   MUST_USE_RESULT MaybeObject* ComputeCallDebugBreak(int argc, Code::Kind kind); | 
|  269  |  285  | 
|  270   MUST_USE_RESULT MaybeObject* ComputeCallDebugPrepareStepIn(int argc, |  286   MUST_USE_RESULT MaybeObject* ComputeCallDebugPrepareStepIn(int argc, | 
|  271                                                              Code::Kind kind); |  287                                                              Code::Kind kind); | 
|  272 #endif |  288 #endif | 
|  273  |  289  | 
|  274   // Update cache for entry hash(name, map). |  290   // Update cache for entry hash(name, map). | 
| (...skipping 462 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  737                                                 int index, |  753                                                 int index, | 
|  738                                                 String* name); |  754                                                 String* name); | 
|  739   MUST_USE_RESULT MaybeObject* CompileCallConstant(Object* object, |  755   MUST_USE_RESULT MaybeObject* CompileCallConstant(Object* object, | 
|  740                                                    JSObject* holder, |  756                                                    JSObject* holder, | 
|  741                                                    JSFunction* function, |  757                                                    JSFunction* function, | 
|  742                                                    String* name, |  758                                                    String* name, | 
|  743                                                    CheckType check); |  759                                                    CheckType check); | 
|  744   MUST_USE_RESULT MaybeObject* CompileCallInterceptor(JSObject* object, |  760   MUST_USE_RESULT MaybeObject* CompileCallInterceptor(JSObject* object, | 
|  745                                                       JSObject* holder, |  761                                                       JSObject* holder, | 
|  746                                                       String* name); |  762                                                       String* name); | 
|  747   MUST_USE_RESULT MaybeObject* CompileCallGlobal(JSObject* object, |  763   MUST_USE_RESULT MaybeObject* CompileCallGlobal( | 
|  748                                                  GlobalObject* holder, |  764       JSObject* object, | 
|  749                                                  JSGlobalPropertyCell* cell, |  765       GlobalObject* holder, | 
|  750                                                  JSFunction* function, |  766       JSGlobalPropertyCell* cell, | 
|  751                                                  String* name); |  767       JSFunction* function, | 
 |  768       String* name, | 
 |  769       Code::ExtraICState extra_ic_state); | 
|  752  |  770  | 
|  753   static bool HasCustomCallGenerator(JSFunction* function); |  771   static bool HasCustomCallGenerator(JSFunction* function); | 
|  754  |  772  | 
|  755  private: |  773  private: | 
|  756   // Compiles a custom call constant/global IC. For constant calls |  774   // Compiles a custom call constant/global IC. For constant calls | 
|  757   // cell is NULL. Returns undefined if there is no custom call code |  775   // cell is NULL. Returns undefined if there is no custom call code | 
|  758   // for the given function or it can't be generated. |  776   // for the given function or it can't be generated. | 
|  759   MUST_USE_RESULT MaybeObject* CompileCustomCall(Object* object, |  777   MUST_USE_RESULT MaybeObject* CompileCustomCall(Object* object, | 
|  760                                                  JSObject* holder, |  778                                                  JSObject* holder, | 
|  761                                                  JSGlobalPropertyCell* cell, |  779                                                  JSGlobalPropertyCell* cell, | 
| (...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  897  private: |  915  private: | 
|  898   MaybeObject* GetCode(); |  916   MaybeObject* GetCode(); | 
|  899  |  917  | 
|  900   StrictModeFlag strict_mode_; |  918   StrictModeFlag strict_mode_; | 
|  901 }; |  919 }; | 
|  902  |  920  | 
|  903  |  921  | 
|  904 } }  // namespace v8::internal |  922 } }  // namespace v8::internal | 
|  905  |  923  | 
|  906 #endif  // V8_STUB_CACHE_H_ |  924 #endif  // V8_STUB_CACHE_H_ | 
| OLD | NEW |