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 661 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
672 // result will be converted to ASCII, otherwise it will be left as | 672 // result will be converted to ASCII, otherwise it will be left as |
673 // two-byte. | 673 // two-byte. |
674 // Returns Failure::RetryAfterGC(requested_bytes, space) if the allocation | 674 // Returns Failure::RetryAfterGC(requested_bytes, space) if the allocation |
675 // failed. | 675 // failed. |
676 // Please note this does not perform a garbage collection. | 676 // Please note this does not perform a garbage collection. |
677 MUST_USE_RESULT MaybeObject* AllocateStringFromAscii( | 677 MUST_USE_RESULT MaybeObject* AllocateStringFromAscii( |
678 Vector<const char> str, | 678 Vector<const char> str, |
679 PretenureFlag pretenure = NOT_TENURED); | 679 PretenureFlag pretenure = NOT_TENURED); |
680 MUST_USE_RESULT inline MaybeObject* AllocateStringFromUtf8( | 680 MUST_USE_RESULT inline MaybeObject* AllocateStringFromUtf8( |
681 Vector<const char> str, | 681 Vector<const char> str, |
682 PretenureFlag pretenure = NOT_TENURED, | 682 PretenureFlag pretenure = NOT_TENURED); |
683 String::AsciiHint ascii_hint = String::MAYBE_ASCII); | |
684 MUST_USE_RESULT MaybeObject* AllocateStringFromUtf8Slow( | 683 MUST_USE_RESULT MaybeObject* AllocateStringFromUtf8Slow( |
685 Vector<const char> str, | 684 Vector<const char> str, |
686 PretenureFlag pretenure = NOT_TENURED); | 685 PretenureFlag pretenure = NOT_TENURED); |
687 MUST_USE_RESULT inline MaybeObject* AllocateStringFromLatin1( | |
688 Vector<const char> str, | |
689 PretenureFlag pretenure = NOT_TENURED, | |
690 String::AsciiHint ascii_hint = String::MAYBE_ASCII); | |
691 MUST_USE_RESULT MaybeObject* AllocateStringFromLatin1Slow( | |
692 Vector<const char> str, | |
693 PretenureFlag pretenure = NOT_TENURED); | |
694 MUST_USE_RESULT MaybeObject* AllocateStringFromTwoByte( | 686 MUST_USE_RESULT MaybeObject* AllocateStringFromTwoByte( |
695 Vector<const uc16> str, | 687 Vector<const uc16> str, |
696 PretenureFlag pretenure = NOT_TENURED); | 688 PretenureFlag pretenure = NOT_TENURED); |
697 | 689 |
698 // Allocates a symbol in old space based on the character stream. | 690 // Allocates a symbol in old space based on the character stream. |
699 // Returns Failure::RetryAfterGC(requested_bytes, space) if the allocation | 691 // Returns Failure::RetryAfterGC(requested_bytes, space) if the allocation |
700 // failed. | 692 // failed. |
701 // Please note this function does not perform a garbage collection. | 693 // Please note this function does not perform a garbage collection. |
702 MUST_USE_RESULT inline MaybeObject* AllocateSymbol(Vector<const char> str, | 694 MUST_USE_RESULT inline MaybeObject* AllocateSymbol(Vector<const char> str, |
703 int chars, | 695 int chars, |
(...skipping 2096 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2800 AssertNoAllocation no_alloc; // i.e. no gc allowed. | 2792 AssertNoAllocation no_alloc; // i.e. no gc allowed. |
2801 | 2793 |
2802 private: | 2794 private: |
2803 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer); | 2795 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer); |
2804 }; | 2796 }; |
2805 #endif // DEBUG || LIVE_OBJECT_LIST | 2797 #endif // DEBUG || LIVE_OBJECT_LIST |
2806 | 2798 |
2807 } } // namespace v8::internal | 2799 } } // namespace v8::internal |
2808 | 2800 |
2809 #endif // V8_HEAP_H_ | 2801 #endif // V8_HEAP_H_ |
OLD | NEW |