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

Side by Side Diff: src/hydrogen-instructions.h

Issue 6801050: Add ToBoolean-conversion of constants in Crankshaft and use it when generating a branch based on ... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 9 years, 8 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/arm/lithium-arm.cc ('k') | src/hydrogen-instructions.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 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 1943 matching lines...) Expand 10 before | Expand all | Expand 10 after
1954 ASSERT(HasInteger32Value()); 1954 ASSERT(HasInteger32Value());
1955 return int32_value_; 1955 return int32_value_;
1956 } 1956 }
1957 bool HasDoubleValue() const { return has_double_value_; } 1957 bool HasDoubleValue() const { return has_double_value_; }
1958 double DoubleValue() const { 1958 double DoubleValue() const {
1959 ASSERT(HasDoubleValue()); 1959 ASSERT(HasDoubleValue());
1960 return double_value_; 1960 return double_value_;
1961 } 1961 }
1962 bool HasStringValue() const { return handle_->IsString(); } 1962 bool HasStringValue() const { return handle_->IsString(); }
1963 1963
1964 bool ToBoolean() const;
1965
1964 virtual intptr_t Hashcode() { 1966 virtual intptr_t Hashcode() {
1965 ASSERT(!HEAP->allow_allocation(false)); 1967 ASSERT(!HEAP->allow_allocation(false));
1966 return reinterpret_cast<intptr_t>(*handle()); 1968 return reinterpret_cast<intptr_t>(*handle());
1967 } 1969 }
1968 1970
1969 #ifdef DEBUG 1971 #ifdef DEBUG
1970 virtual void Verify() { } 1972 virtual void Verify() { }
1971 #endif 1973 #endif
1972 1974
1973 DECLARE_CONCRETE_INSTRUCTION(Constant, "constant") 1975 DECLARE_CONCRETE_INSTRUCTION(Constant, "constant")
(...skipping 1674 matching lines...) Expand 10 before | Expand all | Expand 10 after
3648 HValue* object() { return left(); } 3650 HValue* object() { return left(); }
3649 HValue* key() { return right(); } 3651 HValue* key() { return right(); }
3650 }; 3652 };
3651 3653
3652 #undef DECLARE_INSTRUCTION 3654 #undef DECLARE_INSTRUCTION
3653 #undef DECLARE_CONCRETE_INSTRUCTION 3655 #undef DECLARE_CONCRETE_INSTRUCTION
3654 3656
3655 } } // namespace v8::internal 3657 } } // namespace v8::internal
3656 3658
3657 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ 3659 #endif // V8_HYDROGEN_INSTRUCTIONS_H_
OLDNEW
« no previous file with comments | « src/arm/lithium-arm.cc ('k') | src/hydrogen-instructions.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698