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

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

Issue 47533002: Use nearlabel AFAP in lithium codegen (Closed) Base URL: git://github.com/v8/v8.git@master
Patch Set: fixed x64 assert fail Created 7 years, 1 month 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/ia32/macro-assembler-ia32.h ('k') | src/x64/code-stubs-x64.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 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 849 matching lines...) Expand 10 before | Expand all | Expand 10 after
860 push(scratch1); 860 push(scratch1);
861 fild_s(Operand(esp, 0)); 861 fild_s(Operand(esp, 0));
862 pop(scratch1); 862 pop(scratch1);
863 fstp_d(FieldOperand(elements, key, times_4, 863 fstp_d(FieldOperand(elements, key, times_4,
864 FixedDoubleArray::kHeaderSize - elements_offset)); 864 FixedDoubleArray::kHeaderSize - elements_offset));
865 } 865 }
866 bind(&done); 866 bind(&done);
867 } 867 }
868 868
869 869
870 void MacroAssembler::CompareMap(Register obj, 870 void MacroAssembler::CompareMap(Register obj, Handle<Map> map) {
871 Handle<Map> map,
872 Label* early_success) {
873 cmp(FieldOperand(obj, HeapObject::kMapOffset), map); 871 cmp(FieldOperand(obj, HeapObject::kMapOffset), map);
874 } 872 }
875 873
876 874
877 void MacroAssembler::CheckMap(Register obj, 875 void MacroAssembler::CheckMap(Register obj,
878 Handle<Map> map, 876 Handle<Map> map,
879 Label* fail, 877 Label* fail,
880 SmiCheckType smi_check_type) { 878 SmiCheckType smi_check_type) {
881 if (smi_check_type == DO_SMI_CHECK) { 879 if (smi_check_type == DO_SMI_CHECK) {
882 JumpIfSmi(obj, fail); 880 JumpIfSmi(obj, fail);
883 } 881 }
884 882
885 Label success; 883 CompareMap(obj, map);
886 CompareMap(obj, map, &success);
887 j(not_equal, fail); 884 j(not_equal, fail);
888 bind(&success);
889 } 885 }
890 886
891 887
892 void MacroAssembler::DispatchMap(Register obj, 888 void MacroAssembler::DispatchMap(Register obj,
893 Register unused, 889 Register unused,
894 Handle<Map> map, 890 Handle<Map> map,
895 Handle<Code> success, 891 Handle<Code> success,
896 SmiCheckType smi_check_type) { 892 SmiCheckType smi_check_type) {
897 Label fail; 893 Label fail;
898 if (smi_check_type == DO_SMI_CHECK) { 894 if (smi_check_type == DO_SMI_CHECK) {
(...skipping 2674 matching lines...) Expand 10 before | Expand all | Expand 10 after
3573 cmp(scratch1, Immediate(DICTIONARY_ELEMENTS)); 3569 cmp(scratch1, Immediate(DICTIONARY_ELEMENTS));
3574 j(equal, found); 3570 j(equal, found);
3575 mov(current, FieldOperand(current, Map::kPrototypeOffset)); 3571 mov(current, FieldOperand(current, Map::kPrototypeOffset));
3576 cmp(current, Immediate(factory->null_value())); 3572 cmp(current, Immediate(factory->null_value()));
3577 j(not_equal, &loop_again); 3573 j(not_equal, &loop_again);
3578 } 3574 }
3579 3575
3580 } } // namespace v8::internal 3576 } } // namespace v8::internal
3581 3577
3582 #endif // V8_TARGET_ARCH_IA32 3578 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/ia32/macro-assembler-ia32.h ('k') | src/x64/code-stubs-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698