Chromium Code Reviews

Side by Side Diff: src/arm/stub-cache-arm.cc

Issue 96083005: Remove Reloc::Mode CODE_TARGET_CONTEXT (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Fixed port error in ARM. Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | | Annotate | Revision Log
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 909 matching lines...)
920 } 920 }
921 921
922 GenerateFastApiDirectCall(masm, optimization, argc, true); 922 GenerateFastApiDirectCall(masm, optimization, argc, true);
923 } 923 }
924 924
925 925
926 class CallInterceptorCompiler BASE_EMBEDDED { 926 class CallInterceptorCompiler BASE_EMBEDDED {
927 public: 927 public:
928 CallInterceptorCompiler(CallStubCompiler* stub_compiler, 928 CallInterceptorCompiler(CallStubCompiler* stub_compiler,
929 const ParameterCount& arguments, 929 const ParameterCount& arguments,
930 Register name, 930 Register name)
931 ExtraICState extra_ic_state)
932 : stub_compiler_(stub_compiler), 931 : stub_compiler_(stub_compiler),
933 arguments_(arguments), 932 arguments_(arguments),
934 name_(name), 933 name_(name) {}
935 extra_ic_state_(extra_ic_state) {}
936 934
937 void Compile(MacroAssembler* masm, 935 void Compile(MacroAssembler* masm,
938 Handle<JSObject> object, 936 Handle<JSObject> object,
939 Handle<JSObject> holder, 937 Handle<JSObject> holder,
940 Handle<Name> name, 938 Handle<Name> name,
941 LookupResult* lookup, 939 LookupResult* lookup,
942 Register receiver, 940 Register receiver,
943 Register scratch1, 941 Register scratch1,
944 Register scratch2, 942 Register scratch2,
945 Register scratch3, 943 Register scratch3,
(...skipping 154 matching lines...)
1100 } 1098 }
1101 // If interceptor returns no-result sentinel, call the constant function. 1099 // If interceptor returns no-result sentinel, call the constant function.
1102 __ LoadRoot(scratch, Heap::kNoInterceptorResultSentinelRootIndex); 1100 __ LoadRoot(scratch, Heap::kNoInterceptorResultSentinelRootIndex);
1103 __ cmp(r0, scratch); 1101 __ cmp(r0, scratch);
1104 __ b(ne, interceptor_succeeded); 1102 __ b(ne, interceptor_succeeded);
1105 } 1103 }
1106 1104
1107 CallStubCompiler* stub_compiler_; 1105 CallStubCompiler* stub_compiler_;
1108 const ParameterCount& arguments_; 1106 const ParameterCount& arguments_;
1109 Register name_; 1107 Register name_;
1110 ExtraICState extra_ic_state_;
1111 }; 1108 };
1112 1109
1113 1110
1114 void StubCompiler::GenerateTailCall(MacroAssembler* masm, Handle<Code> code) { 1111 void StubCompiler::GenerateTailCall(MacroAssembler* masm, Handle<Code> code) {
1115 __ Jump(code, RelocInfo::CODE_TARGET); 1112 __ Jump(code, RelocInfo::CODE_TARGET);
1116 } 1113 }
1117 1114
1118 1115
1119 #undef __ 1116 #undef __
1120 #define __ ACCESS_MASM(masm()) 1117 #define __ ACCESS_MASM(masm())
(...skipping 1338 matching lines...)
2459 GenerateNameCheck(name, &miss); 2456 GenerateNameCheck(name, &miss);
2460 2457
2461 // Get the number of arguments. 2458 // Get the number of arguments.
2462 const int argc = arguments().immediate(); 2459 const int argc = arguments().immediate();
2463 LookupResult lookup(isolate()); 2460 LookupResult lookup(isolate());
2464 LookupPostInterceptor(holder, name, &lookup); 2461 LookupPostInterceptor(holder, name, &lookup);
2465 2462
2466 // Get the receiver from the stack. 2463 // Get the receiver from the stack.
2467 __ ldr(r1, MemOperand(sp, argc * kPointerSize)); 2464 __ ldr(r1, MemOperand(sp, argc * kPointerSize));
2468 2465
2469 CallInterceptorCompiler compiler(this, arguments(), r2, extra_state()); 2466 CallInterceptorCompiler compiler(this, arguments(), r2);
2470 compiler.Compile(masm(), object, holder, name, &lookup, r1, r3, r4, r0, 2467 compiler.Compile(masm(), object, holder, name, &lookup, r1, r3, r4, r0,
2471 &miss); 2468 &miss);
2472 2469
2473 // Move returned value, the function to call, to r1. 2470 // Move returned value, the function to call, to r1.
2474 __ mov(r1, r0); 2471 __ mov(r1, r0);
2475 // Restore receiver. 2472 // Restore receiver.
2476 __ ldr(r0, MemOperand(sp, argc * kPointerSize)); 2473 __ ldr(r0, MemOperand(sp, argc * kPointerSize));
2477 2474
2478 GenerateJumpFunction(object, r1, &miss); 2475 GenerateJumpFunction(object, r1, &miss);
2479 2476
(...skipping 411 matching lines...)
2891 // ----------------------------------- 2888 // -----------------------------------
2892 TailCallBuiltin(masm, Builtins::kKeyedLoadIC_Miss); 2889 TailCallBuiltin(masm, Builtins::kKeyedLoadIC_Miss);
2893 } 2890 }
2894 2891
2895 2892
2896 #undef __ 2893 #undef __
2897 2894
2898 } } // namespace v8::internal 2895 } } // namespace v8::internal
2899 2896
2900 #endif // V8_TARGET_ARCH_ARM 2897 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/arm/lithium-codegen-arm.cc ('k') | src/assembler.h » ('j') | src/objects.cc » ('J')

Powered by Google App Engine