| OLD | NEW |
| 1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 1933 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1944 default: | 1944 default: |
| 1945 UNREACHABLE(); | 1945 UNREACHABLE(); |
| 1946 return no_condition; | 1946 return no_condition; |
| 1947 } | 1947 } |
| 1948 } | 1948 } |
| 1949 | 1949 |
| 1950 | 1950 |
| 1951 void CompareIC::UpdateCaches(Handle<Object> x, Handle<Object> y) { | 1951 void CompareIC::UpdateCaches(Handle<Object> x, Handle<Object> y) { |
| 1952 HandleScope scope; | 1952 HandleScope scope; |
| 1953 Handle<Code> rewritten; | 1953 Handle<Code> rewritten; |
| 1954 #ifdef DEBUG | |
| 1955 State previous_state = GetState(); | 1954 State previous_state = GetState(); |
| 1956 #endif | 1955 State state = TargetState(previous_state, x, y); |
| 1957 State state = TargetState(x, y); | |
| 1958 if (state == GENERIC) { | 1956 if (state == GENERIC) { |
| 1959 CompareStub stub(GetCondition(), strict(), NO_COMPARE_FLAGS); | 1957 CompareStub stub(GetCondition(), strict(), NO_COMPARE_FLAGS); |
| 1960 rewritten = stub.GetCode(); | 1958 rewritten = stub.GetCode(); |
| 1961 } else { | 1959 } else { |
| 1962 ICCompareStub stub(op_, state); | 1960 ICCompareStub stub(op_, state); |
| 1963 rewritten = stub.GetCode(); | 1961 rewritten = stub.GetCode(); |
| 1964 } | 1962 } |
| 1965 set_target(*rewritten); | 1963 set_target(*rewritten); |
| 1966 | 1964 |
| 1967 #ifdef DEBUG | 1965 #ifdef DEBUG |
| 1968 if (FLAG_trace_ic) { | 1966 if (FLAG_trace_ic) { |
| 1969 PrintF("[CompareIC (%s->%s)#%s]\n", | 1967 PrintF("[CompareIC (%s->%s)#%s]\n", |
| 1970 GetStateName(previous_state), | 1968 GetStateName(previous_state), |
| 1971 GetStateName(state), | 1969 GetStateName(state), |
| 1972 Token::Name(op_)); | 1970 Token::Name(op_)); |
| 1973 } | 1971 } |
| 1974 #endif | 1972 #endif |
| 1975 } | 1973 } |
| 1976 | 1974 |
| 1975 void PatchInlinedSmiCode(Address address) { |
| 1976 UNIMPLEMENTED(); |
| 1977 } |
| 1978 |
| 1977 } } // namespace v8::internal | 1979 } } // namespace v8::internal |
| 1978 | 1980 |
| 1979 #endif // V8_TARGET_ARCH_X64 | 1981 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |