| OLD | NEW |
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 45 | 45 |
| 46 private: | 46 private: |
| 47 GVNFlagSet CollectSideEffectsOnPathsToDominatedBlock( | 47 GVNFlagSet CollectSideEffectsOnPathsToDominatedBlock( |
| 48 HBasicBlock* dominator, | 48 HBasicBlock* dominator, |
| 49 HBasicBlock* dominated); | 49 HBasicBlock* dominated); |
| 50 void AnalyzeGraph(); | 50 void AnalyzeGraph(); |
| 51 void ComputeBlockSideEffects(); | 51 void ComputeBlockSideEffects(); |
| 52 void LoopInvariantCodeMotion(); | 52 void LoopInvariantCodeMotion(); |
| 53 void ProcessLoopBlock(HBasicBlock* block, | 53 void ProcessLoopBlock(HBasicBlock* block, |
| 54 HBasicBlock* before_loop, | 54 HBasicBlock* before_loop, |
| 55 GVNFlagSet loop_kills, | 55 GVNFlagSet loop_kills); |
| 56 GVNFlagSet* accumulated_first_time_depends, | |
| 57 GVNFlagSet* accumulated_first_time_changes); | |
| 58 bool AllowCodeMotion(); | 56 bool AllowCodeMotion(); |
| 59 bool ShouldMove(HInstruction* instr, HBasicBlock* loop_header); | 57 bool ShouldMove(HInstruction* instr, HBasicBlock* loop_header); |
| 60 | 58 |
| 61 bool removed_side_effects_; | 59 bool removed_side_effects_; |
| 62 | 60 |
| 63 // A map of block IDs to their side effects. | 61 // A map of block IDs to their side effects. |
| 64 ZoneList<GVNFlagSet> block_side_effects_; | 62 ZoneList<GVNFlagSet> block_side_effects_; |
| 65 | 63 |
| 66 // A map of loop header block IDs to their loop's side effects. | 64 // A map of loop header block IDs to their loop's side effects. |
| 67 ZoneList<GVNFlagSet> loop_side_effects_; | 65 ZoneList<GVNFlagSet> loop_side_effects_; |
| 68 | 66 |
| 69 // Used when collecting side effects on paths from dominator to | 67 // Used when collecting side effects on paths from dominator to |
| 70 // dominated. | 68 // dominated. |
| 71 BitVector visited_on_paths_; | 69 BitVector visited_on_paths_; |
| 72 | 70 |
| 73 DISALLOW_COPY_AND_ASSIGN(HGlobalValueNumberingPhase); | 71 DISALLOW_COPY_AND_ASSIGN(HGlobalValueNumberingPhase); |
| 74 }; | 72 }; |
| 75 | 73 |
| 76 | 74 |
| 77 } } // namespace v8::internal | 75 } } // namespace v8::internal |
| 78 | 76 |
| 79 #endif // V8_HYDROGEN_GVN_H_ | 77 #endif // V8_HYDROGEN_GVN_H_ |
| OLD | NEW |