OLD | NEW |
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2008 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 753 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
764 sample->fp = reinterpret_cast<Address>(mcontext.gregs[R11]); | 764 sample->fp = reinterpret_cast<Address>(mcontext.gregs[R11]); |
765 #else | 765 #else |
766 sample->pc = reinterpret_cast<Address>(mcontext.arm_pc); | 766 sample->pc = reinterpret_cast<Address>(mcontext.arm_pc); |
767 sample->sp = reinterpret_cast<Address>(mcontext.arm_sp); | 767 sample->sp = reinterpret_cast<Address>(mcontext.arm_sp); |
768 sample->fp = reinterpret_cast<Address>(mcontext.arm_fp); | 768 sample->fp = reinterpret_cast<Address>(mcontext.arm_fp); |
769 #endif | 769 #endif |
770 #elif V8_HOST_ARCH_MIPS | 770 #elif V8_HOST_ARCH_MIPS |
771 // Implement this on MIPS. | 771 // Implement this on MIPS. |
772 UNIMPLEMENTED(); | 772 UNIMPLEMENTED(); |
773 #endif | 773 #endif |
774 #ifdef ENABLE_CPP_PROFILES_PROCESSOR | |
775 active_sampler_->SampleStack(sample); | |
776 #else | |
777 if (IsVmThread()) { | 774 if (IsVmThread()) { |
778 active_sampler_->SampleStack(sample); | 775 active_sampler_->SampleStack(sample); |
779 } | 776 } |
780 #endif | |
781 } | 777 } |
782 } | 778 } |
783 #ifndef ENABLE_CPP_PROFILES_PROCESSOR | 779 #ifndef ENABLE_CPP_PROFILES_PROCESSOR |
784 active_sampler_->Tick(sample); | 780 active_sampler_->Tick(sample); |
785 #endif | 781 #endif |
786 #endif | 782 #endif |
787 } | 783 } |
788 | 784 |
789 | 785 |
790 class Sampler::PlatformData : public Malloced { | 786 class Sampler::PlatformData : public Malloced { |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
849 | 845 |
850 // This sampler is no longer the active sampler. | 846 // This sampler is no longer the active sampler. |
851 active_sampler_ = NULL; | 847 active_sampler_ = NULL; |
852 active_ = false; | 848 active_ = false; |
853 } | 849 } |
854 | 850 |
855 | 851 |
856 #endif // ENABLE_LOGGING_AND_PROFILING | 852 #endif // ENABLE_LOGGING_AND_PROFILING |
857 | 853 |
858 } } // namespace v8::internal | 854 } } // namespace v8::internal |
OLD | NEW |