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

Side by Side Diff: src/ia32/ic-ia32.cc

Issue 6334015: Support StringLength in hydrogen (similar to ArrayLength). (Closed)
Patch Set: Created 9 years, 11 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/hydrogen.cc ('k') | src/ia32/stub-cache-ia32.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 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 370 matching lines...) Expand 10 before | Expand all | Expand 10 after
381 // -- esp[0] : return address 381 // -- esp[0] : return address
382 // ----------------------------------- 382 // -----------------------------------
383 Label miss; 383 Label miss;
384 384
385 StubCompiler::GenerateLoadArrayLength(masm, eax, edx, &miss); 385 StubCompiler::GenerateLoadArrayLength(masm, eax, edx, &miss);
386 __ bind(&miss); 386 __ bind(&miss);
387 StubCompiler::GenerateLoadMiss(masm, Code::LOAD_IC); 387 StubCompiler::GenerateLoadMiss(masm, Code::LOAD_IC);
388 } 388 }
389 389
390 390
391 void LoadIC::GenerateStringLength(MacroAssembler* masm) { 391 void LoadIC::GenerateStringLength(MacroAssembler* masm,
392 bool support_wrappers) {
392 // ----------- S t a t e ------------- 393 // ----------- S t a t e -------------
393 // -- eax : receiver 394 // -- eax : receiver
394 // -- ecx : name 395 // -- ecx : name
395 // -- esp[0] : return address 396 // -- esp[0] : return address
396 // ----------------------------------- 397 // -----------------------------------
397 Label miss; 398 Label miss;
398 399
399 StubCompiler::GenerateLoadStringLength(masm, eax, edx, ebx, &miss); 400 StubCompiler::GenerateLoadStringLength(masm, eax, edx, ebx, &miss,
401 support_wrappers);
400 __ bind(&miss); 402 __ bind(&miss);
401 StubCompiler::GenerateLoadMiss(masm, Code::LOAD_IC); 403 StubCompiler::GenerateLoadMiss(masm, Code::LOAD_IC);
402 } 404 }
403 405
404 406
405 void LoadIC::GenerateFunctionPrototype(MacroAssembler* masm) { 407 void LoadIC::GenerateFunctionPrototype(MacroAssembler* masm) {
406 // ----------- S t a t e ------------- 408 // ----------- S t a t e -------------
407 // -- eax : receiver 409 // -- eax : receiver
408 // -- ecx : name 410 // -- ecx : name
409 // -- esp[0] : return address 411 // -- esp[0] : return address
(...skipping 1361 matching lines...) Expand 10 before | Expand all | Expand 10 after
1771 Condition cc = *jmp_address == Assembler::kJncShortOpcode 1773 Condition cc = *jmp_address == Assembler::kJncShortOpcode
1772 ? not_zero 1774 ? not_zero
1773 : zero; 1775 : zero;
1774 *jmp_address = static_cast<byte>(Assembler::kJccShortPrefix | cc); 1776 *jmp_address = static_cast<byte>(Assembler::kJccShortPrefix | cc);
1775 } 1777 }
1776 1778
1777 1779
1778 } } // namespace v8::internal 1780 } } // namespace v8::internal
1779 1781
1780 #endif // V8_TARGET_ARCH_IA32 1782 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/hydrogen.cc ('k') | src/ia32/stub-cache-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698