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

Side by Side Diff: src/mips/macro-assembler-mips.cc

Issue 7835025: MIPS: port Generated code for substring slices in x64 and arm. (Closed)
Patch Set: Created 9 years, 3 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
« no previous file with comments | « src/mips/macro-assembler-mips.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 2797 matching lines...) Expand 10 before | Expand all | Expand 10 after
2808 gc_required, 2808 gc_required,
2809 TAG_OBJECT); 2809 TAG_OBJECT);
2810 InitializeNewString(result, 2810 InitializeNewString(result,
2811 length, 2811 length,
2812 Heap::kConsAsciiStringMapRootIndex, 2812 Heap::kConsAsciiStringMapRootIndex,
2813 scratch1, 2813 scratch1,
2814 scratch2); 2814 scratch2);
2815 } 2815 }
2816 2816
2817 2817
2818 void MacroAssembler::AllocateTwoByteSlicedString(Register result,
2819 Register length,
2820 Register scratch1,
2821 Register scratch2,
2822 Label* gc_required) {
2823 AllocateInNewSpace(SlicedString::kSize,
2824 result,
2825 scratch1,
2826 scratch2,
2827 gc_required,
2828 TAG_OBJECT);
2829
2830 InitializeNewString(result,
2831 length,
2832 Heap::kSlicedStringMapRootIndex,
2833 scratch1,
2834 scratch2);
2835 }
2836
2837
2838 void MacroAssembler::AllocateAsciiSlicedString(Register result,
2839 Register length,
2840 Register scratch1,
2841 Register scratch2,
2842 Label* gc_required) {
2843 AllocateInNewSpace(SlicedString::kSize,
2844 result,
2845 scratch1,
2846 scratch2,
2847 gc_required,
2848 TAG_OBJECT);
2849
2850 InitializeNewString(result,
2851 length,
2852 Heap::kSlicedAsciiStringMapRootIndex,
2853 scratch1,
2854 scratch2);
2855 }
2856
2857
2818 // Allocates a heap number or jumps to the label if the young space is full and 2858 // Allocates a heap number or jumps to the label if the young space is full and
2819 // a scavenge is needed. 2859 // a scavenge is needed.
2820 void MacroAssembler::AllocateHeapNumber(Register result, 2860 void MacroAssembler::AllocateHeapNumber(Register result,
2821 Register scratch1, 2861 Register scratch1,
2822 Register scratch2, 2862 Register scratch2,
2823 Register heap_number_map, 2863 Register heap_number_map,
2824 Label* need_gc) { 2864 Label* need_gc) {
2825 // Allocate an object in the heap for the heap number and tag it as a heap 2865 // Allocate an object in the heap for the heap number and tag it as a heap
2826 // object. 2866 // object.
2827 AllocateInNewSpace(HeapNumber::kSize, 2867 AllocateInNewSpace(HeapNumber::kSize,
(...skipping 1539 matching lines...) Expand 10 before | Expand all | Expand 10 after
4367 opcode == BGTZL); 4407 opcode == BGTZL);
4368 opcode = (cond == eq) ? BEQ : BNE; 4408 opcode = (cond == eq) ? BEQ : BNE;
4369 instr = (instr & ~kOpcodeMask) | opcode; 4409 instr = (instr & ~kOpcodeMask) | opcode;
4370 masm_.emit(instr); 4410 masm_.emit(instr);
4371 } 4411 }
4372 4412
4373 4413
4374 } } // namespace v8::internal 4414 } } // namespace v8::internal
4375 4415
4376 #endif // V8_TARGET_ARCH_MIPS 4416 #endif // V8_TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « src/mips/macro-assembler-mips.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698