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

Side by Side Diff: src/assembler.cc

Issue 6170001: Direct call api functions (arm implementation) (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 9 years, 11 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 (c) 1994-2006 Sun Microsystems Inc. 1 // Copyright (c) 1994-2006 Sun Microsystems Inc.
2 // All Rights Reserved. 2 // All Rights Reserved.
3 // 3 //
4 // Redistribution and use in source and binary forms, with or without 4 // Redistribution and use in source and binary forms, with or without
5 // modification, are permitted provided that the following conditions are 5 // modification, are permitted provided that the following conditions are
6 // met: 6 // met:
7 // 7 //
8 // - Redistributions of source code must retain the above copyright notice, 8 // - Redistributions of source code must retain the above copyright notice,
9 // this list of conditions and the following disclaimer. 9 // this list of conditions and the following disclaimer.
10 // 10 //
(...skipping 534 matching lines...) Expand 10 before | Expand all | Expand 10 after
545 #endif // DEBUG 545 #endif // DEBUG
546 546
547 547
548 // ----------------------------------------------------------------------------- 548 // -----------------------------------------------------------------------------
549 // Implementation of ExternalReference 549 // Implementation of ExternalReference
550 550
551 ExternalReference::ExternalReference(Builtins::CFunctionId id) 551 ExternalReference::ExternalReference(Builtins::CFunctionId id)
552 : address_(Redirect(Builtins::c_function_address(id))) {} 552 : address_(Redirect(Builtins::c_function_address(id))) {}
553 553
554 554
555 ExternalReference::ExternalReference(ApiFunction* fun) 555 ExternalReference::ExternalReference(
556 : address_(Redirect(fun->address())) {} 556 ApiFunction* fun, Type type = ExternalReference::BUILTIN_CALL)
557 : address_(Redirect(fun->address(), type)) {}
557 558
558 559
559 ExternalReference::ExternalReference(Builtins::Name name) 560 ExternalReference::ExternalReference(Builtins::Name name)
560 : address_(Builtins::builtin_address(name)) {} 561 : address_(Builtins::builtin_address(name)) {}
561 562
562 563
563 ExternalReference::ExternalReference(Runtime::FunctionId id) 564 ExternalReference::ExternalReference(Runtime::FunctionId id)
564 : address_(Redirect(Runtime::FunctionForId(id)->entry)) {} 565 : address_(Redirect(Runtime::FunctionForId(id)->entry)) {}
565 566
566 567
(...skipping 307 matching lines...) Expand 10 before | Expand all | Expand 10 after
874 case Token::DIV: 875 case Token::DIV:
875 function = &div_two_doubles; 876 function = &div_two_doubles;
876 break; 877 break;
877 case Token::MOD: 878 case Token::MOD:
878 function = &mod_two_doubles; 879 function = &mod_two_doubles;
879 break; 880 break;
880 default: 881 default:
881 UNREACHABLE(); 882 UNREACHABLE();
882 } 883 }
883 // Passing true as 2nd parameter indicates that they return an fp value. 884 // Passing true as 2nd parameter indicates that they return an fp value.
884 return ExternalReference(Redirect(FUNCTION_ADDR(function), true)); 885 return ExternalReference(Redirect(FUNCTION_ADDR(function), FP_RETURN_CALL));
885 } 886 }
886 887
887 888
888 ExternalReference ExternalReference::compare_doubles() { 889 ExternalReference ExternalReference::compare_doubles() {
889 return ExternalReference(Redirect(FUNCTION_ADDR(native_compare_doubles), 890 return ExternalReference(Redirect(FUNCTION_ADDR(native_compare_doubles),
890 false)); 891 BUILTIN_CALL));
891 } 892 }
892 893
893 894
895 ExternalReference::
894 ExternalReferenceRedirector* ExternalReference::redirector_ = NULL; 896 ExternalReferenceRedirector* ExternalReference::redirector_ = NULL;
895 897
896 898
897 #ifdef ENABLE_DEBUGGER_SUPPORT 899 #ifdef ENABLE_DEBUGGER_SUPPORT
898 ExternalReference ExternalReference::debug_break() { 900 ExternalReference ExternalReference::debug_break() {
899 return ExternalReference(Redirect(FUNCTION_ADDR(Debug::Break))); 901 return ExternalReference(Redirect(FUNCTION_ADDR(Debug::Break)));
900 } 902 }
901 903
902 904
903 ExternalReference ExternalReference::debug_step_in_fp_address() { 905 ExternalReference ExternalReference::debug_step_in_fp_address() {
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
941 assembler_->RecordRelocInfo(RelocInfo::POSITION, state_.current_position); 943 assembler_->RecordRelocInfo(RelocInfo::POSITION, state_.current_position);
942 state_.written_position = state_.current_position; 944 state_.written_position = state_.current_position;
943 written = true; 945 written = true;
944 } 946 }
945 947
946 // Return whether something was written. 948 // Return whether something was written.
947 return written; 949 return written;
948 } 950 }
949 951
950 } } // namespace v8::internal 952 } } // namespace v8::internal
OLDNEW
« src/arm/stub-cache-arm.cc ('K') | « src/assembler.h ('k') | src/code-stubs.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698