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

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

Issue 42008: Introduce a BreakTarget subclass of JumpTarget used to represent the... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 11 years, 9 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/ast.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 409 matching lines...) Expand 10 before | Expand all | Expand 10 after
420 bool TryGenerateFastCaseSwitchStatement(SwitchStatement* node); 420 bool TryGenerateFastCaseSwitchStatement(SwitchStatement* node);
421 421
422 422
423 // Methods used to indicate which source code is generated for. Source 423 // Methods used to indicate which source code is generated for. Source
424 // positions are collected by the assembler and emitted with the relocation 424 // positions are collected by the assembler and emitted with the relocation
425 // information. 425 // information.
426 void CodeForFunctionPosition(FunctionLiteral* fun); 426 void CodeForFunctionPosition(FunctionLiteral* fun);
427 void CodeForStatementPosition(Node* node); 427 void CodeForStatementPosition(Node* node);
428 void CodeForSourcePosition(int pos); 428 void CodeForSourcePosition(int pos);
429 429
430 // Is the given jump target the actual (ie, non-shadowed) function return
431 // target?
432 bool IsActualFunctionReturn(JumpTarget* target);
433
434 #ifdef DEBUG 430 #ifdef DEBUG
435 // True if the registers are valid for entry to a block. 431 // True if the registers are valid for entry to a block.
436 bool HasValidEntryRegisters(); 432 bool HasValidEntryRegisters();
437 #endif 433 #endif
438 434
439 bool is_eval_; // Tells whether code is generated for eval. 435 bool is_eval_; // Tells whether code is generated for eval.
440 436
441 Handle<Script> script_; 437 Handle<Script> script_;
442 List<DeferredCode*> deferred_; 438 List<DeferredCode*> deferred_;
443 439
444 // Assembler 440 // Assembler
445 MacroAssembler* masm_; // to generate code 441 MacroAssembler* masm_; // to generate code
446 442
447 // Code generation state 443 // Code generation state
448 Scope* scope_; 444 Scope* scope_;
449 VirtualFrame* frame_; 445 VirtualFrame* frame_;
450 RegisterAllocator* allocator_; 446 RegisterAllocator* allocator_;
451 Condition cc_reg_; 447 Condition cc_reg_;
452 CodeGenState* state_; 448 CodeGenState* state_;
453 int break_stack_height_; 449 int break_stack_height_;
454 450
455 // Jump targets 451 // Jump targets
456 JumpTarget function_return_; 452 BreakTarget function_return_;
457 453
458 // True if the function return is shadowed (ie, jumping to the target 454 // True if the function return is shadowed (ie, jumping to the target
459 // function_return_ does not jump to the true function return, but rather 455 // function_return_ does not jump to the true function return, but rather
460 // to some unlinking code). 456 // to some unlinking code).
461 bool function_return_is_shadowed_; 457 bool function_return_is_shadowed_;
462 458
463 // True when we are in code that expects the virtual frame to be fully 459 // True when we are in code that expects the virtual frame to be fully
464 // spilled. Some virtual frame function are disabled in DEBUG builds when 460 // spilled. Some virtual frame function are disabled in DEBUG builds when
465 // called from spilled code, because they do not leave the virtual frame 461 // called from spilled code, because they do not leave the virtual frame
466 // in a spilled state. 462 // in a spilled state.
(...skipping 12 matching lines...) Expand all
479 cgen_->set_in_spilled_code(false); 475 cgen_->set_in_spilled_code(false);
480 GetValue(typeof_state); 476 GetValue(typeof_state);
481 cgen_->frame()->SpillAll(); 477 cgen_->frame()->SpillAll();
482 cgen_->set_in_spilled_code(true); 478 cgen_->set_in_spilled_code(true);
483 } 479 }
484 480
485 481
486 } } // namespace v8::internal 482 } } // namespace v8::internal
487 483
488 #endif // V8_CODEGEN_ARM_H_ 484 #endif // V8_CODEGEN_ARM_H_
OLDNEW
« no previous file with comments | « src/ast.cc ('k') | src/codegen-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698