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 841 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
852 } else if (FLAG_track_heap_object_fields && representation.IsHeapObject()) { | 852 } else if (FLAG_track_heap_object_fields && representation.IsHeapObject()) { |
853 __ JumpIfSmi(value_reg, miss_label); | 853 __ JumpIfSmi(value_reg, miss_label); |
854 } else if (FLAG_track_double_fields && representation.IsDouble()) { | 854 } else if (FLAG_track_double_fields && representation.IsDouble()) { |
855 Label do_store, heap_number; | 855 Label do_store, heap_number; |
856 __ AllocateHeapNumber(storage_reg, scratch1, scratch2, slow); | 856 __ AllocateHeapNumber(storage_reg, scratch1, scratch2, slow); |
857 | 857 |
858 __ JumpIfNotSmi(value_reg, &heap_number); | 858 __ JumpIfNotSmi(value_reg, &heap_number); |
859 __ SmiUntag(value_reg); | 859 __ SmiUntag(value_reg); |
860 if (CpuFeatures::IsSupported(SSE2)) { | 860 if (CpuFeatures::IsSupported(SSE2)) { |
861 CpuFeatureScope use_sse2(masm, SSE2); | 861 CpuFeatureScope use_sse2(masm, SSE2); |
862 __ cvtsi2sd(xmm0, value_reg); | 862 __ Cvtsi2sd(xmm0, value_reg); |
863 } else { | 863 } else { |
864 __ push(value_reg); | 864 __ push(value_reg); |
865 __ fild_s(Operand(esp, 0)); | 865 __ fild_s(Operand(esp, 0)); |
866 __ pop(value_reg); | 866 __ pop(value_reg); |
867 } | 867 } |
868 __ SmiTag(value_reg); | 868 __ SmiTag(value_reg); |
869 __ jmp(&do_store); | 869 __ jmp(&do_store); |
870 | 870 |
871 __ bind(&heap_number); | 871 __ bind(&heap_number); |
872 __ CheckMap(value_reg, masm->isolate()->factory()->heap_number_map(), | 872 __ CheckMap(value_reg, masm->isolate()->factory()->heap_number_map(), |
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1031 int offset = index * kPointerSize + FixedArray::kHeaderSize; | 1031 int offset = index * kPointerSize + FixedArray::kHeaderSize; |
1032 __ mov(scratch1, FieldOperand(scratch1, offset)); | 1032 __ mov(scratch1, FieldOperand(scratch1, offset)); |
1033 } | 1033 } |
1034 | 1034 |
1035 // Store the value into the storage. | 1035 // Store the value into the storage. |
1036 Label do_store, heap_number; | 1036 Label do_store, heap_number; |
1037 __ JumpIfNotSmi(value_reg, &heap_number); | 1037 __ JumpIfNotSmi(value_reg, &heap_number); |
1038 __ SmiUntag(value_reg); | 1038 __ SmiUntag(value_reg); |
1039 if (CpuFeatures::IsSupported(SSE2)) { | 1039 if (CpuFeatures::IsSupported(SSE2)) { |
1040 CpuFeatureScope use_sse2(masm, SSE2); | 1040 CpuFeatureScope use_sse2(masm, SSE2); |
1041 __ cvtsi2sd(xmm0, value_reg); | 1041 __ Cvtsi2sd(xmm0, value_reg); |
1042 } else { | 1042 } else { |
1043 __ push(value_reg); | 1043 __ push(value_reg); |
1044 __ fild_s(Operand(esp, 0)); | 1044 __ fild_s(Operand(esp, 0)); |
1045 __ pop(value_reg); | 1045 __ pop(value_reg); |
1046 } | 1046 } |
1047 __ SmiTag(value_reg); | 1047 __ SmiTag(value_reg); |
1048 __ jmp(&do_store); | 1048 __ jmp(&do_store); |
1049 __ bind(&heap_number); | 1049 __ bind(&heap_number); |
1050 __ CheckMap(value_reg, masm->isolate()->factory()->heap_number_map(), | 1050 __ CheckMap(value_reg, masm->isolate()->factory()->heap_number_map(), |
1051 miss_label, DONT_DO_SMI_CHECK); | 1051 miss_label, DONT_DO_SMI_CHECK); |
(...skipping 2206 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3258 // ----------------------------------- | 3258 // ----------------------------------- |
3259 TailCallBuiltin(masm, Builtins::kKeyedLoadIC_MissForceGeneric); | 3259 TailCallBuiltin(masm, Builtins::kKeyedLoadIC_MissForceGeneric); |
3260 } | 3260 } |
3261 | 3261 |
3262 | 3262 |
3263 #undef __ | 3263 #undef __ |
3264 | 3264 |
3265 } } // namespace v8::internal | 3265 } } // namespace v8::internal |
3266 | 3266 |
3267 #endif // V8_TARGET_ARCH_IA32 | 3267 #endif // V8_TARGET_ARCH_IA32 |
OLD | NEW |