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

Side by Side Diff: runtime/vm/intermediate_language.h

Issue 10938011: Delete code for the now unused IL instruction NumberNegate. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 3 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 | « runtime/vm/flow_graph_compiler_x64.cc ('k') | runtime/vm/intermediate_language.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 (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #ifndef VM_INTERMEDIATE_LANGUAGE_H_ 5 #ifndef VM_INTERMEDIATE_LANGUAGE_H_
6 #define VM_INTERMEDIATE_LANGUAGE_H_ 6 #define VM_INTERMEDIATE_LANGUAGE_H_
7 7
8 #include "vm/allocation.h" 8 #include "vm/allocation.h"
9 #include "vm/ast.h" 9 #include "vm/ast.h"
10 #include "vm/growable_array.h" 10 #include "vm/growable_array.h"
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after
228 M(InstantiateTypeArguments) \ 228 M(InstantiateTypeArguments) \
229 M(ExtractConstructorTypeArguments) \ 229 M(ExtractConstructorTypeArguments) \
230 M(ExtractConstructorInstantiator) \ 230 M(ExtractConstructorInstantiator) \
231 M(AllocateContext) \ 231 M(AllocateContext) \
232 M(ChainContext) \ 232 M(ChainContext) \
233 M(CloneContext) \ 233 M(CloneContext) \
234 M(CatchEntry) \ 234 M(CatchEntry) \
235 M(BinarySmiOp) \ 235 M(BinarySmiOp) \
236 M(BinaryMintOp) \ 236 M(BinaryMintOp) \
237 M(UnarySmiOp) \ 237 M(UnarySmiOp) \
238 M(NumberNegate) \
239 M(CheckStackOverflow) \ 238 M(CheckStackOverflow) \
240 M(DoubleToDouble) \ 239 M(DoubleToDouble) \
241 M(SmiToDouble) \ 240 M(SmiToDouble) \
242 M(CheckClass) \ 241 M(CheckClass) \
243 M(CheckSmi) \ 242 M(CheckSmi) \
244 M(Constant) \ 243 M(Constant) \
245 M(CheckEitherNonSmi) \ 244 M(CheckEitherNonSmi) \
246 M(UnboxedDoubleBinaryOp) \ 245 M(UnboxedDoubleBinaryOp) \
247 M(MathSqrt) \ 246 M(MathSqrt) \
248 M(UnboxDouble) \ 247 M(UnboxDouble) \
(...skipping 2988 matching lines...) Expand 10 before | Expand all | Expand 10 after
3237 virtual intptr_t ResultCid() const { return kSmiCid; } 3236 virtual intptr_t ResultCid() const { return kSmiCid; }
3238 3237
3239 private: 3238 private:
3240 const Token::Kind op_kind_; 3239 const Token::Kind op_kind_;
3241 InstanceCallInstr* instance_call_; 3240 InstanceCallInstr* instance_call_;
3242 3241
3243 DISALLOW_COPY_AND_ASSIGN(UnarySmiOpInstr); 3242 DISALLOW_COPY_AND_ASSIGN(UnarySmiOpInstr);
3244 }; 3243 };
3245 3244
3246 3245
3247 // Handles non-Smi NEGATE operations
3248 class NumberNegateInstr : public TemplateDefinition<1> {
3249 public:
3250 NumberNegateInstr(InstanceCallInstr* instance_call, Value* value)
3251 : instance_call_(instance_call) {
3252 ASSERT(value != NULL);
3253 inputs_[0] = value;
3254 }
3255
3256 Value* value() const { return inputs_[0]; }
3257
3258 InstanceCallInstr* instance_call() const { return instance_call_; }
3259
3260 const ICData* ic_data() const { return instance_call()->ic_data(); }
3261
3262 DECLARE_INSTRUCTION(NumberNegate)
3263 virtual RawAbstractType* CompileType() const;
3264
3265 virtual bool CanDeoptimize() const { return true; }
3266
3267 virtual bool HasSideEffect() const { return false; }
3268
3269 virtual intptr_t ResultCid() const { return kDoubleCid; }
3270
3271 private:
3272 InstanceCallInstr* instance_call_;
3273
3274 DISALLOW_COPY_AND_ASSIGN(NumberNegateInstr);
3275 };
3276
3277
3278 class CheckStackOverflowInstr : public TemplateDefinition<0> { 3246 class CheckStackOverflowInstr : public TemplateDefinition<0> {
3279 public: 3247 public:
3280 explicit CheckStackOverflowInstr(intptr_t token_pos) 3248 explicit CheckStackOverflowInstr(intptr_t token_pos)
3281 : token_pos_(token_pos) {} 3249 : token_pos_(token_pos) {}
3282 3250
3283 intptr_t token_pos() const { return token_pos_; } 3251 intptr_t token_pos() const { return token_pos_; }
3284 3252
3285 DECLARE_INSTRUCTION(CheckStackOverflow) 3253 DECLARE_INSTRUCTION(CheckStackOverflow)
3286 virtual RawAbstractType* CompileType() const; 3254 virtual RawAbstractType* CompileType() const;
3287 3255
(...skipping 353 matching lines...) Expand 10 before | Expand all | Expand 10 after
3641 ForwardInstructionIterator* current_iterator_; 3609 ForwardInstructionIterator* current_iterator_;
3642 3610
3643 private: 3611 private:
3644 DISALLOW_COPY_AND_ASSIGN(FlowGraphVisitor); 3612 DISALLOW_COPY_AND_ASSIGN(FlowGraphVisitor);
3645 }; 3613 };
3646 3614
3647 3615
3648 } // namespace dart 3616 } // namespace dart
3649 3617
3650 #endif // VM_INTERMEDIATE_LANGUAGE_H_ 3618 #endif // VM_INTERMEDIATE_LANGUAGE_H_
OLDNEW
« no previous file with comments | « runtime/vm/flow_graph_compiler_x64.cc ('k') | runtime/vm/intermediate_language.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698