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

Side by Side Diff: src/x64/lithium-x64.h

Issue 7918012: Unify the handling of comparinsons against null and undefined. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 9 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
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 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 V(Goto) \ 100 V(Goto) \
101 V(HasCachedArrayIndexAndBranch) \ 101 V(HasCachedArrayIndexAndBranch) \
102 V(HasInstanceTypeAndBranch) \ 102 V(HasInstanceTypeAndBranch) \
103 V(In) \ 103 V(In) \
104 V(InstanceOf) \ 104 V(InstanceOf) \
105 V(InstanceOfKnownGlobal) \ 105 V(InstanceOfKnownGlobal) \
106 V(InstructionGap) \ 106 V(InstructionGap) \
107 V(Integer32ToDouble) \ 107 V(Integer32ToDouble) \
108 V(InvokeFunction) \ 108 V(InvokeFunction) \
109 V(IsConstructCallAndBranch) \ 109 V(IsConstructCallAndBranch) \
110 V(IsNullAndBranch) \ 110 V(IsNilAndBranch) \
111 V(IsObjectAndBranch) \ 111 V(IsObjectAndBranch) \
112 V(IsSmiAndBranch) \ 112 V(IsSmiAndBranch) \
113 V(IsUndetectableAndBranch) \ 113 V(IsUndetectableAndBranch) \
114 V(JSArrayLength) \ 114 V(JSArrayLength) \
115 V(Label) \ 115 V(Label) \
116 V(LazyBailout) \ 116 V(LazyBailout) \
117 V(LoadContextSlot) \ 117 V(LoadContextSlot) \
118 V(LoadElements) \ 118 V(LoadElements) \
119 V(LoadExternalArrayPointer) \ 119 V(LoadExternalArrayPointer) \
120 V(LoadFunctionPrototype) \ 120 V(LoadFunctionPrototype) \
(...skipping 481 matching lines...) Expand 10 before | Expand all | Expand 10 after
602 explicit LCmpConstantEqAndBranch(LOperand* left) { 602 explicit LCmpConstantEqAndBranch(LOperand* left) {
603 inputs_[0] = left; 603 inputs_[0] = left;
604 } 604 }
605 605
606 DECLARE_CONCRETE_INSTRUCTION(CmpConstantEqAndBranch, 606 DECLARE_CONCRETE_INSTRUCTION(CmpConstantEqAndBranch,
607 "cmp-constant-eq-and-branch") 607 "cmp-constant-eq-and-branch")
608 DECLARE_HYDROGEN_ACCESSOR(CompareConstantEqAndBranch) 608 DECLARE_HYDROGEN_ACCESSOR(CompareConstantEqAndBranch)
609 }; 609 };
610 610
611 611
612 class LIsNullAndBranch: public LControlInstruction<1, 1> { 612 class LIsNilAndBranch: public LControlInstruction<1, 1> {
613 public: 613 public:
614 LIsNullAndBranch(LOperand* value, LOperand* temp) { 614 LIsNilAndBranch(LOperand* value, LOperand* temp) {
615 inputs_[0] = value; 615 inputs_[0] = value;
616 temps_[0] = temp; 616 temps_[0] = temp;
617 } 617 }
618 618
619 DECLARE_CONCRETE_INSTRUCTION(IsNullAndBranch, "is-null-and-branch") 619 DECLARE_CONCRETE_INSTRUCTION(IsNilAndBranch, "is-nil-and-branch")
620 DECLARE_HYDROGEN_ACCESSOR(IsNullAndBranch) 620 DECLARE_HYDROGEN_ACCESSOR(IsNilAndBranch)
621 621
622 bool is_strict() const { return hydrogen()->is_strict(); } 622 EqualityKind kind() const { return hydrogen()->kind(); }
623 NilValue nil() const { return hydrogen()->nil(); }
623 624
624 virtual void PrintDataTo(StringStream* stream); 625 virtual void PrintDataTo(StringStream* stream);
625 }; 626 };
626 627
627 628
628 class LIsObjectAndBranch: public LControlInstruction<1, 0> { 629 class LIsObjectAndBranch: public LControlInstruction<1, 0> {
629 public: 630 public:
630 explicit LIsObjectAndBranch(LOperand* value) { 631 explicit LIsObjectAndBranch(LOperand* value) {
631 inputs_[0] = value; 632 inputs_[0] = value;
632 } 633 }
(...skipping 1540 matching lines...) Expand 10 before | Expand all | Expand 10 after
2173 2174
2174 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); 2175 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder);
2175 }; 2176 };
2176 2177
2177 #undef DECLARE_HYDROGEN_ACCESSOR 2178 #undef DECLARE_HYDROGEN_ACCESSOR
2178 #undef DECLARE_CONCRETE_INSTRUCTION 2179 #undef DECLARE_CONCRETE_INSTRUCTION
2179 2180
2180 } } // namespace v8::int 2181 } } // namespace v8::int
2181 2182
2182 #endif // V8_X64_LITHIUM_X64_H_ 2183 #endif // V8_X64_LITHIUM_X64_H_
OLDNEW
« src/v8.h ('K') | « src/x64/lithium-codegen-x64.cc ('k') | src/x64/lithium-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698