Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(521)

Side by Side Diff: src/codegen-arm.h

Issue 17203: Periodic merge from bleeding_edge to experimental code generator... (Closed) Base URL: http://v8.googlecode.com/svn/branches/experimental/toiger/
Patch Set: Created 11 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/codegen.cc ('k') | src/codegen-arm.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. 1 // Copyright 2006-2008 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 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 // CodeGenerator 137 // CodeGenerator
138 138
139 class CodeGenerator: public AstVisitor { 139 class CodeGenerator: public AstVisitor {
140 public: 140 public:
141 // Takes a function literal, generates code for it. This function should only 141 // Takes a function literal, generates code for it. This function should only
142 // be called by compiler.cc. 142 // be called by compiler.cc.
143 static Handle<Code> MakeCode(FunctionLiteral* fun, 143 static Handle<Code> MakeCode(FunctionLiteral* fun,
144 Handle<Script> script, 144 Handle<Script> script,
145 bool is_eval); 145 bool is_eval);
146 146
147 static bool ShouldGenerateLog(Expression* type);
148
147 static void SetFunctionInfo(Handle<JSFunction> fun, 149 static void SetFunctionInfo(Handle<JSFunction> fun,
148 int length, 150 int length,
149 int function_token_position, 151 int function_token_position,
150 int start_position, 152 int start_position,
151 int end_position, 153 int end_position,
152 bool is_expression, 154 bool is_expression,
153 bool is_toplevel, 155 bool is_toplevel,
154 Handle<Script> script); 156 Handle<Script> script);
155 157
156 // Accessors 158 // Accessors
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
275 // Support for accessing the value field of an object (used by Date). 277 // Support for accessing the value field of an object (used by Date).
276 void GenerateValueOf(ZoneList<Expression*>* args); 278 void GenerateValueOf(ZoneList<Expression*>* args);
277 void GenerateSetValueOf(ZoneList<Expression*>* args); 279 void GenerateSetValueOf(ZoneList<Expression*>* args);
278 280
279 // Fast support for charCodeAt(n). 281 // Fast support for charCodeAt(n).
280 void GenerateFastCharCodeAt(ZoneList<Expression*>* args); 282 void GenerateFastCharCodeAt(ZoneList<Expression*>* args);
281 283
282 // Fast support for object equality testing. 284 // Fast support for object equality testing.
283 void GenerateObjectEquals(ZoneList<Expression*>* args); 285 void GenerateObjectEquals(ZoneList<Expression*>* args);
284 286
287 void GenerateLog(ZoneList<Expression*>* args);
288
285 // Methods and constants for fast case switch statement support. 289 // Methods and constants for fast case switch statement support.
286 // 290 //
287 // Only allow fast-case switch if the range of labels is at most 291 // Only allow fast-case switch if the range of labels is at most
288 // this factor times the number of case labels. 292 // this factor times the number of case labels.
289 // Value is derived from comparing the size of code generated by the normal 293 // Value is derived from comparing the size of code generated by the normal
290 // switch code for Smi-labels to the size of a single pointer. If code 294 // switch code for Smi-labels to the size of a single pointer. If code
291 // quality increases this number should be decreased to match. 295 // quality increases this number should be decreased to match.
292 static const int kFastSwitchMaxOverheadFactor = 10; 296 static const int kFastSwitchMaxOverheadFactor = 10;
293 297
294 // Minimal number of switch cases required before we allow jump-table 298 // Minimal number of switch cases required before we allow jump-table
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
371 friend class VirtualFrame; 375 friend class VirtualFrame;
372 friend class JumpTarget; 376 friend class JumpTarget;
373 friend class Reference; 377 friend class Reference;
374 378
375 DISALLOW_COPY_AND_ASSIGN(CodeGenerator); 379 DISALLOW_COPY_AND_ASSIGN(CodeGenerator);
376 }; 380 };
377 381
378 } } // namespace v8::internal 382 } } // namespace v8::internal
379 383
380 #endif // V8_CODEGEN_ARM_H_ 384 #endif // V8_CODEGEN_ARM_H_
OLDNEW
« no previous file with comments | « src/codegen.cc ('k') | src/codegen-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698