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

Side by Side Diff: src/ia32/lithium-codegen-ia32.cc

Issue 6893156: Unified CallWrapper and PostCallGenerator classes, the former is a (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 9 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « src/ia32/assembler-ia32.cc ('k') | src/ia32/macro-assembler-ia32.h » ('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 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 22 matching lines...) Expand all
33 #include "code-stubs.h" 33 #include "code-stubs.h"
34 #include "deoptimizer.h" 34 #include "deoptimizer.h"
35 #include "stub-cache.h" 35 #include "stub-cache.h"
36 36
37 namespace v8 { 37 namespace v8 {
38 namespace internal { 38 namespace internal {
39 39
40 40
41 // When invoking builtins, we need to record the safepoint in the middle of 41 // When invoking builtins, we need to record the safepoint in the middle of
42 // the invoke instruction sequence generated by the macro assembler. 42 // the invoke instruction sequence generated by the macro assembler.
43 class SafepointGenerator : public PostCallGenerator { 43 class SafepointGenerator : public CallWrapper {
44 public: 44 public:
45 SafepointGenerator(LCodeGen* codegen, 45 SafepointGenerator(LCodeGen* codegen,
46 LPointerMap* pointers, 46 LPointerMap* pointers,
47 int deoptimization_index) 47 int deoptimization_index)
48 : codegen_(codegen), 48 : codegen_(codegen),
49 pointers_(pointers), 49 pointers_(pointers),
50 deoptimization_index_(deoptimization_index) {} 50 deoptimization_index_(deoptimization_index) {}
51 virtual ~SafepointGenerator() { } 51 virtual ~SafepointGenerator() { }
52 52
53 virtual void Generate() { 53 virtual void BeforeCall(int call_size) {}
54
55 virtual void AfterCall() {
54 codegen_->RecordSafepoint(pointers_, deoptimization_index_); 56 codegen_->RecordSafepoint(pointers_, deoptimization_index_);
55 } 57 }
56 58
57 private: 59 private:
58 LCodeGen* codegen_; 60 LCodeGen* codegen_;
59 LPointerMap* pointers_; 61 LPointerMap* pointers_;
60 int deoptimization_index_; 62 int deoptimization_index_;
61 }; 63 };
62 64
63 65
(...skipping 4233 matching lines...) Expand 10 before | Expand all | Expand 10 after
4297 __ mov(esi, Operand(ebp, StandardFrameConstants::kContextOffset)); 4299 __ mov(esi, Operand(ebp, StandardFrameConstants::kContextOffset));
4298 __ InvokeBuiltin(Builtins::IN, CALL_FUNCTION, &safepoint_generator); 4300 __ InvokeBuiltin(Builtins::IN, CALL_FUNCTION, &safepoint_generator);
4299 } 4301 }
4300 4302
4301 4303
4302 #undef __ 4304 #undef __
4303 4305
4304 } } // namespace v8::internal 4306 } } // namespace v8::internal
4305 4307
4306 #endif // V8_TARGET_ARCH_IA32 4308 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/ia32/assembler-ia32.cc ('k') | src/ia32/macro-assembler-ia32.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698