OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 1547 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1558 | 1558 |
1559 // Emit an address directly. | 1559 // Emit an address directly. |
1560 void Emit(Address addr); | 1560 void Emit(Address addr); |
1561 | 1561 |
1562 // Change the condition part of an instruction leaving the rest of the current | 1562 // Change the condition part of an instruction leaving the rest of the current |
1563 // instruction unchanged. | 1563 // instruction unchanged. |
1564 void ChangeBranchCondition(Condition cond); | 1564 void ChangeBranchCondition(Condition cond); |
1565 | 1565 |
1566 private: | 1566 private: |
1567 byte* address_; // The address of the code being patched. | 1567 byte* address_; // The address of the code being patched. |
1568 int instructions_; // Number of instructions of the expected patch size. | |
1569 int size_; // Number of bytes of the expected patch size. | 1568 int size_; // Number of bytes of the expected patch size. |
1570 MacroAssembler masm_; // Macro assembler used to generate the code. | 1569 MacroAssembler masm_; // Macro assembler used to generate the code. |
1571 }; | 1570 }; |
1572 | 1571 |
1573 | 1572 |
1574 | 1573 |
1575 #ifdef GENERATED_CODE_COVERAGE | 1574 #ifdef GENERATED_CODE_COVERAGE |
1576 #define CODE_COVERAGE_STRINGIFY(x) #x | 1575 #define CODE_COVERAGE_STRINGIFY(x) #x |
1577 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x) | 1576 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x) |
1578 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) | 1577 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) |
1579 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> | 1578 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> |
1580 #else | 1579 #else |
1581 #define ACCESS_MASM(masm) masm-> | 1580 #define ACCESS_MASM(masm) masm-> |
1582 #endif | 1581 #endif |
1583 | 1582 |
1584 } } // namespace v8::internal | 1583 } } // namespace v8::internal |
1585 | 1584 |
1586 #endif // V8_MIPS_MACRO_ASSEMBLER_MIPS_H_ | 1585 #endif // V8_MIPS_MACRO_ASSEMBLER_MIPS_H_ |
OLD | NEW |