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

Side by Side Diff: src/arm64/macro-assembler-arm64.h

Issue 2732273003: Disentangle assembler from isolate. (Closed)
Patch Set: Address feedback. Created 3 years, 9 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/arm64/instructions-arm64.cc ('k') | src/arm64/macro-assembler-arm64.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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_ARM64_MACRO_ASSEMBLER_ARM64_H_ 5 #ifndef V8_ARM64_MACRO_ASSEMBLER_ARM64_H_
6 #define V8_ARM64_MACRO_ASSEMBLER_ARM64_H_ 6 #define V8_ARM64_MACRO_ASSEMBLER_ARM64_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "src/arm64/assembler-arm64.h" 10 #include "src/arm64/assembler-arm64.h"
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after
160 enum ArrayHasHoles { kArrayCantHaveHoles, kArrayCanHaveHoles }; 160 enum ArrayHasHoles { kArrayCantHaveHoles, kArrayCanHaveHoles };
161 enum CopyHint { kCopyUnknown, kCopyShort, kCopyLong }; 161 enum CopyHint { kCopyUnknown, kCopyShort, kCopyLong };
162 enum DiscardMoveMode { kDontDiscardForSameWReg, kDiscardForSameWReg }; 162 enum DiscardMoveMode { kDontDiscardForSameWReg, kDiscardForSameWReg };
163 enum SeqStringSetCharCheckIndexType { kIndexIsSmi, kIndexIsInteger32 }; 163 enum SeqStringSetCharCheckIndexType { kIndexIsSmi, kIndexIsInteger32 };
164 164
165 class MacroAssembler : public Assembler { 165 class MacroAssembler : public Assembler {
166 public: 166 public:
167 MacroAssembler(Isolate* isolate, byte* buffer, unsigned buffer_size, 167 MacroAssembler(Isolate* isolate, byte* buffer, unsigned buffer_size,
168 CodeObjectRequired create_code_object); 168 CodeObjectRequired create_code_object);
169 169
170 Isolate* isolate() const { return isolate_; }
171
170 Handle<Object> CodeObject() { 172 Handle<Object> CodeObject() {
171 DCHECK(!code_object_.is_null()); 173 DCHECK(!code_object_.is_null());
172 return code_object_; 174 return code_object_;
173 } 175 }
174 176
175 // Instruction set functions ------------------------------------------------ 177 // Instruction set functions ------------------------------------------------
176 // Logical macros. 178 // Logical macros.
177 inline void And(const Register& rd, 179 inline void And(const Register& rd,
178 const Register& rn, 180 const Register& rn,
179 const Operand& operand); 181 const Operand& operand);
(...skipping 1769 matching lines...) Expand 10 before | Expand all | Expand 10 after
1949 Label* on_failed_conversion = NULL); 1951 Label* on_failed_conversion = NULL);
1950 1952
1951 bool generating_stub_; 1953 bool generating_stub_;
1952 #if DEBUG 1954 #if DEBUG
1953 // Tell whether any of the macro instruction can be used. When false the 1955 // Tell whether any of the macro instruction can be used. When false the
1954 // MacroAssembler will assert if a method which can emit a variable number 1956 // MacroAssembler will assert if a method which can emit a variable number
1955 // of instructions is called. 1957 // of instructions is called.
1956 bool allow_macro_instructions_; 1958 bool allow_macro_instructions_;
1957 #endif 1959 #endif
1958 bool has_frame_; 1960 bool has_frame_;
1961 Isolate* isolate_;
1959 1962
1960 // The Abort method should call a V8 runtime function, but the CallRuntime 1963 // The Abort method should call a V8 runtime function, but the CallRuntime
1961 // mechanism depends on CEntryStub. If use_real_aborts is false, Abort will 1964 // mechanism depends on CEntryStub. If use_real_aborts is false, Abort will
1962 // use a simpler abort mechanism that doesn't depend on CEntryStub. 1965 // use a simpler abort mechanism that doesn't depend on CEntryStub.
1963 // 1966 //
1964 // The purpose of this is to allow Aborts to be compiled whilst CEntryStub is 1967 // The purpose of this is to allow Aborts to be compiled whilst CEntryStub is
1965 // being generated. 1968 // being generated.
1966 bool use_real_aborts_; 1969 bool use_real_aborts_;
1967 1970
1968 // This handle will be patched with the code object on installation. 1971 // This handle will be patched with the code object on installation.
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after
2150 class RegisterBits : public BitField<unsigned, 0, 5> {}; 2153 class RegisterBits : public BitField<unsigned, 0, 5> {};
2151 class DeltaBits : public BitField<uint32_t, 5, 32-5> {}; 2154 class DeltaBits : public BitField<uint32_t, 5, 32-5> {};
2152 }; 2155 };
2153 2156
2154 } // namespace internal 2157 } // namespace internal
2155 } // namespace v8 2158 } // namespace v8
2156 2159
2157 #define ACCESS_MASM(masm) masm-> 2160 #define ACCESS_MASM(masm) masm->
2158 2161
2159 #endif // V8_ARM64_MACRO_ASSEMBLER_ARM64_H_ 2162 #endif // V8_ARM64_MACRO_ASSEMBLER_ARM64_H_
OLDNEW
« no previous file with comments | « src/arm64/instructions-arm64.cc ('k') | src/arm64/macro-assembler-arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698