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 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
58 // Return the pointer to the allocated already tagged as a heap object. | 58 // Return the pointer to the allocated already tagged as a heap object. |
59 TAG_OBJECT = 1 << 0, | 59 TAG_OBJECT = 1 << 0, |
60 // The content of the result register already contains the allocation top in | 60 // The content of the result register already contains the allocation top in |
61 // new space. | 61 // new space. |
62 RESULT_CONTAINS_TOP = 1 << 1, | 62 RESULT_CONTAINS_TOP = 1 << 1, |
63 // Specify that the requested size of the space to allocate is specified in | 63 // Specify that the requested size of the space to allocate is specified in |
64 // words instead of bytes. | 64 // words instead of bytes. |
65 SIZE_IN_WORDS = 1 << 2 | 65 SIZE_IN_WORDS = 1 << 2 |
66 }; | 66 }; |
67 | 67 |
| 68 // Flags used for AllocateHeapNumber |
| 69 enum TaggingMode { |
| 70 // Tag the result. |
| 71 TAG_RESULT, |
| 72 // Don't tag |
| 73 DONT_TAG_RESULT |
| 74 }; |
| 75 |
68 // Flags used for the ObjectToDoubleFPURegister function. | 76 // Flags used for the ObjectToDoubleFPURegister function. |
69 enum ObjectToDoubleFlags { | 77 enum ObjectToDoubleFlags { |
70 // No special flags. | 78 // No special flags. |
71 NO_OBJECT_TO_DOUBLE_FLAGS = 0, | 79 NO_OBJECT_TO_DOUBLE_FLAGS = 0, |
72 // Object is known to be a non smi. | 80 // Object is known to be a non smi. |
73 OBJECT_NOT_SMI = 1 << 0, | 81 OBJECT_NOT_SMI = 1 << 0, |
74 // Don't load NaNs or infinities, branch to the non number case instead. | 82 // Don't load NaNs or infinities, branch to the non number case instead. |
75 AVOID_NANS_AND_INFINITIES = 1 << 1 | 83 AVOID_NANS_AND_INFINITIES = 1 << 1 |
76 }; | 84 }; |
77 | 85 |
(...skipping 451 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
529 Register scratch2, | 537 Register scratch2, |
530 Label* gc_required); | 538 Label* gc_required); |
531 | 539 |
532 // Allocates a heap number or jumps to the gc_required label if the young | 540 // Allocates a heap number or jumps to the gc_required label if the young |
533 // space is full and a scavenge is needed. All registers are clobbered also | 541 // space is full and a scavenge is needed. All registers are clobbered also |
534 // when control continues at the gc_required label. | 542 // when control continues at the gc_required label. |
535 void AllocateHeapNumber(Register result, | 543 void AllocateHeapNumber(Register result, |
536 Register scratch1, | 544 Register scratch1, |
537 Register scratch2, | 545 Register scratch2, |
538 Register heap_number_map, | 546 Register heap_number_map, |
539 Label* gc_required); | 547 Label* gc_required, |
| 548 TaggingMode tagging_mode = TAG_RESULT); |
540 void AllocateHeapNumberWithValue(Register result, | 549 void AllocateHeapNumberWithValue(Register result, |
541 FPURegister value, | 550 FPURegister value, |
542 Register scratch1, | 551 Register scratch1, |
543 Register scratch2, | 552 Register scratch2, |
544 Label* gc_required); | 553 Label* gc_required); |
545 | 554 |
546 // --------------------------------------------------------------------------- | 555 // --------------------------------------------------------------------------- |
547 // Instruction macros. | 556 // Instruction macros. |
548 | 557 |
549 #define DEFINE_INSTRUCTION(instr) \ | 558 #define DEFINE_INSTRUCTION(instr) \ |
(...skipping 995 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1545 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x) | 1554 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x) |
1546 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) | 1555 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) |
1547 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> | 1556 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> |
1548 #else | 1557 #else |
1549 #define ACCESS_MASM(masm) masm-> | 1558 #define ACCESS_MASM(masm) masm-> |
1550 #endif | 1559 #endif |
1551 | 1560 |
1552 } } // namespace v8::internal | 1561 } } // namespace v8::internal |
1553 | 1562 |
1554 #endif // V8_MIPS_MACRO_ASSEMBLER_MIPS_H_ | 1563 #endif // V8_MIPS_MACRO_ASSEMBLER_MIPS_H_ |
OLD | NEW |